pyarrow.compute.log2

pyarrow.compute.log2(x, *, memory_pool=None)

Compute log base 2 of arguments element-wise.

Non-positive values return -inf or NaN. Null values return null. Use function “log2_checked” if you want non-positive values to raise an error.

Parameters
  • x (Array-like or scalar-like) – Argument to compute function

  • memory_pool (pyarrow.MemoryPool, optional) – If not passed, will allocate memory from the default memory pool.