mirror of
https://github.com/blakeblackshear/frigate.git
synced 2025-03-04 00:17:22 +01:00
fix formatting
This commit is contained in:
parent
beabb58ea7
commit
f3b657259c
@ -240,12 +240,16 @@ class EmbeddingMaintainer(threading.Thread):
|
|||||||
# we don't check required zones here - probably should, but does that run the risk in this simple logic
|
# we don't check required zones here - probably should, but does that run the risk in this simple logic
|
||||||
# that the object doesn't get into the required zones until later in the event?
|
# that the object doesn't get into the required zones until later in the event?
|
||||||
if self.genai_client is not None and camera_config.genai.send_after_frames:
|
if self.genai_client is not None and camera_config.genai.send_after_frames:
|
||||||
if len(self.tracked_events[data["id"]]) == camera_config.genai.send_after_frames:
|
if (
|
||||||
|
len(self.tracked_events[data["id"]])
|
||||||
|
== camera_config.genai.send_after_frames
|
||||||
|
):
|
||||||
event: Event = Event.get(Event.id == data["id"])
|
event: Event = Event.get(Event.id == data["id"])
|
||||||
|
|
||||||
if (not camera_config.genai.objects
|
if (
|
||||||
or event.label in camera_config.genai.objects):
|
not camera_config.genai.objects
|
||||||
|
or event.label in camera_config.genai.objects
|
||||||
|
):
|
||||||
logger.debug(f"{camera} sending early request to GenAI")
|
logger.debug(f"{camera} sending early request to GenAI")
|
||||||
threading.Thread(
|
threading.Thread(
|
||||||
target=self._genai_embed_description,
|
target=self._genai_embed_description,
|
||||||
@ -253,7 +257,10 @@ class EmbeddingMaintainer(threading.Thread):
|
|||||||
daemon=True,
|
daemon=True,
|
||||||
args=(
|
args=(
|
||||||
event,
|
event,
|
||||||
[data["thumbnail"] for data in self.tracked_events[data["id"]]],
|
[
|
||||||
|
data["thumbnail"]
|
||||||
|
for data in self.tracked_events[data["id"]]
|
||||||
|
],
|
||||||
),
|
),
|
||||||
).start()
|
).start()
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user