[🚀🚀🚀CoreML Yolo🚀🚀🚀]
A unified C++ and Objective-C++ toolkit for YOLO v5/v8/v11/v26/..., covering classification/detection/segmentation/pose/obb tasks with easy python-like APIs from ultralytics/ultralytics. Support All Yolo Tasks, All Yolo Versions, All Yolo Runtimes, it's time to make all in one.
- demo code supprots
Yolotasks likedetection/obb. - support all
Yoloversions includingyolov5(anchor-based)/yolov5u(anchor-free)/yolov8/yolov11/yolov26(nms-free)/more in the future, sub versions liken/s/m/l/xare also supported. - supports
CoreMLYolobackends(runtime) - easy APIs to use and integrate, as simple as python APIs from
ultralytics/ultralyticslibrary. - toolkit works out of box, provide the model and set up the config parameters, go predict!
It is tested on Apple Silicon macs with 64GB UM on 6 and 8way video running 54 and 42 fps avg.
- C++ >= 17
- GCC >= 7.5 or clang
- OpenCV == 4.13
- CUDA/ONNXRuntime/TensorRT/OpenVINO/RKNN/... are optional
- run
git clone https://github.com/edselmalasig/one-yolo-coreml.git - run
cd one-yolo && mkdir build-macos && cd build-macos - run
cmake .. && make -j8
build options when run cmake command:
-DBUILD_WITH_CML=ON # enable CoreML(Apple Platform) as inference backend
-DBUILD_WITH_PDL=ON # enable PaddlePaddle as inference backend
-DBUILD_WITH_CAN=ON # enable CANN(HuaWei Platform) as inference backend
-DBUILD_WITH_DEL=ON # enable Denglin's SDK(Denglin/登临 Platform) as inference backend
-DBUILD_WITH_CAB=ON # enable Cambricon'SDK(Cambricon/寒武纪 Platform) as inference backend
...
if you just run `cmake ..` without any options,
one-yolo will depend on OpenCV::DNN module as inference backend by default,
so OpenCV is required for one-yolo, CUDA is optional when building OpenCV from source code.
you can get yolo models .pt from http://www.ultralytics.com
pip install ultralyticsyolo export model=yolo26n.pt format=coreml- copy the assets folder to build-macos/samples
cd build-macos/samplesmkdir models- move the converted .pt package... the .mlpackage to the models directory
- run the executable from the terminal
can be found in assets folder


