mindspore/docs/api/api_python/ops/mindspore.ops.func_ge.rst

28 lines
1018 B
ReStructuredText
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

mindspore.ops.ge
===========================
.. py:function:: mindspore.ops.ge(input, other)
逐元素计算 :math:`input >= other` 的值。
.. note::
- 支持隐式类型转换。
- 输入必须是两个Tensor或一个Tensor和一个Scalar。
- 当输入是两个Tensor时它们的数据类型不能同时是bool并保证其shape可以广播。
- 当输入是一个Tensor和一个Scalar时Scalar只能是一个常数。
- 支持广播。
- 若输入的Tensor可以广播则会把低维度通过复制该维度的值的方式扩展到另一个输入中对应的高维度。
.. math::
out_{i} =\begin{cases}
& \text{True, if } input_{i}>=other_{i} \\
& \text{False, if } input_{i}<other_{i}
\end{cases}
参数:
- **input** (Union[Tensor, Number, bool]) - 第一个输入。
- **other** (Union[Tensor, Number, bool]) - 第二个输入。
返回:
Tensor