Formatting

This commit is contained in:
Nicolas Mowen 2025-04-28 16:30:47 -06:00
parent aefb080920
commit 05392142c6
2 changed files with 21 additions and 18 deletions

View File

@ -1514,7 +1514,8 @@ class LicensePlateProcessingMixin:
# always publish to recognized_license_plate field # always publish to recognized_license_plate field
self.requestor.send_data( self.requestor.send_data(
"tracked_object_update", "tracked_object_update",
json.dumps({ json.dumps(
{
"type": TrackedObjectUpdateTypesEnum.lpr, "type": TrackedObjectUpdateTypesEnum.lpr,
"name": sub_label, "name": sub_label,
"plate": top_plate, "plate": top_plate,
@ -1522,7 +1523,8 @@ class LicensePlateProcessingMixin:
"id": id, "id": id,
"camera": camera, "camera": camera,
"timestamp": start, "timestamp": start,
}), }
),
) )
self.sub_label_publisher.publish( self.sub_label_publisher.publish(
EventMetadataTypeEnum.recognized_license_plate, EventMetadataTypeEnum.recognized_license_plate,

View File

@ -164,7 +164,6 @@ class FaceRealTimeProcessor(RealTimeProcessorApi):
self.metrics.face_rec_fps.value = self.faces_per_second.eps() self.metrics.face_rec_fps.value = self.faces_per_second.eps()
camera = obj_data["camera"] camera = obj_data["camera"]
if not self.config.cameras[camera].face_recognition.enabled: if not self.config.cameras[camera].face_recognition.enabled:
return return
@ -295,14 +294,16 @@ class FaceRealTimeProcessor(RealTimeProcessorApi):
self.requestor.send_data( self.requestor.send_data(
"tracked_object_update", "tracked_object_update",
json.dumps({ json.dumps(
{
"type": TrackedObjectUpdateTypesEnum.face, "type": TrackedObjectUpdateTypesEnum.face,
"name": weighted_sub_label, "name": weighted_sub_label,
"score": weighted_score, "score": weighted_score,
"id": id, "id": id,
"camera": camera, "camera": camera,
"timestamp": start, "timestamp": start,
}), }
),
) )
if weighted_score >= self.face_config.recognition_threshold: if weighted_score >= self.face_config.recognition_threshold: