Overview
Consolidate structure debt from three fast instrument phases. Behaviour-preserving: identical products/provenance (modulo timestamps/version stamps) for identical inputs; public API unchanged. Plan approved in-session (default present-and-wait run; refactor cap is safe but no --auto was given).
Plan
- Decompose
pipeline.reduce_target into per-stage functions (record layout byte-identical).
- Extract
autoreduce/validation/parity.py (sub-pixel registration + ratio stats) — de-triplicates the integration scripts.
- Extract
drizzle/_common.py (chdir-scratch context manager + shared provenance fragment) used by both combine backends.
- Vectorize
psf/stars.reject_crowded (identical selection results; randomized equivalence test).
- Hoist cheap function-local imports; tidy exptime coercion.
Out of scope: _fwhm_of upgrade, dial defaults, tier-2 PSF (behaviour-visible).
Witnesses
- 83-test unit suite per commit (+1 equivalence test).
- Offline cached end-to-end re-runs, ACS (
slacs0008-0004) and JWST (F444W ring): products byte-compared, reduction.json compared modulo written_at/software. Baselines captured from main (f91d79c) before any edit.
RefactorDecision: API guard none-expected; witness registry gap overridden with the above evidence.
Overview
Consolidate structure debt from three fast instrument phases. Behaviour-preserving: identical products/provenance (modulo timestamps/version stamps) for identical inputs; public API unchanged. Plan approved in-session (default present-and-wait run; refactor cap is
safebut no--autowas given).Plan
pipeline.reduce_targetinto per-stage functions (record layout byte-identical).autoreduce/validation/parity.py(sub-pixel registration + ratio stats) — de-triplicates the integration scripts.drizzle/_common.py(chdir-scratch context manager + shared provenance fragment) used by both combine backends.psf/stars.reject_crowded(identical selection results; randomized equivalence test).Out of scope:
_fwhm_ofupgrade, dial defaults, tier-2 PSF (behaviour-visible).Witnesses
slacs0008-0004) and JWST (F444Wring): products byte-compared,reduction.jsoncompared modulowritten_at/software. Baselines captured frommain(f91d79c) before any edit.RefactorDecision: API guard none-expected; witness registry gap overridden with the above evidence.