mindspore.Tensor.ceil
- mindspore.Tensor.ceil()
详情请参考
mindspore.ops.ceil()
。- 支持平台:
Ascend
GPU
CPU
样例:
>>> import mindspore >>> import numpy as np >>> from mindspore import Tensor >>> input = Tensor(np.array([1.1, 2.5, -1.5]), mindspore.float32) >>> output = input.ceil() >>> print(output) [ 2. 3. -1.] >>> input = Tensor(2.1, mindspore.float32) >>> output = input.ceil() >>> print(output) 3.0