Skip to content

❓ [Question] How to convert nvinfer1::ITensor into at::tensor? #580

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
JuncFang-git opened this issue Aug 16, 2021 · 1 comment
Closed
Labels
question Further information is requested

Comments

@JuncFang-git
Copy link

❓ Question

Hi,
How to convert nvinfer1::ITensor into at::tensor? Like #146

What you have already tried

I want to do some operations use libtorch on the nvinfer1::ITensor. So, can I convert nvinfer1::ITensor into at::tensor? Or I must write a custom converter with the libtorch function?
@xsacha @aaronp24 @itsliupeng @lukeyeager @elezar

@JuncFang-git JuncFang-git added the question Further information is requested label Aug 16, 2021
@narendasan
Copy link
Collaborator

You cant really convert ITensors into at::Tensors, ITensors are just edges between layers in the tensorrt and have no concrete value. You can set that ITensor as an output and feed it to some Torch code outside of the TRTorch program

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants