Skip to content

fix: avoid redundant Nautilus completion pass #1651

Description

@Jammy2211

Overview

Nautilus factor searches that converge in their first call still trigger an intermediate result update and a second no-op sampler call. Remove this overhead, following the completed Dynesty EP optimisation in #1642.

Plan

  • Recognize convergence immediately while preserving finite-budget updates.
  • Cover convergence, chunked execution and likelihood limits with regression tests.
  • Compare sampler/update calls, seeded results and timing, then run the full PyAutoFit suite serially.

Detailed implementation plan

  • Repository: PyAutoFit; clean main, no competing claim. Existing hook-maintenance branch does not overlap.
  • Branch: feature/ep-nautilus-single-pass.
  • Inspect the installed Nautilus run completion contract and likelihood counter before selecting the completion condition.
  • Update autofit/non_linear/search/nest/nautilus/search.py (Nautilus.call_search, and budget handling if required). Do not infer likelihood budget exhaustion from posterior sample counts.
  • Extend test_autofit/non_linear/search/nest/test_nautilus.py with converged and finite-cadence cases, global limits and a seeded real-search comparison. No public API change intended.
  • Validate targeted tests and full serial test_autofit; measure overhead without changing sampler settings or EP mathematics.

Original user request

We have begun a task speeding up the PyAutoFit source code to make EP run faster without PyautoFit overheads, continue this task

The human approved this bounded follow-up after explanation: “ok, do it.”

Existing prompt

PyAutoMind/draft/bug/autofit/nautilus_converged_run_double_pass.md records the redundant completion pass and the requirement to preserve finite-cadence sampling.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions