Standalone example of the Darknet C++ API (hank-ai Darknet/YOLO V3+):
load a network (cfg / names / weights), set the detection and NMS
thresholds, run Darknet::predict() on OpenCV frames, print the
detections (class, confidence, box) and draw them with
Darknet::annotate().
- Input: an image (annotated copy saved as <name>_output.jpg), a video
file or a camera index (shown in a window; without a display the
result is written to output.avi).
- Build: make (g++ -std=c++17 ... opencv4 ... -ldarknet); README covers
build, model files, usage and how it works.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0139veDo3XyavMuVhdnHcN16