Bonjour, a tous,
Voila depuis depuis quelques années j’ai monté un NVR diy. mon choix c’etait porte sous AGentDVR (iSPy) avec comme IA codeproject ( deepstack) pour la detection des objet et des facials.
Ce choix c’est fait car a l’époque frigate ne proposait pas vraiment d’interface sympa et pas de coral donc bref…
Avec l’évolution 0.14, il commence a me plaire est entièrement gratuit.
Pour le matériel
I5i5-3470 CPU @ 3.20GHz
16go de ram
Nvidia quadro P400 2Gb
nombre de camera 4
- Amcrest AD110 (doorbell) 2MP
- Dahua DH-SD22404T-GN PTZ
- 2 chinois de 2MP
En ce qui concerne le fonctionnement tout ce petit monde marche sans souci , peux de latence de lag et pas de surcharge du matos.
Voila que les choses se gâtent. je passe sous frigate et la c’est le drame.
la latence ca peux encore allé avec Go2rtc, mais j’ai des coupures régulière. des détections bien aléatoires. et surtout des surcharges du cpu et de la carte graphique.
je ne doutent pas que friaget peux faire aussi bien si ce n’est mieux que AgentDVR mais pour le moment il est loin d’égaler mon setup. je ne met pas en doute le soft mais plus ma config pou mes paramétres.
C’est la que j’ai besoins de votre aide car j’aimerais le faire tourner au mieux.
Pour ce qui est du matos on change rien, je sais qu’un coral est supérieur a ma Quadro mais jusqu’a present elle fait le Job, donc dont’ act de ce coté la.
je ne peux me servir Igpu faut bouger le buios et tout. et ipsy ne s’en sert pas.
POur ce que je désire faire tourner sans trop de latence et pas de lag pour la partie live. et pour la détection on reste sur du CodeProject avec DoubleTake.
pour la config actuelle:
Docker Frigate:
version: "3.9"
services:
frigate:
container_name: frigate
privileged: true # this may not be necessary for all setups
restart: unless-stopped
image: ghcr.io/blakeblackshear/frigate:stable
runtime: nvidia
shm_size: "1g" # update for your cameras based on calculation : Example for 8 cameras detecting at 1280x720, including logs
# python -c 'print("{:.2f}MB".format(((1280 * 720 * 1.5 * 9 + 270480) / 1048576) * 8 + 30))'
#126.99MB
deploy:
resources:
reservations:
devices:
- driver: nvidia
count: 1
capabilities: [gpu]
volumes:
- /etc/localtime:/etc/localtime:ro
- /docker/frigate/config/:/config/
- /docker/frigate/data:/media/frigate
- type: tmpfs # Optional: 1GB of memory, reduces SSD/SD Card wear
target: /tmp/cache
tmpfs:
size: 1000000000
ports:
- "5000:5000"
- "8554:8554" # RTSP feeds
- "8555:8555/tcp" # WebRTC over tcp
- "8555:8555/udp" # WebRTC over udp
- "1984:1984"
environment:
TZ: Europe/Paris
FRIGATE_RTSP_PASSWORD: "xxxxx"
sa config
mqtt:
host: 172.16.128.xxx
port: 1883
user: mqtt
password: xxx
stats_interval: 60
ffmpeg:
hwaccel_args: preset-nvidia-h264
detectors:
codeproject:
api_url: http://172.16.128.xxxx68/v1/vision/detection
type: deepstack
api_timeout: 20 # seconds
birdseye:
enabled: false
snapshots:
enabled: true
# Optional: save a clean PNG copy of the snapshot image (default: shown below)
clean_copy: true
# Optional: print a timestamp on the snapshots (default: shown below)
timestamp: true
# Optional: draw bounding box on the snapshots (default: shown below)
bounding_box: true
# Optional: crop the snapshot (default: shown below)
crop: false
# Optional: Camera override for retention settings (default: global values)
retain:
# Required: Default retention days (default: shown below)
default: 3
# Optional: Per object retention days
objects:
person: 3
# Optional: Record configuration
# NOTE: Can be overridden at the camera level
record:
enabled: true
# Optional: Number of minutes to wait between cleanup runs (default: shown below)
# This can be used to reduce the frequency of deleting recording segments from disk if you want to minimize i/o
expire_interval: 60
# Optional: Retention settings for recording
retain:
# Optional: Number of days to retain recordings regardless of events (default: shown below)
# NOTE: This should be set to 0 and retention should be defined in events section below
# if you only want to retain recordings of events.
days: 3
# Optional: Mode for retention. Available options are: all, motion, and active_objects
# all - save all recording segments regardless of activity
# motion - save all recordings segments with any detected motion
# active_objects - save all recording segments with active/moving objects
# NOTE: this mode only applies when the days setting above is greater than 0
#mode: active_objects
# Optional: Event recording settings
events:
# Optional: Number of seconds before the event to include (default: shown below)
pre_capture: 5
# Optional: Number of seconds after the event to include (default: shown below)
post_capture: 5
# Optional: Objects to save recordings for. (default: all tracked objects)
objects:
- person
# Optional: Retention settings for recordings of events
retain:
# Required: Default retention days (default: shown below)
default: 3
# Optional: Mode for retention. (default: shown below)
# all - save all recording segments for events regardless of activity
# motion - save all recordings segments for events with any detected motion
# active_objects - save all recording segments for event with active/moving objects
#
# NOTE: If the retain mode for the camera is more restrictive than the mode configured
# here, the segments will already be gone by the time this mode is applied.
# For example, if the camera retain mode is "motion", the segments without motion are
# never stored, so setting the mode to "all" here won't bring them back.
mode: active_objects
# Optional: Per object retention days
objects:
person: 3
cameras:
sonette:
ffmpeg:
inputs:
- path: rtsp://127.0.0.1:8554/sonette
input_args: preset-rtsp-restream
roles:
- record
- detect
# hwaccel_args: preset-vaapi
detect:
# width: 1280 #width of the frame for the input with the detect role
# height: 720 #height of the frame for the input with the detect role (default: shown below)
fps: 5 #Recommended value of 5. Ideally, try and reduce your FPS on the camera.
enabled: true
objects:
track:
- person
- dog
- cat
- car
# - mouse
filters:
person:
# Optional: minimum score for the object to initiate tracking (default: shown below)
min_score: 0.7
# Optional: minimum decimal percentage for tracked object's computed score to be considered a true positive (default: shown below)
threshold: 0.8
car: {}
mask: 0.003,0.002,0.775,0.004,0.669,0.212,0.686,0.655,0.323,0.67,0,0.899,0.002,0.631
zones:
Palier:
coordinates:
0.778,0.006,0.998,0.004,0.991,0.987,0.011,0.998,0.005,0.907,0.323,0.683,0.696,0.669,0.683,0.21
inertia: 5
loitering_time: 4
review:
alerts:
required_zones: Palier
detections:
required_zones: Palier
motion:
threshold: 50
contour_area: 10
improve_contrast: 'false'
mask: 0.003,0.007,0.764,0.011,0.663,0.218,0.679,0.648,0.323,0.661,0.01,0.885
test:
ffmpeg:
inputs:
- path: rtsp://127.0.0.1:8554/test
input_args: preset-rtsp-restream
roles:
- record
- detect
# hwaccel_args: preset-nvidia-h264
detect:
# width: 1280 #width of the frame for the input with the detect role
# height: 720 #height of the frame for the input with the detect role (default: shown below)
fps: 5 #Recommended value of 5. Ideally, try and reduce your FPS on the camera.
enabled: true
objects:
track:
- person
# - dog
- cat
# - bird
# - mouse
filters:
person:
# Optional: minimum score for the object to initiate tracking (default: shown below)
min_score: 0.7
# Optional: minimum decimal percentage for tracked object's computed score to be considered a true positive (default: shown below)
threshold: 0.8
mask: 0.598,0.011,0.003,0.009,0.004,0.987,0.574,0.985
motion:
mask: 0.001,0.004,0.603,0.007,0.577,0.994,0.002,0.991
threshold: 60
contour_area: 30
improve_contrast: 'true'
zones:
test2:
coordinates: 0.608,0.007,0.994,0.007,0.994,0.991,0.586,0.989
loitering_time: 0
review:
alerts:
required_zones: test2
detections:
required_zones: test2
imprimate:
ffmpeg:
inputs:
- path: rtsp://127.0.0.1:8554/imprimante
input_args: preset-rtsp-restream
onvif:
host: 172.16.128.20
port: 80
user: xxxx
password: xxxxxx
garage:
ffmpeg:
inputs:
- path: rtsp://127.0.0.1:8554/garage
input_args: preset-rtsp-restream
roles:
- detect
detect:
# width: 1280
# height: 720
fps: 5
enabled: true
objects:
track:
- person - dog - cat - car
# - mouse
filters:
person:
# Optional: minimum score for the object to initiate tracking (default: shown below)
min_score: 0.7
# Optional: minimum decimal percentage for tracked object's computed score to be considered a true positive (default: shown below)
threshold: 0.8
motion:
threshold: 60
contour_area: 10
improve_contrast: 'true'
go2rtc:
streams:
sonette:
- rtsp:/xxxx:xxxx@1.1.2.3.3:554/cam/realmonitor?channel=1&subtype=0&authbasic=64
- rtsp://xxxx:xxxx@1.1.2.3.3:554/cam/realmonitor?channel=1&subtype=1&authbasic=64
test:
- rtsp://admin:admin@1.2.3.4:554/ch0.h264
- rtps://admin:admin@1.2.3.4:554/ch1.h264
imprimante:
- rtsp://xxxxx:xxxx@1.2.3.5:554/cam/realmonitor?channel=1&subtype=2&unicast=true&proto=Onvif
garage:
- rtsp://172.16.128.123:554/0
webrtc:
listen: :8555 # address of your local server and port (TCP/UDP)
candidates:
- 172.16.128.41:8555 # if you have static public IP-address (1.2.3.4 To replace by External Public IP)
- stun:8555 # if you have dynamic public IP-address
version: 0.14
Voila aidez a prouver que frigate et bien meilleur que Ispy et dite mois ce que je peux améliorer, corriger , modifier.
Merci