Cerberus: where does weapon detection stand?
Cerberus builds on Heimdall, our computer-vision building block. The goal: spot a firearm or a drone on a video stream and raise a reliable alert. Here's a progress update.
Responsible use. Cerberus is an experimental detection aid. It replaces neither a certified alarm system nor human intervention. Every alert must be verified by a person before any action. Any deployment must comply with local regulations on video surveillance and data protection.
Two models rather than one
Instead of a single "generalist" model, we train two independent models, one per domain:
- firearm — firearm, robbery context / fixed or CCTV camera;
- drone — aerial threat.
The two domains share neither the same object, nor the same classes, nor the same scene context. Each therefore has its own dataset and model. The V0 classes:
firearm : 0 handgun, 1 long_gun, 2 not_weapon
drone : 0 drone, 1 not_drone
We separate handgun and long_gun (very different silhouettes); the alert fires the same way for both.
The pipeline
- Extract frames from source videos (one every N frames).
- Annotate with CVAT, Label Studio, Roboflow or LabelImg — including images without a target (empty labels) to reduce false positives.
- Train one YOLOv8 model per domain.
- Test on an image, a folder or a video, with temporal-confirmation alerting.
# Extraction
python train_heimdall.py --video videos/firearm/clip.mp4 --domain firearm --extract-every 30
# Training
python train_heimdall.py --domain firearm --train --epochs 80 --imgsz 640
# Test + alert
python detect_heimdall.py --source videos/test/test.mp4 \
--model runs/heimdall_firearm/train/weights/best.pt --alert
Where we stand
- firearm — a first working model exists (v1 prototype, trained on a small batch of ~21
handgunimages). It serves as a base for broader training rather than starting from scratch. Several source videos still need extracting and annotating. - drone — folders ready, dataset still to be built.
A model trained on a small dataset produces false positives and false negatives. What matters now is data: more volume, more scene diversity, and an alert layer that only fires on several consecutive detections.
What's next
Grow the firearm dataset, kick off the drone domain, then measure precision and recall on real videos. Goal: an alert usable in real conditions, not just a demo.