Face Blur Filter
The Face Blur Filter automatically detects and blurs faces in video frames. It is designed for privacy-conscious applications and supports configurable detection models and blur styles.
Features
-
Face Detection with OpenCV Zoo Models
Downloads and uses face detection models from the OpenCV model zoo or a custom path. -
Pluggable Detector and Blurring Strategy
Choose your detection and blurring method via environment variables:DETECTOR_NAME
(e.g."yunet"
)BLURRER_NAME
(e.g."gaussian"
)
-
Minimal Configuration Required
No runtime arguments needed — all behavior is driven by defaults or environment config. -
High Performance
Processes frames in real-time and replaces them with blurred versions where faces are found.
Example .env
Config
MODEL_ARTIFACTORY_URL=https://github.com/opencv/opencv_zoo/raw/main/models/face_detection_yunet/
MODEL_ARTIFACT_NAME=face_detection_yunet_2023mar.onnx
DETECTOR_NAME=yunet
BLURRER_NAME=gaussian
When to Use
Use this filter when:
- You need to anonymize faces in surveillance, retail, or livestream video
- You want a drop-in privacy-preserving filter that runs on the edge
- You want control over detection and obfuscation techniques
Configuration Reference
Key | Type | Source | Description |
---|---|---|---|
MODEL_ARTIFACTORY_URL | string | env var | Base URL of the face detection model |
MODEL_ARTIFACT_NAME | string | env var | File name of the detection model |
DETECTOR_NAME | string | env var | Name of face detector (e.g., yunet ) |
BLURRER_NAME | string | env var | Type of blurring to apply (e.g., gaussian ) |
Note
Ensure the model file is publicly accessible or pre-downloaded for edge deployments.