Skip to content

test: pin DelaunayNN routing to the numba likelihood paths (#623 phase 2) - #625

Merged
Jammy2211 merged 1 commit into
mainfrom
feature/delaunay-nn-numba-routing
Oct 15, 2026
Merged

Jammy2211 merged 1 commit into
mainfrom
feature/delaunay-nn-numba-routing

Conversation

@Jammy2211

Copy link
Copy Markdown
Collaborator

Summary

Phase 2 of #623 (stacked on #624 — merge #624 first). Audits whether DelaunayNN mappers (Sibson rows up to 32 wide, NaN weights on overflow/degenerate) reach the numba likelihood paths and agree with the reference routes. Result: no routing or gate change needed — every measured case already takes the numba class, and NaN weights already give NaN evidence on every route. This PR pins that with tests and documents it.

dataset mesh vertices class nnz/col
Aris interferometer Delaunay / NN 1405 InterferometerSparseNumba 11.5 / 17.8
Aris interferometer Delaunay / NN 5526 InterferometerSparseNumba 3.0 / 1.0
HST imaging (15,380 px), sub 2 Delaunay / NN 1030 ImagingSparseNumba 178 / 431
HST imaging, sub 2 Delaunay / NN 1530 ImagingSparseNumba 120 / 275
HST imaging, sub 4 Delaunay / NN 1030 ImagingSparseNumba 713 / 1723

Steady log_likelihood_function, threads=1 (load 3–5, noisy): imaging sub 2 1030v Delaunay 0.31–0.38 s / NN 0.32 s; 1530v 0.34 / 0.48 s; sub 4 1030v 0.29 / 0.78 s. Interferometer (from #624): 0.41 / 0.57 s @1405, 8.2 / 12.1 s @5526. Imaging sub-4 gap is unique_mappings + adaptive_pixel_signals_from iterating 32-wide padded rows → filed as Mind follow-up draft/feature/autoarray/delaunaynn_wide_row_imaging_overhead.md.

NaN weights: forced Sibson neighbour overflow → curvature matrix and log-evidence NaN on mapping, FFT-sparse and numba-sparse interferometer routes and mapping / numba imaging routes, standard and positive-only solvers; nothing raises. A routing guard would give the same NaN slower, so none added.

API Changes

None — internal changes only (docstrings + tests).
See full details below.

Test Plan

  • New interferometer tests: DelaunayNN → InversionInterferometerSparseNumba at default gate; numba vs FFT parity on variable-width rows (rel 1e-10); NaN weights → NaN evidence on numba / FFT / mapping with factory still choosing numba
  • New imaging tests: DelaunayNN → InversionImagingSparseNumba, parity vs InversionImagingMapping; NaN-weight parity
  • Control: nan_to_num in kernel_inputs_from / data_slim_to_pixelization_unique_from makes both NaN tests fail
  • test_autoarray/ full: 2031 passed, 4 xfailed; emulated nojax on changed files: 37 passed
  • Independent review (fresh-context Opus): CLEAN. Low notes: NaN tests cover neighbour overflow only (cavity overflow / degenerate share the same NaN line); pre-existing Sibson edge case — a failed row with size == 0 keeps its NaNs in padding, so routes would agree on a finite (wrong) evidence — to be tracked separately
Full API Changes (for automation & release notes)

Changed Behaviour

  • None. Docstrings of factory._use_interferometer_numba and InversionInterferometerSparseNumba._check_preconditions now state the NaN-weight contract.

Heart RED override (development only)

Same live-human authorisation as #624 / #623 ("I override, tests will be handled once the epic refactor elsewhere is sorted"), re-confirmed by "go" for phase 2 in the same session. Commit, push and PR-open only — merge needs a separate human /prm with required checks green; does not claim to fix Heart. Current readiness stale ("release validation incomplete: no rehearsal for current source"); feed RED reasons verbatim in #624. Branch gates passed: tests, nojax emulation, independent review (above).

Generated by the PyAutoLabs agent workflow.

🤖 Generated with Claude Code

Phase 2 of #623. DelaunayNN mappers already route to
InversionInterferometerSparseNumba and InversionImagingSparseNumba on the
Aris interferometer and HST-scale imaging setups, and NaN Sibson weights
already give NaN evidence on every route, so no routing change is needed.
Add routing, numba-vs-reference parity and NaN-weight tests for
DelaunayNN, and document the NaN contract on the interferometer gate.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@Jammy2211 Jammy2211 added the pending-release PR queued for the next release build label Oct 15, 2026
Base automatically changed from feature/delaunay-nn-numba to main October 15, 2026 16:13
@Jammy2211
Jammy2211 merged commit a84f724 into main Oct 15, 2026
3 checks passed
@Jammy2211
Jammy2211 deleted the feature/delaunay-nn-numba-routing branch October 15, 2026 16:18
@Jammy2211 Jammy2211 removed the pending-release PR queued for the next release build label Oct 16, 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