[Camera Support]: Imou IPC-F42FE #12463
-
Describe the problem you are havingI have three of these cameras. They have been working ok-ish until a few days ago (not perfect thou, the detection is hit and miss and recording hasn't been working in a month). Now I notice that the ffmpeg crashes all the time! Version0.13.2 Frigate config fileui:
# use_experimental: false
live_mode: mse
mqtt:
enabled: True
host: 192.168.1.xxx
port: 1883
topic_prefix: frigate
client_id: frigate
user: homeassistant
password: super strong password
stats_interval: 60
database:
path: /config/frigate.db
detectors:
coral:
type: edgetpu
device: pci:0
objects:
track:
- person
filters:
person:
min_area: 5000
max_area: 100000
min_ratio: 0.5
max_ratio: 2.0
min_score: 0.5
threshold: 0.7
snapshots:
enabled: True
clean_copy: True
timestamp: True
bounding_box: True
crop: False
required_zones:
- geam_living
- usa_veranda
- gate
- kitchen_window
retain:
default: 10
objects:
person: 15
quality: 100
birdseye:
enabled: True
mode: continuous
width: 1280
height: 720
quality: 10
ffmpeg:
global_args: -hide_banner -loglevel warning -threads 2
# hwaccel_args:
# - preset-intel-qsv-h265
# - /dev/dri/renderD128
hwaccel_args:
- -hwaccel
# - preset-intel-qsv-h265
- vaapi
- -hwaccel_device
- /dev/dri/renderD128
- -hwaccel_output_format
- yuv420p
# hwaccel_args:
# -hwaccel vaapi
# -hwaccel_device /dev/dri/renderD128
input_args: preset-rtsp-restream -avoid_negative_ts make_zero -fflags +genpts+discardcorrupt -stimeout 5000000 -an -rtsp_transport tcp
output_args:
detect: -threads 2 -f rawvideo -pix_fmt yuv420p
record: preset-record-generic-audio-copy
retry_interval: 10
go2rtc:
streams:
gate:
- rtsp://admin:[email protected]:554/cam/realmonitor?channel=1&subtype=0&unicast=true&proto=Onvif
- "ffmpeg:gate#audio=aac"
gate_sub:
- rtsp://admin:[email protected]:554/cam/realmonitor?channel=1&subtype=1&unicast=true&proto=Onvif
veranda:
- rtsp://admin:[email protected]:554/cam/realmonitor?channel=1&subtype=0&unicast=true&proto=Onvif
- "ffmpeg:veranda#audio=aac"
veranda_sub:
- rtsp://admin:[email protected]:554/cam/realmonitor?channel=1&subtype=1&unicast=true&proto=Onvif
terasa:
- rtsp://admin:[email protected]:554/cam/realmonitor?channel=1&subtype=0&unicast=true&proto=Onvif
- "ffmpeg:terasa#audio=aac"
terasa_sub:
- rtsp://admin:[email protected]:554/cam/realmonitor?channel=1&subtype=1&unicast=true&proto=Onvif
webrtc:
candidates:
- 192.168.1.66:8555
- stun: 8555
cameras:
gate_entrance:
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
live:
stream_name: gate_sub
quality: 8
detect:
width: 1280 # <---- update for your camera's resolution
height: 720 # <---- update for your camera's resolution
fps: 5
enabled: True # <---- disable detection until you have a working camera feed
min_initialized: 2
max_disappeared: 25
record:
enabled: True
expire_interval: 60
retain:
days: 7
mode: motion
events:
pre_capture: 5
post_capture: 5
retain:
default: 10
mode: active_objects
required_zones:
- geam_living
- usa_veranda
zones:
geam_living:
coordinates: 810,315,1007,318,1033,108,814,81
objects:
- person
usa_veranda:
coordinates: 637,241,659,311,872,720,611,720,550,328,405,322,425,79,642,69
objects:
- person
motion:
threshold: 30
lightning_threshold: 0.8
contour_area: 10
frame_alpha: 0.01
frame_height: 100
mask:
- 0,720,259,720,606,720,543,332,408,336,423,78,531,39,533,0,0,0
- 1280,0,1035,0,1017,318,934,429,759,448,754,514,871,720,1280,720
veranda_entrance:
ffmpeg:
inputs:
- path: rtsp://127.0.0.1:8554/veranda
input_args: preset-rtsp-restream
roles:
- record
- path: rtsp://127.0.0.1:8554/veranda_sub
input_args: preset-rtsp-restream
roles:
- detect
live:
stream_name: veranda_sub
quality: 8
detect:
width: 1280 # <---- update for your camera's resolution
height: 720 # <---- update for your camera's resolution
fps: 5
enabled: True # <---- disable detection until you have a working camera feed
min_initialized: 2
max_disappeared: 25
record:
enabled: True
expire_interval: 60
retain:
days: 7
mode: motion
events:
pre_capture: 5
post_capture: 5
retain:
default: 10
mode: active_objects
required_zones:
- gate
zones:
gate:
coordinates: 375,414,309,720,572,720,547,287,695,288,699,126,656,77,609,74,605,24,539,23,456,22,458,62,357,72
objects:
- person
motion:
threshold: 30
lightning_threshold: 0.8
contour_area: 10
frame_alpha: 0.01
frame_height: 100
mask:
- 439,0,442,64,362,67,359,0
- 692,279,968,720,1280,720,1280,0,696,0
terasa_back:
ffmpeg:
inputs:
- path: rtsp://127.0.0.1:8554/terasa
input_args: preset-rtsp-restream
roles:
- record
- path: rtsp://127.0.0.1:8554/terasa_sub
input_args: preset-rtsp-restream
roles:
- detect
live:
stream_name: terasa_sub
quality: 8
detect:
width: 1280 # <---- update for your camera's resolution
height: 720 # <---- update for your camera's resolution
fps: 5
enabled: True # <---- disable detection until you have a working camera feed
min_initialized: 2
max_disappeared: 25
record:
enabled: True
expire_interval: 60
retain:
days: 7
mode: motion
events:
pre_capture: 5
post_capture: 5
retain:
default: 10
mode: active_objects
required_zones:
- kitchen_window
- back_terrace
zones:
kitchen_window:
coordinates: 430,91,448,347,128,414,85,144
objects:
- person
back_terrace:
coordinates: 112,720,494,720,1280,720,1280,505,1162,458,688,339,686,74,633,80,631,236,443,265,433,88,85,138,89,182,0,213,34,511
objects:
- person
motion:
threshold: 30
lightning_threshold: 0.95
contour_area: 40
frame_alpha: 0.01
frame_height: 100
mask:
- 1280,0,1280,497,1180,475,1193,423,696,304,692,92,696,0 Relevant log output2024-07-16 02:46:52.213798258 [2024-07-16 02:46:52] watchdog.veranda_entrance INFO : Terminating the existing ffmpeg process...
2024-07-16 02:46:52.213852564 [2024-07-16 02:46:52] watchdog.veranda_entrance INFO : Waiting for ffmpeg to exit gracefully...
2024-07-16 02:46:54.465433034 [2024-07-16 02:46:54] watchdog.gate_entrance INFO : No frames received from gate_entrance in 20 seconds. Exiting ffmpeg...
2024-07-16 02:46:54.465513367 [2024-07-16 02:46:54] watchdog.gate_entrance INFO : Waiting for ffmpeg to exit gracefully...
2024-07-16 02:46:54.476174093 [2024-07-16 02:46:54] frigate.video ERROR : gate_entrance: Unable to read frames from ffmpeg process.
2024-07-16 02:46:54.476498650 [2024-07-16 02:46:54] frigate.video ERROR : gate_entrance: ffmpeg process is not running. exiting capture thread...
2024-07-16 02:46:54.477022957 [2024-07-16 02:46:54] watchdog.gate_entrance ERROR : No new recording segments were created for gate_entrance in the last 120s. restarting the ffmpeg record process...
2024-07-16 02:46:54.477174443 [2024-07-16 02:46:54] watchdog.gate_entrance INFO : Terminating the existing ffmpeg process...
2024-07-16 02:46:54.477177045 [2024-07-16 02:46:54] watchdog.gate_entrance INFO : Waiting for ffmpeg to exit gracefully...
2024-07-16 02:46:57.327316366 [2024-07-16 02:46:57] frigate.video ERROR : veranda_entrance: Unable to read frames from ffmpeg process.
2024-07-16 02:46:57.327388889 [2024-07-16 02:46:57] frigate.video ERROR : veranda_entrance: ffmpeg process is not running. exiting capture thread...
2024-07-16 02:47:02.221958613 [2024-07-16 02:47:02] watchdog.veranda_entrance ERROR : Ffmpeg process crashed unexpectedly for veranda_entrance.
2024-07-16 02:47:02.222098322 [2024-07-16 02:47:02] watchdog.veranda_entrance ERROR : The following ffmpeg logs include the last 100 lines prior to exit.
2024-07-16 02:47:02.222151843 [2024-07-16 02:47:02] ffmpeg.veranda_entrance.detect ERROR : rtsp://127.0.0.1:8554/veranda_sub: Invalid data found when processing input
2024-07-16 02:47:02.230832463 [2024-07-16 02:47:02] watchdog.veranda_entrance ERROR : No new recording segments were created for veranda_entrance in the last 120s. restarting the ffmpeg record process...
2024-07-16 02:47:02.230927943 [2024-07-16 02:47:02] watchdog.veranda_entrance INFO : Terminating the existing ffmpeg process...
2024-07-16 02:47:02.230980389 [2024-07-16 02:47:02] watchdog.veranda_entrance INFO : Waiting for ffmpeg to exit gracefully...
2024-07-16 02:47:04.489832459 [2024-07-16 02:47:04] watchdog.gate_entrance ERROR : Ffmpeg process crashed unexpectedly for gate_entrance.
2024-07-16 02:47:04.489883822 [2024-07-16 02:47:04] watchdog.gate_entrance ERROR : The following ffmpeg logs include the last 100 lines prior to exit.
2024-07-16 02:47:04.489963931 [2024-07-16 02:47:04] ffmpeg.gate_entrance.detect ERROR : Finishing stream 0:0 without any data written to it.
2024-07-16 02:47:04.490007658 [2024-07-16 02:47:04] ffmpeg.gate_entrance.detect ERROR : [swscaler @ 0x6205c00a2980] [swscaler @ 0x6205bffb2180] deprecated pixel format used, make sure you did set range correctly
2024-07-16 02:47:04.490117214 [2024-07-16 02:47:04] ffmpeg.gate_entrance.detect ERROR : [swscaler @ 0x6205c00a2980] [swscaler @ 0x6205bffe0ac0] deprecated pixel format used, make sure you did set range correctly
2024-07-16 02:47:04.490128868 [2024-07-16 02:47:04] ffmpeg.gate_entrance.detect ERROR : Output file is empty, nothing was encoded (check -ss / -t / -frames parameters if used)
2024-07-16 02:47:04.494995317 [2024-07-16 02:47:04] watchdog.gate_entrance ERROR : No new recording segments were created for gate_entrance in the last 120s. restarting the ffmpeg record process...
2024-07-16 02:47:04.495086287 [2024-07-16 02:47:04] watchdog.gate_entrance INFO : Terminating the existing ffmpeg process...
2024-07-16 02:47:04.495088348 [2024-07-16 02:47:04] watchdog.gate_entrance INFO : Waiting for ffmpeg to exit gracefully...
2024-07-16 02:47:07.346019971 [2024-07-16 02:47:07] frigate.video ERROR : veranda_entrance: Unable to read frames from ffmpeg process.
2024-07-16 02:47:07.346101714 [2024-07-16 02:47:07] frigate.video ERROR : veranda_entrance: ffmpeg process is not running. exiting capture thread... FFprobe output from your cameraroot@280e38c72fbf:/opt/frigate# ffmpeg rtsp://admin:[email protected]:554/cam/realmonitor?channel=1&subtype=0&unicast=true&proto=Onvif
[1] 5240
[2] 5241
[3] 5242
root@280e38c72fbf:/opt/frigate# ffmpeg version n5.1-2-g915ef932a3-20220731 Copyright (c) 2000-2022 the FFmpeg developers
built with gcc 12.1.0 (crosstool-NG 1.25.0.55_3defb7b)
configuration: --prefix=/ffbuild/prefix --pkg-config-flags=--static --pkg-config=pkg-config --cross-prefix=x86_64-ffbuild-linux-gnu- --arch=x86_64 --target-os=linux --enable-gpl --enable-version3 --disable-debug --enable-iconv --enable-libxml2 --enable-zlib --enable-libfreetype --enable-libfribidi --enable-gmp --enable-lzma --enable-fontconfig --enable-libvorbis --enable-opencl --enable-libpulse --enable-libvmaf --enable-libxcb --enable-xlib --enable-amf --enable-libaom --enable-libaribb24 --enable-avisynth --enable-libdav1d --enable-libdavs2 --disable-libfdk-aac --enable-ffnvcodec --enable-cuda-llvm --enable-frei0r --enable-libgme --enable-libass --enable-libbluray --enable-libjxl --enable-libmp3lame --enable-libopus --enable-mbedtls --enable-librist --enable-libtheora --enable-libvpx --enable-libwebp --enable-lv2 --enable-libmfx --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenh264 --enable-libopenjpeg --enable-libopenmpt --enable-librav1e --enable-librubberband --disable-schannel --enable-sdl2 --enable-libsoxr --enable-libsrt --enable-libsvtav1 --enable-libtwolame --enable-libuavs3d --enable-libdrm --enable-vaapi --enable-libvidstab --enable-vulkan --enable-libshaderc --enable-libplacebo --enable-libx264 --enable-libx265 --enable-libxavs2 --enable-libxvid --enable-libzimg --enable-libzvbi --extra-cflags=-DLIBTWOLAME_STATIC --extra-cxxflags= --extra-ldflags=-pthread --extra-ldexeflags=-pie --extra-libs='-ldl -lgomp' --extra-version=20220731
libavutil 57. 28.100 / 57. 28.100
libavcodec 59. 37.100 / 59. 37.100
libavformat 59. 27.100 / 59. 27.100
libavdevice 59. 7.100 / 59. 7.100
libavfilter 8. 44.100 / 8. 44.100
libswscale 6. 7.100 / 6. 7.100
libswresample 4. 7.100 / 4. 7.100
libpostproc 56. 6.100 / 56. 6.100 Frigate statsnot sure where that is Operating systemProxmox Install methodDocker Compose Object DetectorCoral Network connectionWireless Camera make and modelImou IPC-F42FE Any other information that may be helpfulNo response |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 18 replies
-
looks like ffmpeg is not receiving data from the cameras, would be good to see go2rtc logs |
Beta Was this translation helpful? Give feedback.
-
unfortunately, the errors are back.
The new settings you suggested appear to be much stable and for a good hours or so yesterday, there were no errors in the logs. This morning I had a look and saw all this. Should I be worried? Or are these things that can be ignored. |
Beta Was this translation helpful? Give feedback.
-
sorry but i can't close this yet. I am running frigate in portainer which is running in a proxmox lxc. with these new settings, the lxc will start consuming all the assigned ram and crash. Is there some method to make ffmpeg ignore the bad data that the cameras send sometimes? |
Beta Was this translation helpful? Give feedback.
ok I am home now. Here is the new config: