mindspore.ops.sqrt
- mindspore.ops.sqrt(x)[source]
Return sqrt of a tensor element-wise.
- Parameters
x (Tensor) – The input tensor.
- Returns
Tensor
- Supported Platforms:
Ascend
GPU
CPU
Examples
>>> import mindspore >>> x = mindspore.tensor([1.0, 4.0, 9.0], mindspore.float32) >>> output = mindspore.ops.sqrt(x) >>> print(output) [1. 2. 3.]