diff --git a/CHANGELOG.md b/CHANGELOG.md index fdaa253d1649..c0228ac63ed9 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -27,6 +27,11 @@ When releasing, please add the new-release-boilerplate to docs/pallas/CHANGELOG. * `JAX_CPU_COLLECTIVES_IMPLEMENTATION` and `JAX_NUM_CPU_DEVICES` now work as env vars. Before they could only be specified via jax.config or flags. +* Deprecations + * Several previously-deprecated APIs have been removed, including: + * From `jax.lib.xla_client`: `FftType`, `PaddingType`, `dtype_to_etype`, + and `shape_from_pyval`. + ## jax 0.5.0 (Jan 17, 2025) As of this release, JAX now uses diff --git a/jax/lib/xla_client.py b/jax/lib/xla_client.py index 86e7307c804b..405b800cd153 100644 --- a/jax/lib/xla_client.py +++ b/jax/lib/xla_client.py @@ -12,7 +12,6 @@ # See the License for the specific language governing permissions and # limitations under the License. -from jax._src.lax.fft import FftType as _FftType from jax._src.lib import xla_client as _xc get_topology_for_devices = _xc.get_topology_for_devices @@ -48,23 +47,27 @@ ), None, ), - # Added Oct 10 2024 + # Finalized 2024-02-03; remove after 2025-05-03 "FftType": ( - "jax.lib.xla_client.FftType is deprecated; use jax.lax.FftType.", - _FftType, + "jax.lib.xla_client.FftType was removed in JAX v0.5.1; use jax.lax.FftType.", + None, ), "PaddingType": ( ( - "jax.lib.xla_client.PaddingType is deprecated; this type is unused" - " by JAX so there is no replacement." + "jax.lib.xla_client.PaddingType was removed in JAX v0.5.1;" + " this type is unused by JAX so there is no replacement." ), - _xc.PaddingType, + None, ), - # Added Oct 11 2024 "dtype_to_etype": ( - "dtype_to_etype is deprecated; use StableHLO instead.", - _xc.dtype_to_etype, + "dtype_to_etype was removed in JAX v0.5.1; use StableHLO instead.", + None, + ), + "shape_from_pyval": ( + "shape_from_pyval was removed in JAX v0.5.1; use StableHLO instead.", + None, ), + # Added Oct 11 2024 "ops": ( "ops is deprecated; use StableHLO instead.", _xc.ops, @@ -74,10 +77,6 @@ "(https://jax.readthedocs.io/en/latest/ffi.html)", _xc.register_custom_call_target, ), - "shape_from_pyval": ( - "shape_from_pyval is deprecated; use StableHLO instead.", - _xc.shape_from_pyval, - ), "PrimitiveType": ( "PrimitiveType is deprecated; use StableHLO instead.", _xc.PrimitiveType, @@ -104,14 +103,10 @@ import typing as _typing if _typing.TYPE_CHECKING: - dtype_to_etype = _xc.dtype_to_etype ops = _xc.ops register_custom_call_target = _xc.register_custom_call_target - shape_from_pyval = _xc.shape_from_pyval ArrayImpl = _xc.ArrayImpl Device = _xc.Device - FftType = _FftType - PaddingType = _xc.PaddingType PrimitiveType = _xc.PrimitiveType Shape = _xc.Shape XlaBuilder = _xc.XlaBuilder @@ -123,5 +118,4 @@ __getattr__ = _deprecation_getattr(__name__, _deprecations) del _deprecation_getattr del _typing -del _FftType del _xc