# Table of Contents - [Introduction | Frigate](#introduction-frigate) - [Custom Classification | Frigate](#custom-classification-frigate) - [api | Frigate](#api-frigate) - [Powered by MDX | Frigate](#powered-by-mdx-frigate) - [Generative AI | Frigate](#generative-ai-frigate) - [Troubleshooting Hardware | Frigate](#troubleshooting-hardware-frigate) - [Troubleshooting Resource Usage | Frigate](#troubleshooting-resource-usage-frigate) - [Frigate Configuration | Frigate](#frigate-configuration-frigate) - [Audio Detectors | Frigate](#audio-detectors-frigate) - [Advanced Options | Frigate](#advanced-options-frigate) - [Bird Classification | Frigate](#bird-classification-frigate) - [Birdseye | Frigate](#birdseye-frigate) - [Camera Configuration | Frigate](#camera-configuration-frigate) - [Camera Autotracking | Frigate](#camera-autotracking-frigate) - [Authentication | Frigate](#authentication-frigate) - [Enrichments | Frigate](#enrichments-frigate) - [FFmpeg presets | Frigate](#ffmpeg-presets-frigate) - [State Classification | Frigate](#state-classification-frigate) - [Object Descriptions | Frigate](#object-descriptions-frigate) - [Object Classification | Frigate](#object-classification-frigate) - [Configuring Generative AI | Frigate](#configuring-generative-ai-frigate) - [Face Recognition | Frigate](#face-recognition-frigate) - [Camera Specific Configurations | Frigate](#camera-specific-configurations-frigate) - [Review Summaries | Frigate](#review-summaries-frigate) - [Installing Frigate App | Frigate](#installing-frigate-app-frigate) - [Notifications | Frigate](#notifications-frigate) - [Metrics | Frigate](#metrics-frigate) - [Motion Detection | Frigate](#motion-detection-frigate) - [Masks | Frigate](#masks-frigate) - [Filters | Frigate](#filters-frigate) - [Available Objects | Frigate](#available-objects-frigate) - [Video Decoding | Frigate](#video-decoding-frigate) - [Live View | Frigate](#live-view-frigate) - [Stationary Objects | Frigate](#stationary-objects-frigate) - [Review | Frigate](#review-frigate) - [TLS | Frigate](#tls-frigate) - [Snapshots | Frigate](#snapshots-frigate) - [Recording | Frigate](#recording-frigate) - [License Plate Recognition (LPR) | Frigate](#license-plate-recognition-lpr-frigate) - [Camera setup | Frigate](#camera-setup-frigate) - [Glossary | Frigate](#glossary-frigate) - [Video pipeline | Frigate](#video-pipeline-frigate) - [Restream | Frigate](#restream-frigate) - [Community Supported Boards | Frigate](#community-supported-boards-frigate) - [Home Assistant network storage | Frigate](#home-assistant-network-storage-frigate) - [Planning a New Installation | Frigate](#planning-a-new-installation-frigate) - [Zones | Frigate](#zones-frigate) - [Updating | Frigate](#updating-frigate) - [Configuring go2rtc | Frigate](#configuring-go2rtc-frigate) - [Home Assistant notifications | Frigate](#home-assistant-notifications-frigate) - [Contributing To The Main Code Base | Frigate](#contributing-to-the-main-code-base-frigate) - [Semantic Search | Frigate](#semantic-search-frigate) - [Recommended hardware | Frigate](#recommended-hardware-frigate) - [Setting up a reverse proxy | Frigate](#setting-up-a-reverse-proxy-frigate) - [Getting started | Frigate](#getting-started-frigate) - [Frigate HTTP API | Frigate](#frigate-http-api-frigate) - [Installation | Frigate](#installation-frigate) - [Get cached preview frame filenames | Frigate](#get-cached-preview-frame-filenames-frigate) - [Get VAPID public key | Frigate](#get-vapid-public-key-frigate) - [Delete export | Frigate](#delete-export-frigate) - [Rename export | Frigate](#rename-export-frigate) - [Start recording export | Frigate](#start-recording-export-frigate) - [Authenticate request | Frigate](#authenticate-request-frigate) - [Full Reference Config | Frigate](#full-reference-config-frigate) - [Get preview clips for specific hour | Frigate](#get-preview-clips-for-specific-hour-frigate) - [Register notifications | Frigate](#register-notifications-frigate) - [Get preview clips for time range | Frigate](#get-preview-clips-for-time-range-frigate) - [Get exports | Frigate](#get-exports-frigate) - [Get a single export | Frigate](#get-a-single-export-frigate) - [Create new user | Frigate](#create-new-user-frigate) - [Object Detectors | Frigate](#object-detectors-frigate) - [Delete user | Frigate](#delete-user-frigate) - [Delete Reviews | Frigate](#delete-reviews-frigate) - [Models | Frigate](#models-frigate) - [HomeKit | Frigate](#homekit-frigate) - [Third Party Extensions | Frigate](#third-party-extensions-frigate) - [Frigate+ | Frigate](#frigate-frigate) - [GPU Errors | Frigate](#gpu-errors-frigate) - [Annotating your images | Frigate](#annotating-your-images-frigate) - [Generate Review Summary | Frigate](#generate-review-summary-frigate) - [Get all users | Frigate](#get-all-users-frigate) - [Login with credentials | Frigate](#login-with-credentials-frigate) - [High CPU Usage | Frigate](#high-cpu-usage-frigate) - [EdgeTPU Errors | Frigate](#edgetpu-errors-frigate) - [Requesting your first model | Frigate](#requesting-your-first-model-frigate) - [Analyzing Object Detection | Frigate](#analyzing-object-detection-frigate) - [FAQ | Frigate](#faq-frigate) - [Get Review | Frigate](#get-review-frigate) - [Get Review From Event | Frigate](#get-review-from-event-frigate) - [Logout user | Frigate](#logout-user-frigate) - [Recordings Errors | Frigate](#recordings-errors-frigate) - [Frequently Asked Questions | Frigate](#frequently-asked-questions-frigate) - [Get user profile | Frigate](#get-user-profile-frigate) - [Motion Activity | Frigate](#motion-activity-frigate) - [Memory Usage | Frigate](#memory-usage-frigate) - [Home Assistant Integration | Frigate](#home-assistant-integration-frigate) - [Review Ids | Frigate](#review-ids-frigate) - [Review Summary | Frigate](#review-summary-frigate) - [Categorize a classification image | Frigate](#categorize-a-classification-image-frigate) - [MQTT | Frigate](#mqtt-frigate) - [Delete classification train images | Frigate](#delete-classification-train-images-frigate) - [Delete classification dataset images | Frigate](#delete-classification-dataset-images-frigate) - [Create a new face name | Frigate](#create-a-new-face-name-frigate) - [Review | Frigate](#review-frigate) - [Update user role | Frigate](#update-user-role-frigate) - [Set Multiple Reviewed | Frigate](#set-multiple-reviewed-frigate) - [Delete face images | Frigate](#delete-face-images-frigate) - [Set Not Reviewed | Frigate](#set-not-reviewed-frigate) - [Update user password | Frigate](#update-user-password-frigate) - [Get classification dataset | Frigate](#get-classification-dataset-frigate) - [Get classification train images | Frigate](#get-classification-train-images-frigate) - [Get custom classification attributes | Frigate](#get-custom-classification-attributes-frigate) - [Config | Frigate](#config-frigate) - [Config Raw | Frigate](#config-raw-frigate) - [Config Save | Frigate](#config-save-frigate) - [Config Set | Frigate](#config-set-frigate) - [Config Schema | Frigate](#config-schema-frigate) - [Get all registered faces | Frigate](#get-all-registered-faces-frigate) - [Create manual event | Frigate](#create-manual-event-frigate) - [Reprocess a face training image | Frigate](#reprocess-a-face-training-image-frigate) - [Recognize a face from an uploaded image | Frigate](#recognize-a-face-from-an-uploaded-image-frigate) - [Create trigger embedding | Frigate](#create-trigger-embedding-frigate) - [Reprocess a license plate | Frigate](#reprocess-a-license-plate-frigate) - [Reindex embeddings | Frigate](#reindex-embeddings-frigate) - [Rename a face name | Frigate](#rename-a-face-name-frigate) - [Register a face image | Frigate](#register-a-face-image-frigate) - [Ffprobe | Frigate](#ffprobe-frigate) - [Delete event | Frigate](#delete-event-frigate) - [Delete events | Frigate](#delete-events-frigate) - [Delete trigger embedding | Frigate](#delete-trigger-embedding-frigate) - [Stop event from being retained indefinitely | Frigate](#stop-event-from-being-retained-indefinitely-frigate) - [Get Labels | Frigate](#get-labels-frigate) - [End manual event | Frigate](#end-manual-event-frigate) - [Get events by ids | Frigate](#get-events-by-ids-frigate) - [Get event by id | Frigate](#get-event-by-id-frigate) - [Get Recognized License Plates | Frigate](#get-recognized-license-plates-frigate) - [Go2Rtc Camera Stream | Frigate](#go2rtc-camera-stream-frigate) - [Get Sub Labels | Frigate](#get-sub-labels-frigate) - [Get summary of objects | Frigate](#get-summary-of-objects-frigate) - [Events Summary | Frigate](#events-summary-frigate) - [Submit false positive to Frigate+ | Frigate](#submit-false-positive-to-frigate-frigate) - [Hourly Timeline | Frigate](#hourly-timeline-frigate) - [Go2Rtc Streams | Frigate](#go2rtc-streams-frigate) - [Generate description embedding | Frigate](#generate-description-embedding-frigate) - [Search events | Frigate](#search-events-frigate) - [Get events | Frigate](#get-events-frigate) - [Logs | Frigate](#logs-frigate) - [Metrics | Frigate](#metrics-frigate) - [Is Healthy | Frigate](#is-healthy-frigate) - [Plusmodels | Frigate](#plusmodels-frigate) - [Nvinfo | Frigate](#nvinfo-frigate) - [Train a classification model | Frigate](#train-a-classification-model-frigate) - [Transcribe audio | Frigate](#transcribe-audio-frigate) - [Classify and save a face training image | Frigate](#classify-and-save-a-face-training-image-frigate) - [Get triggers status | Frigate](#get-triggers-status-frigate) - [Restart | Frigate](#restart-frigate) - [All Recordings Summary | Frigate](#all-recordings-summary-frigate) - [Camera Ptz Info | Frigate](#camera-ptz-info-frigate) - [Regenerate event description | Frigate](#regenerate-event-description-frigate) - [Event Clip | Frigate](#event-clip-frigate) - [Event Preview | Frigate](#event-preview-frigate) - [Stats | Frigate](#stats-frigate) - [Event Thumbnail | Frigate](#event-thumbnail-frigate) - [Event Snapshot | Frigate](#event-snapshot-frigate) - [Timeline | Frigate](#timeline-frigate) - [Stats History | Frigate](#stats-history-frigate) - [Event Snapshot Clean | Frigate](#event-snapshot-clean-frigate) - [Version | Frigate](#version-frigate) - [Vainfo | Frigate](#vainfo-frigate) - [Send event to Frigate+ | Frigate](#send-event-to-frigate-frigate) - [Set event license plate | Frigate](#set-event-license-plate-frigate) - [Set custom classification attributes | Frigate](#set-custom-classification-attributes-frigate) - [Set event retain indefinitely | Frigate](#set-event-retain-indefinitely-frigate) - [Set event description | Frigate](#set-event-description-frigate) - [Get Recordings Storage Usage | Frigate](#get-recordings-storage-usage-frigate) - [Set event sub label | Frigate](#set-event-sub-label-frigate) - [Grid Snapshot | Frigate](#grid-snapshot-frigate) - [Get Snapshot From Recording | Frigate](#get-snapshot-from-recording-frigate) - [Label Thumbnail | Frigate](#label-thumbnail-frigate) - [Label Snapshot | Frigate](#label-snapshot-frigate) - [Label Clip | Frigate](#label-clip-frigate) - [Label Thumbnail | Frigate](#label-thumbnail-frigate) - [Update trigger embedding | Frigate](#update-trigger-embedding-frigate) - [Preview Gif | Frigate](#preview-gif-frigate) - [Preview Thumbnail | Frigate](#preview-thumbnail-frigate) - [Latest Frame | Frigate](#latest-frame-frigate) - [No Recordings | Frigate](#no-recordings-frigate) - [Preview Mp4 | Frigate](#preview-mp4-frigate) - [Recording Clip | Frigate](#recording-clip-frigate) - [Recordings | Frigate](#recordings-frigate) - [Preview Thumbnail | Frigate](#preview-thumbnail-frigate) - [Recordings Summary | Frigate](#recordings-summary-frigate) - [Mjpeg Feed | Frigate](#mjpeg-feed-frigate) - [Review Preview | Frigate](#review-preview-frigate) - [Submit Recording Snapshot To Plus | Frigate](#submit-recording-snapshot-to-plus-frigate) - [Vod Event | Frigate](#vod-event-frigate) - [Vod Hour | Frigate](#vod-hour-frigate) - [Vod Hour No Timezone | Frigate](#vod-hour-no-timezone-frigate) - [Vod Ts | Frigate](#vod-ts-frigate) - [AppPostLoginBody | Frigate](#apppostloginbody-frigate) - [AppPutRoleBody | Frigate](#appputrolebody-frigate) - [AppPutPasswordBody | Frigate](#appputpasswordbody-frigate) - [AudioTranscriptionBody | Frigate](#audiotranscriptionbody-frigate) - [Body_recognize_face_faces_recognize_post | Frigate](#body-recognize-face-faces-recognize-post-frigate) - [Body_register_face_faces__name__register_post | Frigate](#body-register-face-faces-name-register-post-frigate) - [EventMultiDeleteResponse | Frigate](#eventmultideleteresponse-frigate) - [EventCreateResponse | Frigate](#eventcreateresponse-frigate) - [AppPostUsersBody | Frigate](#apppostusersbody-frigate) - [EventsDeleteBody | Frigate](#eventsdeletebody-frigate) - [EventsAttributesBody | Frigate](#eventsattributesbody-frigate) - [EventsDescriptionBody | Frigate](#eventsdescriptionbody-frigate) - [EventsEndBody | Frigate](#eventsendbody-frigate) - [DeleteFaceImagesBody | Frigate](#deletefaceimagesbody-frigate) - [DayReview | Frigate](#dayreview-frigate) - [AppConfigSetBody | Frigate](#appconfigsetbody-frigate) - [EventsLPRBody | Frigate](#eventslprbody-frigate) - [ExportModel | Frigate](#exportmodel-frigate) - [GenericResponse | Frigate](#genericresponse-frigate) - [EventsCreateBody | Frigate](#eventscreatebody-frigate) - [EventResponse | Frigate](#eventresponse-frigate) - [Last24HoursReview | Frigate](#last24hoursreview-frigate) - [PlaybackFactorEnum | Frigate](#playbackfactorenum-frigate) - [PlaybackSourceEnum | Frigate](#playbacksourceenum-frigate) - [EventUploadPlusResponse | Frigate](#eventuploadplusresponse-frigate) - [ExportRenameBody | Frigate](#exportrenamebody-frigate) - [FacesResponse | Frigate](#facesresponse-frigate) - [Extension | Frigate](#extension-frigate) - [ExportRecordingsBody | Frigate](#exportrecordingsbody-frigate) - [HTTPValidationError | Frigate](#httpvalidationerror-frigate) - [FaceRecognitionResponse | Frigate](#facerecognitionresponse-frigate) - [RegenerateDescriptionEnum | Frigate](#regeneratedescriptionenum-frigate) - [EventsSubLabelBody | Frigate](#eventssublabelbody-frigate) - [RenameFaceBody | Frigate](#renamefacebody-frigate) - [ReviewActivityMotionResponse | Frigate](#reviewactivitymotionresponse-frigate) - [ReviewModifyMultipleBody | Frigate](#reviewmodifymultiplebody-frigate) - [ReviewSegmentResponse | Frigate](#reviewsegmentresponse-frigate) - [SeverityEnum | Frigate](#severityenum-frigate) - [PreviewModel | Frigate](#previewmodel-frigate) - [TriggerEmbeddingBody | Frigate](#triggerembeddingbody-frigate) - [StartExportResponse | Frigate](#startexportresponse-frigate) - [ReviewSummaryResponse | Frigate](#reviewsummaryresponse-frigate) - [TriggerType | Frigate](#triggertype-frigate) - [SubmitPlusBody | Frigate](#submitplusbody-frigate) - [ValidationError | Frigate](#validationerror-frigate) --- # Introduction | Frigate [Skip to main content](https://docs.frigate.video/#__docusaurus_skipToContent_fallback) πŸš€ Get more relevant and accurate detections with Frigate+ models. [Learn more](https://frigate.video/plus/) ✨ On this page A complete and local NVR designed for Home Assistant with AI object detection. Uses OpenCV and Tensorflow to perform realtime object detection locally for IP cameras. Use of a [Recommended Detector](https://docs.frigate.video/frigate/hardware#detectors) is optional, but strongly recommended. CPU detection should only be used for testing purposes. * Tight integration with Home Assistant via a [custom component](https://github.com/blakeblackshear/frigate-hass-integration) * Designed to minimize resource use and maximize performance by only looking for objects when and where it is necessary * Leverages multiprocessing heavily with an emphasis on realtime over processing every frame * Uses a very low overhead motion detection to determine where to run object detection * Object detection with TensorFlow runs in separate processes for maximum FPS * Communicates over MQTT for easy integration into other systems * Recording with retention based on detected objects * Re-streaming via RTSP to reduce the number of connections to your camera * A dynamic combined camera view of all tracked cameras. Screenshots[​](https://docs.frigate.video/#screenshots "Direct link to Screenshots") ------------------------------------------------------------------------------------- ![Live View](https://docs.frigate.video/assets/images/live-view-c0b5423966d937ac7f750b67bf8cdf50.png) ![Review Items](https://docs.frigate.video/assets/images/review-items-c7914c6f1b3d92d38b56e6d3559074bc.png) ![Media Browser](https://docs.frigate.video/assets/images/media_browser-min-1f8a7c629d1bdbee1c78f99a97a0219a.png) ![Notification](https://docs.frigate.video/assets/images/notification-min-2f4dd1c2ad07e908a34c04e02e2c78b7.png) * [Screenshots](https://docs.frigate.video/#screenshots) --- # Custom Classification | Frigate [Skip to main content](https://docs.frigate.video/category/custom-classification/#__docusaurus_skipToContent_fallback) πŸš€ Get more relevant and accurate detections with Frigate+ models. [Learn more](https://frigate.video/plus/) ✨ [πŸ“„οΈ State Classification\ ------------------------\ \ State classification allows you to train a custom MobileNetV2 classification model on a fixed region of your camera frame(s) to determine a current state. The model can be configured to run on a schedule and/or when motion is detected in that region. Classification results are available through the frigate//classification/ MQTT topic and in Home Assistant sensors via the official Frigate integration.](https://docs.frigate.video/configuration/custom_classification/state_classification) [πŸ“„οΈ Object Classification\ -------------------------\ \ Object classification allows you to train a custom MobileNetV2 classification model to run on tracked objects (persons, cars, animals, etc.) to identify a finer category or attribute for that object. Classification results are visible in the Tracked Object Details pane in Explore, through the frigate/trackedobjectdetails MQTT topic, in Home Assistant sensors via the official Frigate integration, or through the event endpoints in the HTTP API.](https://docs.frigate.video/configuration/custom_classification/object_classification) --- # api | Frigate [Skip to main content](https://docs.frigate.video/integrations/api/#__docusaurus_skipToContent_fallback) πŸš€ Get more relevant and accurate detections with Frigate+ models. [Learn more](https://frigate.video/plus/) ✨ --- # Powered by MDX | Frigate [Skip to main content](https://docs.frigate.video/mdx/#__docusaurus_skipToContent_fallback) πŸš€ Get more relevant and accurate detections with Frigate+ models. [Learn more](https://frigate.video/plus/) ✨ You can write JSX and use React components within your Markdown thanks to [MDX](https://mdxjs.com/) . Docusaurus green and Facebook blue are my favorite colors. I can write **Markdown** alongside my _JSX_! --- # Generative AI | Frigate [Skip to main content](https://docs.frigate.video/category/generative-ai/#__docusaurus_skipToContent_fallback) πŸš€ Get more relevant and accurate detections with Frigate+ models. [Learn more](https://frigate.video/plus/) ✨ [πŸ“„οΈ Configuring Generative AI\ -----------------------------\ \ Configuration](https://docs.frigate.video/configuration/genai/genai_config) [πŸ“„οΈ Review Summaries\ --------------------\ \ Generative AI can be used to automatically generate structured summaries of review items. These summaries will show up in Frigate's native notifications as well as in the UI. Generative AI can also be used to take a collection of summaries over a period of time and provide a report, which may be useful to get a quick report of everything that happened while out for some amount of time.](https://docs.frigate.video/configuration/genai/genai_review) [πŸ“„οΈ Object Descriptions\ -----------------------\ \ Generative AI can be used to automatically generate descriptive text based on the thumbnails of your tracked objects. This helps with Semantic Search in Frigate to provide more context about your tracked objects. Descriptions are accessed via the Explore\_ view in the Frigate UI by clicking on a tracked object's thumbnail.](https://docs.frigate.video/configuration/genai/genai_objects) --- # Troubleshooting Hardware | Frigate [Skip to main content](https://docs.frigate.video/category/troubleshooting-hardware/#__docusaurus_skipToContent_fallback) πŸš€ Get more relevant and accurate detections with Frigate+ models. [Learn more](https://frigate.video/plus/) ✨ [πŸ“„οΈ GPU Errors\ --------------\ \ OpenVINO](https://docs.frigate.video/troubleshooting/gpu) [πŸ“„οΈ EdgeTPU Errors\ ------------------\ \ USB Coral Not Detected](https://docs.frigate.video/troubleshooting/edgetpu) --- # Troubleshooting Resource Usage | Frigate [Skip to main content](https://docs.frigate.video/category/troubleshooting-resource-usage/#__docusaurus_skipToContent_fallback) πŸš€ Get more relevant and accurate detections with Frigate+ models. [Learn more](https://frigate.video/plus/) ✨ [πŸ“„οΈ High CPU Usage\ ------------------\ \ High CPU usage can impact Frigate's performance and responsiveness. This guide outlines the most effective configuration changes to help reduce CPU consumption and optimize resource usage.](https://docs.frigate.video/troubleshooting/cpu) [πŸ“„οΈ Memory Usage\ ----------------\ \ Frigate includes built-in memory profiling using memray to help diagnose memory issues. This feature allows you to profile specific Frigate modules to identify memory leaks, excessive allocations, or other memory-related problems.](https://docs.frigate.video/troubleshooting/memory) --- # Frigate Configuration | Frigate [Skip to main content](https://docs.frigate.video/configuration/#__docusaurus_skipToContent_fallback) πŸš€ Get more relevant and accurate detections with Frigate+ models. [Learn more](https://frigate.video/plus/) ✨ On this page For Home Assistant App installations, the config file should be at `/addon_configs//config.yml`, where `` is specific to the variant of the Frigate App you are running. See the list of directories [here](https://docs.frigate.video/configuration/#accessing-app-config-dir) . For all other installation types, the config file should be mapped to `/config/config.yml` inside the container. It can be named `config.yml` or `config.yaml`, but if both files exist `config.yml` will be preferred and `config.yaml` will be ignored. It is recommended to start with a minimal configuration and add to it as described in [this guide](https://docs.frigate.video/guides/getting_started) and use the built in configuration editor in Frigate's UI which supports validation. mqtt: enabled: Falsecameras: dummy_camera: # <--- this will be changed to your actual camera later enabled: False ffmpeg: inputs: - path: rtsp://127.0.0.1:554/rtsp roles: - detect Accessing the Home Assistant App configuration directory[​](https://docs.frigate.video/configuration/#accessing-app-config-dir "Direct link to Accessing the Home Assistant App configuration directory") ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- When running Frigate through the HA App, the Frigate `/config` directory is mapped to `/addon_configs/` in the host, where `` is specific to the variant of the Frigate App you are running. | App Variant | Configuration directory | | --- | --- | | Frigate | `/addon_configs/ccab4aaf_frigate` | | Frigate (Full Access) | `/addon_configs/ccab4aaf_frigate-fa` | | Frigate Beta | `/addon_configs/ccab4aaf_frigate-beta` | | Frigate Beta (Full Access) | `/addon_configs/ccab4aaf_frigate-fa-beta` | **Whenever you see `/config` in the documentation, it refers to this directory.** If for example you are running the standard App variant and use the [VS Code App](https://github.com/hassio-addons/addon-vscode) to browse your files, you can click _File_ > _Open folder..._ and navigate to `/addon_configs/ccab4aaf_frigate` to access the Frigate `/config` directory and edit the `config.yaml` file. You can also use the built-in file editor in the Frigate UI to edit the configuration file. VS Code Configuration Schema[​](https://docs.frigate.video/configuration/#vs-code-configuration-schema "Direct link to VS Code Configuration Schema") ------------------------------------------------------------------------------------------------------------------------------------------------------ VS Code supports JSON schemas for automatically validating configuration files. You can enable this feature by adding `# yaml-language-server: $schema=http://frigate_host:5000/api/config/schema.json` to the beginning of the configuration file. Replace `frigate_host` with the IP address or hostname of your Frigate server. If you're using both VS Code and Frigate as an App, you should use `ccab4aaf-frigate` instead. Make sure to expose the internal unauthenticated port `5000` when accessing the config from VS Code on another machine. Environment Variable Substitution[​](https://docs.frigate.video/configuration/#environment-variable-substitution "Direct link to Environment Variable Substitution") --------------------------------------------------------------------------------------------------------------------------------------------------------------------- Frigate supports the use of environment variables starting with `FRIGATE_` **only** where specifically indicated in the [reference config](https://docs.frigate.video/configuration/reference) . For example, the following values can be replaced at runtime by using environment variables: mqtt: host: "{FRIGATE_MQTT_HOST}" user: "{FRIGATE_MQTT_USER}" password: "{FRIGATE_MQTT_PASSWORD}" - path: rtsp://{FRIGATE_RTSP_USER}:{FRIGATE_RTSP_PASSWORD}@10.0.10.10:8554/unicast onvif: host: "192.168.1.12" port: 8000 user: "{FRIGATE_RTSP_USER}" password: "{FRIGATE_RTSP_PASSWORD}" go2rtc: rtsp: username: "{FRIGATE_GO2RTC_RTSP_USERNAME}" password: "{FRIGATE_GO2RTC_RTSP_PASSWORD}" genai: api_key: "{FRIGATE_GENAI_API_KEY}" Common configuration examples[​](https://docs.frigate.video/configuration/#common-configuration-examples "Direct link to Common configuration examples") --------------------------------------------------------------------------------------------------------------------------------------------------------- Here are some common starter configuration examples. Refer to the [reference config](https://docs.frigate.video/configuration/reference) for detailed information about all the config values. ### Raspberry Pi Home Assistant App with USB Coral[​](https://docs.frigate.video/configuration/#raspberry-pi-home-assistant-app-with-usb-coral "Direct link to Raspberry Pi Home Assistant App with USB Coral") * Single camera with 720p, 5fps stream for detect * MQTT connected to the Home Assistant Mosquitto App * Hardware acceleration for decoding video * USB Coral detector * Save all video with any detectable motion for 7 days regardless of whether any objects were detected or not * Continue to keep all video if it qualified as an alert or detection for 30 days * Save snapshots for 30 days * Motion mask for the camera timestamp mqtt: host: core-mosquitto user: mqtt-user password: xxxxxxxxxxffmpeg: hwaccel_args: preset-rpi-64-h264detectors: coral: type: edgetpu device: usbrecord: enabled: True motion: days: 7 alerts: retain: days: 30 mode: motion detections: retain: days: 30 mode: motionsnapshots: enabled: True retain: default: 30cameras: name_of_your_camera: detect: width: 1280 height: 720 fps: 5 ffmpeg: inputs: - path: rtsp://10.0.10.10:554/rtsp roles: - detect motion: mask: - 0.000,0.427,0.002,0.000,0.999,0.000,0.999,0.781,0.885,0.456,0.700,0.424,0.701,0.311,0.507,0.294,0.453,0.347,0.451,0.400 ### Standalone Intel Mini PC with USB Coral[​](https://docs.frigate.video/configuration/#standalone-intel-mini-pc-with-usb-coral "Direct link to Standalone Intel Mini PC with USB Coral") * Single camera with 720p, 5fps stream for detect * MQTT disabled (not integrated with home assistant) * VAAPI hardware acceleration for decoding video * USB Coral detector * Save all video with any detectable motion for 7 days regardless of whether any objects were detected or not * Continue to keep all video if it qualified as an alert or detection for 30 days * Save snapshots for 30 days * Motion mask for the camera timestamp mqtt: enabled: Falseffmpeg: hwaccel_args: preset-vaapidetectors: coral: type: edgetpu device: usbrecord: enabled: True motion: days: 7 alerts: retain: days: 30 mode: motion detections: retain: days: 30 mode: motionsnapshots: enabled: True retain: default: 30cameras: name_of_your_camera: detect: width: 1280 height: 720 fps: 5 ffmpeg: inputs: - path: rtsp://10.0.10.10:554/rtsp roles: - detect motion: mask: - 0.000,0.427,0.002,0.000,0.999,0.000,0.999,0.781,0.885,0.456,0.700,0.424,0.701,0.311,0.507,0.294,0.453,0.347,0.451,0.400 ### Home Assistant integrated Intel Mini PC with OpenVino[​](https://docs.frigate.video/configuration/#home-assistant-integrated-intel-mini-pc-with-openvino "Direct link to Home Assistant integrated Intel Mini PC with OpenVino") * Single camera with 720p, 5fps stream for detect * MQTT connected to same mqtt server as home assistant * VAAPI hardware acceleration for decoding video * OpenVino detector * Save all video with any detectable motion for 7 days regardless of whether any objects were detected or not * Continue to keep all video if it qualified as an alert or detection for 30 days * Save snapshots for 30 days * Motion mask for the camera timestamp mqtt: host: 192.168.X.X # <---- same mqtt broker that home assistant uses user: mqtt-user password: xxxxxxxxxxffmpeg: hwaccel_args: preset-vaapidetectors: ov: type: openvino device: AUTOmodel: 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.txtrecord: enabled: True motion: days: 7 alerts: retain: days: 30 mode: motion detections: retain: days: 30 mode: motionsnapshots: enabled: True retain: default: 30cameras: name_of_your_camera: detect: width: 1280 height: 720 fps: 5 ffmpeg: inputs: - path: rtsp://10.0.10.10:554/rtsp roles: - detect motion: mask: - 0.000,0.427,0.002,0.000,0.999,0.000,0.999,0.781,0.885,0.456,0.700,0.424,0.701,0.311,0.507,0.294,0.453,0.347,0.451,0.400 * [Accessing the Home Assistant App configuration directory](https://docs.frigate.video/configuration/#accessing-app-config-dir) * [VS Code Configuration Schema](https://docs.frigate.video/configuration/#vs-code-configuration-schema) * [Environment Variable Substitution](https://docs.frigate.video/configuration/#environment-variable-substitution) * [Common configuration examples](https://docs.frigate.video/configuration/#common-configuration-examples) * [Raspberry Pi Home Assistant App with USB Coral](https://docs.frigate.video/configuration/#raspberry-pi-home-assistant-app-with-usb-coral) * [Standalone Intel Mini PC with USB Coral](https://docs.frigate.video/configuration/#standalone-intel-mini-pc-with-usb-coral) * [Home Assistant integrated Intel Mini PC with OpenVino](https://docs.frigate.video/configuration/#home-assistant-integrated-intel-mini-pc-with-openvino) --- # Audio Detectors | Frigate [Skip to main content](https://docs.frigate.video/configuration/audio_detectors/#__docusaurus_skipToContent_fallback) πŸš€ Get more relevant and accurate detections with Frigate+ models. [Learn more](https://frigate.video/plus/) ✨ On this page Frigate provides a builtin audio detector which runs on the CPU. Compared to object detection in images, audio detection is a relatively lightweight operation so the only option is to run the detection on a CPU. Configuration[​](https://docs.frigate.video/configuration/audio_detectors/#configuration "Direct link to Configuration") ------------------------------------------------------------------------------------------------------------------------- Audio events work by detecting a type of audio and creating an event, the event will end once the type of audio has not been heard for the configured amount of time. Audio events save a snapshot at the beginning of the event as well as recordings throughout the event. The recordings are retained using the configured recording retention. ### Enabling Audio Events[​](https://docs.frigate.video/configuration/audio_detectors/#enabling-audio-events "Direct link to Enabling Audio Events") Audio events can be enabled for all cameras or only for specific cameras. audio: # <- enable audio events for all camera enabled: Truecameras: front_camera: ffmpeg: ... audio: enabled: True # <- enable audio events for the front_camera If you are using multiple streams then you must set the `audio` role on the stream that is going to be used for audio detection, this can be any stream but the stream must have audio included. note The ffmpeg process for capturing audio will be a separate connection to the camera along with the other roles assigned to the camera, for this reason it is recommended that the go2rtc restream is used for this purpose. See [the restream docs](https://docs.frigate.video/configuration/restream) for more information. cameras: front_camera: ffmpeg: inputs: - path: rtsp://.../main_stream roles: - record - path: rtsp://.../sub_stream # <- this stream must have audio enabled roles: - audio - detect ### Configuring Minimum Volume[​](https://docs.frigate.video/configuration/audio_detectors/#configuring-minimum-volume "Direct link to Configuring Minimum Volume") The audio detector uses volume levels in the same way that motion in a camera feed is used for object detection. This means that Frigate will not run audio detection unless the audio volume is above the configured level in order to reduce resource usage. Audio levels can vary widely between camera models so it is important to run tests to see what volume levels are. The Debug view in the Frigate UI has an Audio tab for cameras that have the `audio` role assigned where a graph and the current levels are is displayed. The `min_volume` parameter should be set to the minimum the `RMS` level required to run audio detection. tip Volume is considered motion for recordings, this means when the `record -> retain -> mode` is set to `motion` any time audio volume is > min\_volume that recording segment for that camera will be kept. ### Configuring Audio Events[​](https://docs.frigate.video/configuration/audio_detectors/#configuring-audio-events "Direct link to Configuring Audio Events") The included audio model has over [500 different types](https://github.com/blakeblackshear/frigate/blob/dev/audio-labelmap.txt) of audio that can be detected, many of which are not practical. By default `bark`, `fire_alarm`, `scream`, `speech`, and `yell` are enabled but these can be customized. audio: enabled: True listen: - bark - fire_alarm - scream - speech - yell ### Audio Transcription[​](https://docs.frigate.video/configuration/audio_detectors/#audio-transcription "Direct link to Audio Transcription") Frigate supports fully local audio transcription using either `sherpa-onnx` or OpenAI’s open-source Whisper models via `faster-whisper`. The goal of this feature is to support Semantic Search for `speech` audio events. Frigate is not intended to act as a continuous, fully-automatic speech transcription service β€” automatically transcribing all speech (or queuing many audio events for transcription) requires substantial CPU (or GPU) resources and is impractical on most systems. For this reason, transcriptions for events are initiated manually from the UI or the API rather than being run continuously in the background. Transcription accuracy also depends heavily on the quality of your camera's microphone and recording conditions. Many cameras use inexpensive microphones, and distance to the speaker, low audio bitrate, or background noise can significantly reduce transcription quality. If you need higher accuracy, more robust long-running queues, or large-scale automatic transcription, consider using the HTTP API in combination with an automation platform and a cloud transcription service. #### Configuration[​](https://docs.frigate.video/configuration/audio_detectors/#configuration-1 "Direct link to Configuration") To enable transcription, enable it in your config. Note that audio detection must also be enabled as described above in order to use audio transcription features. audio_transcription: enabled: True device: ... model_size: ... Disable audio transcription for select cameras at the camera level: cameras: back_yard: ... audio_transcription: enabled: False note Audio detection must be enabled and configured as described above in order to use audio transcription features. The optional config parameters that can be set at the global level include: * **`enabled`**: Enable or disable the audio transcription feature. * Default: `False` * It is recommended to only configure the features at the global level, and enable it at the individual camera level. * **`device`**: Device to use to run transcription and translation models. * Default: `CPU` * This can be `CPU` or `GPU`. The `sherpa-onnx` models are lightweight and run on the CPU only. The `whisper` models can run on GPU but are only supported on CUDA hardware. * **`model_size`**: The size of the model used for live transcription. * Default: `small` * This can be `small` or `large`. The `small` setting uses `sherpa-onnx` models that are fast, lightweight, and always run on the CPU but are not as accurate as the `whisper` model. * This config option applies to **live transcription only**. Recorded `speech` events will always use a different `whisper` model (and can be accelerated for CUDA hardware if available with `device: GPU`). * **`language`**: Defines the language used by `whisper` to translate `speech` audio events (and live audio only if using the `large` model). * Default: `en` * You must use a valid [language code](https://github.com/openai/whisper/blob/main/whisper/tokenizer.py#L10) . * Transcriptions for `speech` events are translated. * Live audio is translated only if you are using the `large` model. The `small` `sherpa-onnx` model is English-only. The only field that is valid at the camera level is `enabled`. #### Live transcription[​](https://docs.frigate.video/configuration/audio_detectors/#live-transcription "Direct link to Live transcription") The single camera Live view in the Frigate UI supports live transcription of audio for streams defined with the `audio` role. Use the Enable/Disable Live Audio Transcription button/switch to toggle transcription processing. When speech is heard, the UI will display a black box over the top of the camera stream with text. The MQTT topic `frigate//audio/transcription` will also be updated in real-time with transcribed text. Results can be error-prone due to a number of factors, including: * Poor quality camera microphone * Distance of the audio source to the camera microphone * Low audio bitrate setting in the camera * Background noise * Using the `small` model - it's fast, but not accurate for poor quality audio For speech sources close to the camera with minimal background noise, use the `small` model. If you have CUDA hardware, you can experiment with the `large` `whisper` model on GPU. Performance is not quite as fast as the `sherpa-onnx` `small` model, but live transcription is far more accurate. Using the `large` model with CPU will likely be too slow for real-time transcription. #### Transcription and translation of `speech` audio events[​](https://docs.frigate.video/configuration/audio_detectors/#transcription-and-translation-of-speech-audio-events "Direct link to transcription-and-translation-of-speech-audio-events") Any `speech` events in Explore can be transcribed and/or translated through the Transcribe button in the Tracked Object Details pane. In order to use transcription and translation for past events, you must enable audio detection and define `speech` as an audio type to listen for in your config. To have `speech` events translated into the language of your choice, set the `language` config parameter with the correct [language code](https://github.com/openai/whisper/blob/main/whisper/tokenizer.py#L10) . The transcribed/translated speech will appear in the description box in the Tracked Object Details pane. If Semantic Search is enabled, embeddings are generated for the transcription text and are fully searchable using the description search type. note Only one `speech` event may be transcribed at a time. Frigate does not automatically transcribe `speech` events or implement a queue for long-running transcription model inference. Recorded `speech` events will always use a `whisper` model, regardless of the `model_size` config setting. Without a supported Nvidia GPU, generating transcriptions for longer `speech` events may take a fair amount of time, so be patient. #### FAQ[​](https://docs.frigate.video/configuration/audio_detectors/#faq "Direct link to FAQ") 1. Why doesn't Frigate automatically transcribe all `speech` events? Frigate does not implement a queue mechanism for speech transcription, and adding one is not trivial. A proper queue would need backpressure, prioritization, memory/disk buffering, retry logic, crash recovery, and safeguards to prevent unbounded growth when events outpace processing. That’s a significant amount of complexity for a feature that, in most real-world environments, would mostly just churn through low-value noise. Because transcription is **serialized (one event at a time)** and speech events can be generated far faster than they can be processed, an auto-transcribe toggle would very quickly create an ever-growing backlog and degrade core functionality. For the amount of engineering and risk involved, it adds **very little practical value** for the majority of deployments, which are often on low-powered, edge hardware. If you hear speech that’s actually important and worth saving/indexing for the future, **just press the transcribe button in Explore** on that specific `speech` event - that keeps things explicit, reliable, and under your control. Other options are being considered for future versions of Frigate to add transcription options that support external `whisper` Docker containers. A single transcription service could then be shared by Frigate and other applications (for example, Home Assistant Voice), and run on more powerful machines when available. 2. Why don't you save live transcription text and use that for `speech` events? There’s no guarantee that a `speech` event is even created from the exact audio that went through the transcription model. Live transcription and `speech` event creation are **separate, asynchronous processes**. Even when both are correctly configured, trying to align the **precise start and end time of a speech event** with whatever audio the model happened to be processing at that moment is unreliable. Automatically persisting that data would often result in **misaligned, partial, or irrelevant transcripts**, while still incurring all of the CPU, storage, and privacy costs of transcription. That’s why Frigate treats transcription as an **explicit, user-initiated action** rather than an automatic side-effect of every `speech` event. * [Configuration](https://docs.frigate.video/configuration/audio_detectors/#configuration) * [Enabling Audio Events](https://docs.frigate.video/configuration/audio_detectors/#enabling-audio-events) * [Configuring Minimum Volume](https://docs.frigate.video/configuration/audio_detectors/#configuring-minimum-volume) * [Configuring Audio Events](https://docs.frigate.video/configuration/audio_detectors/#configuring-audio-events) * [Audio Transcription](https://docs.frigate.video/configuration/audio_detectors/#audio-transcription) --- # Advanced Options | Frigate [Skip to main content](https://docs.frigate.video/configuration/advanced/#__docusaurus_skipToContent_fallback) πŸš€ Get more relevant and accurate detections with Frigate+ models. [Learn more](https://frigate.video/plus/) ✨ On this page ### Logging[​](https://docs.frigate.video/configuration/advanced/#logging "Direct link to Logging") #### Frigate `logger`[​](https://docs.frigate.video/configuration/advanced/#frigate-logger "Direct link to frigate-logger") Change the default log level for troubleshooting purposes. logger: # Optional: default log level (default: shown below) default: info # Optional: module by module log level configuration logs: frigate.mqtt: error Available log levels are: `debug`, `info`, `warning`, `error`, `critical` Examples of available modules are: * `frigate.app` * `frigate.mqtt` * `frigate.object_detection.base` * `detector.` * `watchdog.` * `ffmpeg..` NOTE: All FFmpeg logs are sent as `error` level. #### Go2RTC Logging[​](https://docs.frigate.video/configuration/advanced/#go2rtc-logging "Direct link to Go2RTC Logging") See [the go2rtc docs](https://github.com/AlexxIT/go2rtc?tab=readme-ov-file#module-log) for logging configuration go2rtc: streams: # ... log: exec: trace ### `environment_vars`[​](https://docs.frigate.video/configuration/advanced/#environment_vars "Direct link to environment_vars") This section can be used to set environment variables for those unable to modify the environment of the container, like within Home Assistant OS. Docker users should set environment variables in their `docker run` command (`-e FRIGATE_MQTT_PASSWORD=secret`) or `docker-compose.yml` file (`environment:` section) instead. Note that values set here are stored in plain text in your config file, so if the goal is to keep credentials out of your configuration, use Docker environment variables or Docker secrets instead. Variables prefixed with `FRIGATE_` can be referenced in config fields that support environment variable substitution (such as MQTT host and credentials, camera stream URLs, and ONVIF host and credentials) using the `{FRIGATE_VARIABLE_NAME}` syntax. Example: environment_vars: FRIGATE_MQTT_USER: my_mqtt_user FRIGATE_MQTT_PASSWORD: my_mqtt_passwordmqtt: host: "{FRIGATE_MQTT_HOST}" user: "{FRIGATE_MQTT_USER}" password: "{FRIGATE_MQTT_PASSWORD}" #### TensorFlow Thread Configuration[​](https://docs.frigate.video/configuration/advanced/#tensorflow-thread-configuration "Direct link to TensorFlow Thread Configuration") If you encounter thread creation errors during classification model training, you can limit TensorFlow's thread usage: environment_vars: TF_INTRA_OP_PARALLELISM_THREADS: "2" # Threads within operations (0 = use default) TF_INTER_OP_PARALLELISM_THREADS: "2" # Threads between operations (0 = use default) TF_DATASET_THREAD_POOL_SIZE: "2" # Data pipeline threads (0 = use default) ### `database`[​](https://docs.frigate.video/configuration/advanced/#database "Direct link to database") Tracked object and recording information is managed in a sqlite database at `/config/frigate.db`. If that database is deleted, recordings will be orphaned and will need to be cleaned up manually. They also won't show up in the Media Browser within Home Assistant. If you are storing your database on a network share (SMB, NFS, etc), you may get a `database is locked` error message on startup. You can customize the location of the database in the config if necessary. This may need to be in a custom location if network storage is used for the media folder. database: path: /path/to/frigate.db ### `model`[​](https://docs.frigate.video/configuration/advanced/#model "Direct link to model") If using a custom model, the width and height will need to be specified. Custom models may also require different input tensor formats. The colorspace conversion supports RGB, BGR, or YUV frames to be sent to the object detector. The input tensor shape parameter is an enumeration to match what specified by the model. | Tensor Dimension | Description | | --- | --- | | N | Batch Size | | H | Model Height | | W | Model Width | | C | Color Channels | | Available Input Tensor Shapes | | --- | | "nhwc" | | "nchw" | # Optional: model configmodel: path: /path/to/model width: 320 height: 320 input_tensor: "nhwc" input_pixel_format: "bgr" #### `labelmap`[​](https://docs.frigate.video/configuration/advanced/#labelmap "Direct link to labelmap") warning If the labelmap is customized then the labels used for alerts will need to be adjusted as well. See [alert labels](https://docs.frigate.video/configuration/review#restricting-alerts-to-specific-labels) for more info. The labelmap can be customized to your needs. A common reason to do this is to combine multiple object types that are easily confused when you don't need to be as granular such as car/truck. By default, truck is renamed to car because they are often confused. You cannot add new object types, but you can change the names of existing objects in the model. model: labelmap: 2: vehicle 3: vehicle 5: vehicle 7: vehicle 15: animal 16: animal 17: animal Note that if you rename objects in the labelmap, you will also need to update your `objects -> track` list as well. warning Some labels have special handling and modifications can disable functionality. `person` objects are associated with `face` and `amazon` `car` objects are associated with `license_plate`, `ups`, `fedex`, `amazon` Network Configuration[​](https://docs.frigate.video/configuration/advanced/#network-configuration "Direct link to Network Configuration") ------------------------------------------------------------------------------------------------------------------------------------------ Changes to Frigate's internal network configuration can be made by bind mounting nginx.conf into the container. For example: services: frigate: container_name: frigate ... volumes: ... - /path/to/your/nginx.conf:/usr/local/nginx/conf/nginx.conf ### Enabling IPv6[​](https://docs.frigate.video/configuration/advanced/#enabling-ipv6 "Direct link to Enabling IPv6") IPv6 is disabled by default, to enable IPv6 listen.gotmpl needs to be bind mounted with IPv6 enabled. For example: {{ if not .enabled }}# intended for external traffic, protected by authlisten 8971;{{ else }}# intended for external traffic, protected by authlisten 8971 ssl;# intended for internal traffic, not protected by authlisten 5000; becomes {{ if not .enabled }}# intended for external traffic, protected by authlisten [::]:8971 ipv6only=off;{{ else }}# intended for external traffic, protected by authlisten [::]:8971 ipv6only=off ssl;# intended for internal traffic, not protected by authlisten [::]:5000 ipv6only=off; Base path[​](https://docs.frigate.video/configuration/advanced/#base-path "Direct link to Base path") ------------------------------------------------------------------------------------------------------ By default, Frigate runs at the root path (`/`). However some setups require to run Frigate under a custom path prefix (e.g. `/frigate`), especially when Frigate is located behind a reverse proxy that requires path-based routing. ### Set Base Path via HTTP Header[​](https://docs.frigate.video/configuration/advanced/#set-base-path-via-http-header "Direct link to Set Base Path via HTTP Header") The preferred way to configure the base path is through the `X-Ingress-Path` HTTP header, which needs to be set to the desired base path in an upstream reverse proxy. For example, in Nginx: location /frigate { proxy_set_header X-Ingress-Path /frigate; proxy_pass http://frigate_backend;} ### Set Base Path via Environment Variable[​](https://docs.frigate.video/configuration/advanced/#set-base-path-via-environment-variable "Direct link to Set Base Path via Environment Variable") When it is not feasible to set the base path via a HTTP header, it can also be set via the `FRIGATE_BASE_PATH` environment variable in the Docker Compose file. For example: services: frigate: image: blakeblackshear/frigate:latest environment: - FRIGATE_BASE_PATH=/frigate This can be used for example to access Frigate via a Tailscale agent (https), by simply forwarding all requests to the base path (http): tailscale serve --https=443 --bg --set-path /frigate http://localhost:5000/frigate Custom Dependencies[​](https://docs.frigate.video/configuration/advanced/#custom-dependencies "Direct link to Custom Dependencies") ------------------------------------------------------------------------------------------------------------------------------------ ### Custom ffmpeg build[​](https://docs.frigate.video/configuration/advanced/#custom-ffmpeg-build "Direct link to Custom ffmpeg build") Included with Frigate is a build of ffmpeg that works for the vast majority of users. However, there exists some hardware setups which have incompatibilities with the included build. In this case, statically built `ffmpeg` and `ffprobe` binaries can be placed in `/config/custom-ffmpeg/bin` for Frigate to use. To do this: 1. Download your ffmpeg build and uncompress it to the `/config/custom-ffmpeg` folder. Verify that both the `ffmpeg` and `ffprobe` binaries are located in `/config/custom-ffmpeg/bin`. 2. Update the `ffmpeg.path` in your Frigate config to `/config/custom-ffmpeg`. 3. Restart Frigate and the custom version will be used if the steps above were done correctly. ### Custom go2rtc version[​](https://docs.frigate.video/configuration/advanced/#custom-go2rtc-version "Direct link to Custom go2rtc version") Frigate currently includes go2rtc v1.9.10, there may be certain cases where you want to run a different version of go2rtc. To do this: 1. Download the go2rtc build to the `/config` folder. 2. Rename the build to `go2rtc`. 3. Give `go2rtc` execute permission. 4. Restart Frigate and the custom version will be used, you can verify by checking go2rtc logs. Validating your config.yml file updates[​](https://docs.frigate.video/configuration/advanced/#validating-your-configyml-file-updates "Direct link to Validating your config.yml file updates") ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- When frigate starts up, it checks whether your config file is valid, and if it is not, the process exits. To minimize interruptions when updating your config, you have three options -- you can edit the config via the WebUI which has built in validation, use the config API, or you can validate on the command line using the frigate docker container. ### Via API[​](https://docs.frigate.video/configuration/advanced/#via-api "Direct link to Via API") Frigate can accept a new configuration file as JSON at the `/api/config/save` endpoint. When updating the config this way, Frigate will validate the config before saving it, and return a `400` if the config is not valid. curl -X POST http://frigate_host:5000/api/config/save -d @config.json if you'd like you can use your yaml config directly by using [`yq`](https://github.com/mikefarah/yq) to convert it to json: yq -o=json '.' config.yaml | curl -X POST 'http://frigate_host:5000/api/config/save?save_option=saveonly' --data-binary @- ### Via Command Line[​](https://docs.frigate.video/configuration/advanced/#via-command-line "Direct link to Via Command Line") You can also validate your config at the command line by using the docker container itself. In CI/CD, you leverage the return code to determine if your config is valid, Frigate will return `1` if the config is invalid, or `0` if it's valid. docker run \ -v $(pwd)/config.yml:/config/config.yml \ --entrypoint python3 \ ghcr.io/blakeblackshear/frigate:stable \ -u -m frigate \ --validate-config * [Logging](https://docs.frigate.video/configuration/advanced/#logging) * [`environment_vars`](https://docs.frigate.video/configuration/advanced/#environment_vars) * [`database`](https://docs.frigate.video/configuration/advanced/#database) * [`model`](https://docs.frigate.video/configuration/advanced/#model) * [Network Configuration](https://docs.frigate.video/configuration/advanced/#network-configuration) * [Enabling IPv6](https://docs.frigate.video/configuration/advanced/#enabling-ipv6) * [Base path](https://docs.frigate.video/configuration/advanced/#base-path) * [Set Base Path via HTTP Header](https://docs.frigate.video/configuration/advanced/#set-base-path-via-http-header) * [Set Base Path via Environment Variable](https://docs.frigate.video/configuration/advanced/#set-base-path-via-environment-variable) * [Custom Dependencies](https://docs.frigate.video/configuration/advanced/#custom-dependencies) * [Custom ffmpeg build](https://docs.frigate.video/configuration/advanced/#custom-ffmpeg-build) * [Custom go2rtc version](https://docs.frigate.video/configuration/advanced/#custom-go2rtc-version) * [Validating your config.yml file updates](https://docs.frigate.video/configuration/advanced/#validating-your-configyml-file-updates) * [Via API](https://docs.frigate.video/configuration/advanced/#via-api) * [Via Command Line](https://docs.frigate.video/configuration/advanced/#via-command-line) --- # Bird Classification | Frigate [Skip to main content](https://docs.frigate.video/configuration/bird_classification/#__docusaurus_skipToContent_fallback) πŸš€ Get more relevant and accurate detections with Frigate+ models. [Learn more](https://frigate.video/plus/) ✨ On this page Bird classification identifies known birds using a quantized Tensorflow model. When a known bird is recognized, its common name will be added as a `sub_label`. This information is included in the UI, filters, as well as in notifications. Minimum System Requirements[​](https://docs.frigate.video/configuration/bird_classification/#minimum-system-requirements "Direct link to Minimum System Requirements") ----------------------------------------------------------------------------------------------------------------------------------------------------------------------- Bird classification runs a lightweight tflite model on the CPU, there are no significantly different system requirements than running Frigate itself. Model[​](https://docs.frigate.video/configuration/bird_classification/#model "Direct link to Model") ----------------------------------------------------------------------------------------------------- The classification model used is the MobileNet INat Bird Classification, [available identifiers can be found here.](https://raw.githubusercontent.com/google-coral/test_data/master/inat_bird_labels.txt) Configuration[​](https://docs.frigate.video/configuration/bird_classification/#configuration "Direct link to Configuration") ----------------------------------------------------------------------------------------------------------------------------- Bird classification is disabled by default, it must be enabled in your config file before it can be used. Bird classification is a global configuration setting. classification: bird: enabled: true Advanced Configuration[​](https://docs.frigate.video/configuration/bird_classification/#advanced-configuration "Direct link to Advanced Configuration") -------------------------------------------------------------------------------------------------------------------------------------------------------- Fine-tune bird classification with these optional parameters: * `threshold`: Classification confidence score required to set the sub label on the object. * Default: `0.9`. * [Minimum System Requirements](https://docs.frigate.video/configuration/bird_classification/#minimum-system-requirements) * [Model](https://docs.frigate.video/configuration/bird_classification/#model) * [Configuration](https://docs.frigate.video/configuration/bird_classification/#configuration) * [Advanced Configuration](https://docs.frigate.video/configuration/bird_classification/#advanced-configuration) --- # Birdseye | Frigate [Skip to main content](https://docs.frigate.video/configuration/birdseye/#__docusaurus_skipToContent_fallback) πŸš€ Get more relevant and accurate detections with Frigate+ models. [Learn more](https://frigate.video/plus/) ✨ On this page In addition to Frigate's Live camera dashboard, Birdseye allows a portable heads-up view of your cameras to see what is going on around your property / space without having to watch all cameras that may have nothing happening. Birdseye allows specific modes that intelligently show and disappear based on what you care about. Birdseye can be viewed by adding the "Birdseye" camera to a Camera Group in the Web UI. Add a Camera Group by pressing the "+" icon on the Live page, and choose "Birdseye" as one of the cameras. Birdseye can also be used in Home Assistant dashboards, cast to media devices, etc. Birdseye Behavior[​](https://docs.frigate.video/configuration/birdseye/#birdseye-behavior "Direct link to Birdseye Behavior") ------------------------------------------------------------------------------------------------------------------------------ ### Birdseye Modes[​](https://docs.frigate.video/configuration/birdseye/#birdseye-modes "Direct link to Birdseye Modes") Birdseye offers different modes to customize which cameras show under which circumstances. * **continuous:** All cameras are always included * **motion:** Cameras that have detected motion within the last 30 seconds are included * **objects:** Cameras that have tracked an active object within the last 30 seconds are included ### Custom Birdseye Icon[​](https://docs.frigate.video/configuration/birdseye/#custom-birdseye-icon "Direct link to Custom Birdseye Icon") A custom icon can be added to the birdseye background by providing a 180x180 image named `custom.png` inside of the Frigate `media` folder. The file must be a png with the icon as transparent, any non-transparent pixels will be white when displayed in the birdseye view. ### Birdseye view override at camera level[​](https://docs.frigate.video/configuration/birdseye/#birdseye-view-override-at-camera-level "Direct link to Birdseye view override at camera level") If you want to include a camera in Birdseye view only for specific circumstances, or just don't include it at all, the Birdseye setting can be set at the camera level. # Include all cameras by default in Birdseye viewbirdseye: enabled: True mode: continuouscameras: front: # Only include the "front" camera in Birdseye view when objects are detected birdseye: mode: objects back: # Exclude the "back" camera from Birdseye view birdseye: enabled: False ### Birdseye Inactivity[​](https://docs.frigate.video/configuration/birdseye/#birdseye-inactivity "Direct link to Birdseye Inactivity") By default birdseye shows all cameras that have had the configured activity in the last 30 seconds, this can be configured: birdseye: enabled: True inactivity_threshold: 15 Birdseye Layout[​](https://docs.frigate.video/configuration/birdseye/#birdseye-layout "Direct link to Birdseye Layout") ------------------------------------------------------------------------------------------------------------------------ ### Birdseye Dimensions[​](https://docs.frigate.video/configuration/birdseye/#birdseye-dimensions "Direct link to Birdseye Dimensions") The resolution and aspect ratio of birdseye can be configured. Resolution will increase the quality but does not affect the layout. Changing the aspect ratio of birdseye does affect how cameras are laid out. birdseye: enabled: True width: 1280 height: 720 ### Sorting cameras in the Birdseye view[​](https://docs.frigate.video/configuration/birdseye/#sorting-cameras-in-the-birdseye-view "Direct link to Sorting cameras in the Birdseye view") It is possible to override the order of cameras that are being shown in the Birdseye view. The order needs to be set at the camera level. # Include all cameras by default in Birdseye viewbirdseye: enabled: True mode: continuouscameras: front: birdseye: order: 1 back: birdseye: order: 2 _Note_: Cameras are sorted by default using their name to ensure a constant view inside Birdseye. ### Birdseye Cameras[​](https://docs.frigate.video/configuration/birdseye/#birdseye-cameras "Direct link to Birdseye Cameras") It is possible to limit the number of cameras shown on birdseye at one time. When this is enabled, birdseye will show the cameras with most recent activity. There is a cooldown to ensure that cameras do not switch too frequently. For example, this can be configured to only show the most recently active camera. birdseye: enabled: True layout: max_cameras: 1 ### Birdseye Scaling[​](https://docs.frigate.video/configuration/birdseye/#birdseye-scaling "Direct link to Birdseye Scaling") By default birdseye tries to fit 2 cameras in each row and then double in size until a suitable layout is found. The scaling can be configured with a value between 1.0 and 5.0 depending on use case. birdseye: enabled: True layout: scaling_factor: 3.0 * [Birdseye Behavior](https://docs.frigate.video/configuration/birdseye/#birdseye-behavior) * [Birdseye Modes](https://docs.frigate.video/configuration/birdseye/#birdseye-modes) * [Custom Birdseye Icon](https://docs.frigate.video/configuration/birdseye/#custom-birdseye-icon) * [Birdseye view override at camera level](https://docs.frigate.video/configuration/birdseye/#birdseye-view-override-at-camera-level) * [Birdseye Inactivity](https://docs.frigate.video/configuration/birdseye/#birdseye-inactivity) * [Birdseye Layout](https://docs.frigate.video/configuration/birdseye/#birdseye-layout) * [Birdseye Dimensions](https://docs.frigate.video/configuration/birdseye/#birdseye-dimensions) * [Sorting cameras in the Birdseye view](https://docs.frigate.video/configuration/birdseye/#sorting-cameras-in-the-birdseye-view) * [Birdseye Cameras](https://docs.frigate.video/configuration/birdseye/#birdseye-cameras) * [Birdseye Scaling](https://docs.frigate.video/configuration/birdseye/#birdseye-scaling) --- # Camera Configuration | Frigate [Skip to main content](https://docs.frigate.video/configuration/cameras/#__docusaurus_skipToContent_fallback) πŸš€ Get more relevant and accurate detections with Frigate+ models. [Learn more](https://frigate.video/plus/) ✨ On this page Setting Up Camera Inputs[​](https://docs.frigate.video/configuration/cameras/#setting-up-camera-inputs "Direct link to Setting Up Camera Inputs") -------------------------------------------------------------------------------------------------------------------------------------------------- Several inputs can be configured for each camera and the role of each input can be mixed and matched based on your needs. This allows you to use a lower resolution stream for object detection, but create recordings from a higher resolution stream, or vice versa. A camera is enabled by default but can be disabled by using `enabled: False`. Cameras that are disabled through the configuration file will not appear in the Frigate UI and will not consume system resources. Each role can only be assigned to one input per camera. The options for roles are as follows: | Role | Description | | --- | --- | | `detect` | Main feed for object detection. [docs](https://docs.frigate.video/configuration/object_detectors) | | `record` | Saves segments of the video feed based on configuration settings. [docs](https://docs.frigate.video/configuration/record) | | `audio` | Feed for audio based detection. [docs](https://docs.frigate.video/configuration/audio_detectors) | mqtt: host: mqtt.server.comcameras: back: enabled: True ffmpeg: inputs: - path: rtsp://viewer:{FRIGATE_RTSP_PASSWORD}@10.0.10.10:554/cam/realmonitor?channel=1&subtype=2 roles: - detect - path: rtsp://viewer:{FRIGATE_RTSP_PASSWORD}@10.0.10.10:554/live roles: - record detect: width: 1280 # <- optional, by default Frigate tries to automatically detect resolution height: 720 # <- optional, by default Frigate tries to automatically detect resolution Additional cameras are simply added to the config under the `cameras` entry. mqtt: ...cameras: back: ... front: ... side: ... note If you only define one stream in your `inputs` and do not assign a `detect` role to it, Frigate will automatically assign it the `detect` role. Frigate will always decode a stream to support motion detection, Birdseye, the API image endpoints, and other features, even if you have disabled object detection with `enabled: False` in your config's `detect` section. If you plan to use Frigate for recording only, it is still recommended to define a `detect` role for a low resolution stream to minimize resource usage from the required stream decoding. For camera model specific settings check the [camera specific](https://docs.frigate.video/configuration/camera_specific) infos. Setting up camera PTZ controls[​](https://docs.frigate.video/configuration/cameras/#setting-up-camera-ptz-controls "Direct link to Setting up camera PTZ controls") -------------------------------------------------------------------------------------------------------------------------------------------------------------------- warning Not every PTZ supports ONVIF, which is the standard protocol Frigate uses to communicate with your camera. Check the [official list of ONVIF conformant products](https://www.onvif.org/conformant-products/) , your camera documentation, or camera manufacturer's website to ensure your PTZ supports ONVIF. Also, ensure your camera is running the latest firmware. Add the onvif section to your camera in your configuration file: cameras: back: ffmpeg: ... onvif: host: 10.0.10.10 port: 8000 user: admin password: password If the ONVIF connection is successful, PTZ controls will be available in the camera's WebUI. note Some cameras use a separate ONVIF/service account that is distinct from the device administrator credentials. If ONVIF authentication fails with the admin account, try creating or using an ONVIF/service user in the camera's firmware. Refer to your camera manufacturer's documentation for more. tip If your ONVIF camera does not require authentication credentials, you may still need to specify an empty string for `user` and `password`, eg: `user: ""` and `password: ""`. An ONVIF-capable camera that supports relative movement within the field of view (FOV) can also be configured to automatically track moving objects and keep them in the center of the frame. For autotracking setup, see the [autotracking](https://docs.frigate.video/configuration/autotracking) docs. ONVIF PTZ camera recommendations[​](https://docs.frigate.video/configuration/cameras/#onvif-ptz-camera-recommendations "Direct link to ONVIF PTZ camera recommendations") -------------------------------------------------------------------------------------------------------------------------------------------------------------------------- This list of working and non-working PTZ cameras is based on user feedback. If you'd like to report specific quirks or issues with a manufacturer or camera that would be helpful for other users, open a pull request to add to this list. The FeatureList on the [ONVIF Conformant Products Database](https://www.onvif.org/conformant-products/) can provide a starting point to determine a camera's compatibility with Frigate's autotracking. Look to see if a camera lists `PTZRelative`, `PTZRelativePanTilt` and/or `PTZRelativeZoom`. These features are required for autotracking, but some cameras still fail to respond even if they claim support. If they are missing, autotracking will not work (though basic PTZ in the WebUI might). Avoid cameras with no database entry unless they are confirmed as working below. | Brand or specific camera | PTZ Controls | Autotracking | Notes | | --- | --- | --- | --- | | Amcrest | βœ… | βœ… | ⛔️ Generally, Amcrest should work, but some older models (like the common IP2M-841) don't support autotracking | | Amcrest ASH21 | βœ… | ❌ | ONVIF service port: 80 | | Amcrest IP4M-S2112EW-AI | βœ… | ❌ | FOV relative movement not supported. | | Amcrest IP5M-1190EW | βœ… | ❌ | ONVIF Port: 80. FOV relative movement not supported. | | Annke CZ504 | βœ… | βœ… | Annke support provide specific firmware ([V5.7.1 build 250227](https://github.com/pierrepinon/annke_cz504/raw/refs/heads/main/digicap_V5-7-1_build_250227.dav)
) to fix issue with ONVIF "TranslationSpaceFov" | | Axis Q-6155E | βœ… | ❌ | ONVIF service port: 80; Camera does not support MoveStatus. | | Ctronics PTZ | βœ… | ❌ | | | Dahua | βœ… | βœ… | Some low-end Dahuas (lite series, picoo series (commonly), among others) have been reported to not support autotracking. These models usually don't have a four digit model number with chassis prefix and options postfix (e.g. DH-P5AE-PV vs DH-SD49825GB-HNR). | | Dahua DH-SD2A500HB | βœ… | ❌ | | | Dahua DH-SD49825GB-HNR | βœ… | βœ… | | | Dahua DH-P5AE-PV | ❌ | ❌ | | | Foscam | βœ… | ❌ | In general support PTZ, but not relative move. There are no official ONVIF certifications and tests available on the ONVIF Conformant Products Database | | Foscam R5 | βœ… | ❌ | | | Foscam SD4 | βœ… | ❌ | | | Hanwha XNP-6550RH | βœ… | ❌ | | | Hikvision | βœ… | ❌ | Incomplete ONVIF support (MoveStatus won't update even on latest firmware) - reported with HWP-N4215IH-DE and DS-2DE3304W-DE, but likely others | | Hikvision DS-2DE3A404IWG-E/W | βœ… | βœ… | | | Reolink | βœ… | ❌ | | | Speco O8P32X | βœ… | ❌ | | | Sunba 405-D20X | βœ… | ❌ | Incomplete ONVIF support reported on original, and 4k models. All models are suspected incompatable. | | Tapo | βœ… | ❌ | Many models supported, ONVIF Service Port: 2020 | | Uniview IPC672LR-AX4DUPK | βœ… | ❌ | Firmware says FOV relative movement is supported, but camera doesn't actually move when sending ONVIF commands | | Uniview IPC6612SR-X33-VG | βœ… | βœ… | Leave `calibrate_on_startup` as `False`. A user has reported that zooming with `absolute` is working. | | Vikylin PTZ-2804X-I2 | ❌ | ❌ | Incomplete ONVIF support | Setting up camera groups[​](https://docs.frigate.video/configuration/cameras/#setting-up-camera-groups "Direct link to Setting up camera groups") -------------------------------------------------------------------------------------------------------------------------------------------------- tip It is recommended to set up camera groups using the UI. Cameras can be grouped together and assigned a name and icon, this allows them to be reviewed and filtered together. There will always be the default group for all cameras. camera_groups: front: cameras: - driveway_cam - garage_cam icon: LuCar order: 0 Two-Way Audio[​](https://docs.frigate.video/configuration/cameras/#two-way-audio "Direct link to Two-Way Audio") ----------------------------------------------------------------------------------------------------------------- See the guide [here](https://docs.frigate.video/configuration/live/#two-way-talk) * [Setting Up Camera Inputs](https://docs.frigate.video/configuration/cameras/#setting-up-camera-inputs) * [Setting up camera PTZ controls](https://docs.frigate.video/configuration/cameras/#setting-up-camera-ptz-controls) * [ONVIF PTZ camera recommendations](https://docs.frigate.video/configuration/cameras/#onvif-ptz-camera-recommendations) * [Setting up camera groups](https://docs.frigate.video/configuration/cameras/#setting-up-camera-groups) * [Two-Way Audio](https://docs.frigate.video/configuration/cameras/#two-way-audio) --- # Camera Autotracking | Frigate [Skip to main content](https://docs.frigate.video/configuration/autotracking/#__docusaurus_skipToContent_fallback) πŸš€ Get more relevant and accurate detections with Frigate+ models. [Learn more](https://frigate.video/plus/) ✨ On this page An ONVIF-capable, PTZ (pan-tilt-zoom) camera that supports relative movement within the field of view (FOV) can be configured to automatically track moving objects and keep them in the center of the frame. ![Autotracking example with zooming](https://docs.frigate.video/assets/images/frigate-autotracking-example-a94aa5630a0a63649f2a2290393dab27.gif) Autotracking behavior[​](https://docs.frigate.video/configuration/autotracking/#autotracking-behavior "Direct link to Autotracking behavior") ---------------------------------------------------------------------------------------------------------------------------------------------- Once Frigate determines that an object is not a false positive and has entered one of the required zones, the autotracker will move the PTZ camera to keep the object centered in the frame until the object either moves out of the frame, the PTZ is not capable of any more movement, or Frigate loses track of it. Upon loss of tracking, Frigate will scan the region of the lost object for `timeout` seconds. If an object of the same type is found in that region, Frigate will autotrack that new object. When tracking has ended, Frigate will return to the camera firmware's PTZ preset specified by the `return_preset` configuration entry. Checking ONVIF camera support[​](https://docs.frigate.video/configuration/autotracking/#checking-onvif-camera-support "Direct link to Checking ONVIF camera support") ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- Frigate autotracking functions with PTZ cameras capable of relative movement within the field of view (as specified in the [ONVIF spec](https://www.onvif.org/specs/srv/ptz/ONVIF-PTZ-Service-Spec-v1712.pdf) as `RelativePanTiltTranslationSpace` having a `TranslationSpaceFov` entry). Many cheaper or older PTZs may not support this standard. Frigate will report an error message in the log and disable autotracking if your PTZ is unsupported. The FeatureList on the [ONVIF Conformant Products Database](https://www.onvif.org/conformant-products/) can provide a starting point to determine a camera's compatibility with Frigate's autotracking. Look to see if a camera lists `PTZRelative`, `PTZRelativePanTilt` and/or `PTZRelativeZoom`. These features are required for autotracking, but some cameras still fail to respond even if they claim support. A growing list of cameras and brands that have been reported by users to work with Frigate's autotracking can be found [here](https://docs.frigate.video/configuration/cameras) . Configuration[​](https://docs.frigate.video/configuration/autotracking/#configuration "Direct link to Configuration") ---------------------------------------------------------------------------------------------------------------------- First, set up a PTZ preset in your camera's firmware and give it a name. If you're unsure how to do this, consult the documentation for your camera manufacturer's firmware. Some tutorials for common brands: [Amcrest](https://www.youtube.com/watch?v=lJlE9-krmrM) , [Reolink](https://www.youtube.com/watch?v=VAnxHUY5i5w) , [Dahua](https://www.youtube.com/watch?v=7sNbc5U-k54) . Edit your Frigate configuration file and enter the ONVIF parameters for your camera. Specify the object types to track, a required zone the object must enter to begin autotracking, and the camera preset name you configured in your camera's firmware to return to when tracking has ended. Optionally, specify a delay in seconds before Frigate returns the camera to the preset. An [ONVIF connection](https://docs.frigate.video/configuration/cameras) is required for autotracking to function. Also, a [motion mask](https://docs.frigate.video/configuration/masks) over your camera's timestamp and any overlay text is recommended to ensure they are completely excluded from scene change calculations when the camera is moving. Note that `autotracking` is disabled by default but can be enabled in the configuration or by MQTT. cameras: ptzcamera: ... onvif: # Required: host of the camera being connected to. # NOTE: HTTP is assumed by default; HTTPS is supported if you specify the scheme, ex: "https://0.0.0.0". host: 0.0.0.0 # Optional: ONVIF port for device (default: shown below). port: 8000 # Optional: username for login. # NOTE: Some devices require admin to access ONVIF. user: admin # Optional: password for login. password: admin # Optional: Skip TLS verification from the ONVIF server (default: shown below) tls_insecure: False # Optional: PTZ camera object autotracking. Keeps a moving object in # the center of the frame by automatically moving the PTZ camera. autotracking: # Optional: enable/disable object autotracking. (default: shown below) enabled: False # Optional: calibrate the camera on startup (default: shown below) # A calibration will move the PTZ in increments and measure the time it takes to move. # The results are used to help estimate the position of tracked objects after a camera move. # Frigate will update your config file automatically after a calibration with # a "movement_weights" entry for the camera. You should then set calibrate_on_startup to False. calibrate_on_startup: False # Optional: the mode to use for zooming in/out on objects during autotracking. (default: shown below) # Available options are: disabled, absolute, and relative # disabled - don't zoom in/out on autotracked objects, use pan/tilt only # absolute - use absolute zooming (supported by most PTZ capable cameras) # relative - use relative zooming (not supported on all PTZs, but makes concurrent pan/tilt/zoom movements) zooming: disabled # Optional: A value to change the behavior of zooming on autotracked objects. (default: shown below) # A lower value will keep more of the scene in view around a tracked object. # A higher value will zoom in more on a tracked object, but Frigate may lose tracking more quickly. # The value should be between 0.1 and 0.75 zoom_factor: 0.3 # Optional: list of objects to track from labelmap.txt (default: shown below) track: - person # Required: Begin automatically tracking an object when it enters any of the listed zones. required_zones: - zone_name # Required: Name of ONVIF preset in camera's firmware to return to when tracking is over. (default: shown below) return_preset: home # Optional: Seconds to delay before returning to preset. (default: shown below) timeout: 10 # Optional: Values generated automatically by a camera calibration. Do not modify these manually. (default: shown below) movement_weights: [] Calibration[​](https://docs.frigate.video/configuration/autotracking/#calibration "Direct link to Calibration") ---------------------------------------------------------------------------------------------------------------- PTZ motors operate at different speeds. Performing a calibration will direct Frigate to measure this speed over a variety of movements and use those measurements to better predict the amount of movement necessary to keep autotracked objects in the center of the frame. Calibration is optional, but will greatly assist Frigate in autotracking objects that move across the camera's field of view more quickly. To begin calibration, set the `calibrate_on_startup` for your camera to `True` and restart Frigate. Frigate will then make a series of small and large movements with your camera. Don't move the PTZ manually while calibration is in progress. Once complete, camera motion will stop and your config file will be automatically updated with a `movement_weights` parameter to be used in movement calculations. You should not modify this parameter manually. After calibration has ended, your PTZ will be moved to the preset specified by `return_preset`. note Frigate's web UI and all other cameras will be unresponsive while calibration is in progress. This is expected and normal to avoid excessive network traffic or CPU usage during calibration. Calibration for most PTZs will take about two minutes. The Frigate log will show calibration progress and any errors. At this point, Frigate will be running and will continue to refine and update the `movement_weights` parameter in your config automatically as the PTZ moves during autotracking and more measurements are obtained. Before restarting Frigate, you should set `calibrate_on_startup` in your config file to `False`, otherwise your refined `movement_weights` will be overwritten and calibration will occur when starting again. You can recalibrate at any time by removing the `movement_weights` parameter, setting `calibrate_on_startup` to `True`, and then restarting Frigate. You may need to recalibrate or remove `movement_weights` from your config altogether if autotracking is erratic. If you change your `return_preset` in any way or if you change your camera's detect `fps` value, a recalibration is also recommended. If you initially calibrate with zooming disabled and then enable zooming at a later point, you should also recalibrate. Best practices and considerations[​](https://docs.frigate.video/configuration/autotracking/#best-practices-and-considerations "Direct link to Best practices and considerations") ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- Every PTZ camera is different, so autotracking may not perform ideally in every situation. This experimental feature was initially developed using an EmpireTech/Dahua SD1A404XB-GNR. The object tracker in Frigate estimates the motion of the PTZ so that tracked objects are preserved when the camera moves. In most cases 5 fps is sufficient, but if you plan to track faster moving objects, you may want to increase this slightly. Higher frame rates (> 10fps) will only slow down Frigate and the motion estimator and may lead to dropped frames, especially if you are using experimental zooming. A fast [detector](https://docs.frigate.video/configuration/object_detectors) is recommended. CPU detectors will not perform well or won't work at all. You can watch Frigate's debug viewer for your camera to see a thicker colored box around the object currently being autotracked. ![Autotracking Debug View](https://docs.frigate.video/assets/images/autotracking-debug-6502b11759706f915d11c1d6116aad74.gif) A full-frame zone in `required_zones` is not recommended, especially if you've calibrated your camera and there are `movement_weights` defined in the configuration file. Frigate will continue to autotrack an object that has entered one of the `required_zones`, even if it moves outside of that zone. Some users have found it helpful to adjust the zone `inertia` value. See the [configuration reference](https://docs.frigate.video/configuration/) . Zooming[​](https://docs.frigate.video/configuration/autotracking/#zooming "Direct link to Zooming") ---------------------------------------------------------------------------------------------------- Zooming is a very experimental feature and may use significantly more CPU when tracking objects than panning/tilting only. Absolute zooming makes zoom movements separate from pan/tilt movements. Most PTZ cameras will support absolute zooming. Absolute zooming was developed to be very conservative to work best with a variety of cameras and scenes. Absolute zooming usually will not occur until an object has stopped moving or is moving very slowly. Relative zooming attempts to make a zoom movement concurrently with any pan/tilt movements. It was tested to work with some Dahua and Amcrest PTZs. But the ONVIF specification indicates that there no assumption about how the generic zoom range is mapped to magnification, field of view or other physical zoom dimension when using relative zooming. So if relative zooming behavior is erratic or just doesn't work, try absolute zooming. You can optionally adjust the `zoom_factor` for your camera in your configuration file. Lower values will leave more space from the scene around the tracked object while higher values will cause your camera to zoom in more on the object. However, keep in mind that Frigate needs a fair amount of pixels and scene details outside of the bounding box of the tracked object to estimate the motion of your camera. If the object is taking up too much of the frame, Frigate will not be able to track the motion of the camera and your object will be lost. The range of this option is from 0.1 to 0.75. The default value of 0.3 is conservative and should be sufficient for most users. Because every PTZ and scene is different, you should experiment to determine what works best for you. Usage applications[​](https://docs.frigate.video/configuration/autotracking/#usage-applications "Direct link to Usage applications") ------------------------------------------------------------------------------------------------------------------------------------- In security and surveillance, it's common to use "spotter" cameras in combination with your PTZ. When your fixed spotter camera detects an object, you could use an automation platform like Home Assistant to move the PTZ to a specific preset so that Frigate can begin automatically tracking the object. For example: a residence may have fixed cameras on the east and west side of the property, capturing views up and down a street. When the spotter camera on the west side detects a person, a Home Assistant automation could move the PTZ to a camera preset aimed toward the west. When the object enters the specified zone, Frigate's autotracker could then continue to track the person as it moves out of view of any of the fixed cameras. Troubleshooting and FAQ[​](https://docs.frigate.video/configuration/autotracking/#troubleshooting-and-faq "Direct link to Troubleshooting and FAQ") ---------------------------------------------------------------------------------------------------------------------------------------------------- ### The autotracker loses track of my object. Why?[​](https://docs.frigate.video/configuration/autotracking/#the-autotracker-loses-track-of-my-object-why "Direct link to The autotracker loses track of my object. Why?") There are many reasons this could be the case. If you are using experimental zooming, your `zoom_factor` value might be too high, the object might be traveling too quickly, the scene might be too dark, there are not enough details in the scene (for example, a PTZ looking down on a driveway or other monotone background without a sufficient number of hard edges or corners), or the scene is otherwise less than optimal for Frigate to maintain tracking. Your camera's shutter speed may also be set too low so that blurring occurs with motion. Check your camera's firmware to see if you can increase the shutter speed. Watching Frigate's debug view can help to determine a possible cause. The autotracked object will have a thicker colored box around it. ### I'm seeing an error in the logs that my camera "is still in ONVIF 'MOVING' status." What does this mean?[​](https://docs.frigate.video/configuration/autotracking/#im-seeing-an-error-in-the-logs-that-my-camera-is-still-in-onvif-moving-status-what-does-this-mean "Direct link to I'm seeing an error in the logs that my camera "is still in ONVIF 'MOVING' status." What does this mean?") There are two possible known reasons for this (and perhaps others yet unknown): a slow PTZ motor or buggy camera firmware. Frigate uses an ONVIF parameter provided by the camera, `MoveStatus`, to determine when the PTZ's motor is moving or idle. According to some users, Hikvision PTZs (even with the latest firmware), are not updating this value after PTZ movement. Unfortunately there is no workaround to this bug in Hikvision firmware, so autotracking will not function correctly and should be disabled in your config. This may also be the case with other non-Hikvision cameras utilizing Hikvision firmware. ### I tried calibrating my camera, but the logs show that it is stuck at 0% and Frigate is not starting up.[​](https://docs.frigate.video/configuration/autotracking/#i-tried-calibrating-my-camera-but-the-logs-show-that-it-is-stuck-at-0-and-frigate-is-not-starting-up "Direct link to I tried calibrating my camera, but the logs show that it is stuck at 0% and Frigate is not starting up.") This is often caused by the same reason as above - the `MoveStatus` ONVIF parameter is not changing due to a bug in your camera's firmware. Also, see the note above: Frigate's web UI and all other cameras will be unresponsive while calibration is in progress. This is expected and normal. But if you don't see log entries every few seconds for calibration progress, your camera is not compatible with autotracking. ### I'm seeing this error in the logs: "Autotracker: motion estimator couldn't get transformations". What does this mean?[​](https://docs.frigate.video/configuration/autotracking/#im-seeing-this-error-in-the-logs-autotracker-motion-estimator-couldnt-get-transformations-what-does-this-mean "Direct link to I'm seeing this error in the logs: "Autotracker: motion estimator couldn't get transformations". What does this mean?") To maintain object tracking during PTZ moves, Frigate tracks the motion of your camera based on the details of the frame. If you are seeing this message, it could mean that your `zoom_factor` may be set too high, the scene around your detected object does not have enough details (like hard edges or color variations), or your camera's shutter speed is too slow and motion blur is occurring. Try reducing `zoom_factor`, finding a way to alter the scene around your object, or changing your camera's shutter speed. ### Calibration seems to have completed, but the camera is not actually moving to track my object. Why?[​](https://docs.frigate.video/configuration/autotracking/#calibration-seems-to-have-completed-but-the-camera-is-not-actually-moving-to-track-my-object-why "Direct link to Calibration seems to have completed, but the camera is not actually moving to track my object. Why?") Some cameras have firmware that reports that FOV RelativeMove, the ONVIF command that Frigate uses for autotracking, is supported. However, if the camera does not pan or tilt when an object comes into the required zone, your camera's firmware does not actually support FOV RelativeMove. One such camera is the Uniview IPC672LR-AX4DUPK. It actually moves its zoom motor instead of panning and tilting and does not follow the ONVIF standard whatsoever. ### Frigate reports an error saying that calibration has failed. Why?[​](https://docs.frigate.video/configuration/autotracking/#frigate-reports-an-error-saying-that-calibration-has-failed-why "Direct link to Frigate reports an error saying that calibration has failed. Why?") Calibration measures the amount of time it takes for Frigate to make a series of movements with your PTZ. This error message is recorded in the log if these values are too high for Frigate to support calibrated autotracking. This is often the case when your camera's motor or network connection is too slow or your camera's firmware doesn't report the motor status in a timely manner. You can try running without calibration (just remove the `movement_weights` line from your config and restart), but if calibration fails, this often means that autotracking will behave unpredictably. * [Autotracking behavior](https://docs.frigate.video/configuration/autotracking/#autotracking-behavior) * [Checking ONVIF camera support](https://docs.frigate.video/configuration/autotracking/#checking-onvif-camera-support) * [Configuration](https://docs.frigate.video/configuration/autotracking/#configuration) * [Calibration](https://docs.frigate.video/configuration/autotracking/#calibration) * [Best practices and considerations](https://docs.frigate.video/configuration/autotracking/#best-practices-and-considerations) * [Zooming](https://docs.frigate.video/configuration/autotracking/#zooming) * [Usage applications](https://docs.frigate.video/configuration/autotracking/#usage-applications) * [Troubleshooting and FAQ](https://docs.frigate.video/configuration/autotracking/#troubleshooting-and-faq) * [The autotracker loses track of my object. Why?](https://docs.frigate.video/configuration/autotracking/#the-autotracker-loses-track-of-my-object-why) * [I'm seeing an error in the logs that my camera "is still in ONVIF 'MOVING' status." What does this mean?](https://docs.frigate.video/configuration/autotracking/#im-seeing-an-error-in-the-logs-that-my-camera-is-still-in-onvif-moving-status-what-does-this-mean) * [I tried calibrating my camera, but the logs show that it is stuck at 0% and Frigate is not starting up.](https://docs.frigate.video/configuration/autotracking/#i-tried-calibrating-my-camera-but-the-logs-show-that-it-is-stuck-at-0-and-frigate-is-not-starting-up) * [I'm seeing this error in the logs: "Autotracker: motion estimator couldn't get transformations". What does this mean?](https://docs.frigate.video/configuration/autotracking/#im-seeing-this-error-in-the-logs-autotracker-motion-estimator-couldnt-get-transformations-what-does-this-mean) * [Calibration seems to have completed, but the camera is not actually moving to track my object. Why?](https://docs.frigate.video/configuration/autotracking/#calibration-seems-to-have-completed-but-the-camera-is-not-actually-moving-to-track-my-object-why) * [Frigate reports an error saying that calibration has failed. Why?](https://docs.frigate.video/configuration/autotracking/#frigate-reports-an-error-saying-that-calibration-has-failed-why) --- # Authentication | Frigate [Skip to main content](https://docs.frigate.video/configuration/authentication/#__docusaurus_skipToContent_fallback) πŸš€ Get more relevant and accurate detections with Frigate+ models. [Learn more](https://frigate.video/plus/) ✨ On this page Frigate stores user information in its database. Password hashes are generated using industry standard PBKDF2-SHA256 with 600,000 iterations. Upon successful login, a JWT token is issued with an expiration date and set as a cookie. The cookie is refreshed as needed automatically. This JWT token can also be passed in the Authorization header as a bearer token. Users are managed in the UI under Settings > Users. The following ports are available to access the Frigate web UI. | Port | Description | | --- | --- | | `8971` | Authenticated UI and API. Reverse proxies should use this port. | | `5000` | Internal unauthenticated UI and API access. Access to this port should be limited. Intended to be used within the docker network for services that integrate with Frigate and do not support authentication. | Onboarding[​](https://docs.frigate.video/configuration/authentication/#onboarding "Direct link to Onboarding") --------------------------------------------------------------------------------------------------------------- On startup, an admin user and password are generated and printed in the logs. It is recommended to set a new password for the admin account after logging in for the first time under Settings > Users. Resetting admin password[​](https://docs.frigate.video/configuration/authentication/#resetting-admin-password "Direct link to Resetting admin password") --------------------------------------------------------------------------------------------------------------------------------------------------------- In the event that you are locked out of your instance, you can tell Frigate to reset the admin password and print it in the logs on next startup using the `reset_admin_password` setting in your config file. auth: reset_admin_password: true Password guidance[​](https://docs.frigate.video/configuration/authentication/#password-guidance "Direct link to Password guidance") ------------------------------------------------------------------------------------------------------------------------------------ Constructing secure passwords and managing them properly is important. Frigate requires a minimum length of 12 characters. For guidance on password standards see [NIST SP 800-63B](https://pages.nist.gov/800-63-3/sp800-63b.html) . To learn what makes a password truly secure, read this [article](https://medium.com/peerio/how-to-build-a-billion-dollar-password-3d92568d9277) . Login failure rate limiting[​](https://docs.frigate.video/configuration/authentication/#login-failure-rate-limiting "Direct link to Login failure rate limiting") ------------------------------------------------------------------------------------------------------------------------------------------------------------------ In order to limit the risk of brute force attacks, rate limiting is available for login failures. This is implemented with SlowApi, and the string notation for valid values is available in [the documentation](https://limits.readthedocs.io/en/stable/quickstart.html#examples) . For example, `1/second;5/minute;20/hour` will rate limit the login endpoint when failures occur more than: * 1 time per second * 5 times per minute * 20 times per hour Restarting Frigate will reset the rate limits. If you are running Frigate behind a proxy, you will want to set `trusted_proxies` or these rate limits will apply to the upstream proxy IP address. This means that a brute force attack will rate limit login attempts from other devices and could temporarily lock you out of your instance. In order to ensure rate limits only apply to the actual IP address where the requests are coming from, you will need to list the upstream networks that you want to trust. These trusted proxies are checked against the `X-Forwarded-For` header when looking for the IP address where the request originated. If you are running a reverse proxy in the same Docker Compose file as Frigate, here is an example of how your auth config might look: auth: failed_login_rate_limit: "1/second;5/minute;20/hour" trusted_proxies: - 172.18.0.0/16 # <---- this is the subnet for the internal Docker Compose network Session Length[​](https://docs.frigate.video/configuration/authentication/#session-length "Direct link to Session Length") --------------------------------------------------------------------------------------------------------------------------- The default session length for user authentication in Frigate is 24 hours. This setting determines how long a user's authenticated session remains active before a token refresh is required β€” otherwise, the user will need to log in again. While the default provides a balance of security and convenience, you can customize this duration to suit your specific security requirements and user experience preferences. The session length is configured in seconds. The default value of `86400` will expire the authentication session after 24 hours. Some other examples: * `0`: Setting the session length to 0 will require a user to log in every time they access the application or after a very short, immediate timeout. * `604800`: Setting the session length to 604800 will require a user to log in if the token is not refreshed for 7 days. auth: session_length: 86400 JWT Token Secret[​](https://docs.frigate.video/configuration/authentication/#jwt-token-secret "Direct link to JWT Token Secret") --------------------------------------------------------------------------------------------------------------------------------- The JWT token secret needs to be kept secure. Anyone with this secret can generate valid JWT tokens to authenticate with Frigate. This should be a cryptographically random string of at least 64 characters. You can generate a token using the Python secret library with the following command: python3 -c 'import secrets; print(secrets.token_hex(64))' Frigate looks for a JWT token secret in the following order: 1. An environment variable named `FRIGATE_JWT_SECRET` 2. A file named `FRIGATE_JWT_SECRET` in the directory specified by the `CREDENTIALS_DIRECTORY` environment variable (defaults to the Docker Secrets directory: `/run/secrets/`) 3. A `jwt_secret` option from the Home Assistant App options 4. A `.jwt_secret` file in the config directory If no secret is found on startup, Frigate generates one and stores it in a `.jwt_secret` file in the config directory. Changing the secret will invalidate current tokens. Proxy configuration[​](https://docs.frigate.video/configuration/authentication/#proxy-configuration "Direct link to Proxy configuration") ------------------------------------------------------------------------------------------------------------------------------------------ Frigate can be configured to leverage features of common upstream authentication proxies such as Authelia, Authentik, oauth2\_proxy, or traefik-forward-auth. If you are leveraging the authentication of an upstream proxy, you likely want to disable Frigate's authentication as there is no correspondence between users in Frigate's database and users authenticated via the proxy. Optionally, if communication between the reverse proxy and Frigate is over an untrusted network, you should set an `auth_secret` in the `proxy` config and configure the proxy to send the secret value as a header named `X-Proxy-Secret`. Assuming this is an untrusted network, you will also want to [configure a real TLS certificate](https://docs.frigate.video/configuration/tls) to ensure the traffic can't simply be sniffed to steal the secret. Here is an example of how to disable Frigate's authentication and also ensure the requests come only from your known proxy. auth: enabled: Falseproxy: auth_secret: You can use the following code to generate a random secret. python3 -c 'import secrets; print(secrets.token_hex(64))' ### Header mapping[​](https://docs.frigate.video/configuration/authentication/#header-mapping "Direct link to Header mapping") If you have disabled Frigate's authentication and your proxy supports passing a header with authenticated usernames and/or roles, you can use the `header_map` config to specify the header name so it is passed to Frigate. For example, the following will map the `X-Forwarded-User` and `X-Forwarded-Groups` values. Header names are not case sensitive. Multiple values can be included in the role header. Frigate expects that the character separating the roles is a comma, but this can be specified using the `separator` config entry. proxy: ... separator: "|" # This value defaults to a comma, but Authentik uses a pipe, for example. header_map: user: x-forwarded-user role: x-forwarded-groups Frigate supports `admin`, `viewer`, and custom roles (see below). When using port `8971`, Frigate validates these headers and subsequent requests use the headers `remote-user` and `remote-role` for authorization. A default role can be provided. Any value in the mapped `role` header will override the default. proxy: ... default_role: viewer Role mapping[​](https://docs.frigate.video/configuration/authentication/#role-mapping "Direct link to Role mapping") --------------------------------------------------------------------------------------------------------------------- In some environments, upstream identity providers (OIDC, SAML, LDAP, etc.) do not pass a Frigate-compatible role directly, but instead pass one or more group claims. To handle this, Frigate supports a `role_map` that translates upstream group names into Frigate’s internal roles (`admin`, `viewer`, or custom). proxy: ... header_map: user: x-forwarded-user role: x-forwarded-groups role_map: admin: - sysadmins - access-level-security viewer: - camera-viewer operator: # Custom role mapping - operators In this example: * If the proxy passes a role header containing `sysadmins` or `access-level-security`, the user is assigned the `admin` role. * If the proxy passes a role header containing `camera-viewer`, the user is assigned the `viewer` role. * If the proxy passes a role header containing `operators`, the user is assigned the `operator` custom role. * If no mapping matches, Frigate falls back to `default_role` if configured. * If `role_map` is not defined, Frigate assumes the role header directly contains `admin`, `viewer`, or a custom role name. **Note on matching semantics:** * Admin precedence: if the `admin` mapping matches, Frigate resolves the session to `admin` to avoid accidental downgrade when a user belongs to multiple groups (for example both `admin` and `viewer` groups). #### Port Considerations[​](https://docs.frigate.video/configuration/authentication/#port-considerations "Direct link to Port Considerations") **Authenticated Port (8971)** * Header mapping is **fully supported**. * The `remote-role` header determines the user’s privileges: * **admin** β†’ Full access (user management, configuration changes). * **viewer** β†’ Read-only access. * **Custom roles** β†’ Read-only access limited to the cameras defined in `auth.roles[role]`. * Ensure your **proxy sends both user and role headers** for proper role enforcement. **Unauthenticated Port (5000)** * Headers are **ignored** for role enforcement. * All requests are treated as **anonymous**. * The `remote-role` value is **overridden** to **admin-level access**. * This design ensures **unauthenticated internal use** within a trusted network. Note that only the following list of headers are permitted by default: Remote-UserRemote-GroupsRemote-EmailRemote-NameX-Forwarded-UserX-Forwarded-GroupsX-Forwarded-EmailX-Forwarded-Preferred-UsernameX-authentik-usernameX-authentik-groupsX-authentik-emailX-authentik-nameX-authentik-uid If you would like to add more options, you can overwrite the default file with a docker bind mount at `/usr/local/nginx/conf/proxy_trusted_headers.conf`. Reference the source code for the default file formatting. ### Login page redirection[​](https://docs.frigate.video/configuration/authentication/#login-page-redirection "Direct link to Login page redirection") Frigate gracefully performs login page redirection that should work with most authentication proxies. If your reverse proxy returns a `Location` header on `401`, `302`, or `307` unauthorized responses, Frigate's frontend will automatically detect it and redirect to that URL. ### Custom logout url[​](https://docs.frigate.video/configuration/authentication/#custom-logout-url "Direct link to Custom logout url") If your reverse proxy has a dedicated logout url, you can specify using the `logout_url` config option. This will update the link for the `Logout` link in the UI. User Roles[​](https://docs.frigate.video/configuration/authentication/#user-roles "Direct link to User Roles") --------------------------------------------------------------------------------------------------------------- Frigate supports user roles to control access to certain features in the UI and API, such as managing users or modifying configuration settings. Roles are assigned to users in the database or through proxy headers and are enforced when accessing the UI or API through the authenticated port (`8971`). ### Supported Roles[​](https://docs.frigate.video/configuration/authentication/#supported-roles "Direct link to Supported Roles") * **admin**: Full access to all features, including user management and configuration. * **viewer**: Read-only access to the UI and API, including viewing cameras, review items, and historical footage. Configuration editor and settings in the UI are inaccessible. * **Custom Roles**: Arbitrary role names (alphanumeric, dots/underscores) with specific camera permissions. These extend the system for granular access (e.g., "operator" for select cameras). ### Custom Roles and Camera Access[​](https://docs.frigate.video/configuration/authentication/#custom-roles-and-camera-access "Direct link to Custom Roles and Camera Access") The viewer role provides read-only access to all cameras in the UI and API. Custom roles allow admins to limit read-only access to specific cameras. Each role specifies an array of allowed camera names. If a user is assigned a custom role, their account is like the **viewer** role - they can only view Live, Review/History, Explore, and Export for the designated cameras. Backend API endpoints enforce this server-side (e.g., returning 403 for unauthorized cameras), and the frontend UI filters content accordingly (e.g., camera dropdowns show only permitted options). ### Role Configuration Example[​](https://docs.frigate.video/configuration/authentication/#role-configuration-example "Direct link to Role Configuration Example") cameras: front_door: # ... camera config side_yard: # ... camera config garage: # ... camera configauth: enabled: true roles: operator: # Custom role - front_door - garage # Operator can access front and garage neighbor: - side_yard If you want to provide access to all cameras to a specific user, just use the **viewer** role. ### Managing User Roles[​](https://docs.frigate.video/configuration/authentication/#managing-user-roles "Direct link to Managing User Roles") 1. Log in as an **admin** user via port `8971` (preferred), or unauthenticated via port `5000`. 2. Navigate to **Settings**. 3. In the **Users** section, edit a user’s role by selecting from available roles (admin, viewer, or custom). 4. In the **Roles** section, add/edit/delete custom roles (select cameras via switches). Deleting a role auto-reassigns users to "viewer". ### Role Enforcement[​](https://docs.frigate.video/configuration/authentication/#role-enforcement "Direct link to Role Enforcement") When using the authenticated port (`8971`), roles are validated via the JWT token or proxy headers (e.g., `remote-role`). On the internal **unauthenticated** port (`5000`), roles are **not enforced**. All requests are treated as **anonymous**, granting access equivalent to the **admin** role without restrictions. To use role-based access control, you must connect to Frigate via the **authenticated port (`8971`)** directly or through a reverse proxy. ### Role Visibility in the UI[​](https://docs.frigate.video/configuration/authentication/#role-visibility-in-the-ui "Direct link to Role Visibility in the UI") * When logged in via port `8971`, your **username and role** are displayed in the **account menu** (bottom corner). * When using port `5000`, the UI will always display "anonymous" for the username and "admin" for the role. ### Managing User Roles[​](https://docs.frigate.video/configuration/authentication/#managing-user-roles-1 "Direct link to Managing User Roles") 1. Log in as an **admin** user via port `8971`. 2. Navigate to **Settings > Users**. 3. Edit a user’s role by selecting **admin** or **viewer**. API Authentication Guide[​](https://docs.frigate.video/configuration/authentication/#api-authentication-guide "Direct link to API Authentication Guide") --------------------------------------------------------------------------------------------------------------------------------------------------------- ### Getting a Bearer Token[​](https://docs.frigate.video/configuration/authentication/#getting-a-bearer-token "Direct link to Getting a Bearer Token") To use the Frigate API, you need to authenticate first. Follow these steps to obtain a Bearer token: #### 1\. Login[​](https://docs.frigate.video/configuration/authentication/#1-login "Direct link to 1. Login") Make a POST request to `/login` with your credentials: curl -i -X POST https://frigate_ip:8971/api/login \ -H "Content-Type: application/json" \ -d '{"user": "admin", "password": "your_password"}' note You may need to include `-k` in the argument list in these steps (eg: `curl -k -i -X POST ...`) if your Frigate instance is using a self-signed certificate. The response will contain a cookie with the JWT token. #### 2\. Using the Bearer Token[​](https://docs.frigate.video/configuration/authentication/#2-using-the-bearer-token "Direct link to 2. Using the Bearer Token") Once you have the token, include it in the Authorization header for subsequent requests: curl -H "Authorization: Bearer " https://frigate_ip:8971/api/profile #### 3\. Token Lifecycle[​](https://docs.frigate.video/configuration/authentication/#3-token-lifecycle "Direct link to 3. Token Lifecycle") * Tokens are valid for the configured session length * Tokens are automatically refreshed when you visit the `/auth` endpoint * Tokens are invalidated when the user's password is changed * Use `/logout` to clear your session cookie * [Onboarding](https://docs.frigate.video/configuration/authentication/#onboarding) * [Resetting admin password](https://docs.frigate.video/configuration/authentication/#resetting-admin-password) * [Password guidance](https://docs.frigate.video/configuration/authentication/#password-guidance) * [Login failure rate limiting](https://docs.frigate.video/configuration/authentication/#login-failure-rate-limiting) * [Session Length](https://docs.frigate.video/configuration/authentication/#session-length) * [JWT Token Secret](https://docs.frigate.video/configuration/authentication/#jwt-token-secret) * [Proxy configuration](https://docs.frigate.video/configuration/authentication/#proxy-configuration) * [Header mapping](https://docs.frigate.video/configuration/authentication/#header-mapping) * [Role mapping](https://docs.frigate.video/configuration/authentication/#role-mapping) * [Login page redirection](https://docs.frigate.video/configuration/authentication/#login-page-redirection) * [Custom logout url](https://docs.frigate.video/configuration/authentication/#custom-logout-url) * [User Roles](https://docs.frigate.video/configuration/authentication/#user-roles) * [Supported Roles](https://docs.frigate.video/configuration/authentication/#supported-roles) * [Custom Roles and Camera Access](https://docs.frigate.video/configuration/authentication/#custom-roles-and-camera-access) * [Role Configuration Example](https://docs.frigate.video/configuration/authentication/#role-configuration-example) * [Managing User Roles](https://docs.frigate.video/configuration/authentication/#managing-user-roles) * [Role Enforcement](https://docs.frigate.video/configuration/authentication/#role-enforcement) * [Role Visibility in the UI](https://docs.frigate.video/configuration/authentication/#role-visibility-in-the-ui) * [Managing User Roles](https://docs.frigate.video/configuration/authentication/#managing-user-roles-1) * [API Authentication Guide](https://docs.frigate.video/configuration/authentication/#api-authentication-guide) * [Getting a Bearer Token](https://docs.frigate.video/configuration/authentication/#getting-a-bearer-token) --- # Enrichments | Frigate [Skip to main content](https://docs.frigate.video/configuration/hardware_acceleration_enrichments/#__docusaurus_skipToContent_fallback) πŸš€ Get more relevant and accurate detections with Frigate+ models. [Learn more](https://frigate.video/plus/) ✨ On this page Some of Frigate's enrichments can use a discrete GPU or integrated GPU for accelerated processing. Requirements[​](https://docs.frigate.video/configuration/hardware_acceleration_enrichments/#requirements "Direct link to Requirements") ---------------------------------------------------------------------------------------------------------------------------------------- Object detection and enrichments (like Semantic Search, Face Recognition, and License Plate Recognition) are independent features. To use a GPU / NPU for object detection, see the [Object Detectors](https://docs.frigate.video/configuration/object_detectors) documentation. If you want to use your GPU for any supported enrichments, you must choose the appropriate Frigate Docker image for your GPU / NPU and configure the enrichment according to its specific documentation. * **AMD** * ROCm support in the `-rocm` Frigate image is automatically detected for enrichments, but only some enrichment models are available due to ROCm's focus on LLMs and limited stability with certain neural network models. Frigate disables models that perform poorly or are unstable to ensure reliable operation, so only compatible enrichments may be active. * **Intel** * OpenVINO will automatically be detected and used for enrichments in the default Frigate image. * **Note:** Intel NPUs have limited model support for enrichments. GPU is recommended for enrichments when available. * **Nvidia** * Nvidia GPUs will automatically be detected and used for enrichments in the `-tensorrt` Frigate image. * Jetson devices will automatically be detected and used for enrichments in the `-tensorrt-jp6` Frigate image. * **RockChip** * RockChip NPU will automatically be detected and used for semantic search v1 and face recognition in the `-rk` Frigate image. Utilizing a GPU for enrichments does not require you to use the same GPU for object detection. For example, you can run the `tensorrt` Docker image to run enrichments on an Nvidia GPU and still use other dedicated hardware like a Coral or Hailo for object detection. However, one combination that is not supported is the `tensorrt` image for object detection on an Nvidia GPU and Intel iGPU for enrichments. note A Google Coral is a TPU (Tensor Processing Unit), not a dedicated GPU (Graphics Processing Unit) and therefore does not provide any kind of acceleration for Frigate's enrichments. * [Requirements](https://docs.frigate.video/configuration/hardware_acceleration_enrichments/#requirements) --- # FFmpeg presets | Frigate [Skip to main content](https://docs.frigate.video/configuration/ffmpeg_presets/#__docusaurus_skipToContent_fallback) πŸš€ Get more relevant and accurate detections with Frigate+ models. [Learn more](https://frigate.video/plus/) ✨ On this page Some presets of FFmpeg args are provided by default to make the configuration easier. All presets can be seen in [this file](https://github.com/blakeblackshear/frigate/blob/master/frigate/ffmpeg_presets.py) . ### Hwaccel Presets[​](https://docs.frigate.video/configuration/ffmpeg_presets/#hwaccel-presets "Direct link to Hwaccel Presets") It is highly recommended to use hwaccel presets in the config. These presets not only replace the longer args, but they also give Frigate hints of what hardware is available and allows Frigate to make other optimizations using the GPU such as when encoding the birdseye restream or when scaling a stream that has a size different than the native stream size. See [the hwaccel docs](https://docs.frigate.video/configuration/hardware_acceleration_video) for more info on how to setup hwaccel for your GPU / iGPU. | Preset | Usage | Other Notes | | --- | --- | --- | | preset-rpi-64-h264 | 64 bit Rpi with h264 stream | | | preset-rpi-64-h265 | 64 bit Rpi with h265 stream | | | preset-vaapi | Intel & AMD VAAPI | Check hwaccel docs to ensure correct driver is chosen | | preset-intel-qsv-h264 | Intel QSV with h264 stream | If issues occur recommend using vaapi preset instead | | preset-intel-qsv-h265 | Intel QSV with h265 stream | If issues occur recommend using vaapi preset instead | | preset-nvidia | Nvidia GPU | | | preset-jetson-h264 | Nvidia Jetson with h264 stream | | | preset-jetson-h265 | Nvidia Jetson with h265 stream | | | preset-rkmpp | Rockchip MPP | Use image with \*-rk suffix and privileged mode | ### Input Args Presets[​](https://docs.frigate.video/configuration/ffmpeg_presets/#input-args-presets "Direct link to Input Args Presets") Input args presets help make the config more readable and handle use cases for different types of streams to ensure maximum compatibility. See [the camera specific docs](https://docs.frigate.video/configuration/camera_specific) for more info on non-standard cameras and recommendations for using them in Frigate. | Preset | Usage | Other Notes | | --- | --- | --- | | preset-http-jpeg-generic | HTTP Live Jpeg | Recommend restreaming live jpeg instead | | preset-http-mjpeg-generic | HTTP Mjpeg Stream | Recommend restreaming mjpeg stream instead | | preset-http-reolink | Reolink HTTP-FLV Stream | Only for reolink http, not when restreaming as rtsp | | preset-rtmp-generic | RTMP Stream | | | preset-rtsp-generic | RTSP Stream | This is the default when nothing is specified | | preset-rtsp-restream | RTSP Stream from restream | Use for rtsp restream as source for frigate | | preset-rtsp-restream-low-latency | RTSP Stream from restream | Use for rtsp restream as source for frigate to lower latency, may cause issues with some cameras | | preset-rtsp-udp | RTSP Stream via UDP | Use when camera is UDP only | | preset-rtsp-blue-iris | Blue Iris RTSP Stream | Use when consuming a stream from Blue Iris | warning It is important to be mindful of input args when using restream because you can have a mix of protocols. `http` and `rtmp` presets cannot be used with `rtsp` streams. For example, when using a reolink cam with the rtsp restream as a source for record the preset-http-reolink will cause a crash. In this case presets will need to be set at the stream level. See the example below. go2rtc: streams: reolink_cam: http://192.168.0.139/flv?port=1935&app=bcs&stream=channel0_main.bcs&user=admin&password=passwordcameras: reolink_cam: ffmpeg: inputs: - path: http://192.168.0.139/flv?port=1935&app=bcs&stream=channel0_ext.bcs&user=admin&password=password input_args: preset-http-reolink roles: - detect - path: rtsp://127.0.0.1:8554/reolink_cam input_args: preset-rtsp-generic roles: - record ### Output Args Presets[​](https://docs.frigate.video/configuration/ffmpeg_presets/#output-args-presets "Direct link to Output Args Presets") Output args presets help make the config more readable and handle use cases for different types of streams to ensure consistent recordings. | Preset | Usage | Other Notes | | --- | --- | --- | | preset-record-generic | Record WITHOUT audio | If your camera doesn’t have audio, or if you don’t want to record audio, use this option | | preset-record-generic-audio-copy | Record WITH original audio | Use this to enable audio in recordings | | preset-record-generic-audio-aac | Record WITH transcoded aac audio | This is the default when no option is specified. Use it to transcode audio to AAC. If the source is already in AAC format, use preset-record-generic-audio-copy instead to avoid unnecessary re-encoding | | preset-record-mjpeg | Record an mjpeg stream | Recommend restreaming mjpeg stream instead | | preset-record-jpeg | Record live jpeg | Recommend restreaming live jpeg instead | | preset-record-ubiquiti | Record ubiquiti stream with audio | Recordings with ubiquiti non-standard audio | * [Hwaccel Presets](https://docs.frigate.video/configuration/ffmpeg_presets/#hwaccel-presets) * [Input Args Presets](https://docs.frigate.video/configuration/ffmpeg_presets/#input-args-presets) * [Output Args Presets](https://docs.frigate.video/configuration/ffmpeg_presets/#output-args-presets) --- # State Classification | Frigate [Skip to main content](https://docs.frigate.video/configuration/custom_classification/state_classification/#__docusaurus_skipToContent_fallback) πŸš€ Get more relevant and accurate detections with Frigate+ models. [Learn more](https://frigate.video/plus/) ✨ On this page State classification allows you to train a custom MobileNetV2 classification model on a fixed region of your camera frame(s) to determine a current state. The model can be configured to run on a schedule and/or when motion is detected in that region. Classification results are available through the `frigate//classification/` MQTT topic and in Home Assistant sensors via the official Frigate integration. Minimum System Requirements[​](https://docs.frigate.video/configuration/custom_classification/state_classification/#minimum-system-requirements "Direct link to Minimum System Requirements") ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- State classification models are lightweight and run very fast on CPU. Training the model does briefly use a high amount of system resources for about 1–3 minutes per training run. On lower-power devices, training may take longer. A CPU with AVX + AVX2 instructions is required for training and inference. Classes[​](https://docs.frigate.video/configuration/custom_classification/state_classification/#classes "Direct link to Classes") ---------------------------------------------------------------------------------------------------------------------------------- Classes are the different states an area on your camera can be in. Each class represents a distinct visual state that the model will learn to recognize. For state classification: * Define classes that represent mutually exclusive states * Examples: `open` and `closed` for a garage door, `on` and `off` for lights * Use at least 2 classes (typically binary states work best) * Keep class names clear and descriptive Example use cases[​](https://docs.frigate.video/configuration/custom_classification/state_classification/#example-use-cases "Direct link to Example use cases") ---------------------------------------------------------------------------------------------------------------------------------------------------------------- * **Door state**: Detect if a garage or front door is open vs closed. * **Gate state**: Track if a driveway gate is open or closed. * **Trash day**: Bins at curb vs no bins present. * **Pool cover**: Cover on vs off. Configuration[​](https://docs.frigate.video/configuration/custom_classification/state_classification/#configuration "Direct link to Configuration") ---------------------------------------------------------------------------------------------------------------------------------------------------- State classification is configured as a custom classification model. Each model has its own name and settings. You must provide at least one camera crop under `state_config.cameras`. classification: custom: front_door: threshold: 0.8 state_config: motion: true # run when motion overlaps the crop interval: 10 # also run every N seconds (optional) cameras: front: crop: [0, 180, 220, 400] An optional config, `save_attempts`, can be set as a key under the model name. This defines the number of classification attempts to save in the Recent Classifications tab. For state classification models, the default is 100. Training the model[​](https://docs.frigate.video/configuration/custom_classification/state_classification/#training-the-model "Direct link to Training the model") ------------------------------------------------------------------------------------------------------------------------------------------------------------------- Creating and training the model is done within the Frigate UI using the `Classification` page. The process consists of three steps: ### Step 1: Name and Define[​](https://docs.frigate.video/configuration/custom_classification/state_classification/#step-1-name-and-define "Direct link to Step 1: Name and Define") Enter a name for your model and define at least 2 classes (states) that represent mutually exclusive states. For example, `open` and `closed` for a door, or `on` and `off` for lights. ### Step 2: Select the Crop Area[​](https://docs.frigate.video/configuration/custom_classification/state_classification/#step-2-select-the-crop-area "Direct link to Step 2: Select the Crop Area") Choose one or more cameras and draw a rectangle over the area of interest for each camera. The crop should be tight around the region you want to classify to avoid extra signals unrelated to what is being classified. You can drag and resize the rectangle to adjust the crop area. ### Step 3: Assign Training Examples[​](https://docs.frigate.video/configuration/custom_classification/state_classification/#step-3-assign-training-examples "Direct link to Step 3: Assign Training Examples") The system will automatically generate example images from your camera feeds. You'll be guided through each class one at a time to select which images represent that state. It's not strictly required to select all images you see. If a state is missing from the samples, you can train it from the Recent tab later. Once some images are assigned, training will begin automatically. ### Improving the Model[​](https://docs.frigate.video/configuration/custom_classification/state_classification/#improving-the-model "Direct link to Improving the Model") * **Problem framing**: Keep classes visually distinct and state-focused (e.g., `open`, `closed`, `unknown`). Avoid combining object identity with state in a single model unless necessary. * **Data collection**: Use the model's Recent Classifications tab to gather balanced examples across times of day and weather. * **When to train**: Focus on cases where the model is entirely incorrect or flips between states when it should not. There's no need to train additional images when the model is already working consistently. * **Selecting training images**: Images scoring below 100% due to new conditions (e.g., first snow of the year, seasonal changes) or variations (e.g., objects temporarily in view, insects at night) are good candidates for training, as they represent scenarios different from the default state. Training these lower-scoring images that differ from existing training data helps prevent overfitting. Avoid training large quantities of images that look very similar, especially if they already score 100% as this can lead to overfitting. Debugging Classification Models[​](https://docs.frigate.video/configuration/custom_classification/state_classification/#debugging-classification-models "Direct link to Debugging Classification Models") ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- To troubleshoot issues with state classification models, enable debug logging to see detailed information about classification attempts, scores, and state verification. Enable debug logs for classification models by adding `frigate.data_processing.real_time.custom_classification: debug` to your `logger` configuration. These logs are verbose, so only keep this enabled when necessary. Restart Frigate after this change. logger: default: info logs: frigate.data_processing.real_time.custom_classification: debug The debug logs will show: * Classification probabilities for each attempt * Whether scores meet the threshold requirement * State verification progress (consecutive detections needed) * When state changes are published ### Recent Classifications[​](https://docs.frigate.video/configuration/custom_classification/state_classification/#recent-classifications "Direct link to Recent Classifications") For state classification, images are only added to recent classifications under specific circumstances: * **First detection**: The first classification attempt for a camera is always saved * **State changes**: Images are saved when the detected state differs from the current verified state * **Pending verification**: Images are saved when there's a pending state change being verified (requires 3 consecutive identical states) * **Low confidence**: Images with scores below 100% are saved even if the state matches the current state (useful for training) Images are **not** saved when the state is stable (detected state matches current state) **and** the score is 100%. This prevents unnecessary storage of redundant high-confidence classifications. * [Minimum System Requirements](https://docs.frigate.video/configuration/custom_classification/state_classification/#minimum-system-requirements) * [Classes](https://docs.frigate.video/configuration/custom_classification/state_classification/#classes) * [Example use cases](https://docs.frigate.video/configuration/custom_classification/state_classification/#example-use-cases) * [Configuration](https://docs.frigate.video/configuration/custom_classification/state_classification/#configuration) * [Training the model](https://docs.frigate.video/configuration/custom_classification/state_classification/#training-the-model) * [Step 1: Name and Define](https://docs.frigate.video/configuration/custom_classification/state_classification/#step-1-name-and-define) * [Step 2: Select the Crop Area](https://docs.frigate.video/configuration/custom_classification/state_classification/#step-2-select-the-crop-area) * [Step 3: Assign Training Examples](https://docs.frigate.video/configuration/custom_classification/state_classification/#step-3-assign-training-examples) * [Improving the Model](https://docs.frigate.video/configuration/custom_classification/state_classification/#improving-the-model) * [Debugging Classification Models](https://docs.frigate.video/configuration/custom_classification/state_classification/#debugging-classification-models) * [Recent Classifications](https://docs.frigate.video/configuration/custom_classification/state_classification/#recent-classifications) --- # Object Descriptions | Frigate [Skip to main content](https://docs.frigate.video/configuration/genai/genai_objects/#__docusaurus_skipToContent_fallback) πŸš€ Get more relevant and accurate detections with Frigate+ models. [Learn more](https://frigate.video/plus/) ✨ On this page Generative AI can be used to automatically generate descriptive text based on the thumbnails of your tracked objects. This helps with [Semantic Search](https://docs.frigate.video/configuration/semantic_search) in Frigate to provide more context about your tracked objects. Descriptions are accessed via the _Explore_ view in the Frigate UI by clicking on a tracked object's thumbnail. Requests for a description are sent off automatically to your AI provider at the end of the tracked object's lifecycle, or can optionally be sent earlier after a number of significantly changed frames, for example in use in more real-time notifications. Descriptions can also be regenerated manually via the Frigate UI. Note that if you are manually entering a description for tracked objects prior to its end, this will be overwritten by the generated response. By default, descriptions will be generated for all tracked objects and all zones. But you can also optionally specify `objects` and `required_zones` to only generate descriptions for certain tracked objects or zones. Optionally, you can generate the description using a snapshot (if enabled) by setting `use_snapshot` to `True`. By default, this is set to `False`, which sends the uncompressed images from the `detect` stream collected over the object's lifetime to the model. Once the object lifecycle ends, only a single compressed and cropped thumbnail is saved with the tracked object. Using a snapshot might be useful when you want to _regenerate_ a tracked object's description as it will provide the AI with a higher-quality image (typically downscaled by the AI itself) than the cropped/compressed thumbnail. Using a snapshot otherwise has a trade-off in that only a single image is sent to your provider, which will limit the model's ability to determine object movement or direction. Generative AI object descriptions can also be toggled dynamically for a camera via MQTT with the topic `frigate//object_descriptions/set`. See the [MQTT documentation](https://docs.frigate.video/integrations/mqtt/#frigatecamera_nameobjectdescriptionsset) . Usage and Best Practices[​](https://docs.frigate.video/configuration/genai/genai_objects/#usage-and-best-practices "Direct link to Usage and Best Practices") -------------------------------------------------------------------------------------------------------------------------------------------------------------- Frigate's thumbnail search excels at identifying specific details about tracked objects – for example, using an "image caption" approach to find a "person wearing a yellow vest," "a white dog running across the lawn," or "a red car on a residential street." To enhance this further, Frigate’s default prompts are designed to ask your AI provider about the intent behind the object's actions, rather than just describing its appearance. While generating simple descriptions of detected objects is useful, understanding intent provides a deeper layer of insight. Instead of just recognizing "what" is in a scene, Frigate’s default prompts aim to infer "why" it might be there or "what" it could do next. Descriptions tell you what’s happening, but intent gives context. For instance, a person walking toward a door might seem like a visitor, but if they’re moving quickly after hours, you can infer a potential break-in attempt. Detecting a person loitering near a door at night can trigger an alert sooner than simply noting "a person standing by the door," helping you respond based on the situation’s context. Custom Prompts[​](https://docs.frigate.video/configuration/genai/genai_objects/#custom-prompts "Direct link to Custom Prompts") -------------------------------------------------------------------------------------------------------------------------------- Frigate sends multiple frames from the tracked object along with a prompt to your Generative AI provider asking it to generate a description. The default prompt is as follows: Analyze the sequence of images containing the {label}. Focus on the likely intent or behavior of the {label} based on its actions and movement, rather than describing its appearance or the surroundings. Consider what the {label} is doing, why, and what it might do next. tip Prompts can use variable replacements `{label}`, `{sub_label}`, and `{camera}` to substitute information from the tracked object as part of the prompt. You are also able to define custom prompts in your configuration. genai: provider: ollama base_url: http://localhost:11434 model: qwen3-vl:8b-instructobjects: genai: prompt: "Analyze the {label} in these images from the {camera} security camera. Focus on the actions, behavior, and potential intent of the {label}, rather than just describing its appearance." object_prompts: person: "Examine the main person in these images. What are they doing and what might their actions suggest about their intent (e.g., approaching a door, leaving an area, standing still)? Do not describe the surroundings or static details." car: "Observe the primary vehicle in these images. Focus on its movement, direction, or purpose (e.g., parking, approaching, circling). If it's a delivery vehicle, mention the company." Prompts can also be overridden at the camera level to provide a more detailed prompt to the model about your specific camera, if you desire. cameras: front_door: objects: genai: enabled: True use_snapshot: True prompt: "Analyze the {label} in these images from the {camera} security camera at the front door. Focus on the actions and potential intent of the {label}." object_prompts: person: "Examine the person in these images. What are they doing, and how might their actions suggest their purpose (e.g., delivering something, approaching, leaving)? If they are carrying or interacting with a package, include details about its source or destination." cat: "Observe the cat in these images. Focus on its movement and intent (e.g., wandering, hunting, interacting with objects). If the cat is near the flower pots or engaging in any specific actions, mention it." objects: - person - cat required_zones: - steps ### Experiment with prompts[​](https://docs.frigate.video/configuration/genai/genai_objects/#experiment-with-prompts "Direct link to Experiment with prompts") Many providers also have a public facing chat interface for their models. Download a couple of different thumbnails or snapshots from Frigate and try new things in the playground to get descriptions to your liking before updating the prompt in Frigate. * OpenAI - [ChatGPT](https://chatgpt.com/) * Gemini - [Google AI Studio](https://aistudio.google.com/) * Ollama - [Open WebUI](https://docs.openwebui.com/) * [Usage and Best Practices](https://docs.frigate.video/configuration/genai/genai_objects/#usage-and-best-practices) * [Custom Prompts](https://docs.frigate.video/configuration/genai/genai_objects/#custom-prompts) * [Experiment with prompts](https://docs.frigate.video/configuration/genai/genai_objects/#experiment-with-prompts) --- # Object Classification | Frigate [Skip to main content](https://docs.frigate.video/configuration/custom_classification/object_classification/#__docusaurus_skipToContent_fallback) πŸš€ Get more relevant and accurate detections with Frigate+ models. [Learn more](https://frigate.video/plus/) ✨ On this page Object classification allows you to train a custom MobileNetV2 classification model to run on tracked objects (persons, cars, animals, etc.) to identify a finer category or attribute for that object. Classification results are visible in the Tracked Object Details pane in Explore, through the `frigate/tracked_object_details` MQTT topic, in Home Assistant sensors via the official Frigate integration, or through the event endpoints in the HTTP API. Minimum System Requirements[​](https://docs.frigate.video/configuration/custom_classification/object_classification/#minimum-system-requirements "Direct link to Minimum System Requirements") ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- Object classification models are lightweight and run very fast on CPU. Training the model does briefly use a high amount of system resources for about 1–3 minutes per training run. On lower-power devices, training may take longer. A CPU with AVX + AVX2 instructions is required for training and inference. Classes[​](https://docs.frigate.video/configuration/custom_classification/object_classification/#classes "Direct link to Classes") ----------------------------------------------------------------------------------------------------------------------------------- Classes are the categories your model will learn to distinguish between. Each class represents a distinct visual category that the model will predict. For object classification: * Define classes that represent different types or attributes of the detected object * Examples: For `person` objects, classes might be `delivery_person`, `resident`, `stranger` * Include a `none` class for objects that don't fit any specific category * Keep classes visually distinct to improve accuracy ### Classification Type[​](https://docs.frigate.video/configuration/custom_classification/object_classification/#classification-type "Direct link to Classification Type") * **Sub label**: * Applied to the object’s `sub_label` field. * Ideal for a single, more specific identity or type. * Example: `cat` β†’ `Leo`, `Charlie`, `None`. * **Attribute**: * Added as metadata to the object, visible in the Tracked Object Details pane in Explore, `frigate/events` MQTT messages, and the HTTP API response as `: `. * Ideal when multiple attributes can coexist independently. * Example: Detecting if a `person` in a construction yard is wearing a helmet or not, and if they are wearing a yellow vest or not. note A tracked object can only have a single sub label. If you are using Triggers or Face Recognition and you configure an object classification model for `person` using the sub label type, your sub label may not be assigned correctly as it depends on which enrichment completes its analysis first. This could also occur with `car` objects that are assigned a sub label for a delivery carrier. Consider using the `attribute` type instead. Assignment Requirements[​](https://docs.frigate.video/configuration/custom_classification/object_classification/#assignment-requirements "Direct link to Assignment Requirements") ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- Sub labels and attributes are only assigned when both conditions are met: 1. **Threshold**: Each classification attempt must have a confidence score that meets or exceeds the configured `threshold` (default: `0.8`). 2. **Class Consensus**: After at least 3 classification attempts, 60% of attempts must agree on the same class label. If the consensus class is `none`, no assignment is made. This two-step verification prevents false positives by requiring consistent predictions across multiple frames before assigning a sub label or attribute. Example use cases[​](https://docs.frigate.video/configuration/custom_classification/object_classification/#example-use-cases "Direct link to Example use cases") ----------------------------------------------------------------------------------------------------------------------------------------------------------------- ### Sub label[​](https://docs.frigate.video/configuration/custom_classification/object_classification/#sub-label "Direct link to Sub label") * **Known pet vs unknown**: For `dog` objects, set sub label to your pet’s name (e.g., `buddy`) or `none` for others. * **Mail truck vs normal car**: For `car`, classify as `mail_truck` vs `car` to filter important arrivals. * **Delivery vs non-delivery person**: For `person`, classify `delivery` vs `visitor` based on uniform/props. ### Attributes[​](https://docs.frigate.video/configuration/custom_classification/object_classification/#attributes "Direct link to Attributes") * **Backpack**: For `person`, add attribute `backpack: yes/no`. * **Helmet**: For `person` (worksite), add `helmet: yes/no`. * **Leash**: For `dog`, add `leash: yes/no` (useful for park or yard rules). * **Ladder rack**: For `truck`, add `ladder_rack: yes/no` to flag service vehicles. Configuration[​](https://docs.frigate.video/configuration/custom_classification/object_classification/#configuration "Direct link to Configuration") ----------------------------------------------------------------------------------------------------------------------------------------------------- Object classification is configured as a custom classification model. Each model has its own name and settings. You must list which object labels should be classified. classification: custom: dog: threshold: 0.8 object_config: objects: [dog] # object labels to classify classification_type: sub_label # or: attribute An optional config, `save_attempts`, can be set as a key under the model name. This defines the number of classification attempts to save in the Recent Classifications tab. For object classification models, the default is 200. Training the model[​](https://docs.frigate.video/configuration/custom_classification/object_classification/#training-the-model "Direct link to Training the model") -------------------------------------------------------------------------------------------------------------------------------------------------------------------- Creating and training the model is done within the Frigate UI using the `Classification` page. The process consists of two steps: ### Step 1: Name and Define[​](https://docs.frigate.video/configuration/custom_classification/object_classification/#step-1-name-and-define "Direct link to Step 1: Name and Define") Enter a name for your model, select the object label to classify (e.g., `person`, `dog`, `car`), choose the classification type (sub label or attribute), and define your classes. Frigate will automatically include a `none` class for objects that don't fit any specific category. For example: To classify your two cats, create a model named "Our Cats" and create two classes, "Charlie" and "Leo". A third class, "none", will be created automatically for other neighborhood cats that are not your own. ### Step 2: Assign Training Examples[​](https://docs.frigate.video/configuration/custom_classification/object_classification/#step-2-assign-training-examples "Direct link to Step 2: Assign Training Examples") The system will automatically generate example images from detected objects matching your selected label. You'll be guided through each class one at a time to select which images represent that class. Any images not assigned to a specific class will automatically be assigned to `none` when you complete the last class. Once all images are processed, training will begin automatically. When choosing which objects to classify, start with a small number of visually distinct classes and ensure your training samples match camera viewpoints and distances typical for those objects. If examples for some of your classes do not appear in the grid, you can continue configuring the model without them. New images will begin to appear in the Recent Classifications view. When your missing classes are seen, classify them from this view and retrain your model. ### Improving the Model[​](https://docs.frigate.video/configuration/custom_classification/object_classification/#improving-the-model "Direct link to Improving the Model") * **Problem framing**: Keep classes visually distinct and relevant to the chosen object types. * **Data collection**: Use the model’s Recent Classification tab to gather balanced examples across times of day, weather, and distances. * **Preprocessing**: Ensure examples reflect object crops similar to Frigate’s boxes; keep the subject centered. * **Labels**: Keep label names short and consistent; include a `none` class if you plan to ignore uncertain predictions for sub labels. * **Threshold**: Tune `threshold` per model to reduce false assignments. Start at `0.8` and adjust based on validation. Debugging Classification Models[​](https://docs.frigate.video/configuration/custom_classification/object_classification/#debugging-classification-models "Direct link to Debugging Classification Models") ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- To troubleshoot issues with object classification models, enable debug logging to see detailed information about classification attempts, scores, and consensus calculations. Enable debug logs for classification models by adding `frigate.data_processing.real_time.custom_classification: debug` to your `logger` configuration. These logs are verbose, so only keep this enabled when necessary. Restart Frigate after this change. logger: default: info logs: frigate.data_processing.real_time.custom_classification: debug The debug logs will show: * Classification probabilities for each attempt * Whether scores meet the threshold requirement * Consensus calculations and when assignments are made * Object classification history and weighted scores * [Minimum System Requirements](https://docs.frigate.video/configuration/custom_classification/object_classification/#minimum-system-requirements) * [Classes](https://docs.frigate.video/configuration/custom_classification/object_classification/#classes) * [Classification Type](https://docs.frigate.video/configuration/custom_classification/object_classification/#classification-type) * [Assignment Requirements](https://docs.frigate.video/configuration/custom_classification/object_classification/#assignment-requirements) * [Example use cases](https://docs.frigate.video/configuration/custom_classification/object_classification/#example-use-cases) * [Sub label](https://docs.frigate.video/configuration/custom_classification/object_classification/#sub-label) * [Attributes](https://docs.frigate.video/configuration/custom_classification/object_classification/#attributes) * [Configuration](https://docs.frigate.video/configuration/custom_classification/object_classification/#configuration) * [Training the model](https://docs.frigate.video/configuration/custom_classification/object_classification/#training-the-model) * [Step 1: Name and Define](https://docs.frigate.video/configuration/custom_classification/object_classification/#step-1-name-and-define) * [Step 2: Assign Training Examples](https://docs.frigate.video/configuration/custom_classification/object_classification/#step-2-assign-training-examples) * [Improving the Model](https://docs.frigate.video/configuration/custom_classification/object_classification/#improving-the-model) * [Debugging Classification Models](https://docs.frigate.video/configuration/custom_classification/object_classification/#debugging-classification-models) --- # Configuring Generative AI | Frigate [Skip to main content](https://docs.frigate.video/configuration/genai/genai_config/#__docusaurus_skipToContent_fallback) πŸš€ Get more relevant and accurate detections with Frigate+ models. [Learn more](https://frigate.video/plus/) ✨ On this page Configuration[​](https://docs.frigate.video/configuration/genai/genai_config/#configuration "Direct link to Configuration") ---------------------------------------------------------------------------------------------------------------------------- A Generative AI provider can be configured in the global config, which will make the Generative AI features available for use. There are currently 3 native providers available to integrate with Frigate. Other providers that support the OpenAI standard API can also be used. See the OpenAI section below. To use Generative AI, you must define a single provider at the global level of your Frigate configuration. If the provider you choose requires an API key, you may either directly paste it in your configuration, or store it in an environment variable prefixed with `FRIGATE_`. Ollama[​](https://docs.frigate.video/configuration/genai/genai_config/#ollama "Direct link to Ollama") ------------------------------------------------------------------------------------------------------- warning Using Ollama on CPU is not recommended, high inference times make using Generative AI impractical. [Ollama](https://ollama.com/) allows you to self-host large language models and keep everything running locally. It is highly recommended to host this server on a machine with an Nvidia graphics card, or on a Apple silicon Mac for best performance. Most of the 7b parameter 4-bit vision models will fit inside 8GB of VRAM. There is also a [Docker container](https://hub.docker.com/r/ollama/ollama) available. Parallel requests also come with some caveats. You will need to set `OLLAMA_NUM_PARALLEL=1` and choose a `OLLAMA_MAX_QUEUE` and `OLLAMA_MAX_LOADED_MODELS` values that are appropriate for your hardware and preferences. See the [Ollama documentation](https://docs.ollama.com/faq#how-does-ollama-handle-concurrent-requests) . ### Model Types: Instruct vs Thinking[​](https://docs.frigate.video/configuration/genai/genai_config/#model-types-instruct-vs-thinking "Direct link to Model Types: Instruct vs Thinking") Most vision-language models are available as **instruct** models, which are fine-tuned to follow instructions and respond concisely to prompts. However, some models (such as certain Qwen-VL or minigpt variants) offer both **instruct** and **thinking** versions. * **Instruct models** are always recommended for use with Frigate. These models generate direct, relevant, actionable descriptions that best fit Frigate's object and event summary use case. * **Thinking models** are fine-tuned for more free-form, open-ended, and speculative outputs, which are typically not concise and may not provide the practical summaries Frigate expects. For this reason, Frigate does **not** recommend or support using thinking models. Some models are labeled as **hybrid** (capable of both thinking and instruct tasks). In these cases, Frigate will always use instruct-style prompts and specifically disables thinking-mode behaviors to ensure concise, useful responses. **Recommendation:** Always select the `-instruct` or documented instruct/tagged variant of any model you use in your Frigate configuration. If in doubt, refer to your model provider’s documentation or model library for guidance on the correct model variant to use. ### Supported Models[​](https://docs.frigate.video/configuration/genai/genai_config/#supported-models "Direct link to Supported Models") You must use a vision capable model with Frigate. Current model variants can be found [in their model library](https://ollama.com/library) . Note that Frigate will not automatically download the model you specify in your config, Ollama will try to download the model but it may take longer than the timeout, it is recommended to pull the model beforehand by running `ollama pull your_model` on your Ollama server/Docker container. Note that the model specified in Frigate's config must match the downloaded model tag. info Each model is available in multiple parameter sizes (3b, 4b, 8b, etc.). Larger sizes are more capable of complex tasks and understanding of situations, but requires more memory and computational resources. It is recommended to try multiple models and experiment to see which performs best. tip If you are trying to use a single model for Frigate and HomeAssistant, it will need to support vision and tools calling. qwen3-VL supports vision and tools simultaneously in Ollama. The following models are recommended: | Model | Notes | | --- | --- | | `qwen3-vl` | Strong visual and situational understanding, higher vram requirement | | `Intern3.5VL` | Relatively fast with good vision comprehension | | `gemma3` | Strong frame-to-frame understanding, slower inference times | | `qwen2.5-vl` | Fast but capable model with good vision comprehension | note You should have at least 8 GB of RAM available (or VRAM if running on GPU) to run the 7B models, 16 GB to run the 13B models, and 32 GB to run the 33B models. #### Ollama Cloud models[​](https://docs.frigate.video/configuration/genai/genai_config/#ollama-cloud-models "Direct link to Ollama Cloud models") Ollama also supports [cloud models](https://ollama.com/cloud) , where your local Ollama instance handles requests from Frigate, but model inference is performed in the cloud. Set up Ollama locally, sign in with your Ollama account, and specify the cloud model name in your Frigate config. For more details, see the Ollama cloud model [docs](https://docs.ollama.com/cloud) . ### Configuration[​](https://docs.frigate.video/configuration/genai/genai_config/#configuration-1 "Direct link to Configuration") genai: provider: ollama base_url: http://localhost:11434 model: qwen3-vl:4b Google Gemini[​](https://docs.frigate.video/configuration/genai/genai_config/#google-gemini "Direct link to Google Gemini") ---------------------------------------------------------------------------------------------------------------------------- Google Gemini has a [free tier](https://ai.google.dev/pricing) for the API, however the limits may not be sufficient for standard Frigate usage. Choose a plan appropriate for your installation. ### Supported Models[​](https://docs.frigate.video/configuration/genai/genai_config/#supported-models-1 "Direct link to Supported Models") You must use a vision capable model with Frigate. Current model variants can be found [in their documentation](https://ai.google.dev/gemini-api/docs/models/gemini) . ### Get API Key[​](https://docs.frigate.video/configuration/genai/genai_config/#get-api-key "Direct link to Get API Key") To start using Gemini, you must first get an API key from [Google AI Studio](https://aistudio.google.com/) . 1. Accept the Terms of Service 2. Click "Get API Key" from the right hand navigation 3. Click "Create API key in new project" 4. Copy the API key for use in your config ### Configuration[​](https://docs.frigate.video/configuration/genai/genai_config/#configuration-2 "Direct link to Configuration") genai: provider: gemini api_key: "{FRIGATE_GEMINI_API_KEY}" model: gemini-2.5-flash note To use a different Gemini-compatible API endpoint, set the `provider_options` with the `base_url` key to your provider's API URL. For example: genai: provider: gemini ... provider_options: base_url: https://... Other HTTP options are available, see the [python-genai documentation](https://github.com/googleapis/python-genai) . OpenAI[​](https://docs.frigate.video/configuration/genai/genai_config/#openai "Direct link to OpenAI") ------------------------------------------------------------------------------------------------------- OpenAI does not have a free tier for their API. With the release of gpt-4o, pricing has been reduced and each generation should cost fractions of a cent if you choose to go this route. ### Supported Models[​](https://docs.frigate.video/configuration/genai/genai_config/#supported-models-2 "Direct link to Supported Models") You must use a vision capable model with Frigate. Current model variants can be found [in their documentation](https://platform.openai.com/docs/models) . ### Get API Key[​](https://docs.frigate.video/configuration/genai/genai_config/#get-api-key-1 "Direct link to Get API Key") To start using OpenAI, you must first [create an API key](https://platform.openai.com/api-keys) and [configure billing](https://platform.openai.com/settings/organization/billing/overview) . ### Configuration[​](https://docs.frigate.video/configuration/genai/genai_config/#configuration-3 "Direct link to Configuration") genai: provider: openai api_key: "{FRIGATE_OPENAI_API_KEY}" model: gpt-4o note To use a different OpenAI-compatible API endpoint, set the `OPENAI_BASE_URL` environment variable to your provider's API URL. tip For OpenAI-compatible servers (such as llama.cpp) that don't expose the configured context size in the API response, you can manually specify the context size in `provider_options`: genai: provider: openai base_url: http://your-llama-server model: your-model-name provider_options: context_size: 8192 # Specify the configured context size This ensures Frigate uses the correct context window size when generating prompts. Azure OpenAI[​](https://docs.frigate.video/configuration/genai/genai_config/#azure-openai "Direct link to Azure OpenAI") ------------------------------------------------------------------------------------------------------------------------- Microsoft offers several vision models through Azure OpenAI. A subscription is required. ### Supported Models[​](https://docs.frigate.video/configuration/genai/genai_config/#supported-models-3 "Direct link to Supported Models") You must use a vision capable model with Frigate. Current model variants can be found [in their documentation](https://learn.microsoft.com/en-us/azure/ai-services/openai/concepts/models) . ### Create Resource and Get API Key[​](https://docs.frigate.video/configuration/genai/genai_config/#create-resource-and-get-api-key "Direct link to Create Resource and Get API Key") To start using Azure OpenAI, you must first [create a resource](https://learn.microsoft.com/azure/cognitive-services/openai/how-to/create-resource?pivots=web-portal#create-a-resource) . You'll need your API key, model name, and resource URL, which must include the `api-version` parameter (see the example below). ### Configuration[​](https://docs.frigate.video/configuration/genai/genai_config/#configuration-4 "Direct link to Configuration") genai: provider: azure_openai base_url: https://instance.cognitiveservices.azure.com/openai/responses?api-version=2025-04-01-preview model: gpt-5-mini api_key: "{FRIGATE_OPENAI_API_KEY}" * [Configuration](https://docs.frigate.video/configuration/genai/genai_config/#configuration) * [Ollama](https://docs.frigate.video/configuration/genai/genai_config/#ollama) * [Model Types: Instruct vs Thinking](https://docs.frigate.video/configuration/genai/genai_config/#model-types-instruct-vs-thinking) * [Supported Models](https://docs.frigate.video/configuration/genai/genai_config/#supported-models) * [Configuration](https://docs.frigate.video/configuration/genai/genai_config/#configuration-1) * [Google Gemini](https://docs.frigate.video/configuration/genai/genai_config/#google-gemini) * [Supported Models](https://docs.frigate.video/configuration/genai/genai_config/#supported-models-1) * [Get API Key](https://docs.frigate.video/configuration/genai/genai_config/#get-api-key) * [Configuration](https://docs.frigate.video/configuration/genai/genai_config/#configuration-2) * [OpenAI](https://docs.frigate.video/configuration/genai/genai_config/#openai) * [Supported Models](https://docs.frigate.video/configuration/genai/genai_config/#supported-models-2) * [Get API Key](https://docs.frigate.video/configuration/genai/genai_config/#get-api-key-1) * [Configuration](https://docs.frigate.video/configuration/genai/genai_config/#configuration-3) * [Azure OpenAI](https://docs.frigate.video/configuration/genai/genai_config/#azure-openai) * [Supported Models](https://docs.frigate.video/configuration/genai/genai_config/#supported-models-3) * [Create Resource and Get API Key](https://docs.frigate.video/configuration/genai/genai_config/#create-resource-and-get-api-key) * [Configuration](https://docs.frigate.video/configuration/genai/genai_config/#configuration-4) --- # Face Recognition | Frigate [Skip to main content](https://docs.frigate.video/configuration/face_recognition/#__docusaurus_skipToContent_fallback) πŸš€ Get more relevant and accurate detections with Frigate+ models. [Learn more](https://frigate.video/plus/) ✨ On this page Face recognition identifies known individuals by matching detected faces with previously learned facial data. When a known `person` is recognized, their name will be added as a `sub_label`. This information is included in the UI, filters, as well as in notifications. Model Requirements[​](https://docs.frigate.video/configuration/face_recognition/#model-requirements "Direct link to Model Requirements") ----------------------------------------------------------------------------------------------------------------------------------------- ### Face Detection[​](https://docs.frigate.video/configuration/face_recognition/#face-detection "Direct link to Face Detection") When running a Frigate+ model (or any custom model that natively detects faces) should ensure that `face` is added to the [list of objects to track](https://docs.frigate.video/plus/#available-label-types) either globally or for a specific camera. This will allow face detection to run at the same time as object detection and be more efficient. When running a default COCO model or another model that does not include `face` as a detectable label, face detection will run via CV2 using a lightweight DNN model that runs on the CPU. In this case, you should _not_ define `face` in your list of objects to track. note Frigate needs to first detect a `person` before it can detect and recognize a face. ### Face Recognition[​](https://docs.frigate.video/configuration/face_recognition/#face-recognition "Direct link to Face Recognition") Frigate has support for two face recognition model types: * **small**: Frigate will run a FaceNet embedding model to recognize faces, which runs locally on the CPU. This model is optimized for efficiency and is not as accurate. * **large**: Frigate will run a large ArcFace embedding model that is optimized for accuracy. It is only recommended to be run when an integrated or dedicated GPU / NPU is available. In both cases, a lightweight face landmark detection model is also used to align faces before running recognition. All of these features run locally on your system. Minimum System Requirements[​](https://docs.frigate.video/configuration/face_recognition/#minimum-system-requirements "Direct link to Minimum System Requirements") -------------------------------------------------------------------------------------------------------------------------------------------------------------------- A CPU with AVX + AVX2 instructions is required to run Face Recognition. The `small` model is optimized for efficiency and runs on the CPU, most CPUs should run the model efficiently. The `large` model is optimized for accuracy, an integrated or discrete GPU / NPU is required. See the [Hardware Accelerated Enrichments](https://docs.frigate.video/configuration/hardware_acceleration_enrichments) documentation. Configuration[​](https://docs.frigate.video/configuration/face_recognition/#configuration "Direct link to Configuration") -------------------------------------------------------------------------------------------------------------------------- Face recognition is disabled by default, face recognition must be enabled in the UI or in your config file before it can be used. Face recognition is a global configuration setting. face_recognition: enabled: true Like the other real-time processors in Frigate, face recognition runs on the camera stream defined by the `detect` role in your config. To ensure optimal performance, select a suitable resolution for this stream in your camera's firmware that fits your specific scene and requirements. Advanced Configuration[​](https://docs.frigate.video/configuration/face_recognition/#advanced-configuration "Direct link to Advanced Configuration") ----------------------------------------------------------------------------------------------------------------------------------------------------- Fine-tune face recognition with these optional parameters at the global level of your config. The only optional parameters that can be set at the camera level are `enabled` and `min_area`. ### Detection[​](https://docs.frigate.video/configuration/face_recognition/#detection "Direct link to Detection") * `detection_threshold`: Face detection confidence score required before recognition runs: * Default: `0.7` * Note: This is field only applies to the standalone face detection model, `min_score` should be used to filter for models that have face detection built in. * `min_area`: Defines the minimum size (in pixels) a face must be before recognition runs. * Default: `500` pixels. * Depending on the resolution of your camera's `detect` stream, you can increase this value to ignore small or distant faces. ### Recognition[​](https://docs.frigate.video/configuration/face_recognition/#recognition "Direct link to Recognition") * `model_size`: Which model size to use, options are `small` or `large` * `unknown_score`: Min score to mark a person as a potential match, matches at or below this will be marked as unknown. * Default: `0.8`. * `recognition_threshold`: Recognition confidence score required to add the face to the object as a sub label. * Default: `0.9`. * `min_faces`: Min face recognitions for the sub label to be applied to the person object. * Default: `1` * `save_attempts`: Number of images of recognized faces to save for training. * Default: `200`. * `blur_confidence_filter`: Enables a filter that calculates how blurry the face is and adjusts the confidence based on this. * Default: `True`. * `device`: Target a specific device to run the face recognition model on (multi-GPU installation). * Default: `None`. * Note: This setting is only applicable when using the `large` model. See [onnxruntime's provider options](https://onnxruntime.ai/docs/execution-providers/) Usage[​](https://docs.frigate.video/configuration/face_recognition/#usage "Direct link to Usage") -------------------------------------------------------------------------------------------------- Follow these steps to begin: 1. **Enable face recognition** in your configuration file and restart Frigate. 2. **Upload one face** using the **Add Face** button's wizard in the Face Library section of the Frigate UI. Read below for the best practices on expanding your training set. 3. When Frigate detects and attempts to recognize a face, it will appear in the **Train** tab of the Face Library, along with its associated recognition confidence. 4. From the **Train** tab, you can **assign the face** to a new or existing person to improve recognition accuracy for the future. Creating a Robust Training Set[​](https://docs.frigate.video/configuration/face_recognition/#creating-a-robust-training-set "Direct link to Creating a Robust Training Set") ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------- The number of images needed for a sufficient training set for face recognition varies depending on several factors: * Diversity of the dataset: A dataset with diverse images, including variations in lighting, pose, and facial expressions, will require fewer images per person than a less diverse dataset. * Desired accuracy: The higher the desired accuracy, the more images are typically needed. However, here are some general guidelines: * Minimum: For basic face recognition tasks, a minimum of 5-10 images per person is often recommended. * Recommended: For more robust and accurate systems, 20-30 images per person is a good starting point. * Ideal: For optimal performance, especially in challenging conditions, 50-100 images per person can be beneficial. The accuracy of face recognition is heavily dependent on the quality of data given to it for training. It is recommended to build the face training library in phases. tip When choosing images to include in the face training set it is recommended to always follow these recommendations: * If it is difficult to make out details in a persons face it will not be helpful in training. * Avoid images with extreme under/over-exposure. * Avoid blurry / pixelated images. * Avoid training on infrared (gray-scale). The models are trained on color images and will be able to extract features from gray-scale images. * Using images of people wearing hats / sunglasses may confuse the model. * Do not upload too many similar images at the same time, it is recommended to train no more than 4-6 similar images for each person to avoid over-fitting. ### Understanding the Recent Recognitions Tab[​](https://docs.frigate.video/configuration/face_recognition/#understanding-the-recent-recognitions-tab "Direct link to Understanding the Recent Recognitions Tab") The Recent Recognitions tab in the face library displays recent face recognition attempts. Detected face images are grouped according to the person they were identified as potentially matching. Each face image is labeled with a name (or `Unknown`) along with the confidence score of the recognition attempt. While each image can be used to train the system for a specific person, not all images are suitable for training. Refer to the guidelines below for best practices on selecting images for training. ### Step 1 - Building a Strong Foundation[​](https://docs.frigate.video/configuration/face_recognition/#step-1---building-a-strong-foundation "Direct link to Step 1 - Building a Strong Foundation") When first enabling face recognition it is important to build a foundation of strong images. It is recommended to start by uploading 1-5 photos containing just this person's face. It is important that the person's face in the photo is front-facing and not turned, this will ensure a good starting point. Then it is recommended to use the `Face Library` tab in Frigate to select and train images for each person as they are detected. When building a strong foundation it is strongly recommended to only train on images that are front-facing. Ignore images from cameras that recognize faces from an angle. Aim to strike a balance between the quality of images while also having a range of conditions (day / night, different weather conditions, different times of day, etc.) in order to have diversity in the images used for each person and not have over-fitting. You do not want to train images that are 90%+ as these are already being confidently recognized. In this step the goal is to train on clear, lower scoring front-facing images until the majority of front-facing images for a given person are consistently recognized correctly. Then it is time to move on to step 2. ### Step 2 - Expanding The Dataset[​](https://docs.frigate.video/configuration/face_recognition/#step-2---expanding-the-dataset "Direct link to Step 2 - Expanding The Dataset") Once front-facing images are performing well, start choosing slightly off-angle images to include for training. It is important to still choose images where enough face detail is visible to recognize someone, and you still only want to train on images that score lower. FAQ[​](https://docs.frigate.video/configuration/face_recognition/#faq "Direct link to FAQ") -------------------------------------------------------------------------------------------- ### How do I debug Face Recognition issues?[​](https://docs.frigate.video/configuration/face_recognition/#how-do-i-debug-face-recognition-issues "Direct link to How do I debug Face Recognition issues?") Start with the [Usage](https://docs.frigate.video/configuration/face_recognition/#usage) section and re-read the [Model Requirements](https://docs.frigate.video/configuration/face_recognition/#model-requirements) above. 1. Ensure `person` is being _detected_. A `person` will automatically be scanned by Frigate for a face. Any detected faces will appear in the Recent Recognitions tab in the Frigate UI's Face Library. If you are using a Frigate+ or `face` detecting model: * Watch the debug view (Settings --> Debug) to ensure that `face` is being detected along with `person`. * You may need to adjust the `min_score` for the `face` object if faces are not being detected. If you are **not** using a Frigate+ or `face` detecting model: * Check your `detect` stream resolution and ensure it is sufficiently high enough to capture face details on `person` objects. * You may need to lower your `detection_threshold` if faces are not being detected. 2. Any detected faces will then be _recognized_. * Make sure you have trained at least one face per the recommendations above. * Adjust `recognition_threshold` settings per the suggestions [above](https://docs.frigate.video/configuration/face_recognition/#advanced-configuration) . ### Detection does not work well with blurry images?[​](https://docs.frigate.video/configuration/face_recognition/#detection-does-not-work-well-with-blurry-images "Direct link to Detection does not work well with blurry images?") Accuracy is definitely a going to be improved with higher quality cameras / streams. It is important to look at the DORI (Detection Observation Recognition Identification) range of your camera, if that specification is posted. This specification explains the distance from the camera that a person can be detected, observed, recognized, and identified. The identification range is the most relevant here, and the distance listed by the camera is the furthest that face recognition will realistically work. Some users have also noted that setting the stream in camera firmware to a constant bit rate (CBR) leads to better image clarity than with a variable bit rate (VBR). ### Why can't I bulk upload photos?[​](https://docs.frigate.video/configuration/face_recognition/#why-cant-i-bulk-upload-photos "Direct link to Why can't I bulk upload photos?") It is important to methodically add photos to the library, bulk importing photos (especially from a general photo library) will lead to over-fitting in that particular scenario and hurt recognition performance. ### Why can't I bulk reprocess faces?[​](https://docs.frigate.video/configuration/face_recognition/#why-cant-i-bulk-reprocess-faces "Direct link to Why can't I bulk reprocess faces?") Face embedding models work by breaking apart faces into different features. This means that when reprocessing an image, only images from a similar angle will have its score affected. ### Why do unknown people score similarly to known people?[​](https://docs.frigate.video/configuration/face_recognition/#why-do-unknown-people-score-similarly-to-known-people "Direct link to Why do unknown people score similarly to known people?") This can happen for a few different reasons, but this is usually an indicator that the training set needs to be improved. This is often related to over-fitting: * If you train with only a few images per person, especially if those images are very similar, the recognition model becomes overly specialized to those specific images. * When you provide images with different poses, lighting, and expressions, the algorithm extracts features that are consistent across those variations. * By training on a diverse set of images, the algorithm becomes less sensitive to minor variations and noise in the input image. Review your face collections and remove most of the unclear or low-quality images. Then, use the **Reprocess** button on each face in the **Train** tab to evaluate how the changes affect recognition scores. Avoid training on images that already score highly, as this can lead to over-fitting. Instead, focus on relatively clear images that score lower - ideally with different lighting, angles, and conditionsβ€”to help the model generalize more effectively. ### Frigate misidentified a face. Can I tell it that a face is "not" a specific person?[​](https://docs.frigate.video/configuration/face_recognition/#frigate-misidentified-a-face-can-i-tell-it-that-a-face-is-not-a-specific-person "Direct link to Frigate misidentified a face. Can I tell it that a face is "not" a specific person?") No, face recognition does not support negative training (i.e., explicitly telling it who someone is _not_). Instead, the best approach is to improve the training data by using a more diverse and representative set of images for each person. For more guidance, refer to the section above on improving recognition accuracy. ### I see scores above the threshold in the Recent Recognitions tab, but a sub label wasn't assigned?[​](https://docs.frigate.video/configuration/face_recognition/#i-see-scores-above-the-threshold-in-the-recent-recognitions-tab-but-a-sub-label-wasnt-assigned "Direct link to I see scores above the threshold in the Recent Recognitions tab, but a sub label wasn't assigned?") The Frigate considers the recognition scores across all recognition attempts for each person object. The scores are continually weighted based on the area of the face, and a sub label will only be assigned to person if a person is confidently recognized consistently. This avoids cases where a single high confidence recognition would throw off the results. ### Can I use other face recognition software like DoubleTake at the same time as the built in face recognition?[​](https://docs.frigate.video/configuration/face_recognition/#can-i-use-other-face-recognition-software-like-doubletake-at-the-same-time-as-the-built-in-face-recognition "Direct link to Can I use other face recognition software like DoubleTake at the same time as the built in face recognition?") No, using another face recognition service will interfere with Frigate's built in face recognition. When using double-take the sub\_label feature must be disabled if the built in face recognition is also desired. ### Does face recognition run on the recording stream?[​](https://docs.frigate.video/configuration/face_recognition/#does-face-recognition-run-on-the-recording-stream "Direct link to Does face recognition run on the recording stream?") Face recognition does not run on the recording stream, this would be suboptimal for many reasons: 1. The latency of accessing the recordings means the notifications would not include the names of recognized people because recognition would not complete until after. 2. The embedding models used run on a set image size, so larger images will be scaled down to match this anyway. 3. Motion clarity is much more important than extra pixels, over-compression and motion blur are much more detrimental to results than resolution. ### I get an unknown error when taking a photo directly with my iPhone[​](https://docs.frigate.video/configuration/face_recognition/#i-get-an-unknown-error-when-taking-a-photo-directly-with-my-iphone "Direct link to I get an unknown error when taking a photo directly with my iPhone") By default iOS devices will use HEIC (High Efficiency Image Container) for images, but this format is not supported for uploads. Choosing `large` as the format instead of `original` will use JPG which will work correctly. ### How can I delete the face database and start over?[​](https://docs.frigate.video/configuration/face_recognition/#how-can-i-delete-the-face-database-and-start-over "Direct link to How can I delete the face database and start over?") Frigate does not store anything in its database related to face recognition. You can simply delete all of your faces through the Frigate UI or remove the contents of the `/media/frigate/clips/faces` directory. * [Model Requirements](https://docs.frigate.video/configuration/face_recognition/#model-requirements) * [Face Detection](https://docs.frigate.video/configuration/face_recognition/#face-detection) * [Face Recognition](https://docs.frigate.video/configuration/face_recognition/#face-recognition) * [Minimum System Requirements](https://docs.frigate.video/configuration/face_recognition/#minimum-system-requirements) * [Configuration](https://docs.frigate.video/configuration/face_recognition/#configuration) * [Advanced Configuration](https://docs.frigate.video/configuration/face_recognition/#advanced-configuration) * [Detection](https://docs.frigate.video/configuration/face_recognition/#detection) * [Recognition](https://docs.frigate.video/configuration/face_recognition/#recognition) * [Usage](https://docs.frigate.video/configuration/face_recognition/#usage) * [Creating a Robust Training Set](https://docs.frigate.video/configuration/face_recognition/#creating-a-robust-training-set) * [Understanding the Recent Recognitions Tab](https://docs.frigate.video/configuration/face_recognition/#understanding-the-recent-recognitions-tab) * [Step 1 - Building a Strong Foundation](https://docs.frigate.video/configuration/face_recognition/#step-1---building-a-strong-foundation) * [Step 2 - Expanding The Dataset](https://docs.frigate.video/configuration/face_recognition/#step-2---expanding-the-dataset) * [FAQ](https://docs.frigate.video/configuration/face_recognition/#faq) * [How do I debug Face Recognition issues?](https://docs.frigate.video/configuration/face_recognition/#how-do-i-debug-face-recognition-issues) * [Detection does not work well with blurry images?](https://docs.frigate.video/configuration/face_recognition/#detection-does-not-work-well-with-blurry-images) * [Why can't I bulk upload photos?](https://docs.frigate.video/configuration/face_recognition/#why-cant-i-bulk-upload-photos) * [Why can't I bulk reprocess faces?](https://docs.frigate.video/configuration/face_recognition/#why-cant-i-bulk-reprocess-faces) * [Why do unknown people score similarly to known people?](https://docs.frigate.video/configuration/face_recognition/#why-do-unknown-people-score-similarly-to-known-people) * [Frigate misidentified a face. Can I tell it that a face is "not" a specific person?](https://docs.frigate.video/configuration/face_recognition/#frigate-misidentified-a-face-can-i-tell-it-that-a-face-is-not-a-specific-person) * [I see scores above the threshold in the Recent Recognitions tab, but a sub label wasn't assigned?](https://docs.frigate.video/configuration/face_recognition/#i-see-scores-above-the-threshold-in-the-recent-recognitions-tab-but-a-sub-label-wasnt-assigned) * [Can I use other face recognition software like DoubleTake at the same time as the built in face recognition?](https://docs.frigate.video/configuration/face_recognition/#can-i-use-other-face-recognition-software-like-doubletake-at-the-same-time-as-the-built-in-face-recognition) * [Does face recognition run on the recording stream?](https://docs.frigate.video/configuration/face_recognition/#does-face-recognition-run-on-the-recording-stream) * [I get an unknown error when taking a photo directly with my iPhone](https://docs.frigate.video/configuration/face_recognition/#i-get-an-unknown-error-when-taking-a-photo-directly-with-my-iphone) * [How can I delete the face database and start over?](https://docs.frigate.video/configuration/face_recognition/#how-can-i-delete-the-face-database-and-start-over) --- # Camera Specific Configurations | Frigate [Skip to main content](https://docs.frigate.video/configuration/camera_specific/#__docusaurus_skipToContent_fallback) πŸš€ Get more relevant and accurate detections with Frigate+ models. [Learn more](https://frigate.video/plus/) ✨ On this page note This page makes use of presets of FFmpeg args. For more information on presets, see the [FFmpeg Presets](https://docs.frigate.video/configuration/ffmpeg_presets) page. note Many cameras support encoding options which greatly affect the live view experience, see the [Live view](https://docs.frigate.video/configuration/live) page for more info. H.265 Cameras via Safari[​](https://docs.frigate.video/configuration/camera_specific/#h265-cameras-via-safari "Direct link to H.265 Cameras via Safari") --------------------------------------------------------------------------------------------------------------------------------------------------------- Some cameras support h265 with different formats, but Safari only supports the annexb format. When using h265 camera streams for recording with devices that use the Safari browser, the `apple_compatibility` option should be used. cameras: h265_cam: # <------ Doesn't matter what the camera is called ffmpeg: apple_compatibility: true # <- Adds compatibility with MacOS and iPhone MJPEG Cameras[​](https://docs.frigate.video/configuration/camera_specific/#mjpeg-cameras "Direct link to MJPEG Cameras") ------------------------------------------------------------------------------------------------------------------------- Note that mjpeg cameras require encoding the video into h264 for recording, and restream roles. This will use significantly more CPU than if the cameras supported h264 feeds directly. It is recommended to use the restream role to create an h264 restream and then use that as the source for ffmpeg. go2rtc: streams: mjpeg_cam: "ffmpeg:http://your_mjpeg_stream_url#video=h264#hardware" # <- use hardware acceleration to create an h264 stream usable for other components.cameras: ... mjpeg_cam: ffmpeg: inputs: - path: rtsp://127.0.0.1:8554/mjpeg_cam roles: - detect - record JPEG Stream Cameras[​](https://docs.frigate.video/configuration/camera_specific/#jpeg-stream-cameras "Direct link to JPEG Stream Cameras") ------------------------------------------------------------------------------------------------------------------------------------------- Cameras using a live changing jpeg image will need input parameters as below input_args: preset-http-jpeg-generic Outputting the stream will have the same args and caveats as per [MJPEG Cameras](https://docs.frigate.video/configuration/camera_specific/#mjpeg-cameras) RTMP Cameras[​](https://docs.frigate.video/configuration/camera_specific/#rtmp-cameras "Direct link to RTMP Cameras") ---------------------------------------------------------------------------------------------------------------------- The input parameters need to be adjusted for RTMP cameras ffmpeg: input_args: preset-rtmp-generic UDP Only Cameras[​](https://docs.frigate.video/configuration/camera_specific/#udp-only-cameras "Direct link to UDP Only Cameras") ---------------------------------------------------------------------------------------------------------------------------------- If your cameras do not support TCP connections for RTSP, you can use UDP. ffmpeg: input_args: preset-rtsp-udp Model/vendor specific setup[​](https://docs.frigate.video/configuration/camera_specific/#modelvendor-specific-setup "Direct link to Model/vendor specific setup") ------------------------------------------------------------------------------------------------------------------------------------------------------------------ ### Amcrest & Dahua[​](https://docs.frigate.video/configuration/camera_specific/#amcrest--dahua "Direct link to Amcrest & Dahua") Amcrest & Dahua cameras should be connected to via RTSP using the following format: rtsp://USERNAME:PASSWORD@CAMERA-IP/cam/realmonitor?channel=1&subtype=0 # this is the main streamrtsp://USERNAME:PASSWORD@CAMERA-IP/cam/realmonitor?channel=1&subtype=1 # this is the sub stream, typically supporting low resolutions onlyrtsp://USERNAME:PASSWORD@CAMERA-IP/cam/realmonitor?channel=1&subtype=2 # higher end cameras support a third stream with a mid resolution (1280x720, 1920x1080)rtsp://USERNAME:PASSWORD@CAMERA-IP/cam/realmonitor?channel=1&subtype=3 # new higher end cameras support a fourth stream with another mid resolution (1280x720, 1920x1080) ### Annke C800[​](https://docs.frigate.video/configuration/camera_specific/#annke-c800 "Direct link to Annke C800") This camera is H.265 only. To be able to play clips on some devices (like MacOs or iPhone) the H.265 stream has to be adjusted using the `apple_compatibility` config. cameras: annkec800: # <------ Name the camera ffmpeg: apple_compatibility: true # <- Adds compatibility with MacOS and iPhone output_args: record: preset-record-generic-audio-aac inputs: - path: rtsp://USERNAME:PASSWORD@CAMERA-IP/H264/ch1/main/av_stream # <----- Update for your camera roles: - detect - record detect: width: # <- optional, by default Frigate tries to automatically detect resolution height: # <- optional, by default Frigate tries to automatically detect resolution ### Blue Iris RTSP Cameras[​](https://docs.frigate.video/configuration/camera_specific/#blue-iris-rtsp-cameras "Direct link to Blue Iris RTSP Cameras") You will need to remove `nobuffer` flag for Blue Iris RTSP cameras ffmpeg: input_args: preset-rtsp-blue-iris ### Hikvision Cameras[​](https://docs.frigate.video/configuration/camera_specific/#hikvision-cameras "Direct link to Hikvision Cameras") Hikvision cameras should be connected to via RTSP using the following format: rtsp://USERNAME:PASSWORD@CAMERA-IP/streaming/channels/101 # this is the main streamrtsp://USERNAME:PASSWORD@CAMERA-IP/streaming/channels/102 # this is the sub stream, typically supporting low resolutions onlyrtsp://USERNAME:PASSWORD@CAMERA-IP/streaming/channels/103 # higher end cameras support a third stream with a mid resolution (1280x720, 1920x1080) note [Some users have reported](https://www.reddit.com/r/frigate_nvr/comments/1hg4ze7/hikvision_security_settings) that newer Hikvision cameras require adjustments to the security settings: RTSP Authentication - digest/basicRTSP Digest Algorithm - MD5WEB Authentication - digest/basicWEB Digest Algorithm - MD5 ### Reolink Cameras[​](https://docs.frigate.video/configuration/camera_specific/#reolink-cameras "Direct link to Reolink Cameras") Reolink has many different camera models with inconsistently supported features and behavior. The below table shows a summary of various features and recommendations. | Camera Resolution | Camera Generation | Recommended Stream Type | Additional Notes | | --- | --- | --- | --- | | 5MP or lower | All | http-flv | Stream is h264 | | 6MP or higher | Latest (ex: Duo3, CX-8##) | http-flv with ffmpeg 8.0, or rtsp | This uses the new http-flv-enhanced over H265 which requires ffmpeg 8.0 | | 6MP or higher | Older (ex: RLC-8##) | rtsp | | Frigate works much better with newer reolink cameras that are setup with the below options: If available, recommended settings are: * `On, fluency first` this sets the camera to CBR (constant bit rate) * `Interframe Space 1x` this sets the iframe interval to the same as the frame rate According to [this discussion](https://github.com/blakeblackshear/frigate/issues/3235#issuecomment-1135876973) , the http video streams seem to be the most reliable for Reolink. Cameras connected via a Reolink NVR can be connected with the http stream, use `channel[0..15]` in the stream url for the additional channels. The setup of main stream can be also done via RTSP, but isn't always reliable on all hardware versions. The example configuration is working with the oldest HW version RLN16-410 device with multiple types of cameras. Example Config tip Reolink's latest cameras support two way audio via go2rtc and other applications. It is important that the http-flv stream is still used for stability, a secondary rtsp stream can be added that will be using for the two way audio only. NOTE: The RTSP stream can not be prefixed with `ffmpeg:`, as go2rtc needs to handle the stream to support two way audio. Ensure HTTP is enabled in the camera's advanced network settings. To use two way talk with Frigate, see the [Live view documentation](https://docs.frigate.video/configuration/live#two-way-talk) . go2rtc: streams: # example for connecting to a standard Reolink camera your_reolink_camera: - "ffmpeg:http://reolink_ip/flv?port=1935&app=bcs&stream=channel0_main.bcs&user=username&password=password#video=copy#audio=copy#audio=opus" your_reolink_camera_sub: - "ffmpeg:http://reolink_ip/flv?port=1935&app=bcs&stream=channel0_ext.bcs&user=username&password=password" # example for connectin to a Reolink camera that supports two way talk your_reolink_camera_twt: - "ffmpeg:http://reolink_ip/flv?port=1935&app=bcs&stream=channel0_main.bcs&user=username&password=password#video=copy#audio=copy#audio=opus" - "rtsp://username:password@reolink_ip/Preview_01_sub" your_reolink_camera_twt_sub: - "ffmpeg:http://reolink_ip/flv?port=1935&app=bcs&stream=channel0_ext.bcs&user=username&password=password" - "rtsp://username:password@reolink_ip/Preview_01_sub" # example for connecting to a Reolink NVR your_reolink_camera_via_nvr: - "ffmpeg:http://reolink_nvr_ip/flv?port=1935&app=bcs&stream=channel3_main.bcs&user=username&password=password" # channel numbers are 0-15 - "ffmpeg:your_reolink_camera_via_nvr#audio=aac" your_reolink_camera_via_nvr_sub: - "ffmpeg:http://reolink_nvr_ip/flv?port=1935&app=bcs&stream=channel3_ext.bcs&user=username&password=password"cameras: your_reolink_camera: ffmpeg: inputs: - path: rtsp://127.0.0.1:8554/your_reolink_camera input_args: preset-rtsp-restream roles: - record - path: rtsp://127.0.0.1:8554/your_reolink_camera_sub input_args: preset-rtsp-restream roles: - detect reolink_via_nvr: ffmpeg: inputs: - path: rtsp://127.0.0.1:8554/your_reolink_camera_via_nvr?video=copy&audio=aac input_args: preset-rtsp-restream roles: - record - path: rtsp://127.0.0.1:8554/your_reolink_camera_via_nvr_sub?video=copy input_args: preset-rtsp-restream roles: - detect ### Unifi Protect Cameras[​](https://docs.frigate.video/configuration/camera_specific/#unifi-protect-cameras "Direct link to Unifi Protect Cameras") note Unifi G5s cameras and newer need a Unifi Protect server to enable rtsps stream, it's not posible to enable it in standalone mode. Unifi protect cameras require the rtspx stream to be used with go2rtc. To utilize a Unifi protect camera, modify the rtsps link to begin with rtspx. Additionally, remove the "?enableSrtp" from the end of the Unifi link. go2rtc: streams: front: - rtspx://192.168.1.1:7441/abcdefghijk [See the go2rtc docs for more information](https://github.com/AlexxIT/go2rtc/tree/v1.9.10#source-rtsp) In the Unifi 2.0 update Unifi Protect Cameras had a change in audio sample rate which causes issues for ffmpeg. The input rate needs to be set for record if used directly with unifi protect. ffmpeg: output_args: record: preset-record-ubiquiti ### TP-Link VIGI Cameras[​](https://docs.frigate.video/configuration/camera_specific/#tp-link-vigi-cameras "Direct link to TP-Link VIGI Cameras") TP-Link VIGI cameras need some adjustments to the main stream settings on the camera itself to avoid issues. The stream needs to be configured as `H264` with `Smart Coding` set to `off`. Without these settings you may have problems when trying to watch recorded footage. For example Firefox will stop playback after a few seconds and show the following error message: `The media playback was aborted due to a corruption problem or because the media used features your browser did not support.`. ### Wyze Wireless Cameras[​](https://docs.frigate.video/configuration/camera_specific/#wyze-wireless-cameras "Direct link to Wyze Wireless Cameras") Some community members have found better performance on Wyze cameras by using an alternative firmware known as [Thingino](https://thingino.com/) . USB Cameras (aka Webcams)[​](https://docs.frigate.video/configuration/camera_specific/#usb-cameras-aka-webcams "Direct link to USB Cameras (aka Webcams)") ----------------------------------------------------------------------------------------------------------------------------------------------------------- To use a USB camera (webcam) with Frigate, the recommendation is to use go2rtc's [FFmpeg Device](https://github.com/AlexxIT/go2rtc?tab=readme-ov-file#source-ffmpeg-device) support: * Preparation outside of Frigate: * Get USB camera path. Run `v4l2-ctl --list-devices` to get a listing of locally-connected cameras available. (You may need to install `v4l-utils` in a way appropriate for your Linux distribution). In the sample configuration below, we use `video=0` to correlate with a detected device path of `/dev/video0` * Get USB camera formats & resolutions. Run `ffmpeg -f v4l2 -list_formats all -i /dev/video0` to get an idea of what formats and resolutions the USB Camera supports. In the sample configuration below, we use a width of 1024 and height of 576 in the stream and detection settings based on what was reported back. * If using Frigate in a container (e.g. Docker on TrueNAS), ensure you have USB Passthrough support enabled, along with a specific Host Device (`/dev/video0`) + Container Device (`/dev/video0`) listed. * In your Frigate Configuration File, add the go2rtc stream and roles as appropriate: go2rtc: streams: usb_camera: - "ffmpeg:device?video=0&video_size=1024x576#video=h264"cameras: usb_camera: enabled: true ffmpeg: inputs: - path: rtsp://127.0.0.1:8554/usb_camera input_args: preset-rtsp-restream roles: - detect - record detect: enabled: false # <---- disable detection until you have a working camera feed width: 1024 height: 576 * [H.265 Cameras via Safari](https://docs.frigate.video/configuration/camera_specific/#h265-cameras-via-safari) * [MJPEG Cameras](https://docs.frigate.video/configuration/camera_specific/#mjpeg-cameras) * [JPEG Stream Cameras](https://docs.frigate.video/configuration/camera_specific/#jpeg-stream-cameras) * [RTMP Cameras](https://docs.frigate.video/configuration/camera_specific/#rtmp-cameras) * [UDP Only Cameras](https://docs.frigate.video/configuration/camera_specific/#udp-only-cameras) * [Model/vendor specific setup](https://docs.frigate.video/configuration/camera_specific/#modelvendor-specific-setup) * [Amcrest & Dahua](https://docs.frigate.video/configuration/camera_specific/#amcrest--dahua) * [Annke C800](https://docs.frigate.video/configuration/camera_specific/#annke-c800) * [Blue Iris RTSP Cameras](https://docs.frigate.video/configuration/camera_specific/#blue-iris-rtsp-cameras) * [Hikvision Cameras](https://docs.frigate.video/configuration/camera_specific/#hikvision-cameras) * [Reolink Cameras](https://docs.frigate.video/configuration/camera_specific/#reolink-cameras) * [Unifi Protect Cameras](https://docs.frigate.video/configuration/camera_specific/#unifi-protect-cameras) * [TP-Link VIGI Cameras](https://docs.frigate.video/configuration/camera_specific/#tp-link-vigi-cameras) * [Wyze Wireless Cameras](https://docs.frigate.video/configuration/camera_specific/#wyze-wireless-cameras) * [USB Cameras (aka Webcams)](https://docs.frigate.video/configuration/camera_specific/#usb-cameras-aka-webcams) --- # Review Summaries | Frigate [Skip to main content](https://docs.frigate.video/configuration/genai/genai_review/#__docusaurus_skipToContent_fallback) πŸš€ Get more relevant and accurate detections with Frigate+ models. [Learn more](https://frigate.video/plus/) ✨ On this page Generative AI can be used to automatically generate structured summaries of review items. These summaries will show up in Frigate's native notifications as well as in the UI. Generative AI can also be used to take a collection of summaries over a period of time and provide a report, which may be useful to get a quick report of everything that happened while out for some amount of time. Requests for a summary are requested automatically to your AI provider for alert review items when the activity has ended, they can also be optionally enabled for detections as well. Generative AI review summaries can also be toggled dynamically for a [camera via MQTT](https://docs.frigate.video/integrations/mqtt/#frigatecamera_namereviewdescriptionsset) . Review Summary Usage and Best Practices[​](https://docs.frigate.video/configuration/genai/genai_review/#review-summary-usage-and-best-practices "Direct link to Review Summary Usage and Best Practices") ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- Review summaries provide structured JSON responses that are saved for each review item: - `title` (string): A concise, direct title that describes the purpose or overall action (e.g., "Person taking out trash", "Joe walking dog").- `scene` (string): A narrative description of what happens across the sequence from start to finish, including setting, detected objects, and their observable actions.- `shortSummary` (string): A brief 2-sentence summary of the scene, suitable for notifications. This is a condensed version of the scene description.- `confidence` (float): 0-1 confidence in the analysis. Higher confidence when objects/actions are clearly visible and context is unambiguous.- `other_concerns` (list): List of user-defined concerns that may need additional investigation.- `potential_threat_level` (integer): 0, 1, or 2 as defined below. This will show in multiple places in the UI to give additional context about each activity, and allow viewing more details when extra attention is required. Frigate's built in notifications will automatically show the title and `shortSummary` when the data is available, while the full `scene` description is available in the UI for detailed review. ### Defining Typical Activity[​](https://docs.frigate.video/configuration/genai/genai_review/#defining-typical-activity "Direct link to Defining Typical Activity") Each installation and even camera can have different parameters for what is considered suspicious activity. Frigate allows the `activity_context_prompt` to be defined globally and at the camera level, which allows you to define more specifically what should be considered normal activity. It is important that this is not overly specific as it can sway the output of the response. Default Activity Context Prompt review: genai: activity_context_prompt: | ### Normal Activity Indicators (Level 0) - Known/verified people in any zone at any time - People with pets in residential areas - Deliveries or services during daytime/evening (6 AM - 10 PM): carrying packages to doors/porches, placing items, leaving - Services/maintenance workers with visible tools, uniforms, or service vehicles during daytime - Activity confined to public areas only (sidewalks, streets) without entering property at any time ### Suspicious Activity Indicators (Level 1) - **Testing or attempting to open doors/windows/handles on vehicles or buildings** β€” ALWAYS Level 1 regardless of time or duration - **Unidentified person in private areas (driveways, near vehicles/buildings) during late night/early morning (11 PM - 5 AM)** β€” ALWAYS Level 1 regardless of activity or duration - Taking items that don't belong to them (packages, objects from porches/driveways) - Climbing or jumping fences/barriers to access property - Attempting to conceal actions or items from view - Prolonged loitering: remaining in same area without visible purpose throughout most of the sequence ### Critical Threat Indicators (Level 2) - Holding break-in tools (crowbars, pry bars, bolt cutters) - Weapons visible (guns, knives, bats used aggressively) - Forced entry in progress - Physical aggression or violence - Active property damage or theft in progress ### Assessment Guidance Evaluate in this order: 1. **If person is verified/known** β†’ Level 0 regardless of time or activity 2. **If person is unidentified:** - Check time: If late night/early morning (11 PM - 5 AM) AND in private areas (driveways, near vehicles/buildings) β†’ Level 1 - Check actions: If testing doors/handles, taking items, climbing β†’ Level 1 - Otherwise, if daytime/evening (6 AM - 10 PM) with clear legitimate purpose (delivery, service worker) β†’ Level 0 3. **Escalate to Level 2 if:** Weapons, break-in tools, forced entry in progress, violence, or active property damage visible (escalates from Level 0 or 1) The mere presence of an unidentified person in private areas during late night hours is inherently suspicious and warrants human review, regardless of what activity they appear to be doing or how brief the sequence is. ### Image Source[​](https://docs.frigate.video/configuration/genai/genai_review/#image-source "Direct link to Image Source") By default, review summaries use preview images (cached preview frames) which have a lower resolution but use fewer tokens per image. For better image quality and more detailed analysis, you can configure Frigate to extract frames directly from recordings at a higher resolution: review: genai: enabled: true image_source: recordings # Options: "preview" (default) or "recordings" When using `recordings`, frames are extracted at 480px height while maintaining the camera's original aspect ratio, providing better detail for the LLM while being mindful of context window size. This is particularly useful for scenarios where fine details matter, such as identifying license plates, reading text, or analyzing distant objects. The number of frames sent to the LLM is dynamically calculated based on: * Your LLM provider's context window size * The camera's resolution and aspect ratio (ultrawide cameras like 32:9 use more tokens per image) * The image source (recordings use more tokens than preview images) Frame counts are automatically optimized to use ~98% of the available context window while capping at 20 frames maximum to ensure reasonable inference times. Note that using recordings will: * Provide higher quality images to the LLM (480p vs 180p preview images) * Use more tokens per image due to higher resolution * Result in fewer frames being sent for ultrawide cameras due to larger image size * Require that recordings are enabled for the camera If recordings are not available for a given time period, the system will automatically fall back to using preview frames. ### Additional Concerns[​](https://docs.frigate.video/configuration/genai/genai_review/#additional-concerns "Direct link to Additional Concerns") Along with the concern of suspicious activity or immediate threat, you may have concerns such as animals in your garden or a gate being left open. These concerns can be configured so that the review summaries will make note of them if the activity requires additional review. For example: review: genai: enabled: true additional_concerns: - animals in the garden ### Preferred Language[​](https://docs.frigate.video/configuration/genai/genai_review/#preferred-language "Direct link to Preferred Language") By default, review summaries are generated in English. You can configure Frigate to generate summaries in your preferred language by setting the `preferred_language` option: review: genai: enabled: true preferred_language: Spanish Review Reports[​](https://docs.frigate.video/configuration/genai/genai_review/#review-reports "Direct link to Review Reports") ------------------------------------------------------------------------------------------------------------------------------- Along with individual review item summaries, Generative AI can also produce a single report of review items from all cameras marked "suspicious" over a specified time period (for example, a daily summary of suspicious activity while you're on vacation). ### Requesting Reports Programmatically[​](https://docs.frigate.video/configuration/genai/genai_review/#requesting-reports-programmatically "Direct link to Requesting Reports Programmatically") Review reports can be requested via the [API](https://docs.frigate.video/integrations/api/generate-review-summary-review-summarize-start-start-ts-end-end-ts-post) by sending a POST request to `/api/review/summarize/start/{start_ts}/end/{end_ts}` with Unix timestamps. For Home Assistant users, there is a built-in service (`frigate.review_summarize`) that makes it easy to request review reports as part of automations or scripts. This allows you to automatically generate daily summaries, vacation reports, or custom time period reports based on your specific needs. * [Review Summary Usage and Best Practices](https://docs.frigate.video/configuration/genai/genai_review/#review-summary-usage-and-best-practices) * [Defining Typical Activity](https://docs.frigate.video/configuration/genai/genai_review/#defining-typical-activity) * [Image Source](https://docs.frigate.video/configuration/genai/genai_review/#image-source) * [Additional Concerns](https://docs.frigate.video/configuration/genai/genai_review/#additional-concerns) * [Preferred Language](https://docs.frigate.video/configuration/genai/genai_review/#preferred-language) * [Review Reports](https://docs.frigate.video/configuration/genai/genai_review/#review-reports) * [Requesting Reports Programmatically](https://docs.frigate.video/configuration/genai/genai_review/#requesting-reports-programmatically) --- # Installing Frigate App | Frigate [Skip to main content](https://docs.frigate.video/configuration/pwa/#__docusaurus_skipToContent_fallback) πŸš€ Get more relevant and accurate detections with Frigate+ models. [Learn more](https://frigate.video/plus/) ✨ On this page Frigate supports being installed as a [Progressive Web App](https://web.dev/explore/progressive-web-apps) on Desktop, Android, and iOS. This adds features including the ability to deep link directly into the app. Requirements[​](https://docs.frigate.video/configuration/pwa/#requirements "Direct link to Requirements") ---------------------------------------------------------------------------------------------------------- In order to install Frigate as a PWA, the following requirements must be met: * Frigate must be accessed via a secure context (localhost, secure https, VPN, etc.) * On Android, Firefox, Chrome, Edge, Opera, and Samsung Internet Browser all support installing PWAs. * On iOS 16.4 and later, PWAs can be installed from the Share menu in Safari, Chrome, Edge, Firefox, and Orion. Installation[​](https://docs.frigate.video/configuration/pwa/#installation "Direct link to Installation") ---------------------------------------------------------------------------------------------------------- Installation varies slightly based on the device that is being used: * Desktop: Use the install button typically found in right edge of the address bar * Android: Use the `Install as App` button in the more options menu for Chrome, and the `Add app to Home screen` button for Firefox * iOS: Use the `Add to Homescreen` button in the share menu Usage[​](https://docs.frigate.video/configuration/pwa/#usage "Direct link to Usage") ------------------------------------------------------------------------------------- Once setup, the Frigate app can be used wherever it has access to Frigate. This means it can be setup as local-only, VPN-only, or fully accessible depending on your needs. * [Requirements](https://docs.frigate.video/configuration/pwa/#requirements) * [Installation](https://docs.frigate.video/configuration/pwa/#installation) * [Usage](https://docs.frigate.video/configuration/pwa/#usage) --- # Notifications | Frigate [Skip to main content](https://docs.frigate.video/configuration/notifications/#__docusaurus_skipToContent_fallback) πŸš€ Get more relevant and accurate detections with Frigate+ models. [Learn more](https://frigate.video/plus/) ✨ On this page Frigate offers native notifications using the [WebPush Protocol](https://web.dev/articles/push-notifications-web-push-protocol) which uses the [VAPID spec](https://tools.ietf.org/html/draft-thomson-webpush-vapid) to deliver notifications to web apps using encryption. Setting up Notifications[​](https://docs.frigate.video/configuration/notifications/#setting-up-notifications "Direct link to Setting up Notifications") -------------------------------------------------------------------------------------------------------------------------------------------------------- In order to use notifications the following requirements must be met: * Frigate must be accessed via a secure `https` connection ([see the authorization docs](https://docs.frigate.video/configuration/authentication) ). * A supported browser must be used. Currently Chrome, Firefox, and Safari are known to be supported. * In order for notifications to be usable externally, Frigate must be accessible externally. * For iOS devices, some users have also indicated that the Notifications switch needs to be enabled in iOS Settings --> Apps --> Safari --> Advanced --> Features. ### Configuration[​](https://docs.frigate.video/configuration/notifications/#configuration "Direct link to Configuration") To configure notifications, go to the Frigate WebUI -> Settings -> Notifications and enable, then fill out the fields and save. Optionally, you can change the default cooldown period for notifications through the `cooldown` parameter in your config file. This parameter can also be overridden at the camera level. Notifications will be prevented if either: * The global cooldown period hasn't elapsed since any camera's last notification * The camera-specific cooldown period hasn't elapsed for the specific camera notifications: enabled: True email: "johndoe@gmail.com" cooldown: 10 # wait 10 seconds before sending another notification from any camera cameras: doorbell: ... notifications: enabled: True cooldown: 30 # wait 30 seconds before sending another notification from the doorbell camera ### Registration[​](https://docs.frigate.video/configuration/notifications/#registration "Direct link to Registration") Once notifications are enabled, press the `Register for Notifications` button on all devices that you would like to receive notifications on. This will register the background worker. After this Frigate must be restarted and then notifications will begin to be sent. Supported Notifications[​](https://docs.frigate.video/configuration/notifications/#supported-notifications "Direct link to Supported Notifications") ----------------------------------------------------------------------------------------------------------------------------------------------------- Currently notifications are only supported for review alerts. More notifications will be supported in the future. note Currently, only Chrome supports images in notifications. Safari and Firefox will only show a title and message in the notification. Reduce Notification Latency[​](https://docs.frigate.video/configuration/notifications/#reduce-notification-latency "Direct link to Reduce Notification Latency") ----------------------------------------------------------------------------------------------------------------------------------------------------------------- Different platforms handle notifications differently, some settings changes may be required to get optimal notification delivery. ### Android[​](https://docs.frigate.video/configuration/notifications/#android "Direct link to Android") Most Android phones have battery optimization settings. To get reliable Notification delivery the browser (Chrome, Firefox) should have battery optimizations disabled. If Frigate is running as a PWA then the Frigate app should have battery optimizations disabled as well. * [Setting up Notifications](https://docs.frigate.video/configuration/notifications/#setting-up-notifications) * [Configuration](https://docs.frigate.video/configuration/notifications/#configuration) * [Registration](https://docs.frigate.video/configuration/notifications/#registration) * [Supported Notifications](https://docs.frigate.video/configuration/notifications/#supported-notifications) * [Reduce Notification Latency](https://docs.frigate.video/configuration/notifications/#reduce-notification-latency) * [Android](https://docs.frigate.video/configuration/notifications/#android) --- # Metrics | Frigate [Skip to main content](https://docs.frigate.video/configuration/metrics/#__docusaurus_skipToContent_fallback) πŸš€ Get more relevant and accurate detections with Frigate+ models. [Learn more](https://frigate.video/plus/) ✨ On this page Frigate exposes Prometheus metrics at the `/api/metrics` endpoint that can be used to monitor the performance and health of your Frigate instance. Available Metrics[​](https://docs.frigate.video/configuration/metrics/#available-metrics "Direct link to Available Metrics") ----------------------------------------------------------------------------------------------------------------------------- ### System Metrics[​](https://docs.frigate.video/configuration/metrics/#system-metrics "Direct link to System Metrics") * `frigate_cpu_usage_percent{pid="", name="", process="", type="", cmdline=""}` - Process CPU usage percentage * `frigate_mem_usage_percent{pid="", name="", process="", type="", cmdline=""}` - Process memory usage percentage * `frigate_gpu_usage_percent{gpu_name=""}` - GPU utilization percentage * `frigate_gpu_mem_usage_percent{gpu_name=""}` - GPU memory usage percentage ### Camera Metrics[​](https://docs.frigate.video/configuration/metrics/#camera-metrics "Direct link to Camera Metrics") * `frigate_camera_fps{camera_name=""}` - Frames per second being consumed from your camera * `frigate_detection_fps{camera_name=""}` - Number of times detection is run per second * `frigate_process_fps{camera_name=""}` - Frames per second being processed * `frigate_skipped_fps{camera_name=""}` - Frames per second skipped for processing * `frigate_detection_enabled{camera_name=""}` - Detection enabled status for camera * `frigate_audio_dBFS{camera_name=""}` - Audio dBFS for camera * `frigate_audio_rms{camera_name=""}` - Audio RMS for camera ### Detector Metrics[​](https://docs.frigate.video/configuration/metrics/#detector-metrics "Direct link to Detector Metrics") * `frigate_detector_inference_speed_seconds{name=""}` - Time spent running object detection in seconds * `frigate_detection_start{name=""}` - Detector start time (unix timestamp) ### Storage Metrics[​](https://docs.frigate.video/configuration/metrics/#storage-metrics "Direct link to Storage Metrics") * `frigate_storage_free_bytes{storage=""}` - Storage free bytes * `frigate_storage_total_bytes{storage=""}` - Storage total bytes * `frigate_storage_used_bytes{storage=""}` - Storage used bytes * `frigate_storage_mount_type{mount_type="", storage=""}` - Storage mount type info ### Service Metrics[​](https://docs.frigate.video/configuration/metrics/#service-metrics "Direct link to Service Metrics") * `frigate_service_uptime_seconds` - Uptime in seconds * `frigate_service_last_updated_timestamp` - Stats recorded time (unix timestamp) * `frigate_device_temperature{device=""}` - Device Temperature ### Event Metrics[​](https://docs.frigate.video/configuration/metrics/#event-metrics "Direct link to Event Metrics") * `frigate_camera_events{camera="", label=""}` - Count of camera events since exporter started Configuring Prometheus[​](https://docs.frigate.video/configuration/metrics/#configuring-prometheus "Direct link to Configuring Prometheus") -------------------------------------------------------------------------------------------------------------------------------------------- To scrape metrics from Frigate, add the following to your Prometheus configuration: scrape_configs: - job_name: 'frigate' metrics_path: '/api/metrics' static_configs: - targets: ['frigate:5000'] scrape_interval: 15s Example Queries[​](https://docs.frigate.video/configuration/metrics/#example-queries "Direct link to Example Queries") ----------------------------------------------------------------------------------------------------------------------- Here are some example PromQL queries that might be useful: # Average CPU usage across all processesavg(frigate_cpu_usage_percent)# Total GPU memory usagesum(frigate_gpu_mem_usage_percent)# Detection FPS by camerarate(frigate_detection_fps{camera_name="front_door"}[5m])# Storage usage percentage(frigate_storage_used_bytes / frigate_storage_total_bytes) * 100# Event count by camera in last hourincrease(frigate_camera_events[1h]) Grafana Dashboard[​](https://docs.frigate.video/configuration/metrics/#grafana-dashboard "Direct link to Grafana Dashboard") ----------------------------------------------------------------------------------------------------------------------------- You can use these metrics to create Grafana dashboards to monitor your Frigate instance. Here's an example of metrics you might want to track: * CPU, Memory and GPU usage over time * Camera FPS and detection rates * Storage usage and trends * Event counts by camera * System temperatures A sample Grafana dashboard JSON will be provided in a future update. Metric Types[​](https://docs.frigate.video/configuration/metrics/#metric-types "Direct link to Metric Types") -------------------------------------------------------------------------------------------------------------- The metrics exposed by Frigate use the following Prometheus metric types: * **Counter**: Cumulative values that only increase (e.g., `frigate_camera_events`) * **Gauge**: Values that can go up and down (e.g., `frigate_cpu_usage_percent`) * **Info**: Key-value pairs for metadata (e.g., `frigate_storage_mount_type`) For more information about Prometheus metric types, see the [Prometheus documentation](https://prometheus.io/docs/concepts/metric_types/) . * [Available Metrics](https://docs.frigate.video/configuration/metrics/#available-metrics) * [System Metrics](https://docs.frigate.video/configuration/metrics/#system-metrics) * [Camera Metrics](https://docs.frigate.video/configuration/metrics/#camera-metrics) * [Detector Metrics](https://docs.frigate.video/configuration/metrics/#detector-metrics) * [Storage Metrics](https://docs.frigate.video/configuration/metrics/#storage-metrics) * [Service Metrics](https://docs.frigate.video/configuration/metrics/#service-metrics) * [Event Metrics](https://docs.frigate.video/configuration/metrics/#event-metrics) * [Configuring Prometheus](https://docs.frigate.video/configuration/metrics/#configuring-prometheus) * [Example Queries](https://docs.frigate.video/configuration/metrics/#example-queries) * [Grafana Dashboard](https://docs.frigate.video/configuration/metrics/#grafana-dashboard) * [Metric Types](https://docs.frigate.video/configuration/metrics/#metric-types) --- # Motion Detection | Frigate [Skip to main content](https://docs.frigate.video/configuration/motion_detection/#__docusaurus_skipToContent_fallback) πŸš€ Get more relevant and accurate detections with Frigate+ models. [Learn more](https://frigate.video/plus/) ✨ On this page Frigate uses motion detection as a first line check to see if there is anything happening in the frame worth checking with object detection. Once motion is detected, it tries to group up nearby areas of motion together in hopes of identifying a rectangle in the image that will capture the area worth inspecting. These are the red "motion boxes" you see in the debug viewer. The Goal[​](https://docs.frigate.video/configuration/motion_detection/#the-goal "Direct link to The Goal") ----------------------------------------------------------------------------------------------------------- The default motion settings should work well for the majority of cameras, however there are cases where tuning motion detection can lead to better and more optimal results. Each camera has its own environment with different variables that affect motion, this means that the same motion settings will not fit all of your cameras. Before tuning motion it is important to understand the goal. In an optimal configuration, motion from people and cars would be detected, but not grass moving, lighting changes, timestamps, etc. If your motion detection is too sensitive, you will experience higher CPU loads and greater false positives from the increased rate of object detection. If it is not sensitive enough, you will miss objects that you want to track. Create Motion Masks[​](https://docs.frigate.video/configuration/motion_detection/#create-motion-masks "Direct link to Create Motion Masks") -------------------------------------------------------------------------------------------------------------------------------------------- First, mask areas with regular motion not caused by the objects you want to detect. The best way to find candidates for motion masks is by watching the debug stream with motion boxes enabled. Good use cases for motion masks are timestamps or tree limbs and large bushes that regularly move due to wind. When possible, avoid creating motion masks that would block motion detection for objects you want to track **even if they are in locations where you don't want alerts or detections**. Motion masks should not be used to avoid detecting objects in specific areas. More details can be found [in the masks docs.](https://docs.frigate.video/configuration/masks) . Prepare For Testing[​](https://docs.frigate.video/configuration/motion_detection/#prepare-for-testing "Direct link to Prepare For Testing") -------------------------------------------------------------------------------------------------------------------------------------------- The easiest way to tune motion detection is to use the Frigate UI under Settings > Motion Tuner. This screen allows the changing of motion detection values live to easily see the immediate effect on what is detected as motion. Tuning Motion Detection During The Day[​](https://docs.frigate.video/configuration/motion_detection/#tuning-motion-detection-during-the-day "Direct link to Tuning Motion Detection During The Day") ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- Now that things are set up, find a time to tune that represents normal circumstances. For example, if you tune your motion on a day that is sunny and windy you may find later that the motion settings are not sensitive enough on a cloudy and still day. note Remember that motion detection is just used to determine when object detection should be used. You should aim to have motion detection sensitive enough that you won't miss objects you want to detect with object detection. The goal is to prevent object detection from running constantly for every small pixel change in the image. Windy days are still going to result in lots of motion being detected. ### Threshold[​](https://docs.frigate.video/configuration/motion_detection/#threshold "Direct link to Threshold") The threshold value dictates how much of a change in a pixels luminance is required to be considered motion. # default threshold valuemotion: # Optional: The threshold passed to cv2.threshold to determine if a pixel is different enough to be counted as motion. (default: shown below) # Increasing this value will make motion detection less sensitive and decreasing it will make motion detection more sensitive. # The value should be between 1 and 255. threshold: 30 Lower values mean motion detection is more sensitive to changes in color, making it more likely for example to detect motion when a brown dogs blends in with a brown fence or a person wearing a red shirt blends in with a red car. If the threshold is too low however, it may detect things like grass blowing in the wind, shadows, etc. to be detected as motion. Watching the motion boxes in the debug view, increase the threshold until you only see motion that is visible to the eye. Once this is done, it is important to test and ensure that desired motion is still detected. ### Contour Area[​](https://docs.frigate.video/configuration/motion_detection/#contour-area "Direct link to Contour Area") # default contour_area valuemotion: # Optional: Minimum size in pixels in the resized motion image that counts as motion (default: shown below) # Increasing this value will prevent smaller areas of motion from being detected. Decreasing will # make motion detection more sensitive to smaller moving objects. # As a rule of thumb: # - 10 - high sensitivity # - 30 - medium sensitivity # - 50 - low sensitivity contour_area: 10 Once the threshold calculation is run, the pixels that have changed are grouped together. The contour area value is used to decide which groups of changed pixels qualify as motion. Smaller values are more sensitive meaning people that are far away, small animals, etc. are more likely to be detected as motion, but it also means that small changes in shadows, leaves, etc. are detected as motion. Higher values are less sensitive meaning these things won't be detected as motion but with the risk that desired motion won't be detected until closer to the camera. Watching the motion boxes in the debug view, adjust the contour area until there are no motion boxes smaller than the smallest you'd expect frigate to detect something moving. ### Improve Contrast[​](https://docs.frigate.video/configuration/motion_detection/#improve-contrast "Direct link to Improve Contrast") At this point if motion is working as desired there is no reason to continue with tuning for the day. If you were unable to find a balance between desired and undesired motion being detected, you can try disabling improve contrast and going back to the threshold and contour area steps. Tuning Motion Detection During The Night[​](https://docs.frigate.video/configuration/motion_detection/#tuning-motion-detection-during-the-night "Direct link to Tuning Motion Detection During The Night") ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- Once daytime motion detection is tuned, there is a chance that the settings will work well for motion detection during the night as well. If this is the case then the preferred settings can be written to the config file and left alone. However, if the preferred day settings do not work well at night it is recommended to use Home Assistant or some other solution to automate changing the settings. That way completely separate sets of motion settings can be used for optimal day and night motion detection. Tuning For Large Changes In Motion[​](https://docs.frigate.video/configuration/motion_detection/#tuning-for-large-changes-in-motion "Direct link to Tuning For Large Changes In Motion") ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- # default lightning_threshold:motion: # Optional: The percentage of the image used to detect lightning or other substantial changes where motion detection # needs to recalibrate. (default: shown below) # Increasing this value will make motion detection more likely to consider lightning or ir mode changes as valid motion. # Decreasing this value will make motion detection more likely to ignore large amounts of motion such as a person approaching # a doorbell camera. lightning_threshold: 0.8 warning Some cameras like doorbell cameras may have missed detections when someone walks directly in front of the camera and the lightning\_threshold causes motion detection to be re-calibrated. In this case, it may be desirable to increase the `lightning_threshold` to ensure these objects are not missed. note Lightning threshold does not stop motion based recordings from being saved. Large changes in motion like PTZ moves and camera switches between Color and IR mode should result in a pause in object detection. This is done via the `lightning_threshold` configuration. It is defined as the percentage of the image used to detect lightning or other substantial changes where motion detection needs to recalibrate. Increasing this value will make motion detection more likely to consider lightning or IR mode changes as valid motion. Decreasing this value will make motion detection more likely to ignore large amounts of motion such as a person approaching a doorbell camera. * [The Goal](https://docs.frigate.video/configuration/motion_detection/#the-goal) * [Create Motion Masks](https://docs.frigate.video/configuration/motion_detection/#create-motion-masks) * [Prepare For Testing](https://docs.frigate.video/configuration/motion_detection/#prepare-for-testing) * [Tuning Motion Detection During The Day](https://docs.frigate.video/configuration/motion_detection/#tuning-motion-detection-during-the-day) * [Threshold](https://docs.frigate.video/configuration/motion_detection/#threshold) * [Contour Area](https://docs.frigate.video/configuration/motion_detection/#contour-area) * [Improve Contrast](https://docs.frigate.video/configuration/motion_detection/#improve-contrast) * [Tuning Motion Detection During The Night](https://docs.frigate.video/configuration/motion_detection/#tuning-motion-detection-during-the-night) * [Tuning For Large Changes In Motion](https://docs.frigate.video/configuration/motion_detection/#tuning-for-large-changes-in-motion) --- # Masks | Frigate [Skip to main content](https://docs.frigate.video/configuration/masks/#__docusaurus_skipToContent_fallback) πŸš€ Get more relevant and accurate detections with Frigate+ models. [Learn more](https://frigate.video/plus/) ✨ On this page Frigate has two kinds of masks: motion masks and object filter masks. Both are narrow tools for fine-tuning, **not for hiding an area from Frigate**. Masks should be used sparingly; in most cases where users reach for one, a [zone](https://docs.frigate.video/configuration/zones) with `required_zones` is the right tool instead. See [Which tool do I need?](https://docs.frigate.video/configuration/masks/#which-tool-do-i-need) and [Common mistakes](https://docs.frigate.video/configuration/masks/#common-mistakes) below if you're new to Frigate's mask behavior. Motion masks[​](https://docs.frigate.video/configuration/masks/#motion-masks "Direct link to Motion masks") ------------------------------------------------------------------------------------------------------------ Motion masks are used to prevent unwanted types of motion from triggering detection. Try watching the Debug feed (Settings --> Debug) with `Motion Boxes` enabled to see what may be regularly detected as motion. For example, you want to mask out your timestamp, the sky, rooftops, etc. Keep in mind that this mask only prevents motion from being detected and does not prevent objects from being detected if object detection was started due to motion in unmasked areas. Motion is also used during object tracking to refine the object detection area in the next frame. _Over-masking will make it more difficult for objects to be tracked._ See [further clarification](https://docs.frigate.video/configuration/masks/#further-clarification) below on why you may not want to use a motion mask. Object filter masks[​](https://docs.frigate.video/configuration/masks/#object-filter-masks "Direct link to Object filter masks") --------------------------------------------------------------------------------------------------------------------------------- Object filter masks are used to filter out false positives for a given object type based on location. These should be used to filter any areas where it is not possible for an object of that type to be. The bottom center of the detected object's bounding box is evaluated against the mask. If it is in a masked area, it is assumed to be a false positive. For example, you may want to mask out rooftops, walls, the sky, treetops for people. For cars, masking locations other than the street or your driveway will tell Frigate that anything in your yard is a false positive. Object filter masks can be used to filter out stubborn false positives in fixed locations. For example, the base of this tree may be frequently detected as a person. The following image shows an example of an object filter mask (shaded red area) over the location where the bottom center is typically located to filter out person detections in a precise location. ![object mask](https://docs.frigate.video/assets/images/bottom-center-mask-057616b2b7d545688f32b2eb9a857b7d.jpg) Which tool do I need?[​](https://docs.frigate.video/configuration/masks/#which-tool-do-i-need "Direct link to Which tool do I need?") -------------------------------------------------------------------------------------------------------------------------------------- | What you're trying to do | Recommended tool | How it works | | --- | --- | --- | | Don't get alerts or recordings for activity in an area (e.g., the sidewalk in front of your house) | A [zone](https://docs.frigate.video/configuration/zones)
combined with `review.alerts.required_zones` (and/or `review.detections.required_zones`) | Frigate keeps detecting and tracking activity in the area, but a review item is only created once the bottom-center of an object's bounding box enters a required zone. | | Stop a stubborn false positive at a specific fixed spot (e.g., a tree base that keeps being detected as a person) | An **object filter mask** for that object type | Any detection of that object type whose bounding-box bottom-center lands inside the mask is treated as a false positive and discarded. | | Ignore motion in an area that obviously isn't an object of interest (e.g., the camera timestamp, sky, flags, treetops swaying) | A **motion mask** | Motion inside the mask is ignored when deciding whether to run object detection. Objects can still be detected in a motion masked area if motion elsewhere in the frame triggers detection. | | Stop tracking an object type altogether on this camera (e.g., you never care about cats) | Remove the object from the camera's [`objects.track`](https://docs.frigate.video/configuration/objects)
list | Frigate skips this object type entirely on this camera, regardless of where it appears. | Using the mask creator[​](https://docs.frigate.video/configuration/masks/#using-the-mask-creator "Direct link to Using the mask creator") ------------------------------------------------------------------------------------------------------------------------------------------ To create a poly mask: 1. Visit the Web UI 2. Click/tap the gear icon and open "Settings" 3. Select "Mask / zone editor" 4. At the top right, select the camera you wish to create a mask or zone for 5. Click the plus icon under the type of mask or zone you would like to create 6. Click on the camera's latest image to create the points for a masked area. Click the first point again to close the polygon. 7. When you've finished creating your mask, press Save. Your config file will be updated with the relative coordinates of the mask/zone: motion: mask: "0.000,0.427,0.002,0.000,0.999,0.000,0.999,0.781,0.885,0.456,0.700,0.424,0.701,0.311,0.507,0.294,0.453,0.347,0.451,0.400" Multiple masks can be listed in your config. motion: mask: - 0.239,1.246,0.175,0.901,0.165,0.805,0.195,0.802 - 0.000,0.427,0.002,0.000,0.999,0.000,0.999,0.781,0.885,0.456 ### Further Clarification[​](https://docs.frigate.video/configuration/masks/#further-clarification "Direct link to Further Clarification") This is a response to a [question posed on reddit](https://www.reddit.com/r/homeautomation/comments/ppxdve/replacing_my_doorbell_with_a_security_camera_a_6/hd876w4?utm_source=share&utm_medium=web2x&context=3) : It is helpful to understand a bit about how Frigate uses motion detection and object detection together. First, Frigate uses motion detection as a first line check to see if there is anything happening in the frame worth checking with object detection. Once motion is detected, it tries to group up nearby areas of motion together in hopes of identifying a rectangle in the image that will capture the area worth inspecting. These are the red "motion boxes" you see in the debug viewer. After the area with motion is identified, Frigate creates a "region" (the green boxes in the debug viewer) to run object detection on. The models are trained on square images, so these regions are always squares. It adds a margin around the motion area in hopes of capturing a cropped view of the object moving that fills most of the image passed to object detection, but doesn't cut anything off. It also takes into consideration the location of the bounding box from the previous frame if it is tracking an object. After object detection runs, if there are detected objects that seem to be cut off, Frigate reframes the region and runs object detection again on the same frame to get a better look. All of this happens for each area of motion and tracked object. > Are you simply saying that INITIAL triggering of any kind of detection will only happen in un-masked areas, but that once this triggering happens, the masks become irrelevant and object detection takes precedence? Essentially, yes. I wouldn't describe it as object detection taking precedence though. The motion masks just prevent those areas from being counted as motion. Those masks do not modify the regions passed to object detection in any way, so you can absolutely detect objects in areas masked for motion. > If so, this is completely expected and intuitive behavior for me. Because obviously if a "foot" starts motion detection the camera should be able to check if it's an entire person before it fully crosses into the zone. The docs imply this is the behavior, so I also don't understand why this would be detrimental to object detection on the whole. When just a foot is triggering motion, Frigate will zoom in and look only at the foot. If that even qualifies as a person, it will determine the object is being cut off and look again and again until it zooms back out enough to find the whole person. It is also detrimental to how Frigate tracks a moving object. Motion nearby the bounding box from the previous frame is used to intelligently determine where the region should be in the next frame. With too much masking, tracking is hampered and if an object walks from an unmasked area into a fully masked area, they essentially disappear and will be picked up as a "new" object if they leave the masked area. This is important because Frigate uses the history of scores while tracking an object to determine if it is a false positive or not. It takes a minimum of 3 frames for Frigate to determine is the object type it thinks it is, and the median score must be greater than the threshold. If a person meets this threshold while on the sidewalk before they walk into your stoop, you will get an alert the instant they step a single foot into a zone. > I thought the main point of this feature was to cut down on CPU use when motion is happening in unnecessary areas. It is, but the definition of "unnecessary" varies. I want to ignore areas of motion that I know are definitely not being triggered by objects of interest. Timestamps, trees, sky, rooftops. I don't want to ignore motion from objects that I want to track and know where they go. > For me, giving my masks ANY padding results in a lot of people detection I'm not interested in. I live in the city and catch a lot of the sidewalk on my camera. People walk by my front door all the time and the margin between the sidewalk and actually walking onto my stoop is very thin, so I basically have everything but the exact contours of my stoop masked out. This results in very tidy detections but this info keeps throwing me off. Am I just overthinking it? This is what `required_zones` are for. You should define a zone (remember this is evaluated based on the bottom center of the bounding box) and make it required to save snapshots and clips (previously events in 0.9.0 to 0.13.0 and review items in 0.14.0 and later). You can also use this in your conditions for a notification. > Maybe my specific situation just warrants this. I've just been having a hard time understanding the relevance of this information - it seems to be that it's exactly what would be expected when "masking out" an area of ANY image. That may be the case for you. Frigate will definitely work harder tracking people on the sidewalk to make sure it doesn't miss anyone who steps foot on your stoop. The trade off with the way you have it now is slower recognition of objects and potential misses. That may be acceptable based on your needs. Also, if your resolution is low enough on the detect stream, your regions may already be so big that they grab the entire object anyway. Common mistakes[​](https://docs.frigate.video/configuration/masks/#common-mistakes "Direct link to Common mistakes") --------------------------------------------------------------------------------------------------------------------- **"I added a motion mask to ignore my driveway/sidewalk."** A motion mask doesn't hide an area from Frigate. Objects can still be detected and tracked inside a masked area. The mask only stops motion _in that area_ from triggering object detection. If you want activity on the sidewalk to never produce a review item, define a [zone](https://docs.frigate.video/configuration/zones) over the area you DO care about (your stoop, your driveway) and add it to `review.alerts.required_zones`. Frigate will still see people on the sidewalk, but it won't create an alert until they cross into the zone. **"I added an object filter mask because I don't care about cars in my yard."** Object filter masks are for stubborn false positives at fixed locations, not for filtering whole areas or whole object types. If you only want alerts when a car enters the driveway, use a [zone](https://docs.frigate.video/configuration/zones) with `required_zones`. If you don't care about a whole object type on this camera, remove it from [`objects.track`](https://docs.frigate.video/configuration/objects) . **"I masked everything except a thin strip on my stoop."** Heavy masking hurts tracking. Frigate uses motion near a tracked object's previous bounding box to decide where to look in the next frame; with most of the frame masked, an object walking from an unmasked area into a masked one effectively disappears and gets picked up as a "new" object when it reappears. For example: someone walks down your sidewalk, stops under a tree (masked area) to tie their shoe, then continues. Frigate sees that as two separate people and can create two separate review items. Because Frigate needs several consecutive frames above the confidence threshold to commit to a detection, each re-appearance can also delay or miss alerts. Use `required_zones` for "only alert me about this spot" and leave the surrounding area unmasked so tracking stays intact. * [Motion masks](https://docs.frigate.video/configuration/masks/#motion-masks) * [Object filter masks](https://docs.frigate.video/configuration/masks/#object-filter-masks) * [Which tool do I need?](https://docs.frigate.video/configuration/masks/#which-tool-do-i-need) * [Using the mask creator](https://docs.frigate.video/configuration/masks/#using-the-mask-creator) * [Further Clarification](https://docs.frigate.video/configuration/masks/#further-clarification) * [Common mistakes](https://docs.frigate.video/configuration/masks/#common-mistakes) --- # Filters | Frigate [Skip to main content](https://docs.frigate.video/configuration/object_filters/#__docusaurus_skipToContent_fallback) πŸš€ Get more relevant and accurate detections with Frigate+ models. [Learn more](https://frigate.video/plus/) ✨ On this page There are several types of object filters that can be used to reduce false positive rates. Object Scores[​](https://docs.frigate.video/configuration/object_filters/#object-scores "Direct link to Object Scores") ------------------------------------------------------------------------------------------------------------------------ For object filters in your configuration, any single detection below `min_score` will be ignored as a false positive. `threshold` is based on the median of the history of scores (padded to 3 values) for a tracked object. Consider the following frames when `min_score` is set to 0.6 and threshold is set to 0.85: | Frame | Current Score | Score History | Computed Score | Detected Object | | --- | --- | --- | --- | --- | | 1 | 0.7 | 0.0, 0, 0.7 | 0.0 | No | | 2 | 0.55 | 0.0, 0.7, 0.0 | 0.0 | No | | 3 | 0.85 | 0.7, 0.0, 0.85 | 0.7 | No | | 4 | 0.90 | 0.7, 0.85, 0.95, 0.90 | 0.875 | Yes | | 5 | 0.88 | 0.7, 0.85, 0.95, 0.90, 0.88 | 0.88 | Yes | | 6 | 0.95 | 0.7, 0.85, 0.95, 0.90, 0.88, 0.95 | 0.89 | Yes | In frame 2, the score is below the `min_score` value, so Frigate ignores it and it becomes a 0.0. The computed score is the median of the score history (padding to at least 3 values), and only when that computed score crosses the `threshold` is the object marked as a true positive. That happens in frame 4 in the example. ### Minimum Score[​](https://docs.frigate.video/configuration/object_filters/#minimum-score "Direct link to Minimum Score") Any detection below `min_score` will be immediately thrown out and never tracked because it is considered a false positive. If `min_score` is too low then false positives may be detected and tracked which can confuse the object tracker and may lead to wasted resources. If `min_score` is too high then lower scoring true positives like objects that are further away or partially occluded may be thrown out which can also confuse the tracker and cause valid tracked objects to be lost or disjointed. ### Threshold[​](https://docs.frigate.video/configuration/object_filters/#threshold "Direct link to Threshold") `threshold` is used to determine that the object is a true positive. Once an object is detected with a score >= `threshold` object is considered a true positive. If `threshold` is too low then some higher scoring false positives may create an tracked object. If `threshold` is too high then true positive tracked objects may be missed due to the object never scoring high enough. Object Shape[​](https://docs.frigate.video/configuration/object_filters/#object-shape "Direct link to Object Shape") --------------------------------------------------------------------------------------------------------------------- False positives can also be reduced by filtering a detection based on its shape. ### Object Area[​](https://docs.frigate.video/configuration/object_filters/#object-area "Direct link to Object Area") `min_area` and `max_area` filter on the area of an objects bounding box and can be used to reduce false positives that are outside the range of expected sizes. For example when a leaf is detected as a dog or when a large tree is detected as a person, these can be reduced by adding a `min_area` / `max_area` filter. These values can either be in pixels or as a percentage of the frame (for example, 0.12 represents 12% of the frame). ### Object Proportions[​](https://docs.frigate.video/configuration/object_filters/#object-proportions "Direct link to Object Proportions") `min_ratio` and `max_ratio` values are compared against a given detected object's width/height ratio (in pixels). If the ratio is outside this range, the object will be ignored as a false positive. This allows objects that are proportionally too short-and-wide (higher ratio) or too tall-and-narrow (smaller ratio) to be ignored. info Conceptually, a ratio of 1 is a square, 0.5 is a "tall skinny" box, and 2 is a "wide flat" box. If `min_ratio` is 1.0, any object that is taller than it is wide will be ignored. Similarly, if `max_ratio` is 1.0, then any object that is wider than it is tall will be ignored. Other Tools[​](https://docs.frigate.video/configuration/object_filters/#other-tools "Direct link to Other Tools") ------------------------------------------------------------------------------------------------------------------ ### Zones[​](https://docs.frigate.video/configuration/object_filters/#zones "Direct link to Zones") [Required zones](https://docs.frigate.video/configuration/zones) can be a great tool to reduce false positives that may be detected in the sky or other areas that are not of interest. The required zones will only create tracked objects for objects that enter the zone. ### Object Masks[​](https://docs.frigate.video/configuration/object_filters/#object-masks "Direct link to Object Masks") [Object Filter Masks](https://docs.frigate.video/configuration/masks) are a last resort but can be useful when false positives are in the relatively same place but can not be filtered due to their size or shape. * [Object Scores](https://docs.frigate.video/configuration/object_filters/#object-scores) * [Minimum Score](https://docs.frigate.video/configuration/object_filters/#minimum-score) * [Threshold](https://docs.frigate.video/configuration/object_filters/#threshold) * [Object Shape](https://docs.frigate.video/configuration/object_filters/#object-shape) * [Object Area](https://docs.frigate.video/configuration/object_filters/#object-area) * [Object Proportions](https://docs.frigate.video/configuration/object_filters/#object-proportions) * [Other Tools](https://docs.frigate.video/configuration/object_filters/#other-tools) * [Zones](https://docs.frigate.video/configuration/object_filters/#zones) * [Object Masks](https://docs.frigate.video/configuration/object_filters/#object-masks) --- # Available Objects | Frigate [Skip to main content](https://docs.frigate.video/configuration/objects/#__docusaurus_skipToContent_fallback) πŸš€ Get more relevant and accurate detections with Frigate+ models. [Learn more](https://frigate.video/plus/) ✨ On this page Frigate includes the object labels listed below from the Google Coral test data. Please note: * `car` is listed twice because `truck` has been renamed to `car` by default. These object types are frequently confused. * `person` is the only tracked object by default. See the [full configuration reference](https://docs.frigate.video/configuration/reference) for an example of expanding the list of tracked objects. * person * bicycle * car * motorcycle * airplane * bus * train * car * boat * traffic light * fire hydrant * street sign * stop sign * parking meter * bench * bird * cat * dog * horse * sheep * cow * elephant * bear * zebra * giraffe * hat * backpack * umbrella * shoe * eye glasses * handbag * tie * suitcase * frisbee * skis * snowboard * sports ball * kite * baseball bat * baseball glove * skateboard * surfboard * tennis racket * bottle * plate * wine glass * cup * fork * knife * spoon * bowl * banana * apple * sandwich * orange * broccoli * carrot * hot dog * pizza * donut * cake * chair * couch * potted plant * bed * mirror * dining table * window * desk * toilet * door * tv * laptop * mouse * remote * keyboard * cell phone * microwave * oven * toaster * sink * refrigerator * blender * book * clock * vase * scissors * teddy bear * hair drier * toothbrush * hair brush Custom Models[​](https://docs.frigate.video/configuration/objects/#custom-models "Direct link to Custom Models") ----------------------------------------------------------------------------------------------------------------- Models for both CPU and EdgeTPU (Coral) are bundled in the image. You can use your own models with volume mounts: * CPU Model: `/cpu_model.tflite` * EdgeTPU Model: `/edgetpu_model.tflite` * Labels: `/labelmap.txt` You also need to update the [model config](https://docs.frigate.video/configuration/advanced#model) if they differ from the defaults. * [Custom Models](https://docs.frigate.video/configuration/objects/#custom-models) --- # Video Decoding | Frigate [Skip to main content](https://docs.frigate.video/configuration/hardware_acceleration_video/#__docusaurus_skipToContent_fallback) πŸš€ Get more relevant and accurate detections with Frigate+ models. [Learn more](https://frigate.video/plus/) ✨ On this page It is highly recommended to use an integrated or discrete GPU for hardware acceleration video decoding in Frigate. Some types of hardware acceleration are detected and used automatically, but you may need to update your configuration to enable hardware accelerated decoding in ffmpeg. To verify that hardware acceleration is working: * Check the logs: A message will either say that hardware acceleration was automatically detected, or there will be a warning that no hardware acceleration was automatically detected * If hardware acceleration is specified in the config, verification can be done by ensuring the logs are free from errors. There is no CPU fallback for hardware acceleration. info Frigate supports presets for optimal hardware accelerated video decoding: **AMD** * [AMD](https://docs.frigate.video/configuration/hardware_acceleration_video/#amd-based-cpus) : Frigate can utilize modern AMD integrated GPUs and AMD discrete GPUs to accelerate video decoding. **Intel** * [Intel](https://docs.frigate.video/configuration/hardware_acceleration_video/#intel-based-cpus) : Frigate can utilize most Intel integrated GPUs and Arc GPUs to accelerate video decoding. **Nvidia GPU** * [Nvidia GPU](https://docs.frigate.video/configuration/hardware_acceleration_video/#nvidia-gpus) : Frigate can utilize most modern Nvidia GPUs to accelerate video decoding. **Raspberry Pi 3/4** * [Raspberry Pi](https://docs.frigate.video/configuration/hardware_acceleration_video/#raspberry-pi-34) : Frigate can utilize the media engine in the Raspberry Pi 3 and 4 to slightly accelerate video decoding. **Nvidia Jetson** Community Supported * [Jetson](https://docs.frigate.video/configuration/hardware_acceleration_video/#nvidia-jetson) : Frigate can utilize the media engine in Jetson hardware to accelerate video decoding. **Rockchip** Community Supported * [RKNN](https://docs.frigate.video/configuration/hardware_acceleration_video/#rockchip-platform) : Frigate can utilize the media engine in RockChip SOCs to accelerate video decoding. **Other Hardware** Depending on your system, these presets may not be compatible, and you may need to use manual hwaccel args to take advantage of your hardware. More information on hardware accelerated decoding for ffmpeg can be found here: [https://trac.ffmpeg.org/wiki/HWAccelIntro](https://trac.ffmpeg.org/wiki/HWAccelIntro) Intel-based CPUs[​](https://docs.frigate.video/configuration/hardware_acceleration_video/#intel-based-cpus "Direct link to Intel-based CPUs") ---------------------------------------------------------------------------------------------------------------------------------------------- Frigate can utilize most Intel integrated GPUs and Arc GPUs to accelerate video decoding. info **Recommended hwaccel Preset** | CPU Generation | Intel Driver | Recommended Preset | Notes | | --- | --- | --- | --- | | gen1 - gen5 | i965 | preset-vaapi | qsv is not supported, may not support H.265 | | gen6 - gen7 | iHD | preset-vaapi | qsv is not supported | | gen8 - gen12 | iHD | preset-vaapi | preset-intel-qsv-\* can also be used | | gen13+ | iHD / Xe | preset-intel-qsv-\* | | | Intel Arc GPU | iHD / Xe | preset-intel-qsv-\* | | note The default driver is `iHD`. You may need to change the driver to `i965` by adding the following environment variable `LIBVA_DRIVER_NAME=i965` to your docker-compose file or [in the `config.yml` for HA App users](https://docs.frigate.video/configuration/advanced#environment_vars) . See [The Intel Docs](https://www.intel.com/content/www/us/en/support/articles/000005505/processors.html) to figure out what generation your CPU is. ### Via VAAPI[​](https://docs.frigate.video/configuration/hardware_acceleration_video/#via-vaapi "Direct link to Via VAAPI") VAAPI supports automatic profile selection so it will work automatically with both H.264 and H.265 streams. ffmpeg: hwaccel_args: preset-vaapi ### Via Quicksync[​](https://docs.frigate.video/configuration/hardware_acceleration_video/#via-quicksync "Direct link to Via Quicksync") #### H.264 streams[​](https://docs.frigate.video/configuration/hardware_acceleration_video/#h264-streams "Direct link to H.264 streams") ffmpeg: hwaccel_args: preset-intel-qsv-h264 #### H.265 streams[​](https://docs.frigate.video/configuration/hardware_acceleration_video/#h265-streams "Direct link to H.265 streams") ffmpeg: hwaccel_args: preset-intel-qsv-h265 ### Configuring Intel GPU Stats in Docker[​](https://docs.frigate.video/configuration/hardware_acceleration_video/#configuring-intel-gpu-stats-in-docker "Direct link to Configuring Intel GPU Stats in Docker") Additional configuration is needed for the Docker container to be able to access the `intel_gpu_top` command for GPU stats. There are two options: 1. Run the container as privileged. 2. Add the `CAP_PERFMON` capability (note: you might need to set the `perf_event_paranoid` low enough to allow access to the performance event system.) #### Run as privileged[​](https://docs.frigate.video/configuration/hardware_acceleration_video/#run-as-privileged "Direct link to Run as privileged") This method works, but it gives more permissions to the container than are actually needed. ##### Docker Compose - Privileged[​](https://docs.frigate.video/configuration/hardware_acceleration_video/#docker-compose---privileged "Direct link to Docker Compose - Privileged") services: frigate: ... image: ghcr.io/blakeblackshear/frigate:stable privileged: true ##### Docker Run CLI - Privileged[​](https://docs.frigate.video/configuration/hardware_acceleration_video/#docker-run-cli---privileged "Direct link to Docker Run CLI - Privileged") docker run -d \ --name frigate \ ... --privileged \ ghcr.io/blakeblackshear/frigate:stable #### CAP\_PERFMON[​](https://docs.frigate.video/configuration/hardware_acceleration_video/#cap_perfmon "Direct link to CAP_PERFMON") Only recent versions of Docker support the `CAP_PERFMON` capability. You can test to see if yours supports it by running: `docker run --cap-add=CAP_PERFMON hello-world` ##### Docker Compose - CAP\_PERFMON[​](https://docs.frigate.video/configuration/hardware_acceleration_video/#docker-compose---cap_perfmon "Direct link to Docker Compose - CAP_PERFMON") services: frigate: ... image: ghcr.io/blakeblackshear/frigate:stable cap_add: - CAP_PERFMON ##### Docker Run CLI - CAP\_PERFMON[​](https://docs.frigate.video/configuration/hardware_acceleration_video/#docker-run-cli---cap_perfmon "Direct link to Docker Run CLI - CAP_PERFMON") docker run -d \ --name frigate \ ... --cap-add=CAP_PERFMON \ ghcr.io/blakeblackshear/frigate:stable #### perf\_event\_paranoid[​](https://docs.frigate.video/configuration/hardware_acceleration_video/#perf_event_paranoid "Direct link to perf_event_paranoid") _Note: This setting must be changed for the entire system._ For more information on the various values across different distributions, see [https://askubuntu.com/questions/1400874/what-does-perf-paranoia-level-four-do](https://askubuntu.com/questions/1400874/what-does-perf-paranoia-level-four-do) . Depending on your OS and kernel configuration, you may need to change the `/proc/sys/kernel/perf_event_paranoid` kernel tunable. You can test the change by running `sudo sh -c 'echo 2 >/proc/sys/kernel/perf_event_paranoid'` which will persist until a reboot. Make it permanent by running `sudo sh -c 'echo kernel.perf_event_paranoid=2 >> /etc/sysctl.d/local.conf'` #### Stats for SR-IOV or other devices[​](https://docs.frigate.video/configuration/hardware_acceleration_video/#stats-for-sr-iov-or-other-devices "Direct link to Stats for SR-IOV or other devices") When using virtualized GPUs via SR-IOV, you need to specify the device path to use to gather stats from `intel_gpu_top`. This example may work for some systems using SR-IOV: telemetry: stats: intel_gpu_device: "sriov" For other virtualized GPUs, try specifying the direct path to the device instead: telemetry: stats: intel_gpu_device: "drm:/dev/dri/card0" If you are passing in a device path, make sure you've passed the device through to the container. AMD-based CPUs[​](https://docs.frigate.video/configuration/hardware_acceleration_video/#amd-based-cpus "Direct link to AMD-based CPUs") ---------------------------------------------------------------------------------------------------------------------------------------- Frigate can utilize modern AMD integrated GPUs and AMD GPUs to accelerate video decoding using VAAPI. ### Configuring Radeon Driver[​](https://docs.frigate.video/configuration/hardware_acceleration_video/#configuring-radeon-driver "Direct link to Configuring Radeon Driver") You need to change the driver to `radeonsi` by adding the following environment variable `LIBVA_DRIVER_NAME=radeonsi` to your docker-compose file or [in the `config.yml` for HA App users](https://docs.frigate.video/configuration/advanced#environment_vars) . ### Via VAAPI[​](https://docs.frigate.video/configuration/hardware_acceleration_video/#via-vaapi-1 "Direct link to Via VAAPI") VAAPI supports automatic profile selection so it will work automatically with both H.264 and H.265 streams. ffmpeg: hwaccel_args: preset-vaapi NVIDIA GPUs[​](https://docs.frigate.video/configuration/hardware_acceleration_video/#nvidia-gpus "Direct link to NVIDIA GPUs") ------------------------------------------------------------------------------------------------------------------------------- While older GPUs may work, it is recommended to use modern, supported GPUs. NVIDIA provides a [matrix of supported GPUs and features](https://developer.nvidia.com/video-encode-and-decode-gpu-support-matrix-new) . If your card is on the list and supports CUVID/NVDEC, it will most likely work with Frigate for decoding. However, you must also use [a driver version that will work with FFmpeg](https://github.com/FFmpeg/nv-codec-headers/blob/master/README) . Older driver versions may be missing symbols and fail to work, and older cards are not supported by newer driver versions. The only way around this is to [provide your own FFmpeg](https://docs.frigate.video/configuration/advanced#custom-ffmpeg-build) that will work with your driver version, but this is unsupported and may not work well if at all. A more complete list of cards and their compatible drivers is available in the [driver release readme](https://download.nvidia.com/XFree86/Linux-x86_64/525.85.05/README/supportedchips.html) . If your distribution does not offer NVIDIA driver packages, you can [download them here](https://www.nvidia.com/en-us/drivers/unix/) . ### Configuring Nvidia GPUs in Docker[​](https://docs.frigate.video/configuration/hardware_acceleration_video/#configuring-nvidia-gpus-in-docker "Direct link to Configuring Nvidia GPUs in Docker") Additional configuration is needed for the Docker container to be able to access the NVIDIA GPU. The supported method for this is to install the [NVIDIA Container Toolkit](https://docs.nvidia.com/datacenter/cloud-native/container-toolkit/install-guide.html#docker) and specify the GPU to Docker. How you do this depends on how Docker is being run: #### Docker Compose - Nvidia GPU[​](https://docs.frigate.video/configuration/hardware_acceleration_video/#docker-compose---nvidia-gpu "Direct link to Docker Compose - Nvidia GPU") services: frigate: ... image: ghcr.io/blakeblackshear/frigate:stable-tensorrt deploy: # <------------- Add this section resources: reservations: devices: - driver: nvidia device_ids: ['0'] # this is only needed when using multiple GPUs count: 1 # number of GPUs capabilities: [gpu] #### Docker Run CLI - Nvidia GPU[​](https://docs.frigate.video/configuration/hardware_acceleration_video/#docker-run-cli---nvidia-gpu "Direct link to Docker Run CLI - Nvidia GPU") docker run -d \ --name frigate \ ... --gpus=all \ ghcr.io/blakeblackshear/frigate:stable-tensorrt ### Setup Decoder[​](https://docs.frigate.video/configuration/hardware_acceleration_video/#setup-decoder "Direct link to Setup Decoder") Using `preset-nvidia` ffmpeg will automatically select the necessary profile for the incoming video, and will log an error if the profile is not supported by your GPU. ffmpeg: hwaccel_args: preset-nvidia If everything is working correctly, you should see a significant improvement in performance. Verify that hardware decoding is working by running `nvidia-smi`, which should show `ffmpeg` processes: note `nvidia-smi` will not show `ffmpeg` processes when run inside the container [due to docker limitations](https://github.com/NVIDIA/nvidia-docker/issues/179#issuecomment-645579458) . +-----------------------------------------------------------------------------+| NVIDIA-SMI 455.38 Driver Version: 455.38 CUDA Version: 11.1 ||-------------------------------+----------------------+----------------------+| GPU Name Persistence-M| Bus-Id Disp.A | Volatile Uncorr. ECC || Fan Temp Perf Pwr:Usage/Cap| Memory-Usage | GPU-Util Compute M. || | | MIG M. ||===============================+======================+======================|| 0 GeForce GTX 166... Off | 00000000:03:00.0 Off | N/A || 38% 41C P2 36W / 125W | 2082MiB / 5942MiB | 5% Default || | | N/A |+-------------------------------+----------------------+----------------------++-----------------------------------------------------------------------------+| Processes: || GPU GI CI PID Type Process name GPU Memory || ID ID Usage ||=============================================================================|| 0 N/A N/A 12737 C ffmpeg 249MiB || 0 N/A N/A 12751 C ffmpeg 249MiB || 0 N/A N/A 12772 C ffmpeg 249MiB || 0 N/A N/A 12775 C ffmpeg 249MiB || 0 N/A N/A 12800 C ffmpeg 249MiB || 0 N/A N/A 12811 C ffmpeg 417MiB || 0 N/A N/A 12827 C ffmpeg 417MiB |+-----------------------------------------------------------------------------+ If you do not see these processes, check the `docker logs` for the container and look for decoding errors. These instructions were originally based on the [Jellyfin documentation](https://jellyfin.org/docs/general/administration/hardware-acceleration.html#nvidia-hardware-acceleration-on-docker-linux) . Raspberry Pi 3/4[​](https://docs.frigate.video/configuration/hardware_acceleration_video/#raspberry-pi-34 "Direct link to Raspberry Pi 3/4") --------------------------------------------------------------------------------------------------------------------------------------------- Ensure you increase the allocated RAM for your GPU to at least 128 (`raspi-config` > Performance Options > GPU Memory). If you are using the HA App, you may need to use the full access variant and turn off _Protection mode_ for hardware acceleration. # if you want to decode a h264 streamffmpeg: hwaccel_args: preset-rpi-64-h264# if you want to decode a h265 (hevc) streamffmpeg: hwaccel_args: preset-rpi-64-h265 note If running Frigate through Docker, you either need to run in privileged mode or map the `/dev/video*` devices to Frigate. With Docker Compose add: services: frigate: ... devices: - /dev/video11:/dev/video11 Or with `docker run`: docker run -d \ --name frigate \ ... --device /dev/video11 \ ghcr.io/blakeblackshear/frigate:stable `/dev/video11` is the correct device (on Raspberry Pi 4B). You can check by running the following and looking for `H264`: for d in /dev/video*; do echo -e "---\n$d" v4l2-ctl --list-formats-ext -d $ddone Or map in all the `/dev/video*` devices. Community Supported =================== NVIDIA Jetson[​](https://docs.frigate.video/configuration/hardware_acceleration_video/#nvidia-jetson "Direct link to NVIDIA Jetson") ------------------------------------------------------------------------------------------------------------------------------------- A separate set of docker images is available for Jetson devices. They come with an `ffmpeg` build with codecs that use the Jetson's dedicated media engine. If your Jetson host is running Jetpack 6.0+ use the `stable-tensorrt-jp6` tagged image. Note that the Orin Nano has no video encoder, so frigate will use software encoding on this platform, but the image will still allow hardware decoding and tensorrt object detection. You will need to use the image with the nvidia container runtime: ### Docker Run CLI - Jetson[​](https://docs.frigate.video/configuration/hardware_acceleration_video/#docker-run-cli---jetson "Direct link to Docker Run CLI - Jetson") docker run -d \ ... --runtime nvidia ghcr.io/blakeblackshear/frigate:stable-tensorrt-jp6 ### Docker Compose - Jetson[​](https://docs.frigate.video/configuration/hardware_acceleration_video/#docker-compose---jetson "Direct link to Docker Compose - Jetson") services: frigate: ... image: ghcr.io/blakeblackshear/frigate:stable-tensorrt-jp6 runtime: nvidia # Add this note The `runtime:` tag is not supported on older versions of docker-compose. If you run into this, you can instead use the nvidia runtime system-wide by adding `"default-runtime": "nvidia"` to `/etc/docker/daemon.json`: { "runtimes": { "nvidia": { "path": "nvidia-container-runtime", "runtimeArgs": [] } }, "default-runtime": "nvidia"} ### Setup Decoder[​](https://docs.frigate.video/configuration/hardware_acceleration_video/#setup-decoder-1 "Direct link to Setup Decoder") The decoder you need to pass in the `hwaccel_args` will depend on the input video. A list of supported codecs (you can use `ffmpeg -decoders | grep nvmpi` in the container to get the ones your card supports) V..... h264_nvmpi h264 (nvmpi) (codec h264) V..... hevc_nvmpi hevc (nvmpi) (codec hevc) V..... mpeg2_nvmpi mpeg2 (nvmpi) (codec mpeg2video) V..... mpeg4_nvmpi mpeg4 (nvmpi) (codec mpeg4) V..... vp8_nvmpi vp8 (nvmpi) (codec vp8) V..... vp9_nvmpi vp9 (nvmpi) (codec vp9) For example, for H264 video, you'll select `preset-jetson-h264`. ffmpeg: hwaccel_args: preset-jetson-h264 If everything is working correctly, you should see a significant reduction in ffmpeg CPU load and power consumption. Verify that hardware decoding is working by running `jtop` (`sudo pip3 install -U jetson-stats`), which should show that NVDEC/NVDEC1 are in use. Rockchip platform[​](https://docs.frigate.video/configuration/hardware_acceleration_video/#rockchip-platform "Direct link to Rockchip platform") ------------------------------------------------------------------------------------------------------------------------------------------------- Hardware accelerated video de-/encoding is supported on all Rockchip SoCs using [Nyanmisaka's FFmpeg 6.1 Fork](https://github.com/nyanmisaka/ffmpeg-rockchip) based on [Rockchip's mpp library](https://github.com/rockchip-linux/mpp) . ### Prerequisites[​](https://docs.frigate.video/configuration/hardware_acceleration_video/#prerequisites "Direct link to Prerequisites") Make sure to follow the [Rockchip specific installation instructions](https://docs.frigate.video/frigate/installation#rockchip-platform) . ### Configuration[​](https://docs.frigate.video/configuration/hardware_acceleration_video/#configuration "Direct link to Configuration") Add one of the following FFmpeg presets to your `config.yml` to enable hardware video processing: ffmpeg: hwaccel_args: preset-rkmpp note Make sure that your SoC supports hardware acceleration for your input stream. For example, if your camera streams with h265 encoding and a 4k resolution, your SoC must be able to de- and encode h265 with a 4k resolution or higher. If you are unsure whether your SoC meets the requirements, take a look at the datasheet. warning If one or more of your cameras are not properly processed and this error is shown in the logs: [segment @ 0xaaaaff694790] Timestamps are unset in a packet for stream 0. This is deprecated and will stop working in the future. Fix your code to set the timestamps properly[Parsed_scale_rkrga_0 @ 0xaaaaff819070] No hw context provided on input[Parsed_scale_rkrga_0 @ 0xaaaaff819070] Failed to configure output pad on Parsed_scale_rkrga_0Error initializing filters!Error marking filters as finished[out#1/rawvideo @ 0xaaaaff3d8730] Nothing was written into output file, because at least one of its streams received no packets.Restarting ffmpeg... you should try to uprade to FFmpeg 7. This can be done using this config option: ffmpeg: path: "7.0" You can set this option globally to use FFmpeg 7 for all cameras or on camera level to use it only for specific cameras. Do not confuse this option with: cameras: name: ffmpeg: inputs: - path: rtsp://viewer:{FRIGATE_RTSP_PASSWORD}@10.0.10.10:554/cam/realmonitor?channel=1&subtype=2 Synaptics[​](https://docs.frigate.video/configuration/hardware_acceleration_video/#synaptics "Direct link to Synaptics") ------------------------------------------------------------------------------------------------------------------------- Hardware accelerated video de-/encoding is supported on Synpatics SL-series SoC. ### Prerequisites[​](https://docs.frigate.video/configuration/hardware_acceleration_video/#prerequisites-1 "Direct link to Prerequisites") Make sure to follow the [Synaptics specific installation instructions](https://docs.frigate.video/frigate/installation#synaptics) . ### Configuration[​](https://docs.frigate.video/configuration/hardware_acceleration_video/#configuration-1 "Direct link to Configuration") Add one of the following FFmpeg presets to your `config.yml` to enable hardware video processing: ffmpeg: hwaccel_args: -c:v h264_v4l2m2m input_args: preset-rtsp-restreamoutput_args: record: preset-record-generic-audio-aac warning Make sure that your SoC supports hardware acceleration for your input stream and your input stream is h264 encoding. For example, if your camera streams with h264 encoding, your SoC must be able to de- and encode with it. If you are unsure whether your SoC meets the requirements, take a look at the datasheet. * [Intel-based CPUs](https://docs.frigate.video/configuration/hardware_acceleration_video/#intel-based-cpus) * [Via VAAPI](https://docs.frigate.video/configuration/hardware_acceleration_video/#via-vaapi) * [Via Quicksync](https://docs.frigate.video/configuration/hardware_acceleration_video/#via-quicksync) * [Configuring Intel GPU Stats in Docker](https://docs.frigate.video/configuration/hardware_acceleration_video/#configuring-intel-gpu-stats-in-docker) * [AMD-based CPUs](https://docs.frigate.video/configuration/hardware_acceleration_video/#amd-based-cpus) * [Configuring Radeon Driver](https://docs.frigate.video/configuration/hardware_acceleration_video/#configuring-radeon-driver) * [Via VAAPI](https://docs.frigate.video/configuration/hardware_acceleration_video/#via-vaapi-1) * [NVIDIA GPUs](https://docs.frigate.video/configuration/hardware_acceleration_video/#nvidia-gpus) * [Configuring Nvidia GPUs in Docker](https://docs.frigate.video/configuration/hardware_acceleration_video/#configuring-nvidia-gpus-in-docker) * [Setup Decoder](https://docs.frigate.video/configuration/hardware_acceleration_video/#setup-decoder) * [Raspberry Pi 3/4](https://docs.frigate.video/configuration/hardware_acceleration_video/#raspberry-pi-34) * [NVIDIA Jetson](https://docs.frigate.video/configuration/hardware_acceleration_video/#nvidia-jetson) * [Docker Run CLI - Jetson](https://docs.frigate.video/configuration/hardware_acceleration_video/#docker-run-cli---jetson) * [Docker Compose - Jetson](https://docs.frigate.video/configuration/hardware_acceleration_video/#docker-compose---jetson) * [Setup Decoder](https://docs.frigate.video/configuration/hardware_acceleration_video/#setup-decoder-1) * [Rockchip platform](https://docs.frigate.video/configuration/hardware_acceleration_video/#rockchip-platform) * [Prerequisites](https://docs.frigate.video/configuration/hardware_acceleration_video/#prerequisites) * [Configuration](https://docs.frigate.video/configuration/hardware_acceleration_video/#configuration) * [Synaptics](https://docs.frigate.video/configuration/hardware_acceleration_video/#synaptics) * [Prerequisites](https://docs.frigate.video/configuration/hardware_acceleration_video/#prerequisites-1) * [Configuration](https://docs.frigate.video/configuration/hardware_acceleration_video/#configuration-1) --- # Live View | Frigate [Skip to main content](https://docs.frigate.video/configuration/live/#__docusaurus_skipToContent_fallback) πŸš€ Get more relevant and accurate detections with Frigate+ models. [Learn more](https://frigate.video/plus/) ✨ On this page Frigate intelligently displays your camera streams on the Live view dashboard. By default, Frigate employs "smart streaming" where camera images update once per minute when no detectable activity is occurring to conserve bandwidth and resources. As soon as any motion or active objects are detected, cameras seamlessly switch to a live stream. ### Live View technologies[​](https://docs.frigate.video/configuration/live/#live-view-technologies "Direct link to Live View technologies") Frigate intelligently uses three different streaming technologies to display your camera streams on the dashboard and the single camera view, switching between available modes based on network bandwidth, player errors, or required features like two-way talk. The highest quality and fluency of the Live view requires the bundled `go2rtc` to be configured as shown in the [step by step guide](https://docs.frigate.video/guides/configuring_go2rtc) . The jsmpeg live view will use more browser and client GPU resources. Using go2rtc is highly recommended and will provide a superior experience. | Source | Frame Rate | Resolution | Audio | Requires go2rtc | Notes | | --- | --- | --- | --- | --- | --- | | jsmpeg | same as `detect -> fps`, capped at 10 | 720p | no | no | Resolution is configurable, but go2rtc is recommended if you want higher resolutions and better frame rates. jsmpeg is Frigate's default without go2rtc configured. | | mse | native | native | yes (depends on audio codec) | yes | iPhone requires iOS 17.1+, Firefox is h.264 only. This is Frigate's default when go2rtc is configured. | | webrtc | native | native | yes (depends on audio codec) | yes | Requires extra configuration. Frigate attempts to use WebRTC when MSE fails or when using a camera's two-way talk feature. | ### Camera Settings Recommendations[​](https://docs.frigate.video/configuration/live/#camera-settings-recommendations "Direct link to Camera Settings Recommendations") If you are using go2rtc, you should adjust the following settings in your camera's firmware for the best experience with Live view: * Video codec: **H.264** - provides the most compatible video codec with all Live view technologies and browsers. Avoid any kind of "smart codec" or "+" codec like _H.264+_ or _H.265+_. as these non-standard codecs remove keyframes (see below). * Audio codec: **AAC** - provides the most compatible audio codec with all Live view technologies and browsers that support audio. * I-frame interval (sometimes called the keyframe interval, the interframe space, or the GOP length): match your camera's frame rate, or choose "1x" (for interframe space on Reolink cameras). For example, if your stream outputs 20fps, your i-frame interval should be 20 (or 1x on Reolink). Values higher than the frame rate will cause the stream to take longer to begin playback. See [this page](https://gardinal.net/understanding-the-keyframe-interval/) for more on keyframes. For many users this may not be an issue, but it should be noted that a 1x i-frame interval will cause more storage utilization if you are using the stream for the `record` role as well. The default video and audio codec on your camera may not always be compatible with your browser, which is why setting them to H.264 and AAC is recommended. See the [go2rtc docs](https://github.com/AlexxIT/go2rtc?tab=readme-ov-file#codecs-madness) for codec support information. ### Audio Support[​](https://docs.frigate.video/configuration/live/#audio-support "Direct link to Audio Support") MSE Requires PCMA/PCMU or AAC audio, WebRTC requires PCMA/PCMU or opus audio. If you want to support both MSE and WebRTC then your restream config needs to make sure both are enabled. go2rtc: streams: rtsp_cam: # <- for RTSP streams - rtsp://192.168.1.5:554/live0 # <- stream which supports video & aac audio - "ffmpeg:rtsp_cam#audio=opus" # <- copy of the stream which transcodes audio to the missing codec (usually will be opus) http_cam: # <- for http streams - http://192.168.50.155/flv?port=1935&app=bcs&stream=channel0_main.bcs&user=user&password=password # <- stream which supports video & aac audio - "ffmpeg:http_cam#audio=opus" # <- copy of the stream which transcodes audio to the missing codec (usually will be opus) If your camera does not support AAC audio or are having problems with Live view, try transcoding to AAC audio directly: go2rtc: streams: rtsp_cam: # <- for RTSP streams - "ffmpeg:rtsp://192.168.1.5:554/live0#video=copy#audio=aac" # <- copies video stream and transcodes to aac audio - "ffmpeg:rtsp_cam#audio=opus" # <- provides support for WebRTC If your camera does not have audio and you are having problems with Live view, you should have go2rtc send video only: go2rtc: streams: no_audio_camera: - ffmpeg:rtsp://192.168.1.5:554/live0#video=copy ### Setting Streams For Live UI[​](https://docs.frigate.video/configuration/live/#setting-streams-for-live-ui "Direct link to Setting Streams For Live UI") You can configure Frigate to allow manual selection of the stream you want to view in the Live UI. For example, you may want to view your camera's substream on mobile devices, but the full resolution stream on desktop devices. Setting the `live -> streams` list will populate a dropdown in the UI's Live view that allows you to choose between the streams. This stream setting is _per device_ and is saved in your browser's local storage. Additionally, when creating and editing camera groups in the UI, you can choose the stream you want to use for your camera group's Live dashboard. note Frigate's default dashboard ("All Cameras") will always use the first entry you've defined in `streams:` when playing live streams from your cameras. Configure the `streams` option with a "friendly name" for your stream followed by the go2rtc stream name. Using Frigate's internal version of go2rtc is required to use this feature. You cannot specify paths in the `streams` configuration, only go2rtc stream names. go2rtc: streams: test_cam: - rtsp://192.168.1.5:554/live_main # <- stream which supports video & aac audio. - "ffmpeg:test_cam#audio=opus" # <- copy of the stream which transcodes audio to opus for webrtc test_cam_sub: - rtsp://192.168.1.5:554/live_sub # <- stream which supports video & aac audio. test_cam_another_sub: - rtsp://192.168.1.5:554/live_alt # <- stream which supports video & aac audio.cameras: test_cam: ffmpeg: output_args: record: preset-record-generic-audio-copy inputs: - path: rtsp://127.0.0.1:8554/test_cam # <--- the name here must match the name of the camera in restream input_args: preset-rtsp-restream roles: - record - path: rtsp://127.0.0.1:8554/test_cam_sub # <--- the name here must match the name of the camera_sub in restream input_args: preset-rtsp-restream roles: - detect live: streams: # <--- Multiple streams for Frigate 0.16 and later Main Stream: test_cam # <--- Specify a "friendly name" followed by the go2rtc stream name Sub Stream: test_cam_sub Special Stream: test_cam_another_sub ### WebRTC extra configuration:[​](https://docs.frigate.video/configuration/live/#webrtc-extra-configuration "Direct link to WebRTC extra configuration:") WebRTC works by creating a TCP or UDP connection on port `8555`. However, it requires additional configuration: * For external access, over the internet, setup your router to forward port `8555` to port `8555` on the Frigate device, for both TCP and UDP. * For internal/local access, unless you are running through the HA App, you will also need to set the WebRTC candidates list in the go2rtc config. For example, if `192.168.1.10` is the local IP of the device running Frigate: config.yml go2rtc: streams: test_cam: ... webrtc: candidates: - 192.168.1.10:8555 - stun:8555 * For access through Tailscale, the Frigate system's Tailscale IP must be added as a WebRTC candidate. Tailscale IPs all start with `100.`, and are reserved within the `100.64.0.0/10` CIDR block. * Note that some browsers may not support H.265 (HEVC). You can check your browser's current version for H.265 compatibility [here](https://github.com/AlexxIT/go2rtc?tab=readme-ov-file#codecs-madness) . tip This extra configuration may not be required if Frigate has been installed as a Home Assistant App, as Frigate uses the Supervisor's API to generate a WebRTC candidate. However, it is recommended if issues occur to define the candidates manually. You should do this if the Frigate App fails to generate a valid candidate. If an error occurs you will see some warnings like the below in the App logs page during the initialization: [WARN] Failed to get IP address from supervisor[WARN] Failed to get WebRTC port from supervisor note If you are having difficulties getting WebRTC to work and you are running Frigate with docker, you may want to try changing the container network mode: * `network: host`, in this mode you don't need to forward any ports. The services inside of the Frigate container will have full access to the network interfaces of your host machine as if they were running natively and not in a container. Any port conflicts will need to be resolved. This network mode is recommended by go2rtc, but we recommend you only use it if necessary. * `network: bridge` is the default network driver, a bridge network is a Link Layer device which forwards traffic between network segments. You need to forward any ports that you want to be accessible from the host IP. If not running in host mode, port 8555 will need to be mapped for the container: docker-compose.yml services: frigate: ... ports: - "8555:8555/tcp" # WebRTC over tcp - "8555:8555/udp" # WebRTC over udp See [go2rtc WebRTC docs](https://github.com/AlexxIT/go2rtc/tree/v1.8.3#module-webrtc) for more information about this. ### Two way talk[​](https://docs.frigate.video/configuration/live/#two-way-talk "Direct link to Two way talk") For devices that support two way talk, Frigate can be configured to use the feature from the camera's Live view in the Web UI. You should: * Set up go2rtc with [WebRTC](https://docs.frigate.video/configuration/live/#webrtc-extra-configuration) . * Ensure you access Frigate via https (may require [opening port 8971](https://docs.frigate.video/frigate/installation/#ports) ). * For the Home Assistant Frigate card, [follow the docs](http://card.camera/#/usage/2-way-audio) for the correct source. To use the Reolink Doorbell with two way talk, you should use the [recommended Reolink configuration](https://docs.frigate.video/configuration/camera_specific#reolink-cameras) As a starting point to check compatibility for your camera, view the list of cameras supported for two-way talk on the [go2rtc repository](https://github.com/AlexxIT/go2rtc?tab=readme-ov-file#two-way-audio) . For cameras in the category `ONVIF Profile T`, you can use the [ONVIF Conformant Products Database](https://www.onvif.org/conformant-products/) 's FeatureList to check for the presence of `AudioOutput`. A camera that supports `ONVIF Profile T` _usually_ supports this, but due to inconsistent support, a camera that explicitly lists this feature may still not work. If no entry for your camera exists on the database, it is recommended not to buy it or to consult with the manufacturer's support on the feature availability. To prevent go2rtc from blocking other applications from accessing your camera's two-way audio, you must configure your stream with `#backchannel=0`. See [preventing go2rtc from blocking two-way audio](https://docs.frigate.video/configuration/restream#two-way-talk-restream) in the restream documentation. ### Streaming options on camera group dashboards[​](https://docs.frigate.video/configuration/live/#streaming-options-on-camera-group-dashboards "Direct link to Streaming options on camera group dashboards") Frigate provides a dialog in the Camera Group Edit pane with several options for streaming on a camera group's dashboard. These settings are _per device_ and are saved in your device's local storage. * Stream selection using the `live -> streams` configuration option (see _Setting Streams For Live UI_ above) * Streaming type: * _No streaming_: Camera images will only update once per minute and no live streaming will occur. * _Smart Streaming_ (default, recommended setting): Smart streaming will update your camera image once per minute when no detectable activity is occurring to conserve bandwidth and resources, since a static picture is the same as a streaming image with no motion or objects. When motion or objects are detected, the image seamlessly switches to a live stream. * _Continuous Streaming_: Camera image will always be a live stream when visible on the dashboard, even if no activity is being detected. Continuous streaming may cause high bandwidth usage and performance issues. **Use with caution.** * _Compatibility mode_: Enable this option only if your camera's live stream is displaying color artifacts and has a diagonal line on the right side of the image. Before enabling this, try setting your camera's `detect` width and height to a standard aspect ratio (for example: 640x352 becomes 640x360, and 800x443 becomes 800x450, 2688x1520 becomes 2688x1512, etc). Depending on your browser and device, more than a few cameras in compatibility mode may not be supported, so only use this option if changing your config fails to resolve the color artifacts and diagonal line. note The default dashboard ("All Cameras") will always use: * Smart Streaming, unless you've disabled the global Automatic Live View in Settings. * The first entry set in your `streams` configuration, if defined. Use a camera group if you want to change any of these settings from the defaults. ### Disabling cameras[​](https://docs.frigate.video/configuration/live/#disabling-cameras "Direct link to Disabling cameras") Cameras can be temporarily disabled through the Frigate UI and through [MQTT](https://docs.frigate.video/integrations/mqtt#frigatecamera_nameenabledset) to conserve system resources. When disabled, Frigate's ffmpeg processes are terminated β€” recording stops, object detection is paused, and the Live dashboard displays a blank image with a disabled message. Review items, tracked objects, and historical footage for disabled cameras can still be accessed via the UI. note Disabling a camera via the Frigate UI or MQTT is temporary and does not persist through restarts of Frigate. For restreamed cameras, go2rtc remains active but does not use system resources for decoding or processing unless there are active external consumers (such as the Advanced Camera Card in Home Assistant using a go2rtc source). Note that disabling a camera through the config file (`enabled: False`) removes all related UI elements, including historical footage access. To retain access while disabling the camera, keep it enabled in the config and use the UI or MQTT to disable it temporarily. ### Live player error messages[​](https://docs.frigate.video/configuration/live/#live-player-error-messages "Direct link to Live player error messages") When your browser runs into problems playing back your camera streams, it will log short error messages to the browser console. They indicate playback, codec, or network issues on the client/browser side, not something server side with Frigate itself. Below are the common messages you may see and simple actions you can take to try to resolve them. * **startup** * What it means: The player failed to initialize or connect to the live stream (network or startup error). * What to try: Reload the Live view or click _Reset_. Verify `go2rtc` is running and the camera stream is reachable. Try switching to a different stream from the Live UI dropdown (if available) or use a different browser. * Possible console messages from the player code: * `Error opening MediaSource.` * `Browser reported a network error.` * `Max error count ${errorCount} exceeded.` (the numeric value will vary) * **mse-decode** * What it means: The browser reported a decoding error while trying to play the stream, which usually is a result of a codec incompatibility or corrupted frames. * What to try: Check the browser console for the supported and negotiated codecs. Ensure your camera/restream is using H.264 video and AAC audio (these are the most compatible). If your camera uses a non-standard audio codec, configure `go2rtc` to transcode the stream to AAC. Try another browser (some browsers have stricter MSE/codec support) and, for iPhone, ensure you're on iOS 17.1 or newer. * Possible console messages from the player code: * `Safari cannot open MediaSource.` * `Safari reported InvalidStateError.` * `Safari reported decoding errors.` * **stalled** * What it means: Playback has stalled because the player has fallen too far behind live (extended buffering or no data arriving). * What to try: This is usually indicative of the browser struggling to decode too many high-resolution streams at once. Try selecting a lower-bandwidth stream (substream), reduce the number of live streams open, improve the network connection, or lower the camera resolution. Also check your camera's keyframe (I-frame) interval β€” shorter intervals make playback start and recover faster. You can also try increasing the timeout value in the UI pane of Frigate's settings. * Possible console messages from the player code: * `Buffer time (10 seconds) exceeded, browser may not be playing media correctly.` * `Media playback has stalled after seconds due to insufficient buffering or a network interruption.` (the seconds value will vary) Live view FAQ[​](https://docs.frigate.video/configuration/live/#live-view-faq "Direct link to Live view FAQ") -------------------------------------------------------------------------------------------------------------- 1. **Why don't I have audio in my Live view?** You must use go2rtc to hear audio in your live streams. If you have go2rtc already configured, you need to ensure your camera is sending PCMA/PCMU or AAC audio. If you can't change your camera's audio codec, you need to [transcode the audio](https://github.com/AlexxIT/go2rtc?tab=readme-ov-file#source-ffmpeg) using go2rtc. Note that the low bandwidth mode player is a video-only stream. You should not expect to hear audio when in low bandwidth mode, even if you've set up go2rtc. 2. **Frigate shows that my live stream is in "low bandwidth mode". What does this mean?** Frigate intelligently selects the live streaming technology based on a number of factors (user-selected modes like two-way talk, camera settings, browser capabilities, available bandwidth) and prioritizes showing an actual up-to-date live view of your camera's stream as quickly as possible. When you have go2rtc configured, Live view initially attempts to load and play back your stream with a clearer, fluent stream technology (MSE). An initial timeout, a low bandwidth condition that would cause buffering of the stream, or decoding errors in the stream will cause Frigate to switch to the stream defined by the `detect` role, using the jsmpeg format. This is what the UI labels as "low bandwidth mode". On Live dashboards, the mode will automatically reset when smart streaming is configured and activity stops. Continuous streaming mode does not have an automatic reset mechanism, but you can use the _Reset_ option to force a reload of your stream. If you are using continuous streaming or you are loading more than a few high resolution streams at once on the dashboard, your browser may struggle to begin playback of your streams before the timeout. Frigate always prioritizes showing a live stream as quickly as possible, even if it is a lower quality jsmpeg stream. You can use the "Reset" link/button to try loading your high resolution stream again. Errors in stream playback (e.g., connection failures, codec issues, or buffering timeouts) that cause the fallback to low bandwidth mode (jsmpeg) are logged to the browser console for easier debugging. These errors may include: * Network issues (e.g., MSE or WebRTC network connection problems). * Unsupported codecs or stream formats (e.g., H.265 in WebRTC, which is not supported in some browsers). * Buffering timeouts or low bandwidth conditions causing fallback to jsmpeg. * Browser compatibility problems (e.g., iOS Safari limitations with MSE). To view browser console logs: 1. Open the Frigate Live View in your browser. 2. Open the browser's Developer Tools (F12 or right-click > Inspect > Console tab). 3. Reproduce the error (e.g., load a problematic stream or simulate network issues). 4. Look for messages prefixed with the camera name. These logs help identify if the issue is player-specific (MSE vs. WebRTC) or related to camera configuration (e.g., go2rtc streams, codecs). If you see frequent errors: * Verify your camera's H.264/AAC settings (see [Frigate's camera settings recommendations](https://docs.frigate.video/configuration/live/#camera_settings_recommendations) ). * Check go2rtc configuration for transcoding (e.g., audio to AAC/OPUS). * Test with a different stream via the UI dropdown (if `live -> streams` is configured). * For WebRTC-specific issues, ensure port 8555 is forwarded and candidates are set (see (WebRTC Extra Configuration)(#webrtc-extra-configuration)). * If your cameras are streaming at a high resolution, your browser may be struggling to load all of the streams before the buffering timeout occurs. Frigate prioritizes showing a true live view as quickly as possible. If the fallback occurs often, change your live view settings to use a lower bandwidth substream. 3. **It doesn't seem like my cameras are streaming on the Live dashboard. Why?** On the default Live dashboard ("All Cameras"), your camera images will update once per minute when no detectable activity is occurring to conserve bandwidth and resources. As soon as any activity is detected, cameras seamlessly switch to a full-resolution live stream. If you want to customize this behavior, use a camera group. 4. **I see a strange diagonal line on my live view, but my recordings look fine. How can I fix it?** This is caused by incorrect dimensions set in your detect width or height (or incorrectly auto-detected), causing the jsmpeg player's rendering engine to display a slightly distorted image. You should enlarge the width and height of your `detect` resolution up to a standard aspect ratio (example: 640x352 becomes 640x360, and 800x443 becomes 800x450, 2688x1520 becomes 2688x1512, etc). If changing the resolution to match a standard (4:3, 16:9, or 32:9, etc) aspect ratio does not solve the issue, you can enable "compatibility mode" in your camera group dashboard's stream settings. Depending on your browser and device, more than a few cameras in compatibility mode may not be supported, so only use this option if changing your `detect` width and height fails to resolve the color artifacts and diagonal line. 5. **How does "smart streaming" work?** Because a static image of a scene looks exactly the same as a live stream with no motion or activity, smart streaming updates your camera images once per minute when no detectable activity is occurring to conserve bandwidth and resources. As soon as any activity (motion or object/audio detection) occurs, cameras seamlessly switch to a live stream. This static image is pulled from the stream defined in your config with the `detect` role. When activity is detected, images from the `detect` stream immediately begin updating at ~5 frames per second so you can see the activity until the live player is loaded and begins playing. This usually only takes a second or two. If the live player times out, buffers, or has streaming errors, the jsmpeg player is loaded and plays a video-only stream from the `detect` role. When activity ends, the players are destroyed and a static image is displayed until activity is detected again, and the process repeats. Smart streaming depends on having your camera's motion `threshold` and `contour_area` config values dialed in. Use the Motion Tuner in Settings in the UI to tune these values in real-time. This is Frigate's default and recommended setting because it results in a significant bandwidth savings, especially for high resolution cameras. 6. **I have unmuted some cameras on my dashboard, but I do not hear sound. Why?** If your camera is streaming (as indicated by a red dot in the upper right, or if it has been set to continuous streaming mode), your browser may be blocking audio until you interact with the page. This is an intentional browser limitation. See [this article](https://developer.mozilla.org/en-US/docs/Web/Media/Autoplay_guide#autoplay_availability) . Many browsers have a whitelist feature to change this behavior. 7. **My camera streams have lots of visual artifacts / distortion.** Some cameras don't include the hardware to support multiple connections to the high resolution stream, and this can cause unexpected behavior. In this case it is recommended to [restream](https://docs.frigate.video/configuration/restream) the high resolution stream so that it can be used for live view and recordings. 8. **Why does my camera stream switch aspect ratios on the Live dashboard?** Your camera may change aspect ratios on the dashboard because Frigate uses different streams for different purposes. With go2rtc and Smart Streaming, Frigate shows a static image from the `detect` stream when no activity is present, and switches to the live stream when motion is detected. The camera image will change size if your streams use different aspect ratios. To prevent this, make the `detect` stream match the go2rtc live stream's aspect ratio (resolution does not need to match, just the aspect ratio). You can either adjust the camera's output resolution or set the `width` and `height` values in your config's `detect` section to a resolution with an aspect ratio that matches. Example: Resolutions from two streams * Mismatched (may cause aspect ratio switching on the dashboard): * Live/go2rtc stream: 1920x1080 (16:9) * Detect stream: 640x352 (~1.82:1, not 16:9) * Matched (prevents switching): * Live/go2rtc stream: 1920x1080 (16:9) * Detect stream: 640x360 (16:9) You can update the detect settings in your camera config to match the aspect ratio of your go2rtc live stream. For example: cameras: front_door: detect: width: 640 height: 360 # set this to 360 instead of 352 ffmpeg: inputs: - path: rtsp://127.0.0.1:8554/front_door # main stream 1920x1080 roles: - record - path: rtsp://127.0.0.1:8554/front_door_sub # sub stream 640x352 roles: - detect * [Live View technologies](https://docs.frigate.video/configuration/live/#live-view-technologies) * [Camera Settings Recommendations](https://docs.frigate.video/configuration/live/#camera-settings-recommendations) * [Audio Support](https://docs.frigate.video/configuration/live/#audio-support) * [Setting Streams For Live UI](https://docs.frigate.video/configuration/live/#setting-streams-for-live-ui) * [WebRTC extra configuration:](https://docs.frigate.video/configuration/live/#webrtc-extra-configuration) * [Two way talk](https://docs.frigate.video/configuration/live/#two-way-talk) * [Streaming options on camera group dashboards](https://docs.frigate.video/configuration/live/#streaming-options-on-camera-group-dashboards) * [Disabling cameras](https://docs.frigate.video/configuration/live/#disabling-cameras) * [Live player error messages](https://docs.frigate.video/configuration/live/#live-player-error-messages) * [Live view FAQ](https://docs.frigate.video/configuration/live/#live-view-faq) --- # Stationary Objects | Frigate [Skip to main content](https://docs.frigate.video/configuration/stationary_objects/#__docusaurus_skipToContent_fallback) πŸš€ Get more relevant and accurate detections with Frigate+ models. [Learn more](https://frigate.video/plus/) ✨ On this page An object is considered stationary when it is being tracked and has been in a very similar position for a certain number of frames. This number is defined in the configuration under `detect -> stationary -> threshold`, and is 10x the frame rate (or 10 seconds) by default. Once an object is considered stationary, it will remain stationary until motion occurs within the object at which point object detection will start running again. If the object changes location, it will be considered active. Why does it matter if an object is stationary?[​](https://docs.frigate.video/configuration/stationary_objects/#why-does-it-matter-if-an-object-is-stationary "Direct link to Why does it matter if an object is stationary?") ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ Once an object becomes stationary, object detection will not be continually run on that object. This serves to reduce resource usage and redundant detections when there has been no motion near the tracked object. This also means that Frigate is contextually aware, and can for example [filter out recording segments](https://docs.frigate.video/configuration/record#what-do-the-different-retain-modes-mean) to only when the object is considered active. Motion alone does not determine if an object is "active" for active\_objects segment retention. Lighting changes for a parked car won't make an object active. Tuning stationary behavior[​](https://docs.frigate.video/configuration/stationary_objects/#tuning-stationary-behavior "Direct link to Tuning stationary behavior") ------------------------------------------------------------------------------------------------------------------------------------------------------------------- The default config is: detect: stationary: interval: 50 threshold: 50 `interval` is defined as the frequency for running detection on stationary objects. This means that by default once an object is considered stationary, detection will not be run on it until motion is detected or until the interval (every 50th frame by default). With `interval >= 1`, every nth frames detection will be run to make sure the object is still there. NOTE: There is no way to disable stationary object tracking with this value. `threshold` is the number of frames an object needs to remain relatively still before it is considered stationary. Why does Frigate track stationary objects?[​](https://docs.frigate.video/configuration/stationary_objects/#why-does-frigate-track-stationary-objects "Direct link to Why does Frigate track stationary objects?") ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ Frigate didn't always track stationary objects. In fact, it didn't even track objects at all initially. Let's look at an example use case: I want to record any cars that enter my driveway. One might simply think "Why not just run object detection any time there is motion around the driveway area and notify if the bounding box is in that zone?" With that approach, what video is related to the car that entered the driveway? Did it come from the left or right? Was it parked across the street for an hour before turning into the driveway? One approach is to just record 24/7 or for motion (on any changed changed pixels) and not attempt to do that at all. This is what most other NVRs do. Just don't even try to identify a start and end for that object since it's hard and you will be wrong some portion of the time. Couldn't you just look at when motion stopped and started? Motion for a video feed is nothing more than looking for pixels that are different than they were in previous frames. If the car entered the driveway while someone was mowing the grass, how would you know which motion was for the car and which was for the person when they mow along the driveway or street? What if another car was driving the other direction on the street? Or what if its a windy day and the bush by your mailbox is blowing around? In order to do it more accurately, you need to identify objects and track them with a unique id. In each subsequent frame, everything has moved a little and you need to determine which bounding boxes go with each object from the previous frame. Tracking objects across frames is a challenging problem. Especially if you want to do it in real time. There are entire competitions for research algorithms to see which of them can do it the most accurately. Zero of them are accurate 100% of the time. Even the ones that can't do it in realtime. There is always an error rate in the algorithm. Now consider that the car is driving down a street that has other cars parked along it. It will drive behind some of these cars and in front of others. There may even be a car driving the opposite direction. Let's assume for now that we are NOT already tracking two parked cars on the street or the car parked in the driveway, ie, there is no stationary object tracking. As the car you are tracking approaches an area with 2 cars parked, the headlights reflect off the parked cars and the car parked in your driveway. The pixel values are different in that area, so there is motion detected. Object detection runs and identifies the remaining 3 cars. In the previous frame, you had a single bounding box from the car you are tracking. Now you have 4. The original object, the 2 cars on the street and the one in your driveway. Now you have to determine which of the bounding boxes in this frame should be matched to the tracking id from the previous frame where you only had one. Remember, you have never seen these additional 3 cars before, so you know nothing about them. On top of that the bounding box for the car you are tracking has now moved to a new location, so which of the 4 belongs to the car you were originally tracking? The algorithms here are fairly good. They use a Kalman filter to predict the next location of an object using the historical bounding boxes and the bounding box closest to the predicted location is linked. It's right sometimes, but the error rate is going to be high when there are 4 possible bounding boxes. Now let's assume that those other 3 cars were already being tracked as stationary objects, so the car driving down the street is a new 4th car. The object tracker knows we have had 3 cars and we now have 4. As the new car approaches the parked cars, the bounding boxes for all 4 cars is predicted based on the previous frames. The predicted boxes for the parked cars is pretty much a 100% overlap with the bounding boxes in the new frame. The parked cars are slam dunk matches to the tracking ids they had before and the only one left is the remaining bounding box which gets assigned to the new car. This results in a much lower error rate. Not perfect, but better. The most difficult scenario that causes IDs to be assigned incorrectly is when an object completely occludes another object. When a car drives in front of another car and its no longer visible, a bounding box disappeared and it's a bit of a toss up when assigning the id since it's difficult to know which one is in front of the other. This happens for cars passing in front of other cars fairly often. It's something that we want to improve in the future. * [Why does it matter if an object is stationary?](https://docs.frigate.video/configuration/stationary_objects/#why-does-it-matter-if-an-object-is-stationary) * [Tuning stationary behavior](https://docs.frigate.video/configuration/stationary_objects/#tuning-stationary-behavior) * [Why does Frigate track stationary objects?](https://docs.frigate.video/configuration/stationary_objects/#why-does-frigate-track-stationary-objects) --- # Review | Frigate [Skip to main content](https://docs.frigate.video/configuration/review/#__docusaurus_skipToContent_fallback) πŸš€ Get more relevant and accurate detections with Frigate+ models. [Learn more](https://frigate.video/plus/) ✨ On this page The Review page of the Frigate UI is for quickly reviewing historical footage of interest from your cameras. _Review items_ are indicated on a vertical timeline and displayed as a grid of previews - bandwidth-optimized, low frame rate, low resolution videos. Hovering over or swiping a preview plays the video and marks it as reviewed. If more in-depth analysis is required, the preview can be clicked/tapped and the full frame rate, full resolution recording is displayed. Review items are filterable by date, object type, and camera. ### Review items vs. tracked objects (formerly "events")[​](https://docs.frigate.video/configuration/review/#review-items-vs-tracked-objects-formerly-events "Direct link to Review items vs. tracked objects (formerly "events")") In Frigate 0.13 and earlier versions, the UI presented "events". An event was synonymous with a tracked or detected object. In Frigate 0.14 and later, a review item is a time period where any number of tracked objects were active. For example, consider a situation where two people walked past your house. One was walking a dog. At the same time, a car drove by on the street behind them. In this scenario, Frigate 0.13 and earlier would show 4 "events" in the UI - one for each person, another for the dog, and yet another for the car. You would have had 4 separate videos to watch even though they would have all overlapped. In 0.14 and later, all of that is bundled into a single review item which starts and ends to capture all of that activity. Reviews for a single camera cannot overlap. Once you have watched that time period on that camera, it is marked as reviewed. Alerts and Detections[​](https://docs.frigate.video/configuration/review/#alerts-and-detections "Direct link to Alerts and Detections") ---------------------------------------------------------------------------------------------------------------------------------------- Not every segment of video captured by Frigate may be of the same level of interest to you. Video of people who enter your property may be a different priority than those walking by on the sidewalk. For this reason, Frigate 0.14 categorizes review items as _alerts_ and _detections_. By default, all person and car objects are considered alerts. You can refine categorization of your review items by configuring required zones for them. note Alerts and detections categorize the tracked objects in review items, but Frigate must first detect those objects with your configured object detector (Coral, OpenVINO, etc). By default, the object tracker only detects `person`. Setting `labels` for `alerts` and `detections` does not automatically enable detection of new objects. To detect more than `person`, you should add the following to your config: objects: track: - person - car - ... See the [objects documentation](https://docs.frigate.video/configuration/objects) for the list of objects that Frigate's default model tracks. Restricting alerts to specific labels[​](https://docs.frigate.video/configuration/review/#restricting-alerts-to-specific-labels "Direct link to Restricting alerts to specific labels") ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- By default a review item will only be marked as an alert if a person or car is detected. This can be configured to include any object or audio label using the following config: # can be overridden at the camera levelreview: alerts: labels: - car - cat - dog - person - speech Restricting detections to specific labels[​](https://docs.frigate.video/configuration/review/#restricting-detections-to-specific-labels "Direct link to Restricting detections to specific labels") ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- By default all detections that do not qualify as an alert qualify as a detection. However, detections can further be filtered to only include certain labels or certain zones. # can be overridden at the camera levelreview: detections: labels: - bark - dog Excluding a camera from alerts or detections[​](https://docs.frigate.video/configuration/review/#excluding-a-camera-from-alerts-or-detections "Direct link to Excluding a camera from alerts or detections") ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- To exclude a specific camera from alerts or detections, simply provide an empty list to the alerts or detections field _at the camera level_. For example, to exclude objects on the camera _gatecamera_ from any detections, include this in your config: cameras: gatecamera: review: detections: labels: [] Restricting review items to specific zones[​](https://docs.frigate.video/configuration/review/#restricting-review-items-to-specific-zones "Direct link to Restricting review items to specific zones") ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- By default a review item will be created if any `review -> alerts -> labels` and `review -> detections -> labels` are detected anywhere in the camera frame. You will likely want to configure review items to only be created when the object enters an area of interest, [see the zone docs for more information](https://docs.frigate.video/configuration/zones#restricting-alerts-and-detections-to-specific-zones) info Because zones don't apply to audio, audio labels will always be marked as a detection by default. * [Review items vs. tracked objects (formerly "events")](https://docs.frigate.video/configuration/review/#review-items-vs-tracked-objects-formerly-events) * [Alerts and Detections](https://docs.frigate.video/configuration/review/#alerts-and-detections) * [Restricting alerts to specific labels](https://docs.frigate.video/configuration/review/#restricting-alerts-to-specific-labels) * [Restricting detections to specific labels](https://docs.frigate.video/configuration/review/#restricting-detections-to-specific-labels) * [Excluding a camera from alerts or detections](https://docs.frigate.video/configuration/review/#excluding-a-camera-from-alerts-or-detections) * [Restricting review items to specific zones](https://docs.frigate.video/configuration/review/#restricting-review-items-to-specific-zones) --- # TLS | Frigate [Skip to main content](https://docs.frigate.video/configuration/tls/#__docusaurus_skipToContent_fallback) πŸš€ Get more relevant and accurate detections with Frigate+ models. [Learn more](https://frigate.video/plus/) ✨ On this page Frigate's integrated NGINX server supports TLS certificates. By default Frigate will generate a self signed certificate that will be used for port 8971. Frigate is designed to make it easy to use whatever tool you prefer to manage certificates. Frigate is often running behind a reverse proxy that manages TLS certificates for multiple services. You will likely need to set your reverse proxy to allow self signed certificates or you can disable TLS in Frigate's config. However, if you are running on a dedicated device that's separate from your proxy or if you expose Frigate directly to the internet, you may want to configure TLS with valid certificates. In many deployments, TLS will be unnecessary. It can be disabled in the config with the following yaml: tls: enabled: False Certificates[​](https://docs.frigate.video/configuration/tls/#certificates "Direct link to Certificates") ---------------------------------------------------------------------------------------------------------- TLS certificates can be mounted at `/etc/letsencrypt/live/frigate` using a bind mount or docker volume. frigate: ... volumes: - /path/to/your/certificate_folder:/etc/letsencrypt/live/frigate:ro ... Within the folder, the private key is expected to be named `privkey.pem` and the certificate is expected to be named `fullchain.pem`. Note that certbot uses symlinks, and those can't be followed by the container unless it has access to the targets as well, so if using certbot you'll also have to mount the `archive` folder for your domain, e.g.: frigate: ... volumes: - /etc/letsencrypt/live/your.fqdn.net:/etc/letsencrypt/live/frigate:ro - /etc/letsencrypt/archive/your.fqdn.net:/etc/letsencrypt/archive/your.fqdn.net:ro ... Frigate automatically compares the fingerprint of the certificate at `/etc/letsencrypt/live/frigate/fullchain.pem` against the fingerprint of the TLS cert in NGINX every minute. If these differ, the NGINX config is reloaded to pick up the updated certificate. If you issue Frigate valid certificates you will likely want to configure it to run on port 443 so you can access it without a port number like `https://your-frigate-domain.com` by mapping 8971 to 443. frigate: ... ports: - "443:8971" ... ACME Challenge[​](https://docs.frigate.video/configuration/tls/#acme-challenge "Direct link to ACME Challenge") ---------------------------------------------------------------------------------------------------------------- Frigate also supports hosting the acme challenge files for the HTTP challenge method if needed. The challenge files should be mounted at `/etc/letsencrypt/www`. * [Certificates](https://docs.frigate.video/configuration/tls/#certificates) * [ACME Challenge](https://docs.frigate.video/configuration/tls/#acme-challenge) --- # Snapshots | Frigate [Skip to main content](https://docs.frigate.video/configuration/snapshots/#__docusaurus_skipToContent_fallback) πŸš€ Get more relevant and accurate detections with Frigate+ models. [Learn more](https://frigate.video/plus/) ✨ On this page Frigate can save a snapshot image to `/media/frigate/clips` for each object that is detected named as `-.jpg`. They are also accessible [via the api](https://docs.frigate.video/integrations/api/event-snapshot-events-event-id-snapshot-jpg-get) Snapshots are accessible in the UI in the Explore pane. This allows for quick submission to the Frigate+ service. To only save snapshots for objects that enter a specific zone, [see the zone docs](https://docs.frigate.video/configuration/zones#restricting-snapshots-to-specific-zones) Snapshots sent via MQTT are configured in the [config file](https://docs.frigate.video/configuration) under `cameras -> your_camera -> mqtt` Frame Selection[​](https://docs.frigate.video/configuration/snapshots/#frame-selection "Direct link to Frame Selection") ------------------------------------------------------------------------------------------------------------------------- Frigate does not save every frame β€” it picks a single "best" frame for each tracked object and uses it for both the snapshot and clean copy. As the object is tracked across frames, Frigate continuously evaluates whether the current frame is better than the previous best based on detection confidence, object size, and the presence of key attributes like faces or license plates. Frames where the object touches the edge of the frame are deprioritized. The snapshot is written to disk once tracking ends using whichever frame was determined to be the best. MQTT snapshots are published more frequently β€” each time a better thumbnail frame is found during tracking, or when the current best image is older than `best_image_timeout` (default: 60s). These use their own annotation settings configured under `cameras -> your_camera -> mqtt`. Clean Copy[​](https://docs.frigate.video/configuration/snapshots/#clean-copy "Direct link to Clean Copy") ---------------------------------------------------------------------------------------------------------- Frigate can produce up to two snapshot files per event, each used in different places: | Version | File | Annotations | Used by | | --- | --- | --- | --- | | **Regular snapshot** | `-.jpg` | Respects your `timestamp`, `bounding_box`, `crop`, and `height` settings | API (`/api/events//snapshot.jpg`), MQTT (`/