dpnp.log2

dpnp.log2(x1)[source]

Trigonometric logarithm, element-wise.

For full documentation refer to numpy.log2.

Limitations

Input array is supported as dpnp.ndarray. Input array data types are limited by supported DPNP Data types.

See also

dpnp.log

Natural logarithm, element-wise.

dpnp.log10

Return the base 10 logarithm of the input array, element-wise.

dpnp.log1p

Return the natural logarithm of one plus the input array, element-wise.

Examples

>>> import dpnp as np
>>> x = np.array([0, 1, 2, 2**4])
>>> out = np.log2(x)
>>> [i for i in out]
[-inf, 0.0, 1.0, 4.0]