ge

Contents

ge#

class brainunit.lax.ge(x, y)#

Elementwise greater-than-or-equals: \(x \geq y\).

Parameters:
  • x (saiunit.Quantity | Array | ndarray | bool | number | bool | int | float | complex) – First operand.

  • y (saiunit.Quantity | Array | ndarray | bool | number | bool | int | float | complex) – Second operand. Must have the same unit as x.

Returns:

result – Boolean array. Always unitless.

Return type:

bool | Array

Examples

>>> import saiunit as u
>>> import saiunit.lax as sulax
>>> import jax.numpy as jnp
>>> a = jnp.array([1.0, 3.0, 2.0]) * u.second
>>> b = jnp.array([2.0, 2.0, 2.0]) * u.second
>>> sulax.ge(a, b)
Array([False,  True,  True], dtype=bool)