mindspore.mint.isneginf

查看源文件
mindspore.mint.isneginf(input)[源代码]

逐元素返回输入tensor中元素是否是负无穷数。

警告

  • 该API目前只支持在Atlas A2训练系列产品上使用。

参数:
  • input (Tensor) - 输入tensor。

返回:

Tensor

支持平台:

Ascend

样例:

>>> import mindspore
>>> output = mindspore.mint.isneginf(mindspore.tensor([[-float("inf"), float("inf")], [1, -float("inf")]], dtype=mindspore.float32))
>>> print(output)
[[ True False]
 [False  True]]