jax.numpy.modfΒΆ

jax.numpy.modf(x, out=None)[source]ΒΆ

Return the fractional and integral parts of an array, element-wise.

LAX-backend implementation of modf().

Original docstring below.

The fractional and integral parts are negative if the given number is negative.

Parameters

x (array_like) – Input array.

Returns

  • y1 (ndarray) – Fractional part of x. This is a scalar if x is a scalar.

  • y2 (ndarray) – Integral part of x. This is a scalar if x is a scalar.