jax.numpy.logical_and — JAX documentation (original) (raw)
jax.numpy.logical_and#
jax.numpy.logical_and = <jnp.ufunc 'logical_and'>#
Compute the logical AND operation elementwise.
JAX implementation of numpy.logical_and. This is a universal function, and supports the additional APIs described at jax.numpy.ufunc.
Parameters:
- x – input arrays. Must be broadcastable to a common shape.
- y – input arrays. Must be broadcastable to a common shape.
- args (ArrayLike)
- out (None)
- where (None)
Returns:
Array containing the result of the element-wise logical AND.
Return type:
Any
Examples
x = jnp.arange(4) jnp.logical_and(x, 1) Array([False, True, True, True], dtype=bool)