Coral and Intel 630 OpenVino[Detector Support]: #22504
Describe the problem you are havingI have Frigate running on bare-metal debian with docker compose. I have a Coral, but the PC has an Intel 630 graphics chipset. Should I be using the coral, the intel GPU (with OpenVino?) or both? How should I configure this if so? Version0.17.0-f0d69f7 Frigate config filemqtt:
enabled: false
detectors:
coral:
type: edgetpu
device: pci
audio:
enabled: false
detect:
enabled: true
record:
enabled: true
continuous:
days: 7
alerts:
retain:
days: 30
mode: motion
detections:
retain:
days: 30
mode: motion
motion:
days: 7
snapshots:
enabled: true
retain:
default: 30
ffmpeg:
hwaccel_args: preset-vaapi
output_args:
record: preset-record-generic-audio-copy
go2rtc:
streams:
Cam_01_Kitchen:
- rtsp://redacted:redacted@192.168.123.81:554/H265/ch1/main/av_stream
Cam_02_Workshop:
- rtsp://redacted:redacted@192.168.123.82:554/H265/ch1/main/av_stream
Cam_03_Lounge:
- rtsp://redacted:redacted@192.168.123.83:554/H265/ch1/main/av_stream
Cam_04_Landing:
- rtsp://redacted:redacted@192.168.123.84:554/H265/ch1/main/av_stream
Cam_05_Cabin:
- rtsp://redacted:redacted@192.168.123.85:554/H265/ch1/main/av_stream
Cam_06_B3:
- rtsp://redacted:redacted@192.168.123.86:554/H265/ch1/main/av_stream
Cam_07_B4:
- rtsp://redacted:redacted@192.168.123.87:554/H265/ch1/main/av_stream
Cam_08_B2:
- rtsp://redacted:redacted@192.168.123.88:554/H265/ch1/main/av_stream
Cam_09_B1:
- rtsp://redacted:redacted@192.168.123.89:554/H265/ch1/main/av_stream
Cam_10_Garage:
- rtsp://redacted:redacted@192.168.123.90:554/H265/ch1/main/av_stream
Cam_11_Cons:
- rtsp://redacted:redacted@192.168.123.91:554/H265/ch1/main/av_stream
Cam_12:
- rtsp://redacted:redacted@192.168.123.92:554/H265/ch1/main/av_stream
Cam_13:
- rtsp://redacted:redacted@192.168.123.93:554/H265/ch1/main/av_stream
cameras:
Cam_01_Kitchen:
enabled: true
ffmpeg:
hwaccel_args: preset-vaapi
inputs:
- path:
rtsp://redacted:redacted@192.168.123.81:554/H265/ch2/sub/av_stream
roles:
- detect
- path:
rtsp://redacted:redacted@192.168.123.81:554/H265/ch1/main/av_stream
roles:
- record
detect:
enabled: true
width: 1280
height: 720
fps: 6
motion:
mask: 0.452,0.085,0.45,0.178,0.477,0.183,0.479,0.092
record:
enabled: true
Cam_02_Workshop:
enabled: true
ffmpeg:
hwaccel_args: preset-vaapi
inputs:
- path:
rtsp://redacted:redacted@192.168.123.82:554/H265/ch2/sub/av_stream
roles:
- detect
- path:
rtsp://redacted:redacted@192.168.123.82:554/H265/ch1/main/av_stream
roles:
- record
detect:
enabled: true
width: 1280
height: 720
fps: 6
record:
enabled: true
Cam_03_Lounge:
enabled: true
ffmpeg:
hwaccel_args: preset-vaapi
inputs:
- path:
rtsp://redacted:redacted@192.168.123.83:554/H265/ch2/sub/av_stream
roles:
- detect
- path:
rtsp://redacted:redacted@192.168.123.83:554/H265/ch1/main/av_stream
roles:
- record
detect:
enabled: true
width: 1280
height: 720
fps: 6
motion:
mask:
- 0.87,0.097,0.847,0.327,0.893,0.373,0.923,0.125
- 0.659,0.059,0.657,0.231,0.68,0.238,0.692,0.054
- 0.109,0.01,0.109,0.065,0.152,0.07,0.153,0.01
record:
enabled: true
Cam_04_Landing:
enabled: true
ffmpeg:
hwaccel_args: preset-vaapi
inputs:
- path:
rtsp://redacted:redacted@192.168.123.84:554/H265/ch2/sub/av_stream
roles:
- detect
- path:
rtsp://redacted:redacted@192.168.123.84:554/H265/ch1/main/av_stream
roles:
- record
detect:
enabled: true
width: 1280
height: 720
fps: 6
record:
enabled: true
motion:
mask:
- 0.009,0.583,0.08,0.696,0.131,0.789,0.17,0.886,0.208,1,0.009,0.993
- 0.895,0.98,0.992,0.644,0.995,0.989
Cam_05_Cabin:
enabled: true
ffmpeg:
hwaccel_args: preset-vaapi
inputs:
- path:
rtsp://redacted:redacted@192.168.123.85:554/H265/ch2/sub/av_stream
roles:
- detect
- audio
- path:
rtsp://redacted:redacted@192.168.123.85:554/H265/ch1/main/av_stream
roles:
- record
detect:
enabled: true
width: 1280
height: 720
fps: 6
record:
enabled: true
audio:
enabled: true
Cam_06_B3:
enabled: true
ffmpeg:
hwaccel_args: preset-vaapi
inputs:
- path:
rtsp://redacted:redacted@192.168.123.86:554/H264/ch2/sub/av_stream
roles:
- detect
- audio
- path:
rtsp://redacted:redacted@192.168.123.86:554/H265/ch1/main/av_stream
roles:
- record
detect:
enabled: true
width: 1280
height: 720
fps: 6
record:
enabled: true
audio:
enabled: true
motion:
mask:
- 0.605,0.4,0.667,0.367,0.657,0.985,0.593,0.982
- 0.624,0.271,0.618,0.367,0.686,0.339,0.688,0.222
Cam_07_B4:
enabled: true
ffmpeg:
hwaccel_args: preset-vaapi
inputs:
- path:
rtsp://redacted:redacted@192.168.123.87:554/H265/ch1/sub/av_stream
roles:
- detect
- audio
- path:
rtsp://redacted:redacted@192.168.123.87:554/H265/ch1/main/av_stream
roles:
- record
detect:
enabled: true
width: 1280
height: 720
fps: 6
record:
enabled: true
audio:
enabled: true
Cam_08_B2:
enabled: true
ffmpeg:
hwaccel_args: preset-vaapi
inputs:
- path:
rtsp://redacted:redacted@192.168.123.88:554/H265/ch2/sub/av_stream
roles:
- detect
- audio
- path:
rtsp://redacted:redacted@192.168.123.88:554/H265/ch1/main/av_stream
roles:
- record
detect:
enabled: true
width: 1280
height: 720
fps: 6
record:
enabled: true
audio:
enabled: true
Cam_09_B1:
enabled: true
ffmpeg:
hwaccel_args: preset-vaapi
inputs:
- path:
rtsp://redacted:redacted@192.168.123.89:554/H265/ch2/sub/av_stream
roles:
- detect
- audio
- path:
rtsp://redacted:redacted@192.168.123.89:554/H265/ch1/main/av_stream
roles:
- record
detect:
enabled: true
width: 1280
height: 720
fps: 6
record:
enabled: true
audio:
enabled: true
Cam_10_Garage:
enabled: true
ffmpeg:
hwaccel_args: preset-vaapi
inputs:
- path:
rtsp://redacted:redacted@192.168.123.90:554/H265/ch1/sub/av_stream
roles:
- detect
- audio
- path:
rtsp://redacted:redacted@192.168.123.90:554/H265/ch1/main/av_stream
roles:
- record
detect:
enabled: true
width: 1280
height: 720
fps: 6
record:
enabled: true
audio:
enabled: true
Cam_11_Cons:
enabled: true
ffmpeg:
hwaccel_args: preset-vaapi
inputs:
- path:
rtsp://redacted:redacted@192.168.123.91:554/H265/ch2/sub/av_stream
roles:
- detect
- audio
- path:
rtsp://redacted:redacted@192.168.123.91:554/H265/ch1/main/av_stream
roles:
- record
detect:
enabled: true
width: 1280
height: 720
fps: 6
record:
enabled: true
audio:
enabled: true
Cam_12:
enabled: true
ffmpeg:
hwaccel_args: preset-vaapi
inputs:
- path:
rtsp://redacted:redacted@192.168.123.92:554/H265/ch2/sub/av_stream
roles:
- detect
- audio
- path:
rtsp://redacted:redacted@192.168.123.92:554/H265/ch1/main/av_stream
roles:
- record
detect:
enabled: true
width: 1280
height: 720
fps: 6
record:
enabled: true
audio:
enabled: true
objects:
mask: 0.294,0.293,0.289,0.38,0.339,0.399,0.354,0.305
Cam_13:
enabled: true
ffmpeg:
hwaccel_args: preset-vaapi
inputs:
- path:
rtsp://redacted:redacted@192.168.123.93:554/H265/ch2/sub/av_stream
roles:
- detect
- audio
- path:
rtsp://redacted:redacted@192.168.123.93:554/H265/ch1/main/av_stream
roles:
- record
detect:
enabled: true
width: 1280
height: 720
fps: 6
record:
enabled: true
audio:
enabled: true
camera_groups:
group1:
order: 1
icon: LuAirplay
cameras:
- Cam_01_Kitchen
- Cam_02_Workshop
- Cam_03_Lounge
- Cam_04_Landing
- Cam_05_Cabin
- Cam_06_B3
- Cam_07_B4
- birdseye
- Cam_08_B2
- Cam_09_B1
- Cam_10_Garage
- Cam_11_Cons
- Cam_12
- Cam_13
version: 0.17-0docker-compose file or Docker CLI commandservices:
frigate:
container_name: frigate
privileged: true # this may not be necessary for all setups
restart: unless-stopped
stop_grace_period: 30s # allow enough time to shut down the various services
image: ghcr.io/blakeblackshear/frigate:0.17.0
cap_add:
- CAP_PERFMON
shm_size: "626mb" # update for your cameras based on calculation above
devices:
- /dev/apex_0:/dev/apex_0 # Passes a PCIe Coral, follow driver instructions here https://github.com/jnicolson/gasket-builder
- /dev/dri/renderD128:/dev/dri/renderD128 # Passes an Intel GPU (I think?!)
volumes:
- /etc/localtime:/etc/localtime:ro
- /config:/config
- /mnt/cctv_storage/Frigate:/media/frigate
- type: tmpfs # Optional: 1GB of memory, reduces SSD/SD Card wear
target: /tmp/cache
tmpfs:
size: 1000000000
ports:
- "8971:8971"
# - "5000:5000" # Internal unauthenticated access. Expose carefully.
- "8554:8554" # RTSP feeds
- "8555:8555/tcp" # WebRTC over tcp
- "8555:8555/udp" # WebRTC over udp
environment:
FRIGATE_RTSP_PASSWORD: "password"Relevant Frigate log outputnot relevant to this questionInstall methodDocker Compose Object DetectorCoral Screenshots of the Frigate UI's System metrics pagesnot relevant Any other information that may be helpfulNo response |
Replies: 1 comment
|
Multiple detectors cannot be mixed for object detection—for example, OpenVINO and Coral EdgeTPU cannot be used for object detection at the same time. (1) Your current setup using the Coral EdgeTPU for object detection is a good choice. The Coral is one of the most efficient detectors available, providing fast inference speeds with low power consumption. (1) Your Intel HD 630 GPU is being used appropriately for hardware-accelerated video decoding via your So your configuration is actually well-optimized:
These are two separate tasks, and your current setup uses each piece of hardware for what it does best. (2), (3) If you wanted to use OpenVINO with your Intel GPU for object detection instead of the Coral, you could configure it like this: detectors:
ov:
type: openvino
device: GPU
model:
width: 300
height: 300
input_tensor: nhwc
input_pixel_format: bgr
path: /openvino-model/ssdlite_mobilenet_v2.xml
labelmap_path: /openvino-model/coco_91cl_bkgr.txtHowever, the Coral TPU typically provides faster inference speeds than an integrated GPU like the HD 630, so sticking with your Coral configuration is recommended. Keep your Intel GPU for video decoding via VA-API as you have it configured. 📚 Sources: Have another question? Just tag @inkeep. |
Multiple detectors cannot be mixed for object detection—for example, OpenVINO and Coral EdgeTPU cannot be used for object detection at the same time. (1)
Your current setup using the Coral EdgeTPU for object detection is a good choice. The Coral is one of the most efficient detectors available, providing fast inference speeds with low power consumption. (1)
Your Intel HD 630 GPU is being used appropriately for hardware-accelerated video decoding via your
hwaccel_args: preset-vaapiconfiguration. This offloads the CPU from having to decode your camera streams. (2)So your configuration is actually well-optimized: