You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This example demonstrates how to perform inference using YOLOv8 in C++ with ONNX Runtime and OpenCV's API.
5
+
6
+
7
+
This algorithm is inspired by [Ultralitics](https://github.com/ultralytics/ultralytics/tree/main/examples/YOLOv8-ONNXRuntime-CPP) implementation to perform inference using YOLOv8 (we also supports v11) in C++ with ONNX Runtime and OpenCV's API.
6
8
7
9
## Benefits ✨
8
10
@@ -57,12 +59,12 @@ In order to run example, you also need to download coco.yaml. You can download t
57
59
| OpenCV | >=4.0.0 |
58
60
| C++ Standard | >=17 |
59
61
| Cmake | >=3.5 |
60
-
| Cuda (Optional) |>=11.4 \<12.0|
61
-
| cuDNN (Cuda required) | =8|
62
+
| Cuda (Optional) | =12.8 |
63
+
| cuDNN (Cuda required) | =9|
62
64
63
65
Note: The dependency on C++17 is due to the usage of the C++17 filesystem feature.
64
66
65
-
Note (2): Due to ONNX Runtime, we need to use CUDA 11 and cuDNN 8. Keep in mind that this requirement might change in the future.
67
+
Note (2): Due to ONNX Runtime, we need to use CUDA 12.8 and cuDNN 9. Keep in mind that this requirement might change in the future.
66
68
67
69
## Build 🛠️
68
70
@@ -87,12 +89,8 @@ Note (2): Due to ONNX Runtime, we need to use CUDA 11 and cuDNN 8. Keep in mind
87
89
If you encounter an error indicating that the `ONNXRUNTIME_ROOT` variable is not set correctly, you can resolve this by building the project using the appropriate command tailored to your system.
88
90
89
91
```console
90
-
# compiled in a win32 system
91
-
cmake -D WIN32=TRUE ..
92
92
# compiled in a linux system
93
93
cmake -D LINUX=TRUE ..
94
-
# compiled in an apple system
95
-
cmake -D APPLE=TRUE ..
96
94
```
97
95
98
96
5. Build the project:
@@ -104,9 +102,15 @@ Note (2): Due to ONNX Runtime, we need to use CUDA 11 and cuDNN 8. Keep in mind
104
102
6. The built executable should now be located in the `build` directory.
0 commit comments