mirror of
https://github.com/blakeblackshear/frigate.git
synced 2026-02-08 20:25:26 +03:00
Use different box variation to designate when an object is stationary on debug
This commit is contained in:
parent
7b049c1782
commit
ce36fd16af
@ -489,8 +489,12 @@ class CameraState:
|
|||||||
# draw the bounding boxes on the frame
|
# draw the bounding boxes on the frame
|
||||||
for obj in tracked_objects.values():
|
for obj in tracked_objects.values():
|
||||||
if obj["frame_time"] == frame_time:
|
if obj["frame_time"] == frame_time:
|
||||||
thickness = 2
|
if obj["stationary"]:
|
||||||
color = self.config.model.colormap[obj["label"]]
|
color = (220, 220, 220)
|
||||||
|
thickness = 1
|
||||||
|
else:
|
||||||
|
thickness = 2
|
||||||
|
color = self.config.model.colormap[obj["label"]]
|
||||||
else:
|
else:
|
||||||
thickness = 1
|
thickness = 1
|
||||||
color = (255, 0, 0)
|
color = (255, 0, 0)
|
||||||
|
|||||||
@ -220,9 +220,7 @@ class NorfairTracker(ObjectTracker):
|
|||||||
id = self.track_id_map[track_id]
|
id = self.track_id_map[track_id]
|
||||||
self.disappeared[id] = 0
|
self.disappeared[id] = 0
|
||||||
# update the motionless count if the object has not moved to a new position
|
# update the motionless count if the object has not moved to a new position
|
||||||
if self.update_position(
|
if self.update_position(id, obj["box"]):
|
||||||
id, obj["box"], self.tracked_objects[id]["motionless_count"] > 1
|
|
||||||
):
|
|
||||||
self.tracked_objects[id]["motionless_count"] += 1
|
self.tracked_objects[id]["motionless_count"] += 1
|
||||||
if self.is_expired(id):
|
if self.is_expired(id):
|
||||||
self.deregister(id, track_id)
|
self.deregister(id, track_id)
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user