1 Star 0 Fork 0

兰永洋/yolov5-onnxruntime

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
贡献代码
同步代码
取消
提示: 由于 Git 不支持空文件夾,创建文件夹后会生成空的 .keep 文件
Loading...
README

yolov5-onnxruntime

C++ YOLO v5 ONNX Runtime inference code for object detection.

Dependecies:

  • OpenCV 4.x
  • ONNXRuntime 1.7+
  • OS: Tested on Windows 10 and Ubuntu 20.04
  • CUDA 11+ [Optional]

Build

To build the project you should run the following commands, don't forget to change ONNXRUNTIME_DIR cmake option:

mkdir build
cd build
cmake .. -DONNXRUNTIME_DIR=path_to_onnxruntime -DCMAKE_BUILD_TYPE=Release
cmake --build .

Run

Before running the executable you should convert your PyTorch model to ONNX if you haven't done it yet. Check the official tutorial.

On Windows: to run the executable you should add OpenCV and ONNX Runtime libraries to your environment path or put all needed libraries near the executable (onnxruntime.dll and opencv_world.dll).

Run from CLI:

./yolo_ort --model_path yolov5.onnx --image bus.jpg --class_names coco.names --gpu
# On Windows ./yolo_ort.exe with arguments as above

Demo

YOLOv5m onnx:

References

空文件

简介

yolov5 onnxruntime 展开 收起
C++ 等 2 种语言
取消

发行版

暂无发行版

贡献者

全部

近期动态

不能加载更多了
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/lan-yongyang/yolov5-onnxruntime.git
git@gitee.com:lan-yongyang/yolov5-onnxruntime.git
lan-yongyang
yolov5-onnxruntime
yolov5-onnxruntime
master

搜索帮助