DRIVE OS Version: Drive OS 6.0.10
Target: aarch64
**
Issue Description:** We are trying to develop model to run on DLA. For this all the supported DLA operations are used.
model.dla.bin.json
{
"dataConditionerParams": {
"meanValue": [123.675, 116.28, 103.53],
"stdev": [58.395, 57.12, 57.375],
"splitPlanes": true,
"pixelScaleCoefficient": 1.0,
"ignoreAspectRatio": true,
"doPerPlaneMeanNormalization": false
}
}
command used for tensorRt optimization tool:
/usr/local/driveworks/tools/dnn/tensorRT_optimization --modelType=onnx --onnxFile=<path/to/model.onnx> --out=<path/to/model.dla.bin> --useDLA=1 --inputIOFormats=fp16:chw --outputIOFormats=fp16:chw
logs:
dla_io.log (78.7 KB)
However, when inference script is ran (based on sample_dnn_sensor) this error is found:
[08-06-2026 12:20:43] Driveworks exception thrown: DW_INVALID_ARGUMENT: cudlaModuleLoadFromMemory : load loadable failed. 7
ERROR: [2026-06-08 13:20:43] DW Error DW_INVALID_ARGUMENT executing DW function:
dwDNN_initializeTensorRTFromFileWithEngineId( &dnn, modelPath.c_str(), nullptr, processor, dlaEngine, ctx)
at /usr/local/driveworks/samples/src/DLALaneNET/main.cpp:367
While the model has been successfully converted for DLA, while dwDNN_initializeTensorRTFromFileWithEngineId fails to initialize. Any insights about this would be appreciated.
Dear @atharv.sharma ,
What is the dwProcessorType used in dwDNN_initializeTensorRTFromFileWithEngineId and dlaEngine?
Is it DW_PROCESSOR_TYPE_CUDLA and 0?
If so, any dummy model can be shared to repro and investigate?
for platform VIBRANTE dwProcessorType is set as DW_PROCESSOR_TYPE_CUDLA and DLA engine has been set to 0.
sample code:
const dwProcessorType processor = useCuDla ? DW_PROCESSOR_TYPE_CUDLA : DW_PROCESSOR_TYPE_GPU;
std::cout << "dwProcessorType: " << processor << "\n";
CHECK_DW_ERROR(dwDNN_initializeTensorRTFromFileWithEngineId(
&dnn, modelPath.c_str(), nullptr, processor, dlaEngine, ctx));
CHECK_DW_ERROR(dwDNN_setCUDAStream(stream, dnn));
Model shared over message
Dear @SivaRamaKrishnaNV We found out the that the workflow for DLA compatible models to be accelerated in the following manner :
- use `
trtexec` natively with the onnx model to generate a dla loadable variant of the model
- use `
tensorRT_optimzation` tool to take the loadable compiled with the compiler to wrap it for DriveWorks DNN APIs,
- use processor type DW_PROCESSOR_TYPE_DLA_0/DLA_1/cuDLA with the APIs to run the wrapped model with the APIs on DLA Processor.
commands used -
sudo ./trtexec --onnx=/home/benchdev2/DLALaneNet/dla_lanenet_latest.onnx --useDLACore=0 --buildDLAStandalone --fp16 --inputIOFormats=fp16:dla_hwc4 --outputIOFormats=fp16:chw16 --directIO --saveEngine=/home/benchdev2/DLALaneNet/lanenet.loadable
tensorRT_optimization --modelType=onnx --onnxFile=dla_lanenet_latest.onnx --useDLA=1 \
--dlaLoadable=lanenet.loadable --out=lanenet_newBuild.dla.bin
Application output -
benchdev2@tegra-ubuntu:/usr/local/driveworks/bin$ ./dla_lanenet4 --image=/home/benchdev2/DLALaneNet/1.png --model=/home/benchdev2/DLALaneNet/lanenet_newBuild.dla.bin --device=dla --iterations=10000 --verbose=1
[08-06-2026 18:14:04] Platform: Detected Drive Orin P3710
[08-06-2026 18:14:04] Adding variable DW_Base:DW_Version
[08-06-2026 18:14:04] Added variable DW_Base:DW_Version
[08-06-2026 18:14:04] Platform: number of GPU devices detected 1
[08-06-2026 18:14:04] Platform: currently selected GPU device 0, Resource Data Dir: trt_08_06_12_04, Arch: ga10b
[08-06-2026 18:14:04] Platform: currently selected GPU device integrated ID 0
[08-06-2026 18:14:04] CUDLAEngine:getDLACount: CUDLA version is = 1004000
[08-06-2026 18:14:04] CUDLAEngine:getDLACount: Number of DLA devices = 2
[08-06-2026 18:14:04] Context::mountResourceCandidateDataPath resource FAILED to mount from './resources': VirtualFileSystem: Failed to mount './resources/resources.pak'
[08-06-2026 18:14:04] Context::mountResourceCandidateDataPath resource FAILED to mount from '/usr/local/driveworks-5.20/bin/data': VirtualFileSystem: Failed to mount '/usr/local/driveworks-5.20/bin/data/resources.pak'
[08-06-2026 18:14:04] Context::findDataRootInPathWalk data/DATA_ROOT found at: /usr/local/driveworks-5.20/data
[08-06-2026 18:14:04] Context::mountResourceCandidateDataPath resource FAILED to mount from '/usr/local/driveworks-5.20/data': VirtualFileSystem: Failed to mount '/usr/local/driveworks-5.20/data/resources.pak'
[08-06-2026 18:14:04] Context::findDataRootInPathWalk data/DATA_ROOT found at: /usr/local/driveworks-5.20/data
[08-06-2026 18:14:04] Context::mountResourceCandidateDataPath resource FAILED to mount from '/usr/local/driveworks-5.20/data': VirtualFileSystem: Failed to mount '/usr/local/driveworks-5.20/data/resources.pak'
[08-06-2026 18:14:04] Context::findResourcesPackageInPathWalk: Could not find ./resources/resources.pak in upto 7 parent directories from /usr/local/driveworks-5.20/targets/aarch64-Linux/lib/libdw_base.so.5.20
[08-06-2026 18:14:04] Context::findResourcesPackageInPathWalk: Could not find ./resources/resources.pak in upto 7 parent directories from /usr/local/driveworks-5.20/targets/aarch64-Linux/lib/libdw_base.so.5.20
[08-06-2026 18:14:04] SDK: No resources(.pak) mounted, some modules will not function properly
[08-06-2026 18:14:04] [08-06-2026 18:14:04] Initialize DriveWorks SDK v5.20.24
[08-06-2026 18:14:04] [08-06-2026 18:14:04] Release build with GNU 9.3.0 from buildbrain-branch-0-gb4c0b405b15 against Drive PDK v6.0.10.0
[cfg ] device : dla (DLA_0)
[cfg ] dla-engine : 0
[cfg ] image : /home/benchdev2/DLALaneNet/1.png
[cfg ] model : /home/benchdev2/DLALaneNet/lanenet_newBuild.dla.bin
[cfg ] output : /home/benchdev2/DLALaneNet/dla_preview.png
[cfg ] iterations : 10000
[cfg ] verbose : yes
[cfg ] verify : run `tegrastats` in another terminal; GR3D (GPU) stays idle if on DLA
[08-06-2026 18:14:05] DNN: Initializing network on cuDLA 0.
[08-06-2026 18:14:05] CUDLAEngine:getDLACount: CUDLA version is = 1004000
[08-06-2026 18:14:05] CUDLAEngine:getDLACount: Number of DLA devices = 2
[08-06-2026 18:14:05] ========== DLA Device 0 Attributes ==========
[08-06-2026 18:14:05] UVA supported = 0
[08-06-2026 18:14:05] Device version = 2
[08-06-2026 18:14:05] Device 0 Check PASSED
[08-06-2026 18:14:05] CUDLALoadable: it is DLA Header!
[08-06-2026 18:14:05] TENSOR DESCRIPTOR
[08-06-2026 18:14:05] TENSOR NAME : input'
[08-06-2026 18:14:05] size: 4194304
[08-06-2026 18:14:05] dims: [1, 4, 512, 1024]
[08-06-2026 18:14:05] data fmt: NHWC
[08-06-2026 18:14:05] data type: HALF
[08-06-2026 18:14:05] data category: IMAGE
[08-06-2026 18:14:05] pixel fmt: 8
[08-06-2026 18:14:05] pixel mapping: 0
[08-06-2026 18:14:05] stride[0]: 2
[08-06-2026 18:14:05] stride[1]: 8192
[08-06-2026 18:14:05] stride[2]: 0
[08-06-2026 18:14:05] stride[3]: 0
[08-06-2026 18:14:05] TENSOR DESCRIPTOR
[08-06-2026 18:14:05] TENSOR NAME : logits'
[08-06-2026 18:14:05] size: 16777216
[08-06-2026 18:14:05] dims: [1, 2, 512, 1024]
[08-06-2026 18:14:05] data fmt: NCxHWx
[08-06-2026 18:14:05] data type: HALF
[08-06-2026 18:14:05] data category: FEATURE
[08-06-2026 18:14:05] pixel fmt: 36
[08-06-2026 18:14:05] pixel mapping: 0
[08-06-2026 18:14:05] stride[0]: 2
[08-06-2026 18:14:05] stride[1]: 32768
[08-06-2026 18:14:05] stride[2]: 16777216
[08-06-2026 18:14:05] stride[3]: 0
[08-06-2026 18:14:05] DNN: Metadata json file could not be found. Metadata has been filled with default values. Please place <network_filename>.json in the same directory as the network file if custom metadata is needed.
[08-06-2026 18:14:05] Driveworks exception thrown: DW_DNN_INVALID_MODEL: DNN: Unexpected input blob.
ERROR: [2026-06-08 19:14:05] DW Error DW_DNN_INVALID_MODEL executing DW function:
dwDNN_initializeTensorRTFromFileWithEngineId( &dnn, modelPath.c_str(), nullptr, processor, dlaEngine, ctx)
at /usr/local/driveworks/samples/src/DLALaneNet/main.cpp:426
[08-06-2026 18:14:05] [08-06-2026 18:14:05] Releasing Driveworks SDK Context
benchdev2@tegra-ubuntu:/usr/local/driveworks/bin$
Dear @SivaRamaKrishnaNV Here’s what issue is -
when native `trtexec` is used to compile the model for DLA hardware we see a reformat layer being added to reformat the inputs and outputs blob, and so when the ``tensorRT_optimzation` tool is used to wrap it for DNN APis, we see this
benchdev2@tegra-ubuntu:/usr/local/driveworks/tools/dnn$ ./tensorRT_optimization --modelType=onnx --onnxFile=/home/benchdev2/DLALaneNet/dla_lanenet_latest.onnx --useDLA=1 --dlaLoadable=/home/benchdev2/DLALaneNet/lanenet.loadable --out=/home/benchdev2/DLALaneNet/lanenet_newBuild.dla.bin
[08-06-2026 18:07:43] DNNGenerator: Initializing TensorRT generation on model /home/benchdev2/DLALaneNet/dla_lanenet_latest.onnx.
[08-06-2026 18:07:43] DNNGenerator: Input “input”: 1x3x512x1024
[08-06-2026 18:07:43] DNNGenerator: Output “logits”: 1x2x512x1024
[08-06-2026 18:07:43] DNNGenerator: DLA loadable is already built!
[08-06-2026 18:07:43] DNN: Initializing network on cuDLA 0.
[08-06-2026 18:07:43] CUDLAEngine:getDLACount: CUDLA version is = 1004000
[08-06-2026 18:07:43] CUDLAEngine:getDLACount: Number of DLA devices = 2
[08-06-2026 18:07:43] ========== DLA Device 0 Attributes ==========
[08-06-2026 18:07:43] UVA supported = 0
[08-06-2026 18:07:43] Device version = 2
[08-06-2026 18:07:43] Device 0 Check PASSED
[08-06-2026 18:07:43] CUDLALoadable: it is DLA Header!
[08-06-2026 18:07:43] TENSOR DESCRIPTOR
[08-06-2026 18:07:43] TENSOR NAME : input’
[08-06-2026 18:07:43] size: 4194304
[08-06-2026 18:07:43] dims: [1, 4, 512, 1024]
[08-06-2026 18:07:43] data fmt: NHWC
[08-06-2026 18:07:43] data type: HALF
[08-06-2026 18:07:43] data category: IMAGE
[08-06-2026 18:07:43] pixel fmt: 8
[08-06-2026 18:07:43] pixel mapping: 0
[08-06-2026 18:07:43] stride[0]: 2
[08-06-2026 18:07:43] stride[1]: 8192
[08-06-2026 18:07:43] stride[2]: 0
[08-06-2026 18:07:43] stride[3]: 0
[08-06-2026 18:07:43] TENSOR DESCRIPTOR
[08-06-2026 18:07:43] TENSOR NAME : logits’
[08-06-2026 18:07:43] size: 16777216
[08-06-2026 18:07:43] dims: [1, 2, 512, 1024]
[08-06-2026 18:07:43] data fmt: NCxHWx
[08-06-2026 18:07:43] data type: HALF
[08-06-2026 18:07:43] data category: FEATURE
[08-06-2026 18:07:43] pixel fmt: 36
[08-06-2026 18:07:43] pixel mapping: 0
[08-06-2026 18:07:43] stride[0]: 2
[08-06-2026 18:07:43] stride[1]: 32768
[08-06-2026 18:07:43] stride[2]: 16777216
[08-06-2026 18:07:43] stride[3]: 0
[08-06-2026 18:07:43] DNN: Metadata json file could not be found. Metadata has been filled with default values. Please place <network_filename>.json in the same directory as the network file if custom metadata is needed.
[08-06-2026 18:07:43] [08-06-2026 18:07:43] Releasing Driveworks SDK Context
Error: DW_DNN_INVALID_MODEL: DNN: Unexpected input blob.
benchdev2@tegra-ubuntu:/usr/local/driveworks/tools/dnn$
Can you suggest how to fix this? Do we need to reformatt the boundaries of the onnx model ? (provided to you by @atharv.sharma over PM)
Dear @SivaRamaKrishnaNV any updates about this?
Dear @ashwin.nanda ,
Thank you for sharing model. Let me check and getback to you.
Dear @atharv.sharma @ashwin.nanda ,
Were you able to generate TRT model using tensorRT_optimzation tool with the shared ONNX file? I notice build issues.
Dear @SivaRamaKrishnaNV We were able to generate tensorrt compiled model by both trtexec binary and dw-tensorRT_optimization tool :
The command used was
./tensorRT_optimization --modelType=onnx --onnxFile=/home/benchdev2/DLALaneNet/dla_lanenet_latest.onnx --inputIOFormats=fp16:chw16 --outputIOFormats=fp16:chw16 --useDLA=1 --out=/home/benchdev2/DLALaneNet/lanenet_builtbyTool.dla.bin
Please also refer this thread for detailed issue : I have pasted all the possible debugging from my side.
It looks like some issue with cuDLA lib calls when loading the model. I have filed internal bug to track this issue. I will keep you posted once I have an update.
Dear @SivaRamaKrishnaNV, any updates about this?
It is noticed that tensorRT_optimization tool generated DLA model does not seems to work with DNN APIs. Please use cuDLA APIs directly to run model on DLA.