I have read the guide on converting TensorFlow model to tensorRT: https://docs.nvidia.com/deeplearning/sdk/tensorrt-developer-guide/index.html#import_tf_python. In the last step, step 5, the code example is given as:
with builder = trt.Builder(TRT_LOGGER) as builder, builder.create_network() as network, trt.UffParser() as parser:
parser.register_input("Placeholder", (1, 28, 28))
parser.register_output("fc2/Relu")
parser.parse(model_file, network)
-
I have looked up UFF parser documentation but it is still not clear to me what the input to “register_output” must be. can it be any name – like how we create variable names – or must it be from a specific list of valid operation names?
-
for “register_input(name, shape, order)”, what must the name of the input be? can it be any name that I chose fit or must it be a specific name of a node? And is there a way to make the shape of the input variable? For instance, if I am trying to convert speech to text or text to speech models to TensorRt, the inputs to STT and TTS is going to be variable.