False positive MQTT messages #1261
-
I'm using the Frigate addon for HA. It works really well and I'm impressed over your hard work! It seems that Frigate produces images of detected objects that are being tracked, even though the object isn't inside a required zone. Is this expected behavior? I have the following config:
If I check the Frigate Dashboard for that specific camera, I see images of objects below the camera stream, for instance "BICYCLE" has a thumbnail of a bicycle that is outside the required zone and if I click on the BICYCLE-button I can't find the same picture inside the event history. I'm not seeing any clips or snapshots from this particular event in the media folder either. Should it work like this? I'm also using
But I'm under the impression that Frigate still produces some messages even though the object hasn't entered the required zone. I'm not 100% sure of this though!! But it seems like it, since I can't find any media related to the timestamp when I got the notification on my phone. The images that I see in the dashboard, could they even exist without any MQTT action? These issues started recently, after I removed a motion mask in the config that I previously used to ignore movement outside my property. I thought this solution worked fine but after some reading here and on the HA community page it seems that the general recommendation is to keep motion on everywhere and use object masks to distinguish whether or not it's important enough for notifications, correct? Let me know if I have to provide more of the config or attach images! |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 1 reply
-
It is working as expected. MQTT messages will fire for tracked objects regardless of which zone they have entered. You will want to use a condition to only alert on objects that have entered a zone of interest. Something like the following: automation:
- alias: When a person enters a zone named yard
trigger:
platform: mqtt
topic: frigate/events
condition:
- "{{ trigger.payload_json['after']['label'] == 'person' }}"
- "{{ 'yard' in trigger.payload_json['after']['entered_zones'] }}"
action:
- service: notify.mobile_app_pixel_3
data_template:
message: "A {{trigger.payload_json['after']['label']}} has entered the yard."
data:
image: "https://url.com/api/frigate/notifications/{{trigger.payload_json['after']['id']}}/thumbnail.jpg"
tag: "{{trigger.payload_json['after']['id']}}" You interpreted the guidance for updating your motion masks correctly. Frigate will lock onto and track objects outside of those zones so it can fire alerts more quickly when that tracked object crosses into a zone. It also ensures the clips include footage from before they entered the zone. You should only use motion masking to block out things like the timestamp from the camera or rooftops/trees where you want to ignore excessive motion. |
Beta Was this translation helpful? Give feedback.
-
The |
Beta Was this translation helpful? Give feedback.
It is working as expected. MQTT messages will fire for tracked objects regardless of which zone they have entered. You will want to use a condition to only alert on objects that have entered a zone of interest. Something like the following: