1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
|
ui:
use_experimental: false
live_mode: mse
mqtt:
enabled: true
host: ha ip
port: 1883
topic_prefix: frigate
client_id: frigate
user: mqttuser
password: mqttuser
stats_interval: 300
ffmpeg:
hwaccel_args: preset-nvidia-h264 #nvidia gpu
output_args:
record: preset-record-generic-audio-aac #sound out
# hwaccel_args: preset-vaapi
#錄影秒數
record:
expire_interval: 15
enabled: True
retain:
days: 7
mode: motion
# 註解掉 mode:連續錄影 motion 運動檢測 active_objects 物體移動 all 包含運動跟物體
events:
# pre_capture: 3 #偵測錄影前提前1秒
# post_capture: 3 #偵測錄影後剪輯往後3秒
retain:
default: 14
mode: active_objects
objects:
person: 7
#偵測器(運動檢測)
detectors:
tensorrt:
type: tensorrt
device: 0 #This is the default, select the first GPU
model:
path: /trt-models/yolov7-tiny-416.trt
input_tensor: nchw
input_pixel_format: rgb
width: 416
height: 416
objects:
track:
- person
filters:
person:
min_area: 5000
max_area: 100000
snapshots:
enabled: True
clean_copy: True
timestamp: False
bounding_box: True
crop: False
height: 175
required_zones: []
retain:
default: 7
objects:
person: 7
#錄影時間戳設置參數
timestamp_style:
position: "tl" #"tl" (top left), "tr" (top right), "bl" (bottom left), "br" (bottom right)
format: "%m/%d/%Y %H:%M:%S"
color:
red: 255
green: 255
blue: 255
thickness: 2
effect: shadow
go2rtc:
streams:
gate:
- "ffmpeg:rtsp://admin:pwsswd@192.168.88.53:554/stream1#video=copy#audio=copy#audio=aac"
gate_sub:
- "ffmpeg:rtsp://admin:passwd@192.168.88.53:554/stream2#video=copy#audio=copy#audio=aac"
3f:
- "ffmpeg:rtsp://admin:passwd@192.168.88.54:554/stream1#video=copy#audio=copy#audio=aac"
3f_sub:
- "ffmpeg:rtsp://admin:passwd@192.168.88.54:554/stream2#video=copy#audio=copy#audio=aac"
webrtc:
candidates:
- 127.0.0.1:8555
- stun:8555
cameras:
gate:
ffmpeg:
inputs:
- path: rtsp://127.0.0.1:8554/gate
input_args: preset-rtsp-restream
roles:
- record
- path: rtsp://127.0.0.1:8554/gate_sub
input_args: preset-rtsp-restream
roles:
- detect
record:
enabled: True
detect:
width: 640
height: 360
fps: 7
objects:
track:
- person
filters:
person:
mask:
- 0,190,135,128,138,90,252,95,270,149,483,165,561,360,640,360,640,0,0,0
min_score: 0.4
threshold: 0.5
min_area: 700
snapshots:
enabled: true
timestamp: true
bounding_box: true
crop: True
height: 500
retain:
default: 3
zones:
zone_0:
coordinates: 282,360,552,360,482,164,271,163,271,90,225,92,141,85,136,129,0,201,0,360
motion:
mask:
- 478,178,566,360,640,360,640,0,359,0,0,0,0,89,273,90,279,152
- 148,135,159,0,0,0,0,198
3f:
ffmpeg:
inputs:
- path: rtsp://127.0.0.1:8554/3f
input_args: preset-rtsp-restream
roles:
- record
- path: rtsp://127.0.0.1:8554/3f_sub
input_args: preset-rtsp-restream
roles:
- detect
record:
enabled: True
detect:
width: 640
height: 360
fps: 5
objects:
track:
- person
filters:
person:
mask:
- 0,0,0,311,640,307,640,360,0,360
min_score: 0.4
threshold: 0.5
min_area: 700
zones:
zone_0:
coordinates: 640,360,640,42,0,39,0,360
motion:
mask:
- 640,110,640,0,0,0,0,33
snapshots:
enabled: true
timestamp: true
bounding_box: true
crop: True
height: 500
retain:
default: 3
#detectors:
# coral:
# type: edgetpu
# device: usb
rtmp:
enabled: false
birdseye:
enabled: True
restream: False
width: 1920
height: 1080
quality: 8
mode: continuous
live:
height: 640
quality: 1
|