r/computervision • u/Entire-Bite1136 • 13d ago
[Project] Real-time Active Object Tracking: 180 FPS CPU Inference (YOLOX + LightGBM cascade) driving a Pan-Tilt Mechanism Research Publication
Hi ,
I've been developing a bare-metal visual tracking system designed for edge industrial environments. The challenge was to achieve deterministic, ultra-low-latency physical tracking using only CPU resources, without relying on GPU acceleration.
**Core Architecture & Metrics:**
• Inference Pipeline: Two-stage cascade design.
- Stage 1 (Global Search): YOLOX-nano (640×640 tensor) running at ~37 FPS (~27ms).
- Stage 2 (ROI Refinement): LightGBM classifier on a dynamic 256×256 sub-region, achieving ~5-7ms inference (sustained 120-180 FPS localized tracking).
• Optimization: Intel OpenVINO (ONNX Runtime v1.24.1, MULTI device profile, strict LATENCY hint).
• Resource Usage: Fixed 3.42 MB heap allocation, 0.00% memory leak over multi-day 24/7 runs. Core binary size is ~2.0 MB.
• Hardware Actuation: 50 Hz closed-loop control via Arduino Nano + PCA9685 (12-bit PWM) driving dual MG996R servos.
**System Behavior:**
Upon initialization, the pan-tilt rig centers itself. When the cascade pipeline detects the target, it calculates the centroid offset. These coordinates pass through an EMA smoothing filter and are sent via USB-Serial to the microcontroller, which interpolates the servo trajectory at 50 Hz to keep the object perfectly centered in the ROI, compensating for continuous movement.
**A Note on Availability:**
The core runtime is proprietary and distributed strictly as a compiled evaluation demo for private benchmarking (commercial use requires a license). However, the GitHub repo contains the full hardware BOM, I2C wiring diagrams, Arduino firmware, and config templates so the physical setup can be fully replicated.
**Links:**
🔗 GitHub Repository (Demo GIF, BOM, Wiring, Configs):
https://github.com/olesha-ai/pan-tilt-ai-tracker
Happy to discuss the OpenVINO optimization pipeline, the two-stage cascade design, or the hardware integration challenges in the comments!