Tensorrt: trtexec usage about --loadInputs

Created on 15 Jun 2020  Â·  3Comments  Â·  Source: NVIDIA/TensorRT

Hi everyone,
About trtexec, can any one show a sample usage about the param --loadInputs?
I found someone use the command like:
trtexec --onnx=test.onnx --dumpOutput --batch=1 --safe --loadInputs=Input:input.txt
but he didn't explain where the input.txt is and its data format.
Thank you.

question

All 3 comments

This should be the value of the incoming network,

Load input values from files (default = generate random inputs). Input names can be wrapped with single quotes (ex: 'Input:0')
Input values spec ::= Ival[","spec]
Ival ::= name":"file

Hi @WangXuanBT ,

I believe input.txt is just a binary file of the raw data. Since trtexec is generally used for benchmarking, people generally just use random data. If you wanted to test on real data, I suggest writing a short script using the TensorRT C++/Python APIs directly - this way you can handle all of the necessary pre-processing and post-processing as need be.

Is there new?

Was this page helpful?
0 / 5 - 0 ratings

Related issues

czs1886 picture czs1886  Â·  6Comments

AlphaJia picture AlphaJia  Â·  3Comments

sbbug picture sbbug  Â·  5Comments

mhansinger picture mhansinger  Â·  4Comments

anmol039w picture anmol039w  Â·  5Comments