Hello,
I’m running the Multi-Label Classification for Image Tagging project with resnet18-tangging-voc model in Jetson AGX Orin, after typing the command imagenet.py --model=resnet18-tagging-voc --topK=0 --threshold=0.25 "images/object_*.jpg" images/test/tagging_%i.jpg , the program ran for a while and report a Segmentation fault error. The command line output as followed:
imageNet -- loading classification network model from:
-- prototxt
-- model networks/ResNet18-Tagging-VOC/resnet18.onnx
-- class_labels networks/ResNet18-Tagging-VOC/labels.txt
-- input_blob 'input_0'
-- output_blob 'output_0'
-- batch_size 1
[TRT] TensorRT version 10.3.0
[TRT] loading NVIDIA plugins...
[TRT] Registered plugin creator - ::BatchedNMSDynamic_TRT version 1
[TRT] Registered plugin creator - ::BatchedNMS_TRT version 1
[TRT] Registered plugin creator - ::BatchTilePlugin_TRT version 1
[TRT] Registered plugin creator - ::Clip_TRT version 1
[TRT] Registered plugin creator - ::CoordConvAC version 1
[TRT] Registered plugin creator - ::CropAndResizeDynamic version 1
[TRT] Registered plugin creator - ::CropAndResize version 1
[TRT] Registered plugin creator - ::DecodeBbox3DPlugin version 1
[TRT] Registered plugin creator - ::DetectionLayer_TRT version 1
[TRT] Registered plugin creator - ::EfficientNMS_Explicit_TF_TRT version 1
[TRT] Registered plugin creator - ::EfficientNMS_Implicit_TF_TRT version 1
[TRT] Registered plugin creator - ::EfficientNMS_ONNX_TRT version 1
[TRT] Registered plugin creator - ::EfficientNMS_TRT version 1
[TRT] Could not register plugin creator - ::FlattenConcat_TRT version 1
[TRT] Registered plugin creator - ::GenerateDetection_TRT version 1
[TRT] Registered plugin creator - ::GridAnchor_TRT version 1
[TRT] Registered plugin creator - ::GridAnchorRect_TRT version 1
[TRT] Registered plugin creator - ::InstanceNormalization_TRT version 1
[TRT] Registered plugin creator - ::InstanceNormalization_TRT version 2
[TRT] Registered plugin creator - ::InstanceNormalization_TRT version 3
[TRT] Registered plugin creator - ::LReLU_TRT version 1
[TRT] Registered plugin creator - ::ModulatedDeformConv2d version 1
[TRT] Registered plugin creator - ::MultilevelCropAndResize_TRT version 1
[TRT] Registered plugin creator - ::MultilevelProposeROI_TRT version 1
[TRT] Registered plugin creator - ::MultiscaleDeformableAttnPlugin_TRT version 1
[TRT] Registered plugin creator - ::NMSDynamic_TRT version 1
[TRT] Registered plugin creator - ::NMS_TRT version 1
[TRT] Registered plugin creator - ::Normalize_TRT version 1
[TRT] Registered plugin creator - ::PillarScatterPlugin version 1
[TRT] Registered plugin creator - ::PriorBox_TRT version 1
[TRT] Registered plugin creator - ::ProposalDynamic version 1
[TRT] Registered plugin creator - ::ProposalLayer_TRT version 1
[TRT] Registered plugin creator - ::Proposal version 1
[TRT] Registered plugin creator - ::PyramidROIAlign_TRT version 1
[TRT] Registered plugin creator - ::Region_TRT version 1
[TRT] Registered plugin creator - ::Reorg_TRT version 2
[TRT] Registered plugin creator - ::Reorg_TRT version 1
[TRT] Registered plugin creator - ::ResizeNearest_TRT version 1
[TRT] Registered plugin creator - ::ROIAlign_TRT version 1
[TRT] Registered plugin creator - ::ROIAlign_TRT version 2
[TRT] Registered plugin creator - ::RPROI_TRT version 1
[TRT] Registered plugin creator - ::ScatterElements version 2
[TRT] Registered plugin creator - ::ScatterElements version 1
[TRT] Registered plugin creator - ::ScatterND version 1
[TRT] Registered plugin creator - ::SpecialSlice_TRT version 1
[TRT] Registered plugin creator - ::Split version 1
[TRT] Registered plugin creator - ::VoxelGeneratorPlugin version 1
[TRT] completed loading NVIDIA plugins.
[TRT] detected model format - ONNX (extension '.onnx')
[TRT] desired precision specified for GPU: FASTEST
[TRT] requested fasted precision for device GPU without providing valid calibrator, disabling INT8
[TRT] [MemUsageChange] Init CUDA: CPU +13, GPU +0, now: CPU 41, GPU 5301 (MiB)
[TRT] Trying to load shared library libnvinfer_builder_resource.so.10.3.0
[TRT] Loaded shared library libnvinfer_builder_resource.so.10.3.0
[TRT] [MemUsageChange] Init builder kernel library: CPU +927, GPU +754, now: CPU 1011, GPU 6099 (MiB)
[TRT] CUDA lazy loading is enabled.
[TRT] native precisions detected for GPU: FP32, FP16, INT8
[TRT] selecting fastest native precision for GPU: FP16
[TRT] found engine cache file /usr/local/bin/networks/ResNet18-Tagging-VOC/resnet18.onnx.1.1.100300.GPU.FP16.engine
[TRT] found model checksum /usr/local/bin/networks/ResNet18-Tagging-VOC/resnet18.onnx.sha256sum
[TRT] echo "$(cat /usr/local/bin/networks/ResNet18-Tagging-VOC/resnet18.onnx.sha256sum) /usr/local/bin/networks/ResNet18-Tagging-VOC/resnet18.onnx" | sha256sum --check --status
[TRT] model matched checksum /usr/local/bin/networks/ResNet18-Tagging-VOC/resnet18.onnx.sha256sum
[TRT] loading network plan from engine cache... /usr/local/bin/networks/ResNet18-Tagging-VOC/resnet18.onnx.1.1.100300.GPU.FP16.engine
[TRT] device GPU, loaded /usr/local/bin/networks/ResNet18-Tagging-VOC/resnet18.onnx
[TRT] Loaded engine size: 21 MiB
[TRT] Deserialization required 16109 microseconds.
[TRT] Total per-runner device persistent memory is 0
[TRT] Total per-runner host persistent memory is 120576
[TRT] Allocated device scratch memory of size 2408448
[TRT] - Runner scratch: 2408448 bytes
[TRT] [MemUsageChange] TensorRT-managed allocation in IExecutionContext creation: CPU +0, GPU +2, now: CPU 0, GPU 23 (MiB)
[TRT] CUDA lazy loading is enabled.
[TRT]
[TRT] CUDA engine context initialized on device GPU:
[TRT] -- layers 25
[TRT] -- maxBatchSize 1
[TRT] -- deviceMemory 2408448
[TRT] -- bindings 2
[TRT] binding 0
-- index 0
-- name 'input_0'
-- type Row major linear FP32 format (kLINEAR)
-- in/out INPUT
-- device DEVICE
-- # dims 4
-- dim #0 1
-- dim #1 3
-- dim #2 224
-- dim #3 224
[TRT] binding 1
-- index 1
-- name 'output_0'
-- type Row major linear FP32 format (kLINEAR)
-- in/out OUTPUT
-- device DEVICE
-- # dims 2
-- dim #0 1
-- dim #1 20
[TRT]
[TRT] binding to input 0 input_0 binding index: 0
[TRT] binding to input 0 input_0 dims (b=1 c=3 h=224 w=224) size=602112
[TRT] binding to output 0 output_0 binding index: 1
[TRT] binding to output 0 output_0 dims (b=1 c=1 h=20 w=0) size=80
Segmentation fault (core dumped)
My Jetpack version is 6.1, python version is 3.10.12, the imagenet.py is ran in the folder which is cloned from the jetson inference project in Github. What should I do for a correct result?