refactor stationary config into section

This commit is contained in:
Blake Blackshear
2022-02-13 08:58:44 -06:00
parent 5627b66a6e
commit ff19cdb773
5 changed files with 49 additions and 20 deletions

View File

@@ -511,8 +511,8 @@ def process_frames(
if obj["motionless_count"] >= 10
# and it isn't due for a periodic check
and (
detect_config.stationary_interval == 0
or obj["motionless_count"] % detect_config.stationary_interval != 0
detect_config.stationary.interval == 0
or obj["motionless_count"] % detect_config.stationary.interval != 0
)
# and it hasn't disappeared
and object_tracker.disappeared[obj["id"]] == 0