Skip to content

docs(graphical): analytic_autofit — errors_at_sigma instance path usable again (PyAutoFit#1577) - #99

Merged
Jammy2211 merged 1 commit into
mainfrom
feature/samples-errors-at-sigma-instance
Sep 8, 2026
Merged

Jammy2211 merged 1 commit into
mainfrom
feature/samples-errors-at-sigma-instance

Conversation

@Jammy2211

Copy link
Copy Markdown
Collaborator

Summary

The module docstring of scripts/graphical/analytic_autofit.py said
errors_at_sigma(as_instance=True) could not be used on the hierarchical global
model at all, because building the instance calls
GaussianPrior(mean=(lower, upper), ...) for the distribution_model and raises
inside NormalMessage. PyAutoFit#1578 fixes that, so the claim is now false.

The read itself stays as_instance=False: read_joint_posteriors already indexes
the sample columns positionally through model.prior_tuples_ordered_by_id, so the
flat vector is the like-for-like shape for the positional weighted-moment
comparison the script performs. The docstring now says that, instead of claiming
the instance path is broken. No code change.

D6 link chain: autofit_workspace_test#91 (finding D6) → PyAutoFit#1577 (issue) →
PyAutoFit#1578 (library fix).

Scripts Changed

  • scripts/graphical/analytic_autofit.py — module docstring only (lines ~54-57); no code change

Upstream PR

PyAutoLabs/PyAutoFit#1578 — library-first: merge only after it

Test Plan

  • scripts/graphical/analytic_gaussian_collapse.py referee: RECOVER 5/5, BIASED-TIGHT 0/5, PATHOLOGICAL 0/5, STALE 0/5, COLLAPSE CONFIG PASS 5/5
  • Smoke gate .github/scripts/run_smoke.py: 14/14 PASS
  • scripts/graphical/analytic_gaussian.py (parked NEEDS_FIX) before/after: every closed-form, minimal-EP and autofit-EP cell byte-identical; PARITY FAIL 38/41 both before and after, with the same three autofit-EP failures (leg-B sigma a=0.973 b=0.237, x_2 a=0.190, x_4 a=0.180 — the known Laplace-on-scatter caveat)
  • The [info] graphical median_pdf +/- mean|errors_at_sigma(1)| lines drift between runs because run_joint_fit runs an unseeded DynestyStatic; a control run on the identical edited tree drifted by the same magnitude (and once read 37/41 via x_1 graphical a=0.101 against a 0.10 tolerance). Filed as a PyAutoMind draft (draft/bug/graphical_ep/analytic_gaussian_unseeded_graphical_column.md) — not a regression from this PR.

Generated by the PyAutoLabs agent workflow.

🤖 Generated with Claude Code

https://claude.ai/code/session_01E2HKd5ZocDmTyZ544eVEh4

… is usable again

The module docstring said errors_at_sigma(as_instance=True) could not be
used on the hierarchical global model because building the instance
raised inside NormalMessage. PyAutoFit#1578 fixes that (finding D6 of
autofit_workspace_test#91). The read stays as_instance=False because
read_joint_posteriors already indexes the sample columns positionally
through prior_tuples_ordered_by_id, so the flat vector is the
like-for-like shape; the docstring now says so instead of claiming the
instance path is broken. No code change: referee RECOVER 5/5, smoke gate
14/14, every deterministic analytic_gaussian.py cell byte-identical.

Refs PyAutoFit#1577.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01E2HKd5ZocDmTyZ544eVEh4
@Jammy2211 Jammy2211 added the pending-release PR queued for the next release build label Sep 8, 2026
@Jammy2211
Jammy2211 merged commit 9321910 into main Sep 8, 2026
3 checks passed
@Jammy2211
Jammy2211 deleted the feature/samples-errors-at-sigma-instance branch September 8, 2026 00:05
@Jammy2211 Jammy2211 removed the pending-release PR queued for the next release build label Oct 7, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant