feat(gsdc2023): opt-in DGNSS base correction for FGO-only rows#99
Open
rsasaki0109 wants to merge 1 commit into
Open
feat(gsdc2023): opt-in DGNSS base correction for FGO-only rows#99rsasaki0109 wants to merge 1 commit into
rsasaki0109 wants to merge 1 commit into
Conversation
Adds a BridgeConfig flag base_correction_fgo_only_rows (default False) and CLI --base-correction-fgo-only-rows. When set, the DGNSS base correction is also applied to FGO-only rows — rows whose WLS weight was masked out while the FGO weight (weights_fgo) was kept — so the FGO objective sees corrected pseudoranges on those rows too. The legacy behaviour (correct only WLS-active rows) is preserved by default. apply_base_correction_to_pseudorange gains weights_fgo / include_fgo_only parameters; the flag is threaded through build_trip_arrays, the post-observation stages and the submission CLI. Motivation: a 26-trip A/B (off vs on) on the pixel=FGO preset improves the FGO standalone score from 1.6386 m to 1.5177 m (-12.1 cm aggregate, 12 wins / 5 regressions / 9 wash). The wins are bias-dominated rows recovered by the DGNSS correction (mtv-pe1 -131 cm, lax-t -81 cm, mtv-e -42 cm, lax-o -23 cm); the main regression is sjc-q (+39 cm), an NLOS-heavy trip whose rows are then kept at full weight in FGO. High variance, hence opt-in and default off.
ec54a5a to
f1f367d
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Adds an opt-in flag
base_correction_fgo_only_rows(BridgeConfig, defaultFalse) and CLI--base-correction-fgo-only-rows. When enabled, the DGNSS base correction is also applied to FGO-only rows — rows whose WLS weight was masked out while the FGO weight (weights_fgo) was kept — so the FGO objective sees corrected pseudoranges on those rows too.The legacy behaviour (correct only WLS-active rows,
weights > 0) is preserved by default; nothing changes unless the flag is set.Why
Surfaced during the DGNSS / multi-constellation work: the shared pseudorange feeds both the WLS gate (
weights) and the FGO objective (weights_fgo). Rows that the WLS pseudorange-residual mask zeros out can still feed FGO. Those rows were never base-corrected, so their common-mode error (iono/tropo/sat-clock/orbit) leaked into the FGO solution.26-trip A/B (pixel=FGO preset, off vs on)
Biggest wins are bias-dominated rows recovered by the correction: mtv-pe1 (2023-05-09) -131 cm, lax-t -81 cm, mtv-e -42 cm, routen -27 cm, lax-o -23 cm, mtv-h -18 cm. The main regression is sjc-q +39 cm — an NLOS-heavy trip whose rows are then kept at full weight in FGO.
The result is net-positive but high variance, so the flag is opt-in and default off.
Changes
gsdc2023_bridge_config.py: new field + bool validation.gsdc2023_trip_stages.py:apply_base_correction_to_pseudorangegainsweights_fgo/include_fgo_only; flag threaded through the post-observation stages.gsdc2023_raw_bridge.py:build_trip_arrays+ both callers thread the flag.build_gsdc2023_bridge_submission.py: CLI flag + reproducibility metadata.Tests
tests/test_gsdc2023_bridge_config.py+tests/test_gsdc2023_trip_stages.pygreen (91 passed, +3 new). Full-k gsdc2023suite shows only pre-existing failures unrelated to this change (gnss_log_reader / pixel5_candidate_queue, identical onmain).Production proxy (40-trip phone-aware, selected score)
Built the full 40-trip train set on the production phone-aware config (pixel → FGO direct adoption, non-pixel → taroz_sn gated), flag off vs on, measuring the selected (submission) score:
base_correction_count = 0The non-pixel half is provably inert: base correction is only enabled by the taroz pixel preset (gated non-pixel trips run
apply_base_correction=False), so the flag is structurally a pixel-only lever and touches none of the 14 gated trips. The regressions (e.g. sjc-q +39 cm) are confined to the known pixel set and are net-absorbed. Net-positive and submission-safe on the real selected metric.