7.0 KiB
Complete route search before provisional localization
Decision and scope
Owner-approved follow-up to the entry/seam audit. Fix cold-start search scheduling, retain the precise start-area solver and all geometric/fresh-data gates. No device commands, threshold relaxation, map correction changes, endpoint snapping or retroactive edit of the failed study.
route-relocalization/v7 compares the complete selected route before choosing a
provisional place. A finite hypothesis queue replaces the shared 35-second
deadline. stationary-fresh-bootstrap/v4 separates search geometry from current
localization evidence; an old prefix can never establish tracking directly.
Algorithm and boundaries
- Collect the existing 10-second stationary prefix.
- Run all 108 established dense-start seeds at the start/last confirmed hint. Keep a qualified dense candidate, but do not accept it before route comparison. A missing local start target does not prohibit searching the remaining map.
- Index the complete reference and rank all geometrically usable route anchors, spaced by the existing 5-m policy. Ranking changes order, never eligibility.
- At each anchor, test the existing three yaw proposals with two translations: sensor entry to route anchor, and the former cloud-median placement. One prepared local target tree is shared by all six fits. No atlas density cap or new thinning is introduced.
- Compare the resulting SE(3) clusters together with the dense-start candidate. A distinct similarly good place remains ambiguous; first passing fit is not accepted. A failed fresh trial can advance to the next unambiguous candidate, with a new receipt fence and no reused validation data.
- During search, continue checking source identity/order, receipt segment, pose/cloud freshness and stationary translation (existing 0.10-m envelope). Movement or broken input invalidates the hypothesis. The existing 40-second prefix-age fence remains for the legacy local protocol, not for v7's explicitly monitored stationary whole-route search.
- After the result arrives, discard all pre-result receipts for confirmation. Three consistent fresh geometric checks remain mandatory before tracking. Ordinary tracking, local reference extraction, quality thresholds and the 8-second fresh-result gate are unchanged.
The numerical child emits progress after individual work units. The supervisor allows arbitrary total search duration while work advances; 60 seconds with no progress is a worker stall, not evidence that the location is unknown. STOP, source end, moved-search cancellation and teardown terminate/reap that exact child. A queued operator retry waits for its release and starts with a new prefix. Recording remains owned by the device plugin.
The candidate queue stays in one worker across scheduling batches; this is not a durable checkpoint/resume facility after a process crash. A failed worker returns incomplete search and offers reinitialization without stopping recording. Operator copy uses the existing status surface under the product UI canon.
Real saved-input regressions
Same immutable run 473870e0-5210-452c-b9e4-9d7937e93646, query
20260921T103511Z_viewer_live, corrected full reference
JA-STROITEL-SUN-RING · correction v2, 579.98 m / 694,420 points.
Only original initialization arrays enter the production worker. No end pose,
later successful transform, manually selected anchor or offline deadline override.
One CPU worker at a time; numerical thread counts fixed to one.
| Original attempt | New result | Surface overlap | Inlier RMSE | Worker wall |
|---|---|---|---|---|
| First, failed cold start near route end | Candidate at anchor 113 / 565 m | 98.8467% | 0.14330 m | 138.58 s |
| Second, familiar start | Candidate at start | 98.7191% | 0.13466 m | 156.52 s |
Both searches completed 810/810 fits: 108 dense + 117 anchors × 3 yaws × 2 seeds. No remaining route anchors; no competing qualified location close enough to trigger ambiguity. The second case retained the dense-start solution rather than degrading its target geometry.
All 159 files of the original saved study were hashed before/after each replay
and remained unchanged. Raw evidence and generated arrays/results remain in the
ignored private 2026-09-21-full-route-fix audit directory. The earlier study
still truthfully records its failed first initialization.
Validation and review
- 121 focused backend tests passed: route coverage, last-ranked candidate, dense/global competition, median-seed regression, anchor-origin placement, multi-minute search, stationary continuity, distinct fresh windows, stale and ambiguous rejection, live recovery, cancellation, same-recording retry, child stall/forced cleanup and corrected-map source admission.
- Focused Ruff and
git diff --checkpassed. - Replacing median placement outright failed the existing lateral-offset GICP regression; therefore both initializations are retained. No quality threshold was weakened to make that test pass.
- Registration/correction producer files and reference generations are unchanged.
- Application architecture checks, TypeScript, all 887 frontend tests and the production build passed sequentially. Only the existing large-chunk build warning remains. Normal/expanded planner, latest ring evidence and Escape menu dismissal were checked in the existing in-app browser; no live state was faked.
- With acquisition idle and the old study completed, the canonical LaunchAgent was restarted. Health/liveness passed on the sole port-8000 backend (PID 64086); no backend on 8765 and no temporary search/test workers remain. New captures use v7; the old report continues to expose its original v6 evidence.
Limitations and next field acceptance
Completeness is relative to the declared finite anchor/yaw/seed policy, not a mathematical proof that every pose in continuous space was searched. Descriptor ranking remains imperfect; queue completeness prevents a low rank from excluding the real place, but is not a fast kilometer-scale place-recognition index.
Full comparison increases even familiar-start latency to roughly 2–3 minutes on this 580-m map. This is an explicit regression in speed, accepted here for complete comparison, not a claim of final optimization. Target preprocessing is reused; safe coarse-to-fine acceleration still needs independent evidence.
Offline replay proves the corrected numerical cold-start outcome, not live stationary continuity or independent absolute pose accuracy. Synthetic tests prove the temporal contract; the operator must confirm it on a new capture. Surface overlap/RMSE are not position accuracy or autonomous-driving acceptance.
Field check: start at the formerly rejected place (last point of the old pass), leave the scanner stationary through search and fresh confirmation, then walk 20–30 m across the seam and back. Record the time to tracking and any interruption. No longer route is needed to answer this regression question.