Need help with Pytorch-Model-to-TensorRT?
Click the “chat” button below for chat support from the developer who created it, or find similar developers for support.

About the developer

modricwang
134 Stars 34 Forks GNU General Public License v3.0 13 Commits 7 Opened issues

Services available

!
?

Need anything else?

Contributors list

# 432,449
Python
6 commits
# 454,430
Machine...
C++
data-sc...
Python
4 commits
# 271,582
C#
Shell
MATLAB
pytorch
1 commit

Pytorch-Model-to-TensorRT

Convert a Pytorch model to TensorRT engin (optional: int8 engin)

Required:

Python packages: in

requirements.txt

External:

  • CUDA == 9.0
  • CUDNN == 7.3.1
  • TensorRT == 4.0.2.6 link

Data And Checkpoint Prepare

You should prepare data and model weights in like this way: ``` project
│ └───data │ │ test.txt │ │ fake-test.txt │ │ images │
└───checkpoint │ model_best.pth

The list of test file should follow this format:
```text
file0,label0
file1,label1
... ...

Or you can download the example from BaiduYun

Convert step:

python main.py

We use cookies. If you continue to browse the site, you agree to the use of cookies. For more information on our use of cookies please see our Privacy Policy.