All Projects → ttanzhiqiang → onnx_tensorrt_project

ttanzhiqiang / onnx_tensorrt_project

Licence: other
Support Yolov5(4.0)/Yolov5(5.0)/YoloR/YoloX/Yolov4/Yolov3/CenterNet/CenterFace/RetinaFace/Classify/Unet. use darknet/libtorch/pytorch/mxnet to onnx to tensorrt

Programming Languages

C++
36643 projects - #6 most used programming language
python
139335 projects - #7 most used programming language
Cuda
1817 projects
c
50402 projects - #5 most used programming language

Projects that are alternatives of or similar to onnx tensorrt project

simpleAICV-pytorch-ImageNet-COCO-training
SimpleAICV:pytorch training example on ImageNet(ILSVRC2012)/COCO2017/VOC2007+2012 datasets.Include ResNet/DarkNet/RetinaNet/FCOS/CenterNet/TTFNet/YOLOv3/YOLOv4/YOLOv5/YOLOX.
Stars: ✭ 276 (+90.34%)
Mutual labels:  darknet, centernet, yolov4, yolov5, yolox
lite.ai.toolkit
🛠 A lite C++ toolkit of awesome AI models with ONNXRuntime, NCNN, MNN and TNN. YOLOX, YOLOP, MODNet, YOLOR, NanoDet, YOLOX, SCRFD, YOLOX . MNN, NCNN, TNN, ONNXRuntime, CPU/GPU.
Stars: ✭ 1,354 (+833.79%)
Mutual labels:  retinaface, yolor, yolox
YOLO-Streaming
Push-pull streaming and Web display of YOLO series
Stars: ✭ 56 (-61.38%)
Mutual labels:  yolov4, yolov5, yolox
yolor
implementation of paper - You Only Learn One Representation: Unified Network for Multiple Tasks (https://arxiv.org/abs/2105.04206)
Stars: ✭ 1,867 (+1187.59%)
Mutual labels:  darknet, yolov4, yolor
LibtorchTutorials
This is a code repository for pytorch c++ (or libtorch) tutorial.
Stars: ✭ 463 (+219.31%)
Mutual labels:  unet, libtorch, yolov4
Tensorrtx
Implementation of popular deep learning networks with TensorRT network definition API
Stars: ✭ 3,456 (+2283.45%)
Mutual labels:  retinaface, yolov4, yolov5
onnx2tensorRt
tensorRt-inference darknet2onnx pytorch2onnx mxnet2onnx python version
Stars: ✭ 14 (-90.34%)
Mutual labels:  mxnet, darknet, yolov4
arcface retinaface mxnet2onnx
arcface and retinaface model convert mxnet to onnx.
Stars: ✭ 53 (-63.45%)
Mutual labels:  mxnet, retinaface
object-detection-indonesian-traffic-signs-using-yolo-algorithm
Pendeteksian rambu lalu lintas khas Indonesia menggunakan dataset custom dan menggunakan algoritma Deep Learning You Only Look Once v4
Stars: ✭ 26 (-82.07%)
Mutual labels:  darknet, yolov4
InsightFace-REST
InsightFace REST API for easy deployment of face recognition services with TensorRT in Docker.
Stars: ✭ 308 (+112.41%)
Mutual labels:  retinaface, centerface
YOLOv4MLNet
Use the YOLO v4 and v5 (ONNX) models for object detection in C# using ML.Net
Stars: ✭ 61 (-57.93%)
Mutual labels:  yolov4, yolov5
gluon2pytorch
Gluon to PyTorch deep neural network model converter
Stars: ✭ 72 (-50.34%)
Mutual labels:  mxnet, darknet
YoloV5-LibTorch
一个 C++ 版本的 YoloV5 封装库
Stars: ✭ 77 (-46.9%)
Mutual labels:  libtorch, yolov5
ros-yolo-sort
YOLO v3, v4, v5, v6, v7 + SORT tracking + ROS platform. Supporting: YOLO with Darknet, OpenCV(DNN), OpenVINO, TensorRT(tkDNN). SORT supports python(original) and C++. (Not Deep SORT)
Stars: ✭ 162 (+11.72%)
Mutual labels:  yolov4, yolov5
darknet
php ffi darknet
Stars: ✭ 21 (-85.52%)
Mutual labels:  darknet, yolov4
JSON2YOLO
Convert JSON annotations into YOLO format.
Stars: ✭ 222 (+53.1%)
Mutual labels:  darknet, yolov5
go-darknet
Go bindings for Darknet (YOLO v4 / v3)
Stars: ✭ 56 (-61.38%)
Mutual labels:  darknet, yolov4
Deep-Learning-with-GoogleColab
Deep Learning Applications (Darknet - YOLOv3, YOLOv4 | DeOldify - Image Colorization, Video Colorization | Face-Recognition) with Google Colaboratory - on the free Tesla K80/Tesla T4/Tesla P100 GPU - using Keras, Tensorflow and PyTorch.
Stars: ✭ 63 (-56.55%)
Mutual labels:  darknet, yolov4
odam
ODAM - Object detection and Monitoring
Stars: ✭ 16 (-88.97%)
Mutual labels:  darknet, yolov4
pytorch YOLO OpenVINO demo
No description or website provided.
Stars: ✭ 73 (-49.66%)
Mutual labels:  yolov4, yolov5

ONNX-TensorRT

Yolov5(4.0)/Yolov5(5.0)/YoloR/YoloX/Yolov4/Yolov3/CenterNet/CenterFace/RetinaFace/Classify/Unet Implementation

Yolov4/Yolov3/Yolov5/yolor/YoloX

centernet

Unet

CenterFace

retinaface

INTRODUCTION

you have the trained model file from the darknet/libtorch/pytorch/mxnet

  • yolov5-4.0(5s/5m/5s/5x)
  • yolov5-5.0(5s/5m/5s/5x)
  • yolov4 , yolov4-tiny
  • yolov3 , yolov3-tiny
  • yolor
  • YoloX
  • centernet
  • Unet
  • CenterFace
  • RetinaFace
  • classify(mnist\alexnet\resnet18\resnet34\resnet50\shufflenet_v2\mobilenet_v2)

Features

  • inequal net width and height

  • batch inference


    onnx-tensorrt batch inference : onnx re-export(batch:2)

  • support FP32(m_config.mode = 0),FP16(m_config.mode = 1),INT8(m_config.mode = 2)

  • dynamic input size(tiny_tensorrt_dyn_onnx)

BENCHMARK

window x64 (detect time)

model size gpu fp32 fp16 INT8 GPU(MB)(FP32/FP16/INT8)
yolov3 608x608 2080ti 28.14ms 19.79ms 18.53ms 1382/945/778
yolov4 320x320 2080ti 8.85ms 6.62ms 6.33ms 1130/1075/961
yolov4 416x416 2080ti 12.19ms 10.20ms 9.35ms 1740/1193/1066
yolov4 512x512 2080ti 15.63ms 12.66ms 12.19ms 1960/1251/1218
yolov4 608x608 2080ti 24.39ms 17.54ms 17.24ms 1448/1180/1128
yolov4 320x320 3070 9.70ms 7.30ms 6.37ms 1393/1366/1238
yolov4 416x416 3070 14.08ms 9.80ms 9.70ms 1429/1394/1266
yolov4 512x512 3070 18.87ms 13.51ms 13.51ms 1485/1436/1299
yolov4 608x608 3070 28.57ms 19.60ms 18.52ms 1508/1483/1326
yolov4 320x320 1070 18.52ms \ 12.82ms 686//442
yolov4 416x416 1070 27.03ms \ 20.83ms 1480//477
yolov4 512x512 1070 34.48ms \ 27.03ms 1546//515
yolov4 608x608 1070 50ms \ 35.71ms 1272//584
yolov4 320x320 1660TI 16.39ms 11.90ms 10.20ms 1034/863/787
yolov4 416x416 1660TI 23.25ms 17.24ms 13.70ms 1675/1227/816
yolov4 512x512 1660TI 29.41ms 24.39ms 21.27ms 1906/1322/843
yolov4 608x608 1660TI 43.48ms 34.48ms 26.32ms 1445/1100/950
yolov5 5s 640x640 2080ti 24.47ms 22.46ms 22.38ms 720/666/652
yolov5 5m 640x640 2080ti 30.61ms 24.02ms 23.73ms 851/728/679
yolov5 5l 640x640 2080ti 32.58ms 25.84ms 24.44ms 1154/834/738
yolov5 5x 640x640 2080ti 40.69ms 29.81ms 27.19ms 1530/1001/827
yolor_csp_x 512x512 2080ti 27.89ms 20.54ms 18.71ms 2373/1060/853
yolor_csp 512x512 2080ti 21.30ms 18.06ms 17.03ms 1720/856/763
YOLOX-Nano 416x416 2080ti 6.84ms 6.81ms 6.69ms 795/782/780
YOLOX-Tiny 416x416 2080ti 7.86ms 7.13ms 6.73ms 823/798/790
YOLOX-S 640x640 2080ti 19.51ms 16.62ms 16.33ms 940/836/794
YOLOX-M 640x640 2080ti 23.35ms 18.67ms 17.87ms 919/716/684
YOLOX-L 640x640 2080ti 28.25ms 20.36ms 19.24ms 1410/855/769
YOLOX-Darknet53 640x640 2080ti 29.95ms 20.38ms 18.91ms 1552/928/772
YOLOX-X 640x640 2080ti 40.40ms 22.95ms 21.99ms 1691/1187/1020
darknet53 224*224 2080ti 3.53ms 1.84ms 1.71ms 1005/769/658
darknet53 224*224 3070 4.29ms 2.16ms 1.75ms 1227/1017/951
resnet18-v2-7 224*224 2080ti 1.89ms 1.29ms 1.18ms 878/655/624
unet 512*512 2080ti 20.91ms 17.01ms 16.05ms 1334/766/744
retinaface_r50 512x512 2080ti 12.33ms 8.96ms 8.22ms 1189/745/678
mnet.25 512x512 2080ti 6.90ms 6.32ms 6.23ms 782/603/615

x64(inference / detect time)

model size gpu fp32(inference/detect) fp16(inference/detect) INT8(inference/detect) GPU(MB)(FP32/FP16/INT8)
centernet 512x512 2080ti 17.8ms/39.7ms 15.7ms/36.49ms 14.37ms/36.34ms 1839/1567/1563
centerface 640x640 2080ti 5.56ms/11.79ms 4.23ms/10.89ms / 854/646/640
centerface_bnmerged 640x640 2080ti 5.67ms/11.82ms 4.22ms/10.46ms / 850/651/645

windows10

Model and 3rdparty

model : https://drive.google.com/drive/folders/1KzBjmCOG9ghcq9L6-iqfz6QwBQq6Hl4_?usp=sharing or https://share.weiyun.com/td9CRDhW

3rdparty:https://drive.google.com/drive/folders/1SddUgQ5kGlv6dDGPqnVWZxgCoBY85rM2?usp=sharing or https://share.weiyun.com/WEZ3TGtb

API

struct Config
{
    std::string cfgFile = "configs/yolov3.cfg";

    std::string onnxModelpath = "configs/yolov3.onnx";

    std::string engineFile = "configs/yolov3.engine";

    std::string calibration_image_list_file = "configs/images/";

    std::vector<std::string> customOutput;

    int calibration_width = 0;

    int calibration_height = 0;
    
    int maxBatchSize = 1;

    int mode; //0,1,2

    //std::string calibration_image_list_file_txt = "configs/calibration_images.txt";
};

class YoloDectector
{
void init(Config config);
void detect(const std::vector<cv::Mat>& vec_image,
	std::vector<BatchResult>& vec_batch_result);
}

REFERENCE

https://github.com/onnx/onnx-tensorrt.git

https://github.com/NVIDIA/TensorRT/tree/master/samples/opensource/sampleDynamicReshape

https://github.com/NVIDIA-AI-IOT/deepstream_reference_apps

https://github.com/enazoe/yolo-tensorrt.git

https://github.com/zerollzeng/tiny-tensorrt.git

Contact

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].