mindspore/docs/api/api_python/ops/mindspore.ops.func_trunc.rst

16 lines
391 B
ReStructuredText
Raw Normal View History

mindspore.ops.trunc
===================
2022-11-04 10:40:03 +08:00
.. py:function:: mindspore.ops.trunc(input)
2022-12-29 16:33:21 +08:00
返回一个新的Tensor该Tensor具有输入元素的截断整数值。
2022-07-28 11:58:35 +08:00
参数:
2022-11-04 10:40:03 +08:00
- **input** (Tensor) - 任意维度的Tensor。
2022-07-28 11:58:35 +08:00
返回:
2022-11-04 10:40:03 +08:00
Tensorshape和数据类型与 `input` 相同。
2022-07-28 11:58:35 +08:00
异常:
2022-11-04 10:40:03 +08:00
- **TypeError** - `input` 不是Tensor。