docs(searches): add multi-start gradient searches to the MLE example#95
Merged
Merged
Conversation
Document af.MultiStartAdam (with MultiStartADABelief / MultiStartLion as drop-in alternatives) in scripts/searches/mle.py: a JAX/optax multi-start first-order gradient MAP optimizer run on the 1D Gaussian with a use_jax=True analysis, with the standard fit plot. No pytree registration is needed — the search builds each instance inside its own traced objective, so the model never crosses a jax.jit boundary. Regenerate the paired notebook. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
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
Phase 2 of the multi-start gradient MAP search promotion (PyAutoFit#1369; library merged in Fit#1370, JAX validation in autofit_workspace_test#43). Adds a Search: MultiStartAdam section to
scripts/searches/mle.pydocumenting the newaf.MultiStartAdamsearch (withMultiStartADABelief/MultiStartLionnoted as drop-in optax-rule alternatives), run on the shared 1D Gaussian with ause_jax=Trueanalysis and the standard fit plot. Updates the module header/contents/links and regenerates the pairednotebooks/searches/mle.ipynb.(The original "config + packaged defaults" phase was dropped — PyAutoFit searches have no per-search config and the new searches add zero config keys.)
Test Plan
python scripts/searches/mle.pyruns end-to-end (Drawer + LBFGS + MultiStartAdam); MultiStartAdam recovers the truth basin (centre=50.20, normalization=25.22, sigma=10.03) on jax 0.10.2 + optax 0.2.5py_to_notebook+ colab-injection transform; diff scoped tomle.py+mle.ipynbNotes
MultiStartAdambuilds each model instance inside its traced objective from a plain parameter vector, so (unlikeNautilus_jax) the model never crosses ajax.jitboundary. Verified it runs identically withoutenable_pytrees/register_model.Generated by the PyAutoLabs agent workflow.