Top AI Repos — open-source AI, indexed and scored
Top AI Repos tracks AI repositories on GitHub and answers two different questions about each one: is it moving right now, and would you bet a product on it.
Top AI Repos tracks AI repositories on GitHub and answers two different questions about each one: is it moving right now, and would you bet a product on it.
YOLOv8 using TensorRT accelerate !
| Date | Stars |
|---|---|
| 2026-07-24 | 1800 |
| 2026-07-25 | 1800 |
| 2026-07-28 | 1800 |
| 2026-07-30 | 1800 |
| 2026-08-06 | 1800 |
Today
— stars today
This week
— stars this week
This month
— stars this month
Momentum
0.0
growth rate 0.00%/day
# YOLOv8-TensorRT
`YOLOv8` inference accelerated with `TensorRT` — detection, segmentation, pose, oriented boxes and classification, from Python **and** C++.
**English** | [简体中文](README.zh-CN.md)
______________________________________________________________________
[](https://github.com/triple-Mu/YOLOv8-TensorRT)
[](https://developer.nvidia.com/tensorrt)
[](https://github.com/triple-Mu/YOLOv8-TensorRT)
[](LICENSE)
Take a trained `ultralytics` YOLOv8 model, export it to ONNX, build a TensorRT engine, and run it from Python or a small C++ binary — for any of the five tasks. The Python and C++ sides share the same engines and class files; the build adapts itself to whatever TensorRT and OpenCV you have.
## Highlights
- **One shared C++ core** (`libyolov8_core`): RAII-managed TensorRT/CUDA resources, exceptions instead of `assert`, and a single `trt_compat` layer that is the *only* place branching on the TensorRT version.
- **Version-agnostic build**: auto-detects TensorRT (8 ↔ 10/11, including enterprise headers) and OpenCV (`≥4.7` switches to class-aware NMS); see [docs/Build.md](docs/Build.md). Verified on TensorRT **8.6 / 10.8 / 10.16 / 11.0** and OpenCV **4.5 / 4.6 / 4.11**.
- **C++14 fallback**: `std::filesystem` on C++17, otherwise a vendored `ghc::filesystem` (`-DCMAKE_CXX_STANDARD=14`).
- **One Python entry point**: `infer.py --task {det,seg,pose,obb,cls} --backend {torch,cudart,pycuda}` replaces ten per-task scripts; the cudart/pycuda backends now run on TensorRT 10.
- Unit tests (pytest + ctest), a `--profile` per-layer report, and `benchmark.py`.
## Supported tasks
| Task | `infer.py --task` | C++ binary | Export (ONNX) |
| -------------- | ----------------- | ----------------------------------------------------- | ------------------------------ |
| Detection | `det` | `yolov8_detect` (raw) · `yolov8_detect_e2e` (End2End) | `export-det.py` or ultralytics |
| Segmentation | `seg` | `yolov8_seg` · `yolov8_seg_simple` | `export-seg.py` or ultralytics |
| Pose | `pose` | `yolov8_pose` | ultralytics |
| Oriented boxes | `obb` | `yolov8_obb` | ultralytics |
| Classification | `cls` | `yolov8_cls` | ultralytics |
> **Engine layouts.** `export-det.py` produces an **End2End** detection engine with NMS built in (outputs `num_dets, bboxes, scores, labels`); `export-seg.py` produces a segmentation engine (outputs `outputs, proto`); the native `ultralytics` export keeps the model's **raw** output (e.g. `[1, 84, anchors]`). Match the engine to its consumer: `infer.py --task det` and `yolov8_detect_e2e` need the End2End engine, `infer.py --task seg` needs the `export-seg.py` engine, while `yolov8_detect` and the pose/obb/cls paths take the raw ultralytics export.
## Layout
```
csrc/
├── core/ # libyolov8_core: engine, trt_compat, RAII, pre/post-process, profiler
├── apps/ # one thin executable per task (detect / segment / pose / obb / cls ...)
├── deepstream/ # DeepStream bbox parser plugin (optional)
└── tests/ # C++ unit tests (ctest)
models/ # Python: engine builder, backends, compat, labels, per-task handlers
data/labels/ # class names shared by Python and C++ (coco / imagenet / dota)
infer.py build.py export-det.py export-seg.py benchmark.py
```
## Setup
> The repo is small; for the lightest checkout use a shallow clone: `git clone --depth 1 <url>` (latest code only,Excerpt of 9,895 characters
Read on GitHubWould you bet a product on this? Bounded 0–100 and slow moving.
matched fp:432e337d40cbd816, topic:tensorrt, topic:onnx