oneflow.gt

oneflow.gt()

Returns the truth value of \(input > other\) element-wise.

Parameters
Returns

A Tensor with bool type.

Return type

oneflow.Tensor

For example:

>>> import numpy as np
>>> import oneflow as flow

>>> input1 = flow.tensor(np.random.randn(2, 6, 5, 3), dtype=flow.float32)
>>> input2 = flow.tensor(np.random.randn(2, 6, 5, 3), dtype=flow.float32)

>>> out = flow.gt(input1, input2).shape
>>> out
oneflow.Size([2, 6, 5, 3])