Device temporal scores: model version, separate threshold, minimum frames

Abierto
#737 0 comentarios 0 reacciones 0 asignados Ver en GitHub

Los mantenedores suelen responder en 6 días

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
4/5
Tiempo estimado
3-5 días
Aptitud para principiantes
45/100
Tipo de issue
Nueva funcionalidad
Claridad
Bastante claro
Estado de actividad
Activo
Stack tecnológico
fastapi, postgresql, python

Línea de trabajo

Read the implementation of POST /detections, pyroclient.create_detection, and the worker branch that handles device scores, along with the existing temporal_model_version, TEMPORAL_MODEL_THRESHOLD, and MIN_FRAMES settings. Check how the engine’s 11-frame window fills early in an event before deciding where the minimum-frame rule belongs. Done means device scores can carry a model version, use their own threshold, and follow a clearly chosen minimum-frame rule.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

Follow-up of #723, which stores the temporal score computed on the device with engine as provenance and applies TEMPORAL_MODEL_THRESHOLD to it.

Three things were left out of that PR to keep it small:

  • Model version. The engine sends no version with its scores, so temporal_model_version stays NULL for device scores. We cannot tell which release produced a score or spot calibration drift. Proposal: an optional temporal_model_version form field on POST /detections (and the matching pyroclient.create_detection parameter), stored in the existing column. pyro-engine side: send the version reported by pyro_temporal_api /health.
  • Separate threshold. The device model and the API model share TEMPORAL_MODEL_THRESHOLD, but their scores are not necessarily comparable. Proposal: a DEVICE_TEMPORAL_MODEL_THRESHOLD setting, defaulting to TEMPORAL_MODEL_THRESHOLD, used by the worker's device branch only.
  • Minimum frames. MIN_FRAMES does not apply to device scores: the engine scores its own window (11 frames, pyronear/pyro-engine#415) and sends a score with every frame once an alert is ongoing, so a sequence can validate on its creation frame. Decide whether the engine must score a minimum number of frames before sending scores, or whether the API should require a minimum here. Needs a look at how many frames the engine window holds early in an event.

No migration for the first two.

Lenguaje dominante
Python
Estrellas
30
Forks
15
Merge medio
7 d 16 h
PR fusionados (30 d)
16

Preparar el entorno

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de pyronear/pyro-api

Todos los issues de pyronear/pyro-api

Issues similares

Más issues de Python

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.