Closed yanivf38 closed 1 year ago
The docs cover a number of strategies to filter out false positives. https://docs.frigate.video/guides/false_positives
In this case, min_area would likely work well.
Thank you @NickM-27 , what would you suggest putting as min_area? any recommendations for the other settings?
I can't see in your image what the area of the plant was detected as
Is there a recommended setting? how can I measure it
The value is based on the resolution of the camera. The number next to the % score is the area of that box. You want min_area to be higher than that but lower than a real person detection would be
For this I would recommend an object mask so that a person could never be detected in that small area. The object mask should cover the bottom of the detection bounding box as that is where the object is defined. I.E set the object mask to cover where the table legs are.
Thank you @LaurenceGough and @NickM-27 for the help. I get the workarounds but why would static plant is identified as a person to begin with?
Thank you @LaurenceGough and @NickM-27 for the help. I get the workarounds but why would static plant is identified as a person to begin with?
Because the default model is not trained on the perspective of security cameras, it comes from a demo model from Google which is trained on many types of images like you can see here https://imgur.com/a/CNImofJ so it has false positives.
Hi,
I have simular problems with person detection. I had a busy day with lots of people @ my house. Now the Add-on stucks on detecting persons.
As you can see below, the LOG shows that the detection gives an errors. The errors are also present when it is not busy @ my home.
Here is my config:
mqtt:
host: 192.168.X.X
user: mqtt-user
password: mqtt-password
detectors:
coral:
type: edgetpu
device: usb
birdseye:
enabled: False
################################################################################
cameras:
frigate_voordeur:
ffmpeg:
inputs:
- path: rtsp://XXX/videoSub
roles:
- detect
- rtmp
- path: rtsp://XXX/videoMain
roles:
- record
rtmp:
enabled: False
detect:
width: 1280
height: 720
zones:
zone_0_voordeur:
coordinates: 309,720,1280,720,1280,221,454,131,196,41
objects:
track:
- person
filters:
person:
min_area: 5000
mask:
- 426,144,437,255,401,262,389,147
- 1280,0,1280,164,191,83,302,720,0,720,0,0
- 1280,720,1280,377,949,512
motion:
mask:
- 0,39,374,38,373,0,0,0
- 1280,0,1280,164,191,83,302,720,0,720,0,0
- 1280,720,1280,377,949,512
record:
enabled: True
events:
objects:
- person
required_zones:
- zone_0_voordeur
retain:
default: 5
mode: active_objects
snapshots:
enabled: True
clean_copy: False
retain:
default: 5
################################################################################
frigate_oprit:
ffmpeg:
inputs:
- path: rtsp://XXX/videoSub
roles:
- detect
- rtmp
- path: rtsp://XXX/videoMain
roles:
- record
rtmp:
enabled: False
detect:
width: 1280
height: 720
zones:
zone_0_oprit:
coordinates: 530,32,740,25,846,720,137,720
objects:
track:
- person
filters:
person:
min_area: 3000
mask: 44,296,181,460,317,462,367,571,311,720,0,720,0,346
motion:
mask: 0,39,374,38,373,0,0,0
record:
enabled: True
events:
objects:
- person
required_zones:
- zone_0_oprit
retain:
default: 5
mode: active_objects
snapshots:
enabled: True
clean_copy: False
retain:
default: 5
################################################################################
frigate_tuin:
ffmpeg:
inputs:
- path: rtsp://XXX/videoSub
roles:
- detect
- rtmp
- path: rtsp://XXX/videoMain
roles:
- record
rtmp:
enabled: False
detect:
width: 1280
height: 720
zones:
zone_0_tuin:
coordinates: 0,720,1280,720,1107,89,0,82
objects:
track:
- person
filters:
person:
min_area: 5000
mask: 769,93,845,92,848,194,767,194
motion:
mask:
- 0,96,739,86,741,184,856,181,853,86,1130,96,1114,235,1280,471,1280,105,1280,0,0,0
- 0,421,142,391,250,356,333,314,397,280,410,243,366,213,282,194,146,195,0,215
record:
enabled: True
events:
objects:
- person
required_zones:
- zone_0_tuin
retain:
default: 5
mode: active_objects
snapshots:
enabled: True
clean_copy: False
retain:
default: 5
Any advise? I'm reading the DOCS and Github Issues for weeks now. But can't get it to work stable.
Detector getting stuck is usually a host issue. Some users have found in proxmox using lxc instead of VM works better. I'd suggesting searching past issues for that error.
Hi Nick,
I have a system with only Home Assistant installed. Is that also a Vitual Machine setup?
No, in that case might be a hardware issue. Do you have different USB ports to try?
Yes I have 2 USB 3.0 ports. I switched port last week but that did not solve this issue.
Could it be the Coral USB not getting enough power?
I guess as a test you could try CPU detectors to rule it out?
Thanks for thinking with me Nick and Laurence.
Yes it could be a power issue. I will check it and post an update.
I'm a Linux newb but try checking the following areas to check for log details:
Subsite "nano" with your text editor of your choice such as vi or just use the cat command to see the contents of these files. Home Assistant OS might store these files in a different location so I am not sure on that. You might need to allow SSH / terminal access first as well if you cannot find the logs otherwise. nano /var/log/debug nano /var/log/syslog (will be pretty full and may be harder to browse) nano /var/log/user.log nano /var/log/kern.log
Also try the following commands: journalctl dmesg -l 0,1,2,3 dmesg (if the above doesn't help)
I think you are right Laurence
Output of the dmesg:
First google result:
Update: I changed my power supply and will post an update tomorrow
@yanivf38 did you solve your challenge?
Snap, I get the same about once or twice a day... Works fine though so I'm leaving it be.
[2391261.094972] usb 2-2: reset SuperSpeed USB device number 4 using xhci_hcd [2391261.113637] usb 2-2: LPM exit latency is zeroed, disabling LPM.
Also in the Frigate logs occasionally, I assume related but might not be...
''2023-04-06 01:22:18.475157321 [2023-04-06 01:22:18] frigate.watchdog INFO : Detection appears to be stuck. Restarting detection process... 2023-04-06 01:22:18.476173821 [2023-04-06 01:22:18] root INFO : Waiting for detection process to exit gracefully...
2023-04-06 01:22:48.505573469 [2023-04-06 01:22:48] root INFO : Detection process didnt exit. Force killing... 2023-04-06 01:22:48.529025506 [2023-04-06 01:22:48] root INFO : Detection process has exited... 2023-04-06 01:22:48.605190062 [2023-04-06 01:22:48] detector.coral INFO : Starting detection process: 10963 2023-04-06 01:22:48.612780932 [2023-04-06 01:22:48] frigate.detectors.plugins.edgetpu_tfl INFO : Attempting to load TPU as usb 2023-04-06 01:22:51.941904393 [2023-04-06 01:22:51] frigate.detectors.plugins.edgetpu_tfl INFO : TPU found''
I've never had it get stuck like yours though.
The Raspberry Pi 4 itself never gets any undervolt issues, and on USB it's just the Coral and a very low power SSD (SSDs can vary a lot in power). Perhaps the Pi 4 just cannot handle the burst current the Coral requires, or there is some other issue..
Hmmm... My LOGS are clear for now after changing the power supply:
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
Describe the problem you are having
Version
0.11.1-2EADA21
Frigate config file
docker-compose file or Docker CLI command
Relevant log output
Operating system
HassOS
Install method
HassOS Addon
Coral version
USB
Any other information that may be helpful
No response