log2#
- class brainunit.math.log2(x, unit_to_scale=None, **kwargs)#
Base-2 logarithm, element-wise.
- Parameters:
- Returns:
out – Element-wise base-2 logarithm.
- Return type:
Array
Examples
>>> import saiunit as u >>> import jax.numpy as jnp >>> u.math.log2(jnp.array([1.0, 2.0, 4.0])) Array([0., 1., 2.], dtype=float32)