Commit 19355588 authored by Andrey Filippov's avatar Andrey Filippov

CLAUDE: pose_stored DEBUG: apply STORED per-scene ERS rates (match the render path)

Andrey's diagnosis: the composite-vs-DBG sub-pixel warp field (static, sy-
dominated: uniform 0.24px, x-shear, +0.3% y-scale ~ tilt_rate*frame_time)
comes from the ErsCorrection infrastructure - the render path sets each
scene's ERS from the STORED scenes_<ts>_dt (xyz_dt AND atr_dt,
renderSceneSequence/OpticalFlow:10555) while the pose loop used finite-
difference ATR-only rates with xyz_dt=0. Different scene-side ERS by
construction. (Virtual center's own ERS rates confirmed ZERO in corr-xml;
GPU corr_vector imu_rot/imu_move ERS support confirmed present but dormant.)

pose_stored mode now sets setErsDt from ers_center.getSceneErsXYZ_dt/
getSceneErsATR_dt - the exact calls the render uses - so the decoupled
measurement/render applies IDENTICAL poses AND ERS as CUAS-MERGED-CUAS-DBG.
If the warp field collapses in the next pose_stored run, the divergence is
proven. Live (LMA) mode unchanged: finite-difference rates - to be replaced
by rates computed from pose + rotation model (RT design: ErsCorrection
preserved fully, thin non-QuadCLT plumbing; per-sensor ERS available on GPU
via corr_vector imu when fed).

Verified: mvn -DskipTests clean package OK.
Co-Authored-By: 's avatarClaude Fable 5 <noreply@anthropic.com>
parent b5e1fcd9
...@@ -724,8 +724,28 @@ public class CuasPoseRT { ...@@ -724,8 +724,28 @@ public class CuasPoseRT {
dxyzatr_dt[1][j] = (predicted[1][j] - prev_pose[1][j]) / (ts - prev_ts); dxyzatr_dt[1][j] = (predicted[1][j] - prev_pose[1][j]) / (ts - prev_ts);
} }
} }
// pose_stored (DEBUG): use the STORED per-scene ERS rates (xyz_dt AND atr_dt), the
// same source and calls as the render path (renderSceneSequence) - so the decoupled
// measurement/render applies IDENTICAL ERS to the CUAS-MERGED-CUAS-DBG renders.
// Live mode keeps finite-difference ATR rates (xyz_dt=0) - the ErsCorrection-vs-
// render divergence under test. By Claude on 07/04/2026, from Andrey's diagnosis.
double [] stored_ers_xyz_dt = null, stored_ers_atr_dt = null;
if (clt_parameters.curt.pose_stored) {
stored_ers_xyz_dt = ers_center.getSceneErsXYZ_dt(ts_name);
stored_ers_atr_dt = ers_center.getSceneErsATR_dt(ts_name);
}
if ((stored_ers_xyz_dt != null) && (stored_ers_atr_dt != null)) {
quadCLTs[nscene].getErsCorrection().setErsDt(
stored_ers_xyz_dt, // double [] ers_xyz_dt,
stored_ers_atr_dt); // double [] ers_atr_dt - exactly as renderSceneSequence
} else {
if (clt_parameters.curt.pose_stored && (debugLevel > -4)) {
System.out.println("CuasPoseRT: scene "+nscene+" ("+ts_name+
") pose_stored: no stored ERS rates, falling back to finite differences");
}
quadCLTs[nscene].getErsCorrection().setErsDt( quadCLTs[nscene].getErsCorrection().setErsDt(
QuadCLTCPU.scaleDtToErs(clt_parameters, dxyzatr_dt)); QuadCLTCPU.scaleDtToErs(clt_parameters, dxyzatr_dt));
}
// Phase A2 ingest (curt_pose_raw): read RAW /jp4/, condition with the CURRENT // Phase A2 ingest (curt_pose_raw): read RAW /jp4/, condition with the CURRENT
// calibration and force-upload straight to the GPU - bypasses the prepared // calibration and force-upload straight to the GPU - bypasses the prepared
// image_data (old broken Photogrammetric Calibration). The bayer guard keeps // image_data (old broken Photogrammetric Calibration). The bayer guard keeps
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment