Dynamic attributes config (#14035)

* Add config for attribute map and generate all labels from the map

* Update docs

* Formatting

* Use the dynamic label map

* Fix check

* Fix docs typo
This commit is contained in:
Nicolas Mowen
2024-09-28 07:49:04 -06:00
committed by GitHub
parent 7da44115d3
commit 38d398c967
7 changed files with 57 additions and 18 deletions

View File

@@ -15,13 +15,10 @@ PLUS_API_HOST = "https://api.frigate.video"
# Attribute & Object constants
ATTRIBUTE_LABEL_MAP = {
"person": ["face", "amazon"],
"car": ["ups", "fedex", "amazon", "license_plate"],
DEFAULT_ATTRIBUTE_LABEL_MAP = {
"person": ["amazon", "face"],
"car": ["amazon", "fedex", "license_plate", "ups"],
}
ALL_ATTRIBUTE_LABELS = [
item for sublist in ATTRIBUTE_LABEL_MAP.values() for item in sublist
]
LABEL_CONSOLIDATION_MAP = {
"car": 0.8,
"face": 0.5,