Please provide complete information as applicable to your setup.
• Hardware Platform (Jetson / GPU): NVIDIA RTX A5000
• DeepStream Version: 6.3
• TensorRT Version: 8.6.1.6
• CUDA Version: 12.2
• NVIDIA GPU Driver Version (valid for GPU only): 535.129.03
• Issue Type( questions, new requirements, bugs): bugs
• How to reproduce the issue ? (This is for bugs. Including which sample app is using, the configuration files content, the command line used and other details for reproducing)
• Requirement details( This is for new requirement. Including the module name-for which plugin or for which sample application, the function description)
Hello,
I’m trying to use an onnx file in deepstream but it fails to build trt engine with batch size greater than one with the following error
cuda_codegen.hpp:604: DCHECK(it != shape_name_map_.end()) failed. Shape tensor is not found in shape_name_map: __mye85697-HOST-(i64[1][1]so[0]p[0], mem_prop=100)
cuda_codegen.hpp:604: DCHECK(it != shape_name_map_.end()) failed. Shape tensor is not found in shape_name_map: __mye85697-HOST-(i64[1][1]so[0]p[0], mem_prop=100)
cuda_codegen.hpp:604: DCHECK(it != shape_name_map_.end()) failed. Shape tensor is not found in shape_name_map: __mye85660-HOST-(i64[1][1]so[0]p[0], mem_prop=100)
ERROR: [TRT]: 10: Could not find any implementation for node {ForeignNode[onnx::MatMul_8444 + (Unnamed Layer* 1931) [Shuffle].../ScatterND_14]}.
ERROR: [TRT]: 10: [optimizer.cpp::computeCosts::3869] Error Code 10: Internal Error (Could not find any implementation for node {ForeignNode[onnx::MatMul_8444 + (Unnamed Layer* 1931) [Shuffle].../ScatterND_14]}.)
ERROR: ../nvdsinfer/nvdsinfer_model_builder.cpp:1124 Build engine failed from config file
ERROR: ../nvdsinfer/nvdsinfer_model_builder.cpp:816 failed to build trt engine.
0:05:14.693655320 332 0x5624d87c0090 ERROR nvinfer gstnvinfer.cpp:676:gst_nvinfer_logger:<nvinfer0> NvDsInferContext[UID 1]: Error in NvDsInferContextImpl::buildModel() <nvdsinfer_context_impl.cpp:2022> [UID = 1]: build engine file failed
0:05:14.856545171 332 0x5624d87c0090 ERROR nvinfer gstnvinfer.cpp:676:gst_nvinfer_logger:<nvinfer0> NvDsInferContext[UID 1]: Error in NvDsInferContextImpl::generateBackendContext() <nvdsinfer_context_impl.cpp:2108> [UID = 1]: build backend context failed
0:05:14.856564079 332 0x5624d87c0090 ERROR nvinfer gstnvinfer.cpp:676:gst_nvinfer_logger:<nvinfer0> NvDsInferContext[UID 1]: Error in NvDsInferContextImpl::initialize() <nvdsinfer_context_impl.cpp:1282> [UID = 1]: generate backend failed, check config file settings
0:05:14.856579200 332 0x5624d87c0090 WARN nvinfer gstnvinfer.cpp:898:gst_nvinfer_start:<nvinfer0> error: Failed to create NvDsInferContext instance
0:05:14.856582381 332 0x5624d87c0090 WARN nvinfer gstnvinfer.cpp:898:gst_nvinfer_start:<nvinfer0> error: Config file path: /build/TestModels/cltr/config_infer_crowd_count_cltr.txt, NvDsInfer Error: NVDSINFER_CONFIG_FAILED
I increased workspace-size to 6144 but it didn’t fix the issue.
I also did two other experiments with different deepstream and TensorRT version
Experiment #1
Using nvcr.io/nvidia/deepstream:6.3-samples docker image
-
DeepStream Version: 6.3
-
TensorRT Version: 8.5.3.1
The engine build failed with the same error when using the default workspace-size but worked when setting workspace-size to 6144.
Experiment #2
Using nvcr.io/nvidia/deepstream:6.4-samples-multiarch docker image
-
DeepStream Version: 6.4
-
TensorRT Version: 8.6.1.6
The engine build failed with the same error when using the default workspace-size and even when setting workspace-size to 6144.
You can find the model here.