Use a rolling average of iou to determine if an object is no longer stationary (#9381)

* Use a rolling average of iou to determine if an object is no longer stationary

* Use different box variation to designate when an object is stationary on debug

* In progress

* Use average of boxes instead of average of iou

* Update frigate/track/norfair_tracker.py

Co-authored-by: Blake Blackshear <blake@frigate.video>

---------

Co-authored-by: Blake Blackshear <blake@frigate.video>
This commit is contained in:
Nicolas Mowen
2024-02-26 06:37:56 -07:00
committed by GitHub
parent 0a15ef022b
commit 3f1bd891e4
3 changed files with 41 additions and 11 deletions

View File

@@ -489,8 +489,12 @@ class CameraState:
# draw the bounding boxes on the frame
for obj in tracked_objects.values():
if obj["frame_time"] == frame_time:
thickness = 2
color = self.config.model.colormap[obj["label"]]
if obj["stationary"]:
color = (220, 220, 220)
thickness = 1
else:
thickness = 2
color = self.config.model.colormap[obj["label"]]
else:
thickness = 1
color = (255, 0, 0)