searches: preserve the NSS sampler for re-mainlining#20
Merged
Conversation
Parks the af.NSS nested slice sampler (removed from PyAutoFit in #1356) alongside the ultranest/pyswarms parked samplers. Module imports relativized as a drop-in; tests kept verbatim against the library paths; README captures the pinned blackjax/nss install recipe and a re-mainline checklist for when nss ships on PyPI. Issue: PyAutoFit#1356 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.
Preserves the
af.NSSnested slice sampler — removed from PyAutoFit in PyAutoLabs/PyAutoFit#1357 — so it can be re-mainlined cheaply oncenssships as a genuine PyPI package.Part of PyAutoLabs/PyAutoFit#1356.
What's added —
searches/nss/Sits alongside the existing parked samplers (
ultranest/,pyswarms/), same "previously bundled with PyAutoFit, kept as a drop-in" convention:search.py/samples.py/_chunked_nss.py/_chunked_update.py— the sampler, with intra-package imports relativized so it imports both here (from searches.nss import NSS, verified) and verbatim if dropped back into the library.tests/—test_search.py+test_checkpoint.py, kept verbatim against the library import paths (incl.mock.patchtargets), so they run unchanged when restored totest_autofit/…/nss/.README.md— the reuse recipe: the pinnedhandley-lab/blackjax@ef45acd2+yallup/nss@69159b0fSHAs, why it couldn't be a plain wheel extra, theuse_jax=Truerequirement, kwarg defaults, and a step-by-step re-mainline checklist.example.py— runnable usage demo.Pure addition — imports nothing new into any shipped path; not wired into CI.
🤖 Generated with Claude Code
https://claude.ai/code/session_01Y9eyGoEAUHGSqcmJpzzjsi