default video playback for the "deepstream-test3-app" in deepstream-4.0 not working

hi,
refering to this topic: https://devtalk.nvidia.com/default/topic/1057686/jetson-nano/jetson-nano-camera-with-remote-desktop-on-pipeline-ip-camera-rtsp/post/5381864/#5381864
i tried this command to check if default playback works:

./deepstream-test3-app file:///opt/nvidia/deepstream/deepstream-4.0/samples/streams/sample_720p.mp4

and this was the result:

Failed to load config file: No such file or directory
** ERROR: <gst_nvinfer_parse_config_file:943>: failed
Now playing: file:///opt/nvidia/deepstream/deepstream-4.0/samples/streams/sample_720p.mp4,

Using winsys: x11 
Creating LL OSD context new
0:00:00.230961190  8187      0x6343c40 WARN                 nvinfer gstnvinfer.cpp:658:gst_nvinfer_start:<primary-nvinference-engine> error: Configuration file parsing failed
0:00:00.231123379  8187      0x6343c40 WARN                 nvinfer gstnvinfer.cpp:658:gst_nvinfer_start:<primary-nvinference-engine> error: Config file path: dstest3_pgie_config.txt
Running...
ERROR from element primary-nvinference-engine: Configuration file parsing failed
Error details: /dvs/git/dirty/git-master_linux/deepstream/sdk/src/gst-plugins/gst-nvinfer/gstnvinfer.cpp(658): gst_nvinfer_start (): /GstPipeline:dstest3-pipeline/GstNvInfer:primary-nvinference-engine:
Config file path: dstest3_pgie_config.txt
Returned, stopping playback
Deleting pipeline

i also tried following this blog post: https://devtalk.nvidia.com/default/topic/1058086/deepstream-sdk/how-to-run-rtp-camera-in-deepstream-on-nano/post/5369243/#5369243
and it gave the following result when display is 1:

Using launch string: rtspsrc location=rtsp://admin:*pass*@192.168.1.** ! rtph264depay ! h264parse ! nvv4l2decoder ! appsink name=mysink sync=false 
[INFO] (NvEglRenderer.cpp:110) <renderer0> Setting Screen width 1920 height 1080
Opening in BLOCKING MODE

and the following result when display is 0:

Invalid MIT-MAGIC-COOKIE-1 keynvbuf_utils: Could not get EGL display connection
Using launch string: rtspsrc location=rtsp://admin:*pass*@192.168.1.** ! rtph264depay ! h264parse ! nvv4l2decoder ! appsink name=mysink sync=false 
Invalid MIT-MAGIC-COOKIE-1 key[ERROR] (NvEglRenderer.cpp:98) <renderer0> Error in opening display
[ERROR] (NvEglRenderer.cpp:154) <renderer0> Got ERROR closing display
Segmentation fault (core dumped)

*i have tried this on a freshly flashed sd card through the sdk manager.

*i got here because i want to run an rtsp stream on the yolo application, but i had an issue with that. please check this blog post: https://devtalk.nvidia.com/default/topic/1060789/deepstream-sdk/yolov3-deepstream-sdk-4-0-performance-on-jetson-nano-/post/5374823/#5374823

Hi,
Please check if you can run

$ gst-launch-1.0 rtspsrc location=rtsp://admin:*pass*@192.168.1.** ! rtph264depay ! h264parse ! nvv4l2decoder ! nvoverlaysink

And share resolution of the rtsp source. Looks like it is not 1920x1080.

Hi,
And please follow this to modify dstest3_pgie_config.txt for Jetson Nano, and run

nvidia@nvidia-desktop:~/deepstream_sdk_v4.0_jetson/sources/apps/sample_apps/deepstream-test3$ export DISPLAY=:1(or 0)
nvidia@nvidia-desktop:~/deepstream_sdk_v4.0_jetson/sources/apps/sample_apps/deepstream-test3$ ls
deepstream-test3-app    deepstream_test3_app.o   Makefile
deepstream_test3_app.c  dstest3_pgie_config.txt  README
nvidia@nvidia-desktop:~/deepstream_sdk_v4.0_jetson/sources/apps/sample_apps/deepstream-test3$ ./deepstream-test3-app file:///home/nvidia/deepstream_sdk_v4.0_jetson/samples/streams/sample_720p.mp4
1 Like

Hi DaneLLL,

sorry for the late reply.

output for this command

"gst-launch-1.0 rtspsrc location=rtsp://admin:*pass*@192.168.1.** ! rtph264depay ! h264parse ! nvv4l2decoder ! nvoverlaysink"

:

Setting pipeline to PAUSED ...
Opening in BLOCKING MODE 
Pipeline is live and does not need PREROLL ...
Progress: (open) Opening Stream
Progress: (connect) Connecting to rtsp://admin:pass@192.168.1.77
Progress: (open) Retrieving server options
Progress: (open) Retrieving media info
Progress: (request) SETUP stream 0
Progress: (request) SETUP stream 1
Progress: (open) Opened Stream
Setting pipeline to PLAYING ...
New clock: GstSystemClock
Progress: (request) Sending PLAY request
Progress: (request) Sending PLAY request
Progress: (request) Sent PLAY request
WARNING: from element /GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0: Delayed linking failed.
Additional debug info:
./grammar.y(510): gst_parse_no_more_pads (): /GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0:
failed delayed linking some pad of GstRTSPSrc named rtspsrc0 to some pad of GstRtpH264Depay named rtph264depay0
ERROR: from element /GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstUDPSrc:udpsrc2: Internal data stream error.
Additional debug info:
gstbasesrc.c(3055): gst_base_src_loop (): /GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstUDPSrc:udpsrc2:
streaming stopped, reason not-linked (-1)
Execution ended after 0:00:23.815394113
Setting pipeline to PAUSED ...
Setting pipeline to READY ...
Setting pipeline to NULL ...
Freeing pipeline ...

about your second comment inference worked, but i was also able to run my custom yolo model on the same sample video in the first place. it just doesnt work when i run it on my RTSP stream. i also tried running it on a playback of my rtsp stream and it also did not work. i dont know if it is important, but the playback extension was .mkv

Hi,
You need to figure out how to run the rtsp source in gst-launch-1.0 before running deepstream-test3.
Maybe your source is encoded into h265? You may try rtph265depay and h265parse.

hi DaneLLL,

i am indeed using h265 and 1080p resolution. I have modfied my pipline to look like this :

gst-launch-1.0 rtspsrc location=rtsp://admin:pass@192.168.1.77 ! rtph265depay ! h265parse ! queue ! omxh265dec ! nvoverlaysink

now i am getting this output:

gst-launch-1.0 rtspsrc location=rtsp://admin:pass@192.168.1.77 ! rtph265depay ! h265parse ! queue ! omxh265dec ! nvoverlaysink
Setting pipeline to PAUSED ...
Pipeline is live and does not need PREROLL ...
Progress: (open) Opening Stream
Progress: (connect) Connecting to rtsp://admin:pass@192.168.1.77
Progress: (open) Retrieving server options
Progress: (open) Retrieving media info
Progress: (request) SETUP stream 0
Progress: (request) SETUP stream 1
Progress: (open) Opened Stream
Setting pipeline to PLAYING ...
New clock: GstSystemClock
Progress: (request) Sending PLAY request
Progress: (request) Sending PLAY request
Progress: (request) Sent PLAY request

(gst-launch-1.0:10040): GStreamer-CRITICAL **: 10:13:07.752: gst_caps_is_empty: assertion 'GST_IS_CAPS (caps)' failed

(gst-launch-1.0:10040): GStreamer-CRITICAL **: 10:13:07.753: gst_caps_truncate: assertion 'GST_IS_CAPS (caps)' failed

(gst-launch-1.0:10040): GStreamer-CRITICAL **: 10:13:07.753: gst_caps_fixate: assertion 'GST_IS_CAPS (caps)' failed

(gst-launch-1.0:10040): GStreamer-CRITICAL **: 10:13:07.753: gst_caps_get_structure: assertion 'GST_IS_CAPS (caps)' failed

(gst-launch-1.0:10040): GStreamer-CRITICAL **: 10:13:07.753: gst_structure_get_string: assertion 'structure != NULL' failed

(gst-launch-1.0:10040): GStreamer-CRITICAL **: 10:13:07.753: gst_mini_object_unref: assertion 'mini_object != NULL' failed
NvMMLiteOpen : Block : BlockType = 279 
NVMEDIA: Reading vendor.tegra.display-size : status: 6 
NvMMLiteBlockCreate : Block : BlockType = 279 
Allocating new output: 1920x1088 (x 10), ThumbnailMode = 0
OPENMAX: HandleNewStreamFormat: 3605: Send OMX_EventPortSettingsChanged: nFrameWidth = 1920, nFrameHeight = 1080 
^Chandling interrupt.
Interrupt: Stopping pipeline ...
Execution ended after 0:00:06.850663176
Setting pipeline to PAUSED ...
Setting pipeline to READY ...
Setting pipeline to NULL ...
Freeing pipeline ...

UPDATE: changed the stream to h264 and it also doesnt work.

deepstream-test3 output with h264 RTSP:

Using winsys: x11 
Creating LL OSD context new
0:00:00.899198688 12692   0x5591588440 WARN                 nvinfer gstnvinfer.cpp:515:gst_nvinfer_logger:<primary-nvinference-engine> NvDsInferContext[UID 1]:useEngineFile(): Failed to read from model engine file
0:00:00.899264679 12692   0x5591588440 INFO                 nvinfer gstnvinfer.cpp:519:gst_nvinfer_logger:<primary-nvinference-engine> NvDsInferContext[UID 1]:initialize(): Trying to create engine from model files
0:01:49.876247870 12692   0x5591588440 INFO                 nvinfer gstnvinfer.cpp:519:gst_nvinfer_logger:<primary-nvinference-engine> NvDsInferContext[UID 1]:generateTRTModel(): Storing the serialized cuda engine to file at /opt/nvidia/deepstream/deepstream-4.0/samples/models/Primary_Detector_Nano/resnet10.caffemodel_b1_fp16.engine
Decodebin child added: source
Running...
Decodebin child added: decodebin0
WARNING from element uri-decode-bin: No decoder available for type 'application/x-rtp, media=(string)application, payload=(int)107, clock-rate=(int)90000, encoding-name=(string)VND.ONVIF.METADATA, decodertag=(string)"h3c-v3\ RTCP\=0", a-recvonly=(string)"", ssrc=(uint)22325684, npt-start=(guint64)0, play-speed=(double)1, play-scale=(double)1'.
Warning: No decoder available for type 'application/x-rtp, media=(string)application, payload=(int)107, clock-rate=(int)90000, encoding-name=(string)VND.ONVIF.METADATA, decodertag=(string)"h3c-v3\ RTCP\=0", a-recvonly=(string)"", ssrc=(uint)22325684, npt-start=(guint64)0, play-speed=(double)1, play-scale=(double)1'.
Decodebin child added: decodebin1
Decodebin child added: rtph264depay0
Decodebin child added: h264parse0
Decodebin child added: capsfilter0
Decodebin child added: nvv4l2decoder0
Seting bufapi_version
Opening in BLOCKING MODE 
NvMMLiteOpen : Block : BlockType = 261 
NVMEDIA: Reading vendor.tegra.display-size : status: 6 
NvMMLiteBlockCreate : Block : BlockType = 261 
In cb_newpad
Creating LL OSD context new
^C

similar output when stream is on h265.

thanks

Hi,
Please try uridecodebin:

$ export GST_DEBUG=*FACTORY*:4
$ gst-launch-1.0 uridecodebin uri=RTSP_URI ! nvvoverlaysink

And check if nvv4l2decoder is used.

Hi,
Please also upgrade to DS4.0.1 and give it a try.

Hi,

still the same problem, even after DS4.0.1

Hi,
Please check if you upgrade to r32.2.1.

$ head -1 /etc/nv_tegra_release

If it does not work on r32.2.1, please share log of running

$ export GST_DEBUG=*FACTORY*:4
$ gst-launch-1.0 uridecodebin uri=RTSP_URI ! nvvoverlaysink

Hi DaneLLL
the command

gst-launch-1.0 uridecodebin uri=rtsp://admin:1111@10.0.0.155:554 ! nvoverlaysink

it can work.

Actually,I tested two cameras for deepstream-test5-app, one of which worked and the other don’t.The two cameras are the same brand but different models.The brand is Tiandy. Both cameras have the same configuration.

Both cameras can work when I converted deepstream-test4 to read the RTSP.

hi DaneLLL,

tegra version is r32.2.1

gst log:

gst-launch-1.0 uridecodebin uri=rtsp://admin:22072207@192.168.1.77 ! nvoverlaysink
0:00:00.055232134 10297   0x55935a7720 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:361:gst_element_factory_create: creating element "uridecodebin"
0:00:00.093205034 10297   0x55935a7720 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:361:gst_element_factory_create: creating element "nvoverlaysink"
0:00:00.093591550 10297   0x55935a7720 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:361:gst_element_factory_create: creating element "pipeline"
Setting pipeline to PAUSED ...
0:00:00.104465630 10297   0x55935a7720 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:359:gst_element_factory_create: creating element "rtspsrc" named "source"
0:00:00.107251144 10297   0x55935a7720 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:361:gst_element_factory_create: creating element "rtspwms"
0:00:00.108184961 10297   0x55935a7720 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:361:gst_element_factory_create: creating element "rtspreal"
Pipeline is live and does not need PREROLL ...
Progress: (open) Opening Stream
Progress: (connect) Connecting to rtsp://admin:22072207@192.168.1.77
Progress: (open) Retrieving server options
Progress: (open) Retrieving media info
0:00:02.041509340 10297   0x5593618000 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:361:gst_element_factory_create: creating element "udpsrc"
0:00:02.043707917 10297   0x5593618000 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:361:gst_element_factory_create: creating element "udpsrc"
Progress: (request) SETUP stream 0
0:00:02.196301661 10297   0x5593618000 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:359:gst_element_factory_create: creating element "rtpbin" named "manager"
0:00:02.199127957 10297   0x5593618000 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:361:gst_element_factory_create: creating element "rtpsession"
0:00:02.201130072 10297   0x5593618000 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:361:gst_element_factory_create: creating element "rtpssrcdemux"
0:00:02.204435802 10297   0x5593618000 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:361:gst_element_factory_create: creating element "rtpstorage"
0:00:02.206231299 10297   0x5593618000 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:361:gst_element_factory_create: creating element "funnel"
0:00:02.206385052 10297   0x5593618000 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:361:gst_element_factory_create: creating element "funnel"
0:00:02.208767850 10297   0x5593618000 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:361:gst_element_factory_create: creating element "udpsink"
0:00:02.209844274 10297   0x5593618000 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:361:gst_element_factory_create: creating element "fakesrc"
0:00:02.211069658 10297   0x5593618000 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:361:gst_element_factory_create: creating element "udpsink"
0:00:02.212710570 10297   0x5593618000 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:361:gst_element_factory_create: creating element "udpsrc"
0:00:02.213981007 10297   0x5593618000 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:361:gst_element_factory_create: creating element "udpsrc"
0:00:02.214852219 10297   0x5593618000 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:361:gst_element_factory_create: creating element "udpsrc"
Progress: (request) SETUP stream 1
0:00:02.414731511 10297   0x5593618000 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:361:gst_element_factory_create: creating element "rtpsession"
0:00:02.415494544 10297   0x5593618000 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:361:gst_element_factory_create: creating element "rtpssrcdemux"
0:00:02.416078252 10297   0x5593618000 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:361:gst_element_factory_create: creating element "rtpstorage"
0:00:02.416554197 10297   0x5593618000 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:361:gst_element_factory_create: creating element "funnel"
0:00:02.416873369 10297   0x5593618000 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:361:gst_element_factory_create: creating element "funnel"
0:00:02.422389238 10297   0x5593618000 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:361:gst_element_factory_create: creating element "udpsink"
0:00:02.423188782 10297   0x5593618000 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:361:gst_element_factory_create: creating element "fakesrc"
0:00:02.424250310 10297   0x5593618000 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:361:gst_element_factory_create: creating element "udpsink"
Progress: (open) Opened Stream
Setting pipeline to PLAYING ...
New clock: GstSystemClock
Progress: (request) Sending PLAY request
Progress: (request) Sending PLAY request
Progress: (request) Sent PLAY request
0:00:02.506649910 10297   0x7f84052e30 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:361:gst_element_factory_create: creating element "rtpjitterbuffer"
0:00:02.507866492 10297   0x7f84052e30 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:361:gst_element_factory_create: creating element "rtpptdemux"
0:00:02.538676151 10297   0x7f84052c50 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:361:gst_element_factory_create: creating element "rtpjitterbuffer"
0:00:02.539021834 10297   0x7f84052c50 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:361:gst_element_factory_create: creating element "rtpptdemux"
0:00:04.507960483 10297   0x7f540040f0 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:361:gst_element_factory_create: creating element "decodebin"
0:00:04.508723568 10297   0x7f540040f0 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:359:gst_element_factory_create: creating element "typefind" named "typefind"
Missing element: VND.ONVIF.METADATA RTP depayloader
WARNING: from element /GstPipeline:pipeline0/GstURIDecodeBin:uridecodebin0: No decoder available for type 'application/x-rtp, media=(string)application, payload=(int)107, clock-rate=(int)90000, encoding-name=(string)VND.ONVIF.METADATA, decodertag=(string)"h3c-v3\ RTCP\=0", a-recvonly=(string)"", ssrc=(uint)152338286, npt-start=(guint64)0, play-speed=(double)1, play-scale=(double)1'.
Additional debug info:
gsturidecodebin.c(921): unknown_type_cb (): /GstPipeline:pipeline0/GstURIDecodeBin:uridecodebin0
0:00:04.541300287 10297   0x7f580020f0 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:361:gst_element_factory_create: creating element "decodebin"
0:00:04.541466957 10297   0x7f580020f0 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:359:gst_element_factory_create: creating element "typefind" named "typefind"
0:00:04.545038472 10297   0x7f580020f0 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:361:gst_element_factory_create: creating element "rtph265depay"
0:00:04.549597347 10297   0x7f580020f0 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:361:gst_element_factory_create: creating element "h265parse"
0:00:04.550995026 10297   0x7f580020f0 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:361:gst_element_factory_create: creating element "capsfilter"
0:00:04.697182678 10297   0x7f580020f0 INFO     GST_ELEMENT_FACTORY gstelementfactory.c:361:gst_element_factory_create: creating element "nvv4l2decoder"
Opening in BLOCKING MODE 
NvMMLiteOpen : Block : BlockType = 279 
NVMEDIA: Reading vendor.tegra.display-size : status: 6 
NvMMLiteBlockCreate : Block : BlockType = 279 
^Chandling interrupt.
Interrupt: Stopping pipeline ...
Execution ended after 0:00:32.004334309
Setting pipeline to PAUSED ...
Setting pipeline to READY ...
Setting pipeline to NULL ...
Freeing pipeline ...

i feel it has something to do with missing the following element as it says in the logs :

Missing element: VND.ONVIF.METADATA RTP depayloader

Hi ibondokji,
Please share more information about the rtsp source. If it is a IP camera, please share brand and model ID.

Also please try software decoder. Would like to know if it works in using software decoder.

gst-launch-1.0 rtspsrc location=rtsp://admin:pass@192.168.1.77 ! rtph265depay ! h265parse ! queue ! avdec_h265 ! videoconvert ! xvimagesink