I’m using trt API to generate an trt engine from trained SSD model with ONNX format.
running /usr/src/tensorrt/bin/trtexec --onnx=~/modifed_SSD_model_ops13.onnx raised the below error. I was wondering if you could help me to fix it.
[11/19/2020-16:44:47] [I] === Model Options ===
[11/19/2020-16:44:47] [I] Format: ONNX
[11/19/2020-16:44:47] [I] Model: /home/bl/Desktop/Workplace/projects/Meat_stag1/SSD/modifed_SSD_model_ops13.onnx
[11/19/2020-16:44:47] [I] Output:
[11/19/2020-16:44:47] [I] === Build Options ===
[11/19/2020-16:44:47] [I] Max batch: 1
[11/19/2020-16:44:47] [I] Workspace: 16 MB
[11/19/2020-16:44:47] [I] minTiming: 1
[11/19/2020-16:44:47] [I] avgTiming: 8
[11/19/2020-16:44:47] [I] Precision: FP32
[11/19/2020-16:44:47] [I] Calibration:
[11/19/2020-16:44:47] [I] Safe mode: Disabled
[11/19/2020-16:44:47] [I] Save engine:
[11/19/2020-16:44:47] [I] Load engine:
[11/19/2020-16:44:47] [I] Builder Cache: Enabled
[11/19/2020-16:44:47] [I] NVTX verbosity: 0
[11/19/2020-16:44:47] [I] Inputs format: fp32:CHW
[11/19/2020-16:44:47] [I] Outputs format: fp32:CHW
[11/19/2020-16:44:47] [I] Input build shapes: model
[11/19/2020-16:44:47] [I] Input calibration shapes: model
[11/19/2020-16:44:47] [I] === System Options ===
[11/19/2020-16:44:47] [I] Device: 0
[11/19/2020-16:44:47] [I] DLACore:
[11/19/2020-16:44:47] [I] Plugins:
[11/19/2020-16:44:47] [I] === Inference Options ===
[11/19/2020-16:44:47] [I] Batch: 1
[11/19/2020-16:44:47] [I] Input inference shapes: model
[11/19/2020-16:44:47] [I] Iterations: 10
[11/19/2020-16:44:47] [I] Duration: 3s (+ 200ms warm up)
[11/19/2020-16:44:47] [I] Sleep time: 0ms
[11/19/2020-16:44:47] [I] Streams: 1
[11/19/2020-16:44:47] [I] ExposeDMA: Disabled
[11/19/2020-16:44:47] [I] Spin-wait: Disabled
[11/19/2020-16:44:47] [I] Multithreading: Disabled
[11/19/2020-16:44:47] [I] CUDA Graph: Disabled
[11/19/2020-16:44:47] [I] Skip inference: Disabled
[11/19/2020-16:44:47] [I] Inputs:
[11/19/2020-16:44:47] [I] === Reporting Options ===
[11/19/2020-16:44:47] [I] Verbose: Enabled
[11/19/2020-16:44:47] [I] Averages: 10 inferences
[11/19/2020-16:44:47] [I] Percentile: 99
[11/19/2020-16:44:47] [I] Dump output: Disabled
[11/19/2020-16:44:47] [I] Profile: Disabled
[11/19/2020-16:44:47] [I] Export timing to JSON file:
[11/19/2020-16:44:47] [I] Export output to JSON file:
[11/19/2020-16:44:47] [I] Export profile to JSON file:
[11/19/2020-16:44:47] [I]
[11/19/2020-16:44:47] [V] [TRT] Registered plugin creator - ::GridAnchor_TRT version 1
[11/19/2020-16:44:47] [V] [TRT] Registered plugin creator - ::NMS_TRT version 1
[11/19/2020-16:44:47] [V] [TRT] Registered plugin creator - ::Reorg_TRT version 1
[11/19/2020-16:44:47] [V] [TRT] Registered plugin creator - ::Region_TRT version 1
[11/19/2020-16:44:47] [V] [TRT] Registered plugin creator - ::Clip_TRT version 1
[11/19/2020-16:44:47] [V] [TRT] Registered plugin creator - ::LReLU_TRT version 1
[11/19/2020-16:44:47] [V] [TRT] Registered plugin creator - ::PriorBox_TRT version 1
[11/19/2020-16:44:47] [V] [TRT] Registered plugin creator - ::Normalize_TRT version 1
[11/19/2020-16:44:47] [V] [TRT] Registered plugin creator - ::RPROI_TRT version 1
[11/19/2020-16:44:47] [V] [TRT] Registered plugin creator - ::BatchedNMS_TRT version 1
[11/19/2020-16:44:47] [V] [TRT] Registered plugin creator - ::FlattenConcat_TRT version 1
[11/19/2020-16:44:47] [V] [TRT] Registered plugin creator - ::CropAndResize version 1
[11/19/2020-16:44:47] [V] [TRT] Registered plugin creator - ::DetectionLayer_TRT version 1
[11/19/2020-16:44:47] [V] [TRT] Registered plugin creator - ::Proposal version 1
[11/19/2020-16:44:47] [V] [TRT] Registered plugin creator - ::ProposalLayer_TRT version 1
[11/19/2020-16:44:47] [V] [TRT] Registered plugin creator - ::PyramidROIAlign_TRT version 1
[11/19/2020-16:44:47] [V] [TRT] Registered plugin creator - ::ResizeNearest_TRT version 1
[11/19/2020-16:44:47] [V] [TRT] Registered plugin creator - ::Split version 1
[11/19/2020-16:44:47] [V] [TRT] Registered plugin creator - ::SpecialSlice_TRT version 1
[11/19/2020-16:44:47] [V] [TRT] Registered plugin creator - ::InstanceNormalization_TRT version 1
[libprotobuf ERROR google/protobuf/text_format.cc:298] Error parsing text-format onnx2trt_onnx.ModelProto: 1:1: Invalid control characters encountered in text.
[libprotobuf ERROR google/protobuf/text_format.cc:298] Error parsing text-format onnx2trt_onnx.ModelProto: 1:3: Expected identifier, got: :
Failed to parse ONNX model from file/home/bl/Desktop/Workplace/projects/Meat_stag1/SSD/modifed_SSD_model_ops13.onnx
[11/19/2020-16:44:48] [E] [TRT] Network must have at least one output
[11/19/2020-16:44:48] [E] [TRT] Network validation failed.
[11/19/2020-16:44:48] [E] Engine creation failed
[11/19/2020-16:44:48] [E] Engine set up failed
&&&& FAILED TensorRT.trtexec # /usr/src/tensorrt/bin/trtexec --onnx=/home/bl/Desktop/Workplace/projects/Meat_stag1/SSD/modifed_SSD_model_ops13.onnx --verbose
thanks