My configuration does not capture any cats, dogs, birds or raccoons! It’s frustrating. I have read a lot the documentations, and I just get lost.
For the detection of person, cat, bird, and raccoon in Frigate, using a Lorex camera model E892AB, attached to the corner of a soffit of a house (about 10 feet from the ground, with a distance from the camera to the closest point on the ground of 11 feet, and the farthest point from the camera, being detected, of around 24 feet.
How do people figure out the resolution, width, height, min_area, max_area, based on the distance of a camera?
Is their a formula or a method that people use to figure out these values?
Furthermore, I am not getting not that many snapshots in the camera3 area to attempt to analyze, guess for values. The only ones I get are from object, person.
Is there a way to get more information about the object on the bounding_box?
This is my current yaml for one of the camera. I hope someone would help.
Yaml Code:
#--------------------------------
# <------ Name the camera 3 BEGIN
#--------------------------------
camera3:
enabled: true
ffmpeg:
output_args:
record: preset-record-generic-audio-copy
inputs:
- path: rtsp://admin:[email protected]:554/cam/realmonitor?channel=3&subtype=1
input_args: preset-rtsp-restream
roles:
- detect
- path: rtsp://admin:[email protected]:554/cam/realmonitor?channel=3&subtype=0
roles:
- record
detect:
width: 1920 # <- optional, by default Frigate tries to automatically detect resolution
height: 1080 # <- optional, by default Frigate tries to automatically detect resolution
fps: 5
stationary:
interval: 30
threshold: 70
# object track ????
objects:
track:
- person
#- dog
- cat
- bird
- raccoon
filters: # experimental from https://docs.frigate.video/configuration/object_filters
#person:
# min_area: 5000
# min_score: 0.6 # Orig 0.5
# threshold: 0.8 # Orig 0.6
# min_ratio: 0.5
# max_ratio: 1.0
person:
min_area: 10000 # Persons are typically larger, so use a higher minimum area to filter smaller objects
max_area: 100000 # Set a large max area to filter out anything too large
min_score: 0.7 # Confidence score for detection, ensure relatively high accuracy
threshold: 0.7 # Threshold for detection, increase if you're getting too many false positives
min_ratio: 0.4 # Persons tend to be tall and narrow (standing position)
max_ratio: 1.0 # Allow some flexibility in ratio for different body postures
#dog:
# min_area: 5000
# min_score: 0.6 # Orig 0.5
# threshold: 0.85 # Orig 0.6
cat:
min_area: 2000 # Adjust depending on the size and distance of the object in view
max_area: 10000 # Limit larger object detections
min_score: 0.6 # Confidence score for detection
threshold: 0.7 # Higher threshold to avoid false positives
min_ratio: 0.4 # Cat's body tends to be longer than it is tall
max_ratio: 2.0 # Allow for a longer body, so the width can be up to twice the height
bird:
min_area: 500 # Small area for small birds
max_area: 2000 # Limit larger object detections
min_score: 0.7 # Confidence score for detection
threshold: 0.7 # Higher threshold to reduce false positives
min_ratio: 0.5 # Birds have a relatively balanced height-to-width ratio
max_ratio: 1.5 # Allows for slight variations when wings are spread or folded
raccoon:
min_area: 3000 # Raccoons are larger than small animals, so increase the minimum area
max_area: 15000 # Maximum area to filter out larger objects (like people)
min_score: 0.6 # Confidence score for detection
threshold: 0.6 # Adjust based on detection accuracy (increase if false positives occur)
min_ratio: 0.7 # Raccoons have a slightly longer body than their height, so adjust the ratio
max_ratio: 1.8 # Account for flexibility in posture, allowing wider objects to be detected
# Optional: Record configuration
record:
enabled: true
retain:
days: 3
mode: active_objects #options: all motion active_objects
events:
pre_capture: 20
post_capture: 20
retain:
default: 3
mode: active_objects #options: All motion active_objects
# Optional: Objects to save recordings for. (default: all tracked objects)
objects:
- person
#- dog
- cat
- bird
- raccoon
# Optional: Per object retention days
# person: 7
# cat: 3
# bird: 2
# raccoon: 3
# Optional: Configuration for the jpg snapshots written to the clips directory for each event
snapshots:
enabled: true
timestamp: true
bounding_box: true
crop: false
retain:
default: 3
# Optional: Configuration clips
#clips:
# enabled: true
# retain:
# default: 2
zones:
front3_zone1:
coordinates:
0.004,0.988,0.006,0.139,0.141,0.102,0.284,0.091,0.453,0.115,0.661,0.155,0.677,0.093,0.742,0.092,0.742,0.184,0.792,0.227,0.919,0.392,0.911,0.478,0.979,0.234,0.995,0.252,0.995,0.423,0.901,0.68,0.771,0.991
loitering_time: 0 # Orig 0
objects:
- person
#- dog
- cat
- bird
- raccoon
inertia: 3
motion:
mask:
- 0.124,0,0.127,0.027,0.184,0.026,0.372,0.034,0.584,0.062,0.682,0.077,0.744,0.079,0.75,0.17,0.922,0.325,0.92,0.373,0.929,0.386,0.978,0.213,1,0.236,1,0
- 0.782,0.984,0.995,0.991,0.997,0.455
review:
alerts:
required_zones: front3_zone1
detections:
required_zones: front3_zone1