TensorRT icon indicating copy to clipboard operation
TensorRT copied to clipboard

TensorRT 8.5 deprecated functions

Open lioriz1 opened this issue 1 year ago • 2 comments

I updated my TensorRT version to 8.5 and got warnings about deprecated functions, opened question on NVIDIA developer forums tensorrt-8-5-depecated-functions.

I used void nvinfer1::IRuntime::destroy() and it Deprecated interface will be removed in TensorRT 10.0. Is this function not needed and can I remove it from my code?

Code:

IRuntime *runtime = createInferRuntime(gLogger);
ICudaEngine *engine = runtime->deserializeCudaEngine(trtModelStream_.data(), trtModelStream_.size(), nullptr);
runtime->destroy();

Should convert to:

IRuntime *runtime = createInferRuntime(gLogger);
ICudaEngine *engine = runtime->deserializeCudaEngine(trtModelStream_.data(), trtModelStream_.size());

Just remove runtime->destroy();?

lioriz1 avatar Jan 22 '24 09:01 lioriz1

use delete runtime or use smart pointer.

zerollzeng avatar Jan 24 '24 13:01 zerollzeng

Deprecated interface will be removed in TensorRT 10.0.

it means if you compile the code with TRT 10.0, you will get compile error.

zerollzeng avatar Jan 24 '24 13:01 zerollzeng

closing since no activity for more than 3 weeks, thanks all!

ttyio avatar Mar 05 '24 17:03 ttyio