Skip to content

Latest commit

 

History

History
25 lines (18 loc) · 491 Bytes

File metadata and controls

25 lines (18 loc) · 491 Bytes

timm_to_trt_python2

Polygraphy: A Deep Learning Inference Prototyping and Debugging Toolkit

How to Run

  1. generate .onnx from timm model
pip install torch
pip install onnx
pip install timm
pip install polygraphy
pip install numpy (2.0 below version)

python onnx_export.py
// a file 'resnet18_cuda.onnx' will be generated in onnx directory.
  1. build tensorrt model and run
python onnx2trt.py
// a file 'resnet18_fp16.engine' will be generated in engine directory.