Undefined Symbol Error in Custom YOLO Plugin on DeepStream 7.1 with GPU

Details of Setup

  • Hardware Platform (Jetson / GPU): GPU
  • DeepStream Version: 7.1.0
  • TensorRT Version: 10.7.0.23-1+cuda12.6 amd64
  • NVIDIA GPU Driver Version (valid for GPU only): 560.35.03 (CUDA Version: 12.6)

Issue Type: Bug

Description of Issue:
I encounter a symbol lookup error when running a custom-built DeepStream YOLO plugin. The error log is as follows:

deepstream-app: symbol lookup error: /home/ds_tracker/workspace/DeepStream-Yolo/build/libnvdsinfer_custom_impl_Yolo.so: undefined symbol: _ZNSt12experimental10filesystem2v17__cxx114path14_M_split_cmptsEv

The issue arises during the engine creation phase:

NvDsInferContext[UID 1]: Trying to create engine from model files

Configuration Details:
The relevant configuration files are:

  1. deepstream_app_config.txt:

    • config-file points to config_infer_primary_yoloV11.txt.
    • Full configuration:
    [application]
    enable-perf-measurement=1
    perf-measurement-interval-sec=5
    ...  
    

    Full file attached for reference.

  2. config_infer_primary_yoloV11.txt:

    • ONNX file: yolo11m_yolo11.onnx
    • Custom library path: /home/ds_tracker/workspace/DeepStream-Yolo/build/libnvdsinfer_custom_impl_Yolo.so
    • Custom functions:
      • parse-bbox-func-name: NvDsInferParseYolo
      • engine-create-func-name: NvDsInferYoloCudaEngineGet

Reproduction Steps:

  1. Build the custom library libnvdsinfer_custom_impl_Yolo.so using the provided source code.
  2. Configure the application using the attached files.
  3. Run deepstream-app -c deepstream_app_config.txt.

Additional Notes:

  • The application halts at the engine-building stage.
  • I suspect the issue might be linked to C++ standard library compatibility, as the undefined symbol references experimental filesystem.

Request:
Could you provide guidance on resolving the undefined symbol issue? Specifically:

  • Are there specific build flags or dependencies required for libnvdsinfer_custom_impl_Yolo.so?
  • Does DeepStream 7.1 have compatibility constraints with certain GCC versions or C++ filesystem implementations?

Attachments:

  1. deepstream_app_config.txt

[application]
enable-perf-measurement=1
perf-measurement-interval-sec=5

[tiled-display]
enable=0
rows=1
columns=1
width=1280
height=720
gpu-id=0
nvbuf-memory-type=0

[source0]
enable=1
type=3
uri=file:///opt/nvidia/deepstream/deepstream/samples/streams/sample_1080p_h264.mp4
num-sources=1
gpu-id=0
cudadec-memtype=0
drop-frame-interval=0 # Add this
eos-timeout=5000000 # Add this (5 seconds timeout)

[sink0]
enable=1
type=3
sync=1
gpu-id=0
nvbuf-memory-type=0
output-file=output.mp4

[osd]
enable=0
gpu-id=0
border-width=5
text-size=15
text-color=1;1;1;1;
text-bg-color=0.3;0.3;0.3;1
font=Serif
show-clock=0
clock-x-offset=800
clock-y-offset=820
clock-text-size=12
clock-color=1;0;0;0
nvbuf-memory-type=0

[streammux]
gpu-id=0
live-source=0
width=1920
height=1080
enable-padding=0
nvbuf-memory-type=0
batch-size=1
batched-push-timeout=40000

[primary-gie]
enable=1
gpu-id=0
gie-unique-id=1
nvbuf-memory-type=0
config-file=config_infer_primary_yoloV11.txt

  1. config_infer_primary_yoloV11.txt

[property]
gpu-id=0
net-scale-factor=1
model-color-format=1
onnx-file=yolo11m_yolo11.onnx
#model-engine-file=model_b1_gpu0_fp32.engine
#int8-calib-file=calib.table
labelfile-path=labels.txt
batch-size=1
network-mode=0
num-detected-classes=80
interval=0
gie-unique-id=1
process-mode=1
network-type=0
cluster-mode=2
maintain-aspect-ratio=1
symmetric-padding=0
#workspace-size=2000
parse-bbox-func-name=NvDsInferParseYolo
#parse-bbox-func-name=NvDsInferParseYoloCuda
custom-lib-path=/home/ds_tracker/workspace/DeepStream-Yolo/build/libnvdsinfer_custom_impl_Yolo.so
engine-create-func-name=NvDsInferYoloCudaEngineGet

[class-attrs-all]
nms-iou-threshold=0.45
pre-cluster-threshold=0.25
topk=300

Your Makefile is missing a link library. Refer to this answer.

Thank you!

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.