mindspore.ops.Eps
- class mindspore.ops.Eps[source]
Create a Tensor with the same data type and shape as input, and the element value is the minimum value that the corresponding data type can express.
Refer to
mindspore.ops.eps()for more detail.- Inputs:
x (Tensor) - Tensor of any dimension used to obtain the minimum value that its data type can express. The data type must be float16, float32 or float64.
- Outputs:
Tensor, has the same type and shape as x, but filled with x dtype minimum val.
- Raises
- Supported Platforms:
AscendGPUCPU
Examples
>>> import mindspore >>> from mindspore import Tensor, ops >>> x = Tensor([4, 1, 2, 3], mindspore.float32) >>> output = ops.Eps()(x) >>> print(output) [1.1920929e-07 1.1920929e-07 1.1920929e-07 1.1920929e-07]