Revamp object debug view (#11186)

* revamp object debug view

* fix vite

* remove console log

* don't display empty fields

* clarify masks as motion masks

* add descriptions

* color and spacing

* add sub_label to camera activity

* add sub_label to type

* rename to debug
This commit is contained in:
Josh Hawkins
2024-05-01 09:07:56 -05:00
committed by GitHub
parent bb335638a4
commit 6d2457ebad
7 changed files with 301 additions and 28 deletions

View File

@@ -739,15 +739,25 @@ class CameraState:
if not obj.false_positive:
label = object_type
sub_label = None
if obj.obj_data.get("sub_label"):
if obj.obj_data.get("sub_label")[0] in ALL_ATTRIBUTE_LABELS:
label = obj.obj_data["sub_label"][0]
else:
label = f"{object_type}-verified"
sub_label = obj.obj_data["sub_label"][0]
camera_activity["objects"].append(
{"id": obj.obj_data["id"], "label": label, "stationary": not active}
{
"id": obj.obj_data["id"],
"label": label,
"stationary": not active,
"area": obj.obj_data["area"],
"ratio": obj.obj_data["ratio"],
"score": obj.obj_data["score"],
"sub_label": sub_label,
}
)
# if the object's thumbnail is not from the current frame