Skip to content
This repository has been archived by the owner on Dec 7, 2022. It is now read-only.

wnen I run python onnx2trt.py,it occurs a mistake #1

Open
xuhui1994 opened this issue Dec 17, 2021 · 6 comments
Open

wnen I run python onnx2trt.py,it occurs a mistake #1

xuhui1994 opened this issue Dec 17, 2021 · 6 comments

Comments

@xuhui1994
Copy link

image

@xuhui1994
Copy link
Author

image

sorry, it's nothing with onnx_trt.py, It occurs a mistake above when I run python infer_trt.py.

@k9ele7en
Copy link
Owner

Hi @xuhui1994 , I have noted that infer code using TRT are currently return wrong output. I don't have time to debug it right away, but will do it soon. Thanks.
image

@xuhui1994
Copy link
Author

Hi @xuhui1994 , I have noted that infer code using TRT are currently return wrong output. I don't have time to debug it right away, but will do it soon. Thanks. image

yes, what you say above is right. How can I get a correct ouput when run infer_trt.py ?Can you have a good solution?

@k9ele7en
Copy link
Owner

k9ele7en commented Dec 17, 2021

Yes, I have worked on it a lot, a problem is in the inference step on GPU (load RT engine, host<->device data moving...). I know that because when I using the same RT engine converted from this to put in Triton Server's Model Repository, it works well.
It would be nice if you can have a look at Tensor RT inference example and debug the code. If you have installed TensorRT, example are in path: /usr/src/tensorrt/samples/. Also checkout this:https://docs.nvidia.com/deeplearning/tensorrt/sample-support-guide/index.html#mnist_sample. If the code run well, you can post a PR so that people can find useful later. Thanks @xuhui1994

@k9ele7en
Copy link
Owner

@xuhui1994 TensorRT also update new lib called Torch-TensorRT that flexible build and load engine right in python code, you can check this out, I'm gonna update the repo with this method soon... https://developer.nvidia.com/blog/accelerating-inference-up-to-6x-faster-in-pytorch-with-torch-tensorrt/

@xuhui1994
Copy link
Author

xuhui1994 commented Dec 17, 2021 via email

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants