Skip to content

Commit

Permalink
In jnp.reshape, use shape rather than deprecated newshape. The `n…
Browse files Browse the repository at this point in the history
…ewshape` parameter was deprecated in JAX v0.4.28, and will soon be removed.

PiperOrigin-RevId: 694193311
  • Loading branch information
Jake VanderPlas authored and PIXDev committed Nov 8, 2024
1 parent b76b0b6 commit f7a7c99
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion dm_pix/_src/augment.py
Original file line number Diff line number Diff line change
Expand Up @@ -715,7 +715,7 @@ def affine_transform(

# Alter coordinates to account for offset.
offset = jnp.full((3,), fill_value=offset)
coordinates += jnp.reshape(a=offset, newshape=(*offset.shape, 1, 1, 1))
coordinates += jnp.reshape(a=offset, shape=(*offset.shape, 1, 1, 1))

interpolate_function = _get_interpolate_function(
mode=mode,
Expand Down

0 comments on commit f7a7c99

Please sign in to comment.