fix: pin tfp-nightly for JAX Matern-kernel path (tfp 0.25.0 × jax 0.10.2 crash)#386
Merged
Merged
Conversation
… 0.10.2 crash) The last stable tensorflow-probability (0.25.0) references jax.interpreters.xla.pytype_aval_mappings, removed from modern JAX, so it crashes at import under the resolved jax>=0.7 stack — breaking every Matern-kernel pixelization on the JAX backend (release-validation run 29266305445). Swap the pin to tfp-nightly==0.26.0.dev20260713 (verified to compute bessel_kve on jax 0.10.2) and correct the kv_xp docstring/ImportError. Fixes #385 Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01TDCsgNCXacXqiWAPTswWCt
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
The JAX Matern-kernel regularization path crashed at import for every user on the release-resolved stack.
autoarray/inversion/regularization/matern_kernel.py(kv_xp) importstensorflow_probability.substrates.jaxforbessel_kve; the last stable tfp (0.25.0) referencesjax.interpreters.xla.pytype_aval_mappings, removed from modern JAX, soimportcrashes underjax 0.10.2. Surfaced by release-validation run29266305445(TestPyPI2026.7.13.1.dev65501).Fix
pyproject.toml(optionalextra):tensorflow-probability==0.25.0→tfp-nightly==0.26.0.dev20260713. No stable tfp is compatible (0.25.0 is the latest); the nightly restores modern-JAX support and installs via an explicit==pin (no--pre). Import name is unchanged, somatern_kernel.pyneeds no code edit.matern_kernel.py: corrected thekv_xpdocstring (it advertised a non-existentjax.scipy.special.kvfast-path) and pointed theImportErrorattfp-nightly. No behaviour change.Why not the alternatives
pytype_aval_mappingsis gone by jax 0.9.2 andautoconf[jax]floorsjax>=0.7.jax.scipy.specialhas nokv/kve, andnuis a continuous free prior, so no closed-form shortcut. Vendoring tfp'sbessel_kveis the durable fix, filed as a follow-up.Verification
jax 0.10.2+tfp 0.25.0); confirmedtfp-nightlycomputesbessel_kve(0.5,1.0)=1.2533onjax 0.10.2.autogalaxy_workspace_testPR): np-vs-JAX Matern regularization matrix atnu=0.5andnu=1.7, jitted → passes.pytest test_autoarray/→ 897 passed.API Changes
None — public surface unchanged.
Fixes #385
🤖 Generated with Claude Code
https://claude.ai/code/session_01TDCsgNCXacXqiWAPTswWCt