Skip to content

Commit 8a0c433

Browse files
YoshiRiclaude
andauthored
feat: add per-frame 2D visualization (static demo) (#11)
src/tracking/evaluation/interactive.py - _ggiw_to_ellipse(): GGIW extent → {ext_a, ext_b, ext_theta, x, y, vx, vy} - run_once(): add record_frames flag; captures GT/obs/est snapshots per frame - run_simulation_json(): include frame_data (sensor_origin + frames[]) from MC run 0 scripts/generate_demo.py - Runs run_simulation_json for selected/all scenarios - Writes docs/data/demo_<scenario>.json docs/demo.html - Canvas 2D renderer: GT rectangles (green), LiDAR points (yellow), GGIW estimate ellipses (red), velocity arrows, sensor origin marker - Frame slider + Play/Pause/Step/Reset controls - Auto-fit coordinate transform with grid and axis labels - Missed-detection badge for miss frames - Per-scenario summary metrics strip - Loads all scenarios from docs/data/ via fetch (falls back gracefully) tests/tracking/test_interactive.py (+10 tests) - frame_data present and correctly nested - frame index sequential, GT fields valid, obs pairs finite - est ellipse axes positive (guards eigenvalue sign bugs) - missed frames have empty obs + missed=True flag - record_frames=False → snapshots is None - record_frames=True → snapshots length matches n_frames Usage (local preview): uv run python scripts/generate_demo.py --all cd docs && python -m http.server 8080 # open http://localhost:8080/demo.html https://claude.ai/code/session_013sQREGvTmjgFT8cyRNmPUL Co-authored-by: Claude <noreply@anthropic.com>
1 parent fdc5448 commit 8a0c433

4 files changed

Lines changed: 640 additions & 8 deletions

File tree

0 commit comments

Comments
 (0)