Design
Specification
API
API Mapping
Migration Guide
FAQ
RELEASE NOTES
Return absolute value element-wisely.
Tensor.
Ascend GPU CPU
Ascend
GPU
CPU
Examples
>>> from mindspore import Tensor >>> a = Tensor([1.1, -2.1]).astype("float32") >>> output = a.abs() >>> print(output) [1.1 2.1]