Skip to content

Add pyro-detector-baseline experiment#31

Merged
Chouffe merged 13 commits intomainfrom
arthur/experiment-pyro-detector-baseline
Apr 1, 2026
Merged

Add pyro-detector-baseline experiment#31
Chouffe merged 13 commits intomainfrom
arthur/experiment-pyro-detector-baseline

Conversation

@Chouffe
Copy link
Copy Markdown
Collaborator

@Chouffe Chouffe commented Apr 1, 2026

Summary

  • Wraps the production pyro-predictor package (YOLO ONNX + sliding-window temporal smoothing) as a TemporalModel baseline
  • Uses production defaults from pyro-engine's Engine class (conf_thresh=0.35, nb_consecutive_frames=7)
  • Dataset imported from pyro-dataset v2.2.0 via dvc import (sequential_train_val split)
  • DVC pipeline: prepare -> predict (train/val) -> evaluate (4 slices)

Test plan

  • make lint passes
  • make test passes (41 tests)
  • uv run dvc repro completes successfully
  • Metrics look reasonable (uv run dvc metrics show)

Chouffe added 13 commits April 1, 2026 13:39
Wrap the production pyro-predictor package (YOLO ONNX + sliding-window
temporal smoothing) as a TemporalModel baseline. Uses production defaults
from pyro-engine's Engine class (conf_thresh=0.35, nb_consecutive_frames=7).

Dataset imported from pyro-dataset v2.2.0 via dvc import.
DVC pipeline: prepare -> predict (train/val) -> evaluate.
….0 model

- Add package module and script to bundle ONNX weights + config into a
  deployable .zip archive (mirrors FSM baseline pattern)
- Refactor predict script to use PyroDetectorModel (TemporalModel subclass)
  instead of calling predictor_wrapper directly
- Add from_package classmethod to PyroDetectorModel for loading archives
- Switch YOLO model to pyronear/yolo11s_nimble-narwhal_v6.0.0
- Add 10 package tests (build, roundtrip, error cases)
…ections

Split YOLO inference from temporal logic so the model runs once:
- infer stage: runs YOLO Classifier, caches per-frame detections as JSON
- predict stage: replays cached detections through Predictor temporal logic
- sweep stage: grid-searches conf_thresh x nb_consecutive_frames (64 combos)

Best val F1=0.913 at conf=0.2, nb_frames=4 (vs 0.825 with production defaults).
Sweep found best val F1=0.913 at conf_thresh=0.2, nb_consecutive_frames=4
(vs F1=0.825 with production defaults conf=0.35, nb_frames=7).
Move create_replay_predictor(), load_detections(), and replay_sequence()
from predict.py and sweep.py into predictor_wrapper.py to eliminate
duplication. Update DVC deps to include predictor_wrapper.py.
@Chouffe Chouffe merged commit 01b8497 into main Apr 1, 2026
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant