blosc2.log10#
- blosc2.log10(ndarr: NDArray | NDField | C2Array | LazyExpr, /) LazyExpr #
Return the base 10 logarithm of the input array, element-wise.
- Parameters:
ndarr¶ (NDArray or NDField or C2Array or LazyExpr) – The input array.
- Returns:
out – A lazy expression representing the base 10 logarithm of the input array.
- Return type:
References
Examples
>>> import numpy as np >>> import blosc2 >>> values = np.array([1, 10, 100, 1000, 10000]) >>> ndarray = blosc2.asarray(values) >>> result_lazy = blosc2.log10(ndarray) >>> result = result_lazy[:] >>> print("Original values:", values) Original values: [ 1 10 100 1000 10000] >>> print("Logarithm (base 10):", result) Logarithm (base 10): [0. 1. 2. 3. 4.]