Add Apple Silicon ZMQ detector for Frigate #206

Merged
eblume merged 7 commits from feature/frigate-zmq-detector into main 2026-02-17 19:03:29 -08:00
Owner

Summary

  • New frigate_detector ansible role deploys the apple-silicon-detector as a LaunchAgent on indri
  • Switches Frigate from ONNX CPU detector (~117ms) to ZMQ detector backed by CoreML/Neural Engine (~15ms)
  • Removes detect FPS cap (no longer needed with fast inference)
  • Updates Frigate docs and adds changelog fragment

Deployment

Phase 1: Deploy detector on indri (one-time setup + ansible)

ssh indri 'git clone https://github.com/frigate-nvr/apple-silicon-detector.git ~/code/3rd/apple-silicon-detector'
ssh indri 'cd ~/code/3rd/apple-silicon-detector && make install'
mise run provision-indri -- --tags frigate_detector --check --diff  # dry run
mise run provision-indri -- --tags frigate_detector                 # apply
ssh indri 'launchctl list mcquack.eblume.frigate-detector'          # verify running
ssh indri 'tail ~/Library/Logs/mcquack.frigate-detector.out.log'    # verify bound

Phase 2: Test connectivity

kubectl --context=minikube-indri -n frigate exec deploy/frigate -- nc -vz host.minikube.internal 5555

Phase 3: Deploy Frigate config (branch workflow)

argocd app set frigate --revision feature/frigate-zmq-detector && argocd app sync frigate

Phase 4: Post-deploy checks

  • Pod starts, no config errors
  • /api/stats shows detector type zmq, inference_speed ~15ms
  • detect_fps uncapped
  • Recordings and MQTT events flowing
  • After merge: argocd app set frigate --revision main && argocd app sync frigate

🤖 Generated with Claude Code

## Summary - New `frigate_detector` ansible role deploys the [apple-silicon-detector](https://github.com/frigate-nvr/apple-silicon-detector) as a LaunchAgent on indri - Switches Frigate from ONNX CPU detector (~117ms) to ZMQ detector backed by CoreML/Neural Engine (~15ms) - Removes detect FPS cap (no longer needed with fast inference) - Updates Frigate docs and adds changelog fragment ## Deployment ### Phase 1: Deploy detector on indri (one-time setup + ansible) ```fish ssh indri 'git clone https://github.com/frigate-nvr/apple-silicon-detector.git ~/code/3rd/apple-silicon-detector' ssh indri 'cd ~/code/3rd/apple-silicon-detector && make install' mise run provision-indri -- --tags frigate_detector --check --diff # dry run mise run provision-indri -- --tags frigate_detector # apply ssh indri 'launchctl list mcquack.eblume.frigate-detector' # verify running ssh indri 'tail ~/Library/Logs/mcquack.frigate-detector.out.log' # verify bound ``` ### Phase 2: Test connectivity ```fish kubectl --context=minikube-indri -n frigate exec deploy/frigate -- nc -vz host.minikube.internal 5555 ``` ### Phase 3: Deploy Frigate config (branch workflow) ```fish argocd app set frigate --revision feature/frigate-zmq-detector && argocd app sync frigate ``` ### Phase 4: Post-deploy checks - [ ] Pod starts, no config errors - [ ] `/api/stats` shows detector type zmq, inference_speed ~15ms - [ ] detect_fps uncapped - [ ] Recordings and MQTT events flowing - [ ] After merge: `argocd app set frigate --revision main && argocd app sync frigate` 🤖 Generated with [Claude Code](https://claude.com/claude-code)
Moves object detection from ONNX CPU (~117ms/frame) to the
apple-silicon-detector running natively on indri via CoreML/Neural Engine
(~15ms), communicating with Frigate over ZMQ (tcp://host.minikube.internal:5555).

- New ansible role `frigate_detector` with LaunchAgent
- Switch Frigate configmap from ONNX to ZMQ detector
- Remove detect FPS cap (no longer needed with fast inference)
- Update docs and add changelog fragment

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Runs the detector script directly via `uv run --with` with inline
dependencies, eliminating the need for `make install` and a managed venv.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
YOLO-NAS has dynamic output shapes incompatible with CoreML EP, and the
apple-silicon-detector has no yolonas post-processor. YOLOv9-t works with
CoreML and uses the supported yolo-generic model type.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
CoreML runs 468/662 model nodes with the rest on CPU, yielding
~50-80ms inference rather than the initially estimated ~15ms.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Add driveway zone from UI config with review detection filtering
- Upgrade model from YOLOv9-t (7.7M params) to YOLOv9-m (51M params)
  for improved nighttime/low-light detection capability
- YOLOv9-t produced max 5.7% confidence on nighttime IR footage

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
eblume merged commit 5f9b024b4a into main 2026-02-17 19:03:29 -08:00
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
eblume/blumeops!206
No description provided.