Movatterモバイル変換


[0]ホーム

URL:


Skip to main content
Ctrl+K
JAX  documentation - Home

jax.numpy.modf

Contents

jax.numpy.modf#

jax.numpy.modf(x,/,out=None)[source]#

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

JAX implementation ofnumpy.modf.

Parameters:
  • x (ArrayLike) – input array or scalar.

  • out – Not used by JAX.

Returns:

An array containing the fractional and integral parts of the elements ofx,promoting dtypes inexact.

Return type:

tuple[Array,Array]

See also

Examples

>>>jnp.modf(4.8)(Array(0.8000002, dtype=float32, weak_type=True), Array(4., dtype=float32, weak_type=True))>>>x=jnp.array([-3.4,-5.7,0.6,1.5,2.3])>>>jnp.modf(x)(Array([-0.4000001 , -0.6999998 ,  0.6       ,  0.5       ,  0.29999995],      dtype=float32), Array([-3., -5.,  0.,  1.,  2.], dtype=float32))
Contents

[8]ページ先頭

©2009-2025 Movatter.jp