2WFS/LIVEOnline Calibration (In-Loop)VERIFIEDStg 22-Stage

2-Stage Passive 2WFS1DM Online Calibration

Probe-free Differenced Lagged-A 2SLS calibrating Stage-2 OG, ZPO, and DM2->DM1 offload.

Overview & Role

Uses natural Stage-1 turbulence leakage as a zero-contrast-hit instrumental variable in native C (milk-fpsexec-mlt-sysid, .method=ivdiff): exposure-overlap alignment, jitter-immune nearest_idx counter pairing, NA=160 plate DM1 projection, optional Stage-2 H_eff DM2 kernel ingestion, circular block bootstrap SEs, and < 5% usable_ok health gating.

Pure-MILK mlt.apply2wfs1dm applies outlier-clamped per-mode aol2_mWFSfact (with .psol_safety=0.90 and scalar comp.WFSfact=1.0 reset) and updates Stage-2 acquWFS-2.WFSzpogain = 0.95 * g_med, plus solves level-IV Mda_virt for blind offload.

Compute Units / Entry Points: milk-fpsexec-mlt-sysidmlt.apply2wfs1dm

Verified Highlights:

Option Variants (CODE/OPT)

Option CodeBehavior & UsageMain Flags
2WFS/IVDefault Differenced Lagged-A 2SLS (`ivdiff`) with overlap alignment & health gate.--live-2wfs1dm-sec --sysid-modes --clock-skew-us
2WFS/WLegacy AR(p) temporal whitening estimator (`whiten`) retained for comparison.--sysid-whiten-order

Dependencies & Calibration Chain

Selected Algorithm
★ Current Entry
2WFS/LIVEOnline Calib
2-Stage Passive 2WFS1DM Online Calibration

CLI Flags, Environment Variables & FPS Parameters

LayerOption (Links to Reference)DefaultDescription
CLI Flag--live-2wfs1dm-sec0Capture live Stage-2 2WFS1DM ivdiff burst [s] and apply via mlt.apply2wfs1dm
CLI Flag--sysid-modes40Leading Stage-2 modes solved in --calib-2wfs1dm system identification
CLI Flag--sysid-whiten-order4Causal AR(p) temporal whitening filter order W(z) for --calib-2wfs1dm
CLI Flag--clock-skew-us—Stage-2 WFS clock trigger offset [us] relative to Stage 1
CACAO_* EnvCACAO_WFSZPO_GAIN1.0Optical-gain scaling factor applied to WFS zero-point offset (wfszpo)

Implementation, Tests & Related Reports

Source Files

Verification Tests

Related Staged Technical Reports