maximum

ivy.maximum(x: ivy.NativeArray, y: ivy.NativeArray, f: Optional[ivy.Framework] = None) → ivy.NativeArray[source]

Returns the max of x and y (i.e. x > y ? x : y) element-wise.

Parameters
  • x (array) – Input array containing elements to maximum threshold.

  • y (array) – Tensor containing maximum values, must be broadcastable to x.

  • f (ml_framework, optional) – Machine learning framework. Inferred from inputs if None.

Returns

An array with the elements of x, but clipped to not be lower than the y values.


Supported Frameworks:

empty jax_logo empty tf_logo empty pytorch_logo empty mxnet_logo empty numpy_logo empty