Repository navigation
feat: analyses default to setup="auto"; explicit use_jax opts out (R6) - #760
Merged
Merged
Conversation
Part of #759. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This was referenced Nov 26, 2026
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
Closes #759 together with the PyAutoArray, PyAutoFit, PyAutoLens and autolens_workspace_test PRs on branch
feature/likelihood-lifecycle-r6-default-auto. Merge order: Array → Fit → Galaxy → Lens → autolens_workspace_test.setup="auto"is the default forag.AnalysisImaging/ag.AnalysisInterferometer(viaAnalysisDataset). Precedence (setup_util.setup_and_use_jax_from):setuppassed → used as given (setup=Noneis the manual opt-out); elseuse_jaxpassed explicitly → manual opt-out (today's behaviour plus the "would choose" banner); elsesetup="auto".use_jaxnow defaults toNone.SETUP_DEFAULT, astrequal to"auto"told apart by identity), so an explicitsetup="auto"and the default behave the same but the guard can tell them apart."auto"cannot choose a setup, the fit logs a warning and runs with the constructor backend instead of failing (an explicitsetup="auto"still raises).dataset.apply_setup(setup)(the build lives in PyAutoArray), so no further slimming was needed.API Changes
AnalysisImaging/AnalysisInterferometer:use_jax: Optional[bool] = None,setupdefaults to"auto"; explicituse_jaxwith nosetupopts out of auto. Newsetup_util.SETUP_DEFAULT,setup_util.setup_and_use_jax_from.See full details below.
Test Plan
pyauto-heart smoke --affected-by PyAutoFitagainst the task worktree: 7/8 workspaces; the one failing script (autolens_workspace_testjax_assertions/fit_interferometer_sparse_operator.py) encodes the old lazy-off default and is fixed by the companion autolens_workspace_test PR (passes against this branch)setup="auto"with the "Automatic compute setup" banner; explicituse_jax=False/setup=Noneopt out; pickling keeps the default; lazy default on numpy pixelized fitsFull API Changes (for automation & release notes)
Added
autogalaxy.analysis.setup_util.SETUP_DEFAULT,setup_and_use_jax_from(setup, use_jax, default_use_jax).Changed
ag.AnalysisImaging(dataset, use_jax=None, setup="auto", ...),ag.AnalysisInterferometer(...)likewise.AnalysisSetupMixin._init_setup(setup, setup_defaulted=False);resolve_setupfalls back to the constructor backend with a warning when the defaulted auto cannot choose.Migration
ag.AnalysisImaging(dataset=dataset, use_jax=True)(orsetup=None).Generated by the PyAutoLabs agent workflow.
🤖 Generated with Claude Code