[BUG] Deepstream-6.2 deepstream_test_3.py does not work on some GPUs with visualization (Internal data stream error)

I am working with Nvidia Deepstream in docker and I have a problem with visualizing output on some of my machines.

Hardware

  • Machine1
+---------------------------------------------------------------------------------------+
| NVIDIA-SMI 535.113.01             Driver Version: 535.113.01   CUDA Version: 12.2     |
|-----------------------------------------+----------------------+----------------------+
| GPU  Name                 Persistence-M | Bus-Id        Disp.A | Volatile Uncorr. ECC |
| Fan  Temp   Perf          Pwr:Usage/Cap |         Memory-Usage | GPU-Util  Compute M. |
|                                         |                      |               MIG M. |
|=========================================+======================+======================|
|   0  NVIDIA RTX A4000 Laptop GPU    Off | 00000000:01:00.0 Off |                  N/A |
| N/A   53C    P0              N/A /  90W |      7MiB /  8192MiB |      0%      Default |
|                                         |                      |                  N/A |
+-----------------------------------------+----------------------+----------------------+

  • Machine2
+---------------------------------------------------------------------------------------+
| NVIDIA-SMI 535.113.01             Driver Version: 535.113.01   CUDA Version: 12.2     |
|-----------------------------------------+----------------------+----------------------+
| GPU  Name                 Persistence-M | Bus-Id        Disp.A | Volatile Uncorr. ECC |
| Fan  Temp   Perf          Pwr:Usage/Cap |         Memory-Usage | GPU-Util  Compute M. |
|                                         |                      |               MIG M. |
|=========================================+======================+======================|
|   0  NVIDIA GeForce RTX 3090        On  | 00000000:01:00.0  On |                  N/A |
| 53%   44C    P8              28W / 350W |    325MiB / 24576MiB |      0%      Default |
|                                         |                      |                  N/A |
+-----------------------------------------+----------------------+----------------------+

Both use Ubuntu and have configured nvidia container toolkit.

Reproduction

Run deepstream container (and let it opening windows)

xhost +local:
docker container run --rm --net host --runtime=nvidia --gpus=1 -v /tmp/.X11-unix:/tmp/.X11-unix  -e DISPLAY=$DISPLAY -it nvcr.io/nvidia/deepstream:6.2-devel bash

Copy deepstream examples and compile deps

apt update
apt install -y apt-transport-https ca-certificates \
    python3-gi python3-dev python3-gst-1.0 python-gi-dev git python-dev \
    python3 python3-pip python3.8-dev cmake g++ build-essential libglib2.0-dev \
    libglib2.0-dev-bin libgstreamer1.0-dev libtool m4 autoconf automake libgirepository1.0-dev libcairo2-dev
update-ca-certificates
cd /opt/nvidia/deepstream/deepstream/sources && \
    git clone https://github.com/NVIDIA-AI-IOT/deepstream_python_apps  --branch v1.1.6 --depth 1 && \
    cd deepstream_python_apps && \
    git submodule update --init && \
    cd 3rdparty/gst-python/ && \
    ./autogen.sh && \
    make -j$(nproc) && \
    make install && \
    cd /opt/nvidia/deepstream/deepstream/sources/deepstream_python_apps/bindings && \
    mkdir build && \
    cd build && \
    cmake .. && \
    make -j$(nproc) && \
    pip3 install ./pyds-*.whl

Run example app

cd /opt/nvidia/deepstream/deepstream/sources/deepstream_python_apps/apps/deepstream-test3
./deepstream_test_3.py -i file:///opt/nvidia/deepstream/deepstream/samples/streams/sample_1080p_h264.mp4

Results

On Machine 2 everything works, I get window with red rectangles and see detections in terminal.

On Machine 1 pipeline breaks (window quickly appears and disappears) :

root@WBEC832l:/opt/nvidia/deepstream/deepstream/sources/deepstream_python_apps/apps/deepstream-test3# ./deepstream_test_3.py -i file:///opt/nvidia/deepstream/deepstream/samples/streams/sample_1080p_h264.mp4
{'input': ['file:///opt/nvidia/deepstream/deepstream/samples/streams/sample_1080p_h264.mp4'], 'configfile': None, 'pgie': None, 'no_display': False, 'file_loop': False, 'disable_probe': False, 'silent': False}

(gst-plugin-scanner:8942): GStreamer-WARNING **: 09:13:43.275: Failed to load plugin '/usr/lib/x86_64-linux-gnu/gstreamer-1.0/libgstmpg123.so': libmpg123.so.0: cannot open shared object file: No such file or directory

(gst-plugin-scanner:8942): GStreamer-WARNING **: 09:13:43.285: Failed to load plugin '/usr/lib/x86_64-linux-gnu/gstreamer-1.0/libgstopenmpt.so': libmpg123.so.0: cannot open shared object file: No such file or directory

(gst-plugin-scanner:8942): GStreamer-WARNING **: 09:13:43.308: Failed to load plugin '/usr/lib/x86_64-linux-gnu/gstreamer-1.0/libgstmpeg2dec.so': libmpeg2.so.0: cannot open shared object file: No such file or directory

(gst-plugin-scanner:8942): GStreamer-WARNING **: 09:13:43.316: Failed to load plugin '/usr/lib/x86_64-linux-gnu/gstreamer-1.0/libgstchromaprint.so': libavcodec.so.58: cannot open shared object file: No such file or directory

(gst-plugin-scanner:8942): GStreamer-WARNING **: 09:13:43.331: Failed to load plugin '/usr/lib/x86_64-linux-gnu/gstreamer-1.0/libgstmpeg2enc.so': libmpeg2encpp-2.1.so.0: cannot open shared object file: No such file or directory

(gst-plugin-scanner:8942): GStreamer-WARNING **: 09:13:44.725: Failed to load plugin '/usr/lib/x86_64-linux-gnu/gstreamer-1.0/deepstream/libnvdsgst_udp.so': librivermax.so.0: cannot open shared object file: No such file or directory

(gst-plugin-scanner:8942): GStreamer-WARNING **: 09:13:44.726: Failed to load plugin '/usr/lib/x86_64-linux-gnu/gstreamer-1.0/deepstream/libnvdsgst_inferserver.so': libtritonserver.so: cannot open shared object file: No such file or directory
Creating Pipeline 
 
Creating streamux 
 
Creating source_bin  0  
 
Creating source bin
source-bin-00
Creating Pgie 
 
Creating tiler 
 
Creating nvvidconv 
 
Creating nvosd 
 
Creating EGLSink 

Adding elements to Pipeline 

Linking elements in the Pipeline 

Now playing...
0 :  file:///opt/nvidia/deepstream/deepstream/samples/streams/sample_1080p_h264.mp4
Starting pipeline 

libEGL warning: MESA-LOADER: failed to retrieve device information

WARNING: ../nvdsinfer/nvdsinfer_model_builder.cpp:1487 Deserialize engine failed because file path: /opt/nvidia/deepstream/deepstream-6.2/sources/deepstream_python_apps/apps/deepstream-test3/../../../../samples/models/Primary_Detector/resnet10.caffemodel_b1_gpu0_int8.engine open error
0:00:03.100905144  8941      0x32fc360 WARN                 nvinfer gstnvinfer.cpp:677:gst_nvinfer_logger:<primary-inference> NvDsInferContext[UID 1]: Warning from NvDsInferContextImpl::deserializeEngineAndBackend() <nvdsinfer_context_impl.cpp:1897> [UID = 1]: deserialize engine from file :/opt/nvidia/deepstream/deepstream-6.2/sources/deepstream_python_apps/apps/deepstream-test3/../../../../samples/models/Primary_Detector/resnet10.caffemodel_b1_gpu0_int8.engine failed
0:00:03.159279151  8941      0x32fc360 WARN                 nvinfer gstnvinfer.cpp:677:gst_nvinfer_logger:<primary-inference> NvDsInferContext[UID 1]: Warning from NvDsInferContextImpl::generateBackendContext() <nvdsinfer_context_impl.cpp:2002> [UID = 1]: deserialize backend context from engine from file :/opt/nvidia/deepstream/deepstream-6.2/sources/deepstream_python_apps/apps/deepstream-test3/../../../../samples/models/Primary_Detector/resnet10.caffemodel_b1_gpu0_int8.engine failed, try rebuild
0:00:03.159458063  8941      0x32fc360 INFO                 nvinfer gstnvinfer.cpp:680:gst_nvinfer_logger:<primary-inference> NvDsInferContext[UID 1]: Info from NvDsInferContextImpl::buildModel() <nvdsinfer_context_impl.cpp:1923> [UID = 1]: Trying to create engine from model files
WARNING: [TRT]: The implicit batch dimension mode has been deprecated. Please create the network with NetworkDefinitionCreationFlag::kEXPLICIT_BATCH flag whenever possible.
0:00:21.578526957  8941      0x32fc360 INFO                 nvinfer gstnvinfer.cpp:680:gst_nvinfer_logger:<primary-inference> NvDsInferContext[UID 1]: Info from NvDsInferContextImpl::buildModel() <nvdsinfer_context_impl.cpp:1955> [UID = 1]: serialize cuda engine to file: /opt/nvidia/deepstream/deepstream-6.2/samples/models/Primary_Detector/resnet10.caffemodel_b1_gpu0_int8.engine successfully
INFO: ../nvdsinfer/nvdsinfer_model_builder.cpp:610 [Implicit Engine Info]: layers num: 3
0   INPUT  kFLOAT input_1         3x368x640       
1   OUTPUT kFLOAT conv2d_bbox     16x23x40        
2   OUTPUT kFLOAT conv2d_cov/Sigmoid 4x23x40         

0:00:21.644598881  8941      0x32fc360 INFO                 nvinfer gstnvinfer_impl.cpp:328:notifyLoadModelStatus:<primary-inference> [UID 1]: Load new model:dstest3_pgie_config.txt sucessfully
Decodebin child added: source 

Decodebin child added: decodebin0 

**PERF:  {'stream0': 0.0} 

Decodebin child added: qtdemux0 

Decodebin child added: multiqueue0 

Decodebin child added: h264parse0 

Decodebin child added: capsfilter0 

Warning: gst-stream-error-quark: No decoder available for type 'audio/mpeg, mpegversion=(int)4, framed=(boolean)true, stream-format=(string)raw, level=(string)2, base-profile=(string)lc, profile=(string)lc, codec_data=(buffer)119056e500, rate=(int)48000, channels=(int)2'. (6): gsturidecodebin.c(920): unknown_type_cb (): /GstPipeline:pipeline0/GstBin:source-bin-00/GstURIDecodeBin:uri-decode-bin
Decodebin child added: nvv4l2decoder0 

In cb_newpad

gstname= video/x-raw
features= <Gst.CapsFeatures object at 0x7fb785695640 (GstCapsFeatures at 0x2433b80)>
Frame Number= 0 Number of Objects= 14 Vehicle_count= 8 Person_count= 6
Frame Number= 3 Number of Objects= 11 Vehicle_count= 6 Person_count= 5
cuGraphicsGLRegisterBuffer failed with error(219) gst_eglglessink_cuda_init texture = 1
Frame Number= 4 Number of Objects= 14 Vehicle_count= 7 Person_count= 7
Frame Number= 7 Number of Objects= 11 Vehicle_count= 7 Person_count= 4
Frame Number= 12 Number of Objects= 9 Vehicle_count= 6 Person_count= 3
0:00:21.834477776  8941      0x3286800 WARN                 nvinfer gstnvinfer.cpp:2369:gst_nvinfer_output_loop:<primary-inference> error: Internal data stream error.
0:00:21.834486445  8941      0x3286800 WARN                 nvinfer gstnvinfer.cpp:2369:gst_nvinfer_output_loop:<primary-inference> error: streaming stopped, reason not-negotiated (-4)
Error: gst-stream-error-quark: Internal data stream error. (1): gstnvinfer.cpp(2369): gst_nvinfer_output_loop (): /GstPipeline:pipeline0/GstNvInfer:primary-inference:
streaming stopped, reason not-negotiated (-4)
Exiting app

Frame Number= 13 Number of Objects= 10 Vehicle_count= 7 Person_count= 3

But when I launch this example with flag --no-display everything works.

How to make display work on Machine 1?

Could you add the GST_DEBUG=3 at the beginning of the command to open more log on * Machine1?

@yuweiw

{'input': ['file:///opt/nvidia/deepstream/deepstream/samples/streams/sample_1080p_h264.mp4'], 'configfile': None, 'pgie': None, 'no_display': False, 'file_loop': False, 'disable_probe': False, 'silent': False}
0:00:00.006553156  9163 0x5635163ddc30 WARN      GST_PLUGIN_LOADING gstplugin.c:792:_priv_gst_plugin_load_file_for_registry: module_open failed: libmpg123.so.0: cannot open shared object file: No such file or directory

(gst-plugin-scanner:9163): GStreamer-WARNING **: 08:09:37.020: Failed to load plugin '/usr/lib/x86_64-linux-gnu/gstreamer-1.0/libgstmpg123.so': libmpg123.so.0: cannot open shared object file: No such file or directory
0:00:00.020434085  9163 0x5635163ddc30 WARN      GST_PLUGIN_LOADING gstplugin.c:792:_priv_gst_plugin_load_file_for_registry: module_open failed: libmpg123.so.0: cannot open shared object file: No such file or directory

(gst-plugin-scanner:9163): GStreamer-WARNING **: 08:09:37.034: Failed to load plugin '/usr/lib/x86_64-linux-gnu/gstreamer-1.0/libgstopenmpt.so': libmpg123.so.0: cannot open shared object file: No such file or directory
0:00:00.047563639  9163 0x5635163ddc30 WARN                 default gstsf.c:97:gst_sf_create_audio_template_caps: format 0x120000: 'AVR (Audio Visual Research)' is not mapped
0:00:00.047575446  9163 0x5635163ddc30 WARN                 default gstsf.c:97:gst_sf_create_audio_template_caps: format 0x180000: 'CAF (Apple Core Audio File)' is not mapped
0:00:00.047578462  9163 0x5635163ddc30 WARN                 default gstsf.c:97:gst_sf_create_audio_template_caps: format 0x100000: 'HTK (HMM Tool Kit)' is not mapped
0:00:00.047582787  9163 0x5635163ddc30 WARN                 default gstsf.c:97:gst_sf_create_audio_template_caps: format 0xc0000: 'MAT4 (GNU Octave 2.0 / Matlab 4.2)' is not mapped
0:00:00.047585441  9163 0x5635163ddc30 WARN                 default gstsf.c:97:gst_sf_create_audio_template_caps: format 0xd0000: 'MAT5 (GNU Octave 2.1 / Matlab 5.0)' is not mapped
0:00:00.047588249  9163 0x5635163ddc30 WARN                 default gstsf.c:97:gst_sf_create_audio_template_caps: format 0x210000: 'MPC (Akai MPC 2k)' is not mapped
0:00:00.047591367  9163 0x5635163ddc30 WARN                 default gstsf.c:97:gst_sf_create_audio_template_caps: format 0xe0000: 'PVF (Portable Voice Format)' is not mapped
0:00:00.047607586  9163 0x5635163ddc30 WARN                 default gstsf.c:97:gst_sf_create_audio_template_caps: format 0x160000: 'SD2 (Sound Designer II)' is not mapped
0:00:00.047611173  9163 0x5635163ddc30 WARN                 default gstsf.c:97:gst_sf_create_audio_template_caps: format 0x190000: 'WVE (Psion Series 3)' is not mapped
0:00:00.049553120  9163 0x5635163ddc30 WARN      GST_PLUGIN_LOADING gstplugin.c:792:_priv_gst_plugin_load_file_for_registry: module_open failed: libmpeg2.so.0: cannot open shared object file: No such file or directory

(gst-plugin-scanner:9163): GStreamer-WARNING **: 08:09:37.063: Failed to load plugin '/usr/lib/x86_64-linux-gnu/gstreamer-1.0/libgstmpeg2dec.so': libmpeg2.so.0: cannot open shared object file: No such file or directory
0:00:00.060357385  9163 0x5635163ddc30 WARN      GST_PLUGIN_LOADING gstplugin.c:792:_priv_gst_plugin_load_file_for_registry: module_open failed: libavcodec.so.58: cannot open shared object file: No such file or directory

(gst-plugin-scanner:9163): GStreamer-WARNING **: 08:09:37.074: Failed to load plugin '/usr/lib/x86_64-linux-gnu/gstreamer-1.0/libgstchromaprint.so': libavcodec.so.58: cannot open shared object file: No such file or directory
0:00:00.070643300  9163 0x5635163ddc30 WARN                  ladspa gstladspa.c:507:plugin_init:<plugin197> no LADSPA plugins found, check LADSPA_PATH
0:00:00.080166847  9163 0x5635163ddc30 WARN      GST_PLUGIN_LOADING gstplugin.c:792:_priv_gst_plugin_load_file_for_registry: module_open failed: libmpeg2encpp-2.1.so.0: cannot open shared object file: No such file or directory

(gst-plugin-scanner:9163): GStreamer-WARNING **: 08:09:37.094: Failed to load plugin '/usr/lib/x86_64-linux-gnu/gstreamer-1.0/libgstmpeg2enc.so': libmpeg2encpp-2.1.so.0: cannot open shared object file: No such file or directory
0:00:00.147455677  9163 0x5635163ddc30 WARN      GST_PLUGIN_LOADING gstplugin.c:792:_priv_gst_plugin_load_file_for_registry: module_open failed: librivermax.so.0: cannot open shared object file: No such file or directory

(gst-plugin-scanner:9163): GStreamer-WARNING **: 08:09:37.161: Failed to load plugin '/usr/lib/x86_64-linux-gnu/gstreamer-1.0/deepstream/libnvdsgst_udp.so': librivermax.so.0: cannot open shared object file: No such file or directory
0:00:00.148498697  9163 0x5635163ddc30 WARN      GST_PLUGIN_LOADING gstplugin.c:792:_priv_gst_plugin_load_file_for_registry: module_open failed: libtritonserver.so: cannot open shared object file: No such file or directory

(gst-plugin-scanner:9163): GStreamer-WARNING **: 08:09:37.162: Failed to load plugin '/usr/lib/x86_64-linux-gnu/gstreamer-1.0/deepstream/libnvdsgst_inferserver.so': libtritonserver.so: cannot open shared object file: No such file or directory
Creating Pipeline 
 
Creating streamux 
 
Creating source_bin  0  
 
Creating source bin
source-bin-00
Creating Pgie 
 
Creating tiler 
 
Creating nvvidconv 
 
Creating nvosd 
 
Creating EGLSink 

Adding elements to Pipeline 

Linking elements in the Pipeline 

Now playing...
0 :  file:///opt/nvidia/deepstream/deepstream/samples/streams/sample_1080p_h264.mp4
Starting pipeline 

libEGL warning: MESA-LOADER: failed to retrieve device information

0:00:01.913853649  9162      0x2fa9360 INFO                 nvinfer gstnvinfer.cpp:680:gst_nvinfer_logger:<primary-inference> NvDsInferContext[UID 1]: Info from NvDsInferContextImpl::deserializeEngineAndBackend() <nvdsinfer_context_impl.cpp:1909> [UID = 1]: deserialized trt engine from :/opt/nvidia/deepstream/deepstream-6.2/samples/models/Primary_Detector/resnet10.caffemodel_b1_gpu0_int8.engine
INFO: ../nvdsinfer/nvdsinfer_model_builder.cpp:610 [Implicit Engine Info]: layers num: 3
0   INPUT  kFLOAT input_1         3x368x640       
1   OUTPUT kFLOAT conv2d_bbox     16x23x40        
2   OUTPUT kFLOAT conv2d_cov/Sigmoid 4x23x40         

0:00:01.981942885  9162      0x2fa9360 INFO                 nvinfer gstnvinfer.cpp:680:gst_nvinfer_logger:<primary-inference> NvDsInferContext[UID 1]: Info from NvDsInferContextImpl::generateBackendContext() <nvdsinfer_context_impl.cpp:2012> [UID = 1]: Use deserialized engine model: /opt/nvidia/deepstream/deepstream-6.2/samples/models/Primary_Detector/resnet10.caffemodel_b1_gpu0_int8.engine
0:00:01.984393428  9162      0x2fa9360 INFO                 nvinfer gstnvinfer_impl.cpp:328:notifyLoadModelStatus:<primary-inference> [UID 1]: Load new model:dstest3_pgie_config.txt sucessfully
0:00:01.984825119  9162      0x2fa9360 WARN                 basesrc gstbasesrc.c:3600:gst_base_src_start_complete:<source> pad not activated yet
Decodebin child added: source 

Decodebin child added: decodebin0 

0:00:01.985535954  9162      0x2fa9360 WARN                 basesrc gstbasesrc.c:3600:gst_base_src_start_complete:<source> pad not activated yet
Decodebin child added: qtdemux0 

0:00:01.988998926  9162 0x7f841c0420c0 WARN                 qtdemux qtdemux.c:3250:qtdemux_parse_trex:<qtdemux0> failed to find fragment defaults for stream 1
0:00:01.989222494  9162 0x7f841c0420c0 WARN                 qtdemux qtdemux.c:3250:qtdemux_parse_trex:<qtdemux0> failed to find fragment defaults for stream 2
Decodebin child added: multiqueue0 

Decodebin child added: h264parse0 

Decodebin child added: capsfilter0 

0:00:01.991240171  9162 0x7f841c0420c0 WARN            uridecodebin gsturidecodebin.c:920:unknown_type_cb:<uri-decode-bin> warning: No decoder available for type 'audio/mpeg, mpegversion=(int)4, framed=(boolean)true, stream-format=(string)raw, level=(string)2, base-profile=(string)lc, profile=(string)lc, codec_data=(buffer)119056e500, rate=(int)48000, channels=(int)2'.
Warning: gst-stream-error-quark: No decoder available for type 'audio/mpeg, mpegversion=(int)4, framed=(boolean)true, stream-format=(string)raw, level=(string)2, base-profile=(string)lc, profile=(string)lc, codec_data=(buffer)119056e500, rate=(int)48000, channels=(int)2'. (6): gsturidecodebin.c(920): unknown_type_cb (): /GstPipeline:pipeline0/GstBin:source-bin-00/GstURIDecodeBin:uri-decode-bin
Decodebin child added: nvv4l2decoder0 

0:00:01.993329781  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:3057:gst_v4l2_object_get_nearest_size:<nvv4l2decoder0:sink> Unable to try format: Unknown error -1
0:00:01.993338365  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:2942:gst_v4l2_object_probe_caps_for_format:<nvv4l2decoder0:sink> Could not probe minimum capture size for pixelformat MJPG
0:00:01.993341188  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:3057:gst_v4l2_object_get_nearest_size:<nvv4l2decoder0:sink> Unable to try format: Unknown error -1
0:00:01.993343775  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:2948:gst_v4l2_object_probe_caps_for_format:<nvv4l2decoder0:sink> Could not probe maximum capture size for pixelformat MJPG
0:00:01.993350416  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:3057:gst_v4l2_object_get_nearest_size:<nvv4l2decoder0:sink> Unable to try format: Unknown error -1
0:00:01.993354014  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:2942:gst_v4l2_object_probe_caps_for_format:<nvv4l2decoder0:sink> Could not probe minimum capture size for pixelformat AV10
0:00:01.993356188  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:3057:gst_v4l2_object_get_nearest_size:<nvv4l2decoder0:sink> Unable to try format: Unknown error -1
0:00:01.993358821  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:2948:gst_v4l2_object_probe_caps_for_format:<nvv4l2decoder0:sink> Could not probe maximum capture size for pixelformat AV10
0:00:01.993363876  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:3057:gst_v4l2_object_get_nearest_size:<nvv4l2decoder0:sink> Unable to try format: Unknown error -1
0:00:01.993366543  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:2942:gst_v4l2_object_probe_caps_for_format:<nvv4l2decoder0:sink> Could not probe minimum capture size for pixelformat DVX5
0:00:01.993368626  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:3057:gst_v4l2_object_get_nearest_size:<nvv4l2decoder0:sink> Unable to try format: Unknown error -1
0:00:01.993371998  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:2948:gst_v4l2_object_probe_caps_for_format:<nvv4l2decoder0:sink> Could not probe maximum capture size for pixelformat DVX5
0:00:01.993376152  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:3057:gst_v4l2_object_get_nearest_size:<nvv4l2decoder0:sink> Unable to try format: Unknown error -1
0:00:01.993379051  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:2942:gst_v4l2_object_probe_caps_for_format:<nvv4l2decoder0:sink> Could not probe minimum capture size for pixelformat DVX4
0:00:01.993381066  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:3057:gst_v4l2_object_get_nearest_size:<nvv4l2decoder0:sink> Unable to try format: Unknown error -1
0:00:01.993383535  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:2948:gst_v4l2_object_probe_caps_for_format:<nvv4l2decoder0:sink> Could not probe maximum capture size for pixelformat DVX4
0:00:01.993387707  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:3057:gst_v4l2_object_get_nearest_size:<nvv4l2decoder0:sink> Unable to try format: Unknown error -1
0:00:01.993390549  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:2942:gst_v4l2_object_probe_caps_for_format:<nvv4l2decoder0:sink> Could not probe minimum capture size for pixelformat MPG4
0:00:01.993392570  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:3057:gst_v4l2_object_get_nearest_size:<nvv4l2decoder0:sink> Unable to try format: Unknown error -1
0:00:01.993395236  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:2948:gst_v4l2_object_probe_caps_for_format:<nvv4l2decoder0:sink> Could not probe maximum capture size for pixelformat MPG4
0:00:01.993399194  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:3057:gst_v4l2_object_get_nearest_size:<nvv4l2decoder0:sink> Unable to try format: Unknown error -1
0:00:01.993402408  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:2942:gst_v4l2_object_probe_caps_for_format:<nvv4l2decoder0:sink> Could not probe minimum capture size for pixelformat MPG2
0:00:01.993404558  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:3057:gst_v4l2_object_get_nearest_size:<nvv4l2decoder0:sink> Unable to try format: Unknown error -1
0:00:01.993407221  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:2948:gst_v4l2_object_probe_caps_for_format:<nvv4l2decoder0:sink> Could not probe maximum capture size for pixelformat MPG2
0:00:01.993411979  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:3057:gst_v4l2_object_get_nearest_size:<nvv4l2decoder0:sink> Unable to try format: Unknown error -1
0:00:01.993419244  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:2942:gst_v4l2_object_probe_caps_for_format:<nvv4l2decoder0:sink> Could not probe minimum capture size for pixelformat H265
0:00:01.993421465  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:3057:gst_v4l2_object_get_nearest_size:<nvv4l2decoder0:sink> Unable to try format: Unknown error -1
0:00:01.993424787  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:2948:gst_v4l2_object_probe_caps_for_format:<nvv4l2decoder0:sink> Could not probe maximum capture size for pixelformat H265
0:00:01.993428906  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:3057:gst_v4l2_object_get_nearest_size:<nvv4l2decoder0:sink> Unable to try format: Unknown error -1
0:00:01.993432276  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:2942:gst_v4l2_object_probe_caps_for_format:<nvv4l2decoder0:sink> Could not probe minimum capture size for pixelformat VP90
0:00:01.993435437  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:3057:gst_v4l2_object_get_nearest_size:<nvv4l2decoder0:sink> Unable to try format: Unknown error -1
0:00:01.993440235  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:2948:gst_v4l2_object_probe_caps_for_format:<nvv4l2decoder0:sink> Could not probe maximum capture size for pixelformat VP90
0:00:01.993458971  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:3057:gst_v4l2_object_get_nearest_size:<nvv4l2decoder0:sink> Unable to try format: Unknown error -1
0:00:01.993462245  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:2942:gst_v4l2_object_probe_caps_for_format:<nvv4l2decoder0:sink> Could not probe minimum capture size for pixelformat VP80
0:00:01.993464390  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:3057:gst_v4l2_object_get_nearest_size:<nvv4l2decoder0:sink> Unable to try format: Unknown error -1
0:00:01.993467515  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:2948:gst_v4l2_object_probe_caps_for_format:<nvv4l2decoder0:sink> Could not probe maximum capture size for pixelformat VP80
0:00:01.993472451  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:3057:gst_v4l2_object_get_nearest_size:<nvv4l2decoder0:sink> Unable to try format: Unknown error -1
0:00:01.993475797  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:2942:gst_v4l2_object_probe_caps_for_format:<nvv4l2decoder0:sink> Could not probe minimum capture size for pixelformat H264
0:00:01.993477897  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:3057:gst_v4l2_object_get_nearest_size:<nvv4l2decoder0:sink> Unable to try format: Unknown error -1
0:00:01.993480939  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:2948:gst_v4l2_object_probe_caps_for_format:<nvv4l2decoder0:sink> Could not probe maximum capture size for pixelformat H264
0:00:01.993702188  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:3057:gst_v4l2_object_get_nearest_size:<nvv4l2decoder0:src> Unable to try format: Unknown error -1
0:00:01.993706420  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:2942:gst_v4l2_object_probe_caps_for_format:<nvv4l2decoder0:src> Could not probe minimum capture size for pixelformat NM12
0:00:01.993708751  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:3057:gst_v4l2_object_get_nearest_size:<nvv4l2decoder0:src> Unable to try format: Unknown error -1
0:00:01.993712904  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:2948:gst_v4l2_object_probe_caps_for_format:<nvv4l2decoder0:src> Could not probe maximum capture size for pixelformat NM12
0:00:01.993729350  9162 0x7f841c0425e0 WARN                    v4l2 gstv4l2object.c:2395:gst_v4l2_object_add_interlace_mode:0x7f840401fbe0 Failed to determine interlace mode
In cb_newpad

gstname= video/x-raw
features= <Gst.CapsFeatures object at 0x7f84c01775e0 (GstCapsFeatures at 0x20fb080)>
0:00:02.100936804  9162 0x7f841c0425e0 WARN            v4l2videodec gstv4l2videodec.c:1836:gst_v4l2_video_dec_decide_allocation:<nvv4l2decoder0> Duration invalid, not setting latency
0:00:02.100975120  9162 0x7f841c0425e0 WARN          v4l2bufferpool gstv4l2bufferpool.c:1082:gst_v4l2_buffer_pool_start:<nvv4l2decoder0:pool:src> Uncertain or not enough buffers, enabling copy threshold
0:00:02.102885181  9162 0x7f8404033060 WARN          v4l2bufferpool gstv4l2bufferpool.c:1533:gst_v4l2_buffer_pool_dqbuf:<nvv4l2decoder0:pool:src> Driver should never set v4l2_buffer.field to ANY
Frame Number= 0 Number of Objects= 14 Vehicle_count= 8 Person_count= 6
Frame Number= 1 Number of Objects= 12 Vehicle_count= 7 Person_count= 5
Frame Number= 2 Number of Objects= 13 Vehicle_count= 7 Person_count= 6
Frame Number= 3 Number of Objects= 11 Vehicle_count= 6 Person_count= 5
cuGraphicsGLRegisterBuffer failed with error(219) gst_eglglessink_cuda_init texture = 1
0:00:02.181892303  9162      0x22b21e0 ERROR          nveglglessink ext/eglgles/gsteglglessink.c:2922:gst_eglglessink_configure_caps:<nvvideo-renderer> Cuda Init failed
0:00:02.181900425  9162      0x22b21e0 ERROR          nveglglessink ext/eglgles/gsteglglessink.c:2933:gst_eglglessink_configure_caps:<nvvideo-renderer> Configuring caps failed
0:00:02.182034936  9162      0x22b2240 ERROR          nveglglessink ext/eglgles/gsteglglessink.c:2978:gst_eglglessink_setcaps:<nvvideo-renderer> Failed to configure caps
0:00:02.182156666  9162      0x22b2240 ERROR          nveglglessink ext/eglgles/gsteglglessink.c:2978:gst_eglglessink_setcaps:<nvvideo-renderer> Failed to configure caps
0:00:02.182170282  9162      0x22b2240 WARN                GST_PADS gstpad.c:4231:gst_pad_peer_query:<queue5:src> could not send sticky events
0:00:02.183850752  9162      0x22b2240 ERROR          nveglglessink ext/eglgles/gsteglglessink.c:2978:gst_eglglessink_setcaps:<nvvideo-renderer> Failed to configure caps
0:00:02.183876161  9162      0x22b2240 ERROR          nveglglessink ext/eglgles/gsteglglessink.c:2978:gst_eglglessink_setcaps:<nvvideo-renderer> Failed to configure caps
0:00:02.183888199  9162      0x22b2240 ERROR          nveglglessink ext/eglgles/gsteglglessink.c:2978:gst_eglglessink_setcaps:<nvvideo-renderer> Failed to configure caps
0:00:02.183898366  9162      0x22b2240 ERROR          nveglglessink ext/eglgles/gsteglglessink.c:2978:gst_eglglessink_setcaps:<nvvideo-renderer> Failed to configure caps
0:00:02.183908364  9162      0x22b2240 ERROR          nveglglessink ext/eglgles/gsteglglessink.c:2978:gst_eglglessink_setcaps:<nvvideo-renderer> Failed to configure caps
0:00:02.183918483  9162      0x22b2240 ERROR          nveglglessink ext/eglgles/gsteglglessink.c:2978:gst_eglglessink_setcaps:<nvvideo-renderer> Failed to configure caps
0:00:02.183933416  9162      0x22b2240 ERROR          nveglglessink ext/eglgles/gsteglglessink.c:2978:gst_eglglessink_setcaps:<nvvideo-renderer> Failed to configure caps
0:00:02.183943551  9162      0x22b2240 ERROR          nveglglessink ext/eglgles/gsteglglessink.c:2978:gst_eglglessink_setcaps:<nvvideo-renderer> Failed to configure caps
0:00:02.183953157  9162      0x22b2240 ERROR          nveglglessink ext/eglgles/gsteglglessink.c:2978:gst_eglglessink_setcaps:<nvvideo-renderer> Failed to configure caps
0:00:02.183962909  9162      0x22b2240 ERROR          nveglglessink ext/eglgles/gsteglglessink.c:2978:gst_eglglessink_setcaps:<nvvideo-renderer> Failed to configure caps
Frame Number= 4 Number of Objects= 14 Vehicle_count= 7 Person_count= 7
Frame Number= 5 Number of Objects= 14 Vehicle_count= 8 Person_count= 6
Frame Number= 6 Number of Objects= 10 Vehicle_count= 6 Person_count= 4
Frame Number= 7 Number of Objects= 11 Vehicle_count= 7 Person_count= 4
Frame Number= 8 Number of Objects= 11 Vehicle_count= 6 Person_count= 5
0:00:02.196355659  9162      0x22b2240 ERROR          nveglglessink ext/eglgles/gsteglglessink.c:2978:gst_eglglessink_setcaps:<nvvideo-renderer> Failed to configure caps
Frame Number= 9 Number of Objects= 10 Vehicle_count= 6 Person_count= 4
Frame Number= 10 Number of Objects= 11 Vehicle_count= 6 Person_count= 5
0:00:02.204141815  9162      0x2f33000 WARN                 nvinfer gstnvinfer.cpp:2369:gst_nvinfer_output_loop:<primary-inference> error: Internal data stream error.
0:00:02.204150023  9162      0x2f33000 WARN                 nvinfer gstnvinfer.cpp:2369:gst_nvinfer_output_loop:<primary-inference> error: streaming stopped, reason not-negotiated (-4)
Error: gst-stream-error-quark: Internal data stream error. (1): gstnvinfer.cpp(2369): gst_nvinfer_output_loop (): /GstPipeline:pipeline0/GstNvInfer:primary-inference:
streaming stopped, reason not-negotiated (-4)
Exiting app

Frame Number= 11 Number of Objects= 14 Vehicle_count= 8 Person_count= 6
Frame Number= 12 Number of Objects= 9 Vehicle_count= 6 Person_count= 3
Frame Number= 13 Number of Objects= 10 Vehicle_count= 7 Person_count= 3
Frame Number= 14 Number of Objects= 12 Vehicle_count= 8 Person_count= 4
0:00:02.211895573  9162 0x7f841c0420c0 WARN                 qtdemux qtdemux.c:6619:gst_qtdemux_loop:<qtdemux0> error: Internal data stream error.
0:00:02.211934585  9162 0x7f841c0420c0 WARN                 qtdemux qtdemux.c:6619:gst_qtdemux_loop:<qtdemux0> error: streaming stopped, reason not-negotiated (-4)

I tested this on two additional machines with following results:

  • RTX 4090 - Everything worked well
+-----------------------------------------------------------------------------+
| NVIDIA-SMI 525.125.06   Driver Version: 525.125.06   CUDA Version: 12.0     |
|-------------------------------+----------------------+----------------------+
| GPU  Name        Persistence-M| Bus-Id        Disp.A | Volatile Uncorr. ECC |
| Fan  Temp  Perf  Pwr:Usage/Cap|         Memory-Usage | GPU-Util  Compute M. |
|                               |                      |               MIG M. |
|===============================+======================+======================|
|   0  NVIDIA GeForce ...  On   | 00000000:01:00.0 Off |                  Off |
|  0%   43C    P8    11W / 450W |    508MiB / 24564MiB |      0%      Default |
|                               |                      |                  N/A |
  • Quadro T2000 (in laptop)- also got the same error.

Could you refer the link below and set the appropriate value for the DISPLAY paramter?
https://docs.nvidia.com/metropolis/deepstream/dev-guide/text/DS_troubleshooting.html?highlight=xhost#deepstream-plugins-failing-to-load-without-display-variable-set-when-launching-ds-dockers

DISPLAY value is already set. (see parameter -e DISPLAY=$DISPLAY in my docker run command).

I also tested it using command xeyes inside of docker, but I skipped this step in my reproduction steps.

apt install -y x11-tools

xeyes

OK. Are your gpu cards integrated on one machine or separate? Could you try the method below: deepstream-sdk-faq?

Are your gpu cards integrated on one machine or separate?

Every GPU is on another machine.
I have desktop PC with RTX 3090. (Machine 1)
and laptop Dell precission 7560 with RTX RTX A4000 Laptop GPU (Machine 2)
Both run Ubuntu 22.04. (laptop has a freshly installed System)

Could you try the method below: deepstream-sdk-faq?

Do I have to launch nvidia-xconfig in docker or in host machine?
How to verify whether I use nvidia X driver?

The driver in the docker is mapped to your host machines, so you need to launch that on your host machine.
Your scenario is similar to the 213783. Please refer to that too.

I launched sudo nvidia-xconfig and it broke my my Ubuntu.
I had to prepare USB with another system and remove /etc/X11/xorg.conf
I think that your official tools shouldn’t break operating systems and make them not bootable.

I attach ~/.local/share/xorg/Xorg.1.log, none of the logs matched problems mentioned in Chapter 8. Common Problems.
Xorg.log.copy.txt (88.9 KB)

Also installing dependencies mentioned in Issue runnung deepstream-app docker container (5.0 & 6.0) in RTX 3080 and A5000 laptop - #8 by peterchensm did not help

And run “sudo apt-get install mesa-common-dev libgl1-mesa-dev libglu1-mesa-dev”.

And additionally
sudo apt install mesa-utils
Xorg.1 (copy).log (69.0 KB)

OK. I noticed that you used the Docker command with --gpus=1. So are there more than 1 gpu on your laptop?

I have only one dedicated GPU in my laptop.
But I have also an Intel integrated Mesa GPU.

I also tried to launch docker with --gpus all and nothing changed.

It may be that your display is not the Nvidia card by default. Could you refer to the link below and try to switch to the Nvidia card?
https://www.linuxbabe.com/desktop-linux/switch-intel-nvidia-graphics-card-ubuntu

Nvidia seems to be already enabled.

$ prime-select query
nvidia

Could you install the DeepStream directly on your host and check if it can display normally?
Because you are using DeepStream 6.2, the corresponding driver version is R525.85.12. You can also try to install the corresponding dirver version.

Could you install the DeepStream directly on your host and check if it can display normally?

This defeats the purpose of using docker. Moreover all of my working machines (with RTX 4090) use the same version of drivers.

It appears, that the main source of problems was Hybrid mode in PRIME Profiles.
After switching to performance mode and rebooting my machine I was able to run examples with visualization.

After rebooting in the panel of Nvidia Settings X Screen and X Server Display Configuration settings appeared.

That’s a shame your drivers/libraries don’t provide precise messages in such cases.

Thanks for the suggestion. We have added that to our FAQ.
https://forums.developer.nvidia.com/t/deepstream-sdk-faq/80236/42

1 Like

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