mirror of
https://github.com/blakeblackshear/frigate.git
synced 2026-08-02 17:12:16 +03:00
Autotracking improvements (#17955)
* add zoom time to movement predictions * config migrator * add space to face rename regex * more debug * only calculate zoom time of relative move * fix test * make migrated movement weight a zero * check for str and bool for movestatus support
This commit is contained in:
@@ -319,6 +319,21 @@ def migrate_016_0(config: dict[str, dict[str, any]]) -> dict[str, dict[str, any]
|
||||
|
||||
camera_config["live"] = live_config
|
||||
|
||||
# add another value to movement_weights for autotracking cams
|
||||
onvif_config = camera_config.get("onvif", {})
|
||||
if "autotracking" in onvif_config:
|
||||
movement_weights = (
|
||||
camera_config.get("onvif", {})
|
||||
.get("autotracking")
|
||||
.get("movement_weights", {})
|
||||
)
|
||||
|
||||
if movement_weights and len(movement_weights.split(",")) == 5:
|
||||
onvif_config["autotracking"]["movement_weights"] = (
|
||||
movement_weights + ", 0"
|
||||
)
|
||||
camera_config["onvif"] = onvif_config
|
||||
|
||||
new_config["cameras"][name] = camera_config
|
||||
|
||||
new_config["version"] = "0.16-0"
|
||||
|
||||
Reference in New Issue
Block a user