DeepStream 6.2 - RTSP streaming is not working for NVIDIA Jetson AGX Orin kit

**• NVIDIA Jetson AGX Orin Kit
**• DeepStream Version 6.2
**• JetPack Version: 5.0.2-b231
• Issue Type( bugs)
**• How to reproduce the issue? I am running the config file source1_usb_dec_infer_resnet_int8.txt using deepstream-app

I have been using Deepstream for a year now. However, I used it on dGPU and still getting used to Jetson Orin Kit.

Recently, we installed the e-con_e-cam20_cuoagx 6 synchronized cameras. I am running the tests with Deepstream.
When I am running with the EGL sink option then DeepStream is working well. The frame rate is stable at 60 FPS for all six cameras. However when I run it with the RSTP streaming option then a problem occurs.

When I try to see the result of streaming using VLC, I only receive a blank screen that closes soon after. Sometimes the frame rate drops as well (I can see it on the console).

Here is the console result of the RTSP streaming case:

*** DeepStream: Launched RTSP Streaming at rtsp://localhost:8554/ds-test ***

Opening in BLOCKING MODE
0:00:02.772901904 5957 0xaaaabd3692a0 INFO nvinfer gstnvinfer.cpp:680:gst_nvinfer_logger:<primary_gie> 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/configs/deepstream-app/…/…/models/Primary_Detector/resnet10.caffemodel_b1_gpu0_int8.engine
INFO: [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:02.895334626 5957 0xaaaabd3692a0 INFO nvinfer gstnvinfer.cpp:680:gst_nvinfer_logger:<primary_gie> 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/configs/deepstream-app/…/…/models/Primary_Detector/resnet10.caffemodel_b1_gpu0_int8.engine
0:00:02.924887587 5957 0xaaaabd3692a0 INFO nvinfer gstnvinfer_impl.cpp:328:notifyLoadModelStatus:<primary_gie> [UID 1]: Load new model:/opt/nvidia/deepstream/deepstream-6.2/samples/configs/deepstream-app/config_infer_primary.txt sucessfully

Runtime commands:
h: Print this help
q: Quit

    p: Pause
    r: Resume

NOTE: To expand a source in the 2D tiled display and view object details, left-click on the source.
To go back to the tiled display, right-click anywhere on the window.

** INFO: <bus_callback:239>: Pipeline ready

** INFO: <bus_callback:225>: Pipeline running

NvMMLiteOpen : Block : BlockType = 4
===== NVMEDIA: NVENC =====
NvMMLiteBlockCreate : Block : BlockType = 4
H264: Profile = 66, Level = 0
NVMEDIA: Need to set EMC bandwidth : 814666
NVMEDIA_ENC: bBlitMode is set to TRUE

**PERF: FPS 0 (Avg) FPS 1 (Avg) FPS 2 (Avg) FPS 3 (Avg) FPS 4 (Avg) FPS 5 (Avg)
**PERF: 33.29 (32.90) 33.60 (33.30) 33.86 (33.70) 32.72 (32.63) 32.80 (32.29) 31.85 (31.44)
**PERF: 34.72 (34.31) 34.73 (34.42) 34.74 (34.52) 34.74 (34.09) 34.76 (34.15) 34.74 (33.91)
**PERF: 34.81 (34.52) 34.80 (34.58) 34.81 (34.64) 34.79 (34.39) 34.78 (34.43) 34.78 (34.29)
q
Quitting
nvstreammux: Successfully handled EOS for source_id=0
nvstreammux: Successfully handled EOS for source_id=1
nvstreammux: Successfully handled EOS for source_id=2
nvstreammux: Successfully handled EOS for source_id=3
nvstreammux: Successfully handled EOS for source_id=4
nvstreammux: Successfully handled EOS for source_id=5

I tested it with different scenarios, including with a single camera. Also, I tested the file sink option, then the file itself is blank as well. I am running Orin Kit at max mode.

  1. did you modify the source1_usb_dec_infer_resnet_int8.txt? if yes, please share this file.
  2. please set enc-type to 1 and try again, it will use softwrae encoding.
  3. please check the hardware encoding separately. please execute this command " gst-launch-1.0 filesrc location=/opt/nvidia/deepstream/deepstream/samples/streams/sample_720p.mp4 ! qtdemux ! h264parse ! nvv4l2decoder ! nvvideoconvert ! ‘video/x-raw(memory:NVMM),format=I420’ ! nvv4l2h264enc bitrate=1000000 ! h264parse ! qtmux ! filesink location=./out.mp4", and check if out.mp4 is blank.

Hi,thank you for your reply

  1. This is the source1_usb_dec_infer_resnet_int8.txt that I am using is below:

In this version the encoding is set to software. The one that I used previously was set to hardware encoding.

[application]
enable-perf-measurement=1
perf-measurement-interval-sec=5
#gie-kitti-output-dir=streamscl

[tiled-display]
enable=1
rows=3
columns=2
width=1280
height=720

[source0]
enable=1
#Type - 1=CameraV4L2 2=URI 3=MultiURI
type=1
camera-width=1920
camera-height=1080
camera-fps-n=65
camera-fps-d=1
camera-v4l2-dev-node=0

[source1]
enable=1
#Type - 1=CameraV4L2 2=URI 3=MultiURI
type=1
camera-width=1920
camera-height=1080
camera-fps-n=65
camera-fps-d=1
camera-v4l2-dev-node=1

[source2]
enable=1
#Type - 1=CameraV4L2 2=URI 3=MultiURI
type=1
camera-width=1920
camera-height=1080
camera-fps-n=65
camera-fps-d=1
camera-v4l2-dev-node=2

[source3]
enable=1
#Type - 1=CameraV4L2 2=URI 3=MultiURI
type=1
camera-width=1920
camera-height=1080
camera-fps-n=65
camera-fps-d=1
camera-v4l2-dev-node=3

[source4]
enable=1
#Type - 1=CameraV4L2 2=URI 3=MultiURI
type=1
camera-width=1920
camera-height=1080
camera-fps-n=65
camera-fps-d=1
camera-v4l2-dev-node=4

[source5]
enable=1
#Type - 1=CameraV4L2 2=URI 3=MultiURI
type=1
camera-width=1920
camera-height=1080
camera-fps-n=65
camera-fps-d=1
camera-v4l2-dev-node=5

[sink0]
enable=0
#Type - 1=FakeSink 2=EglSink/nv3dsink(Jetson only) 3=File 4=RTSPStreaming 5=nvdrmvideosink
type=2
sync=0
conn-id=0
width=0
height=0
plane-id=1
source-id=0

[sink1]
enable=0
type=3
#1=mp4 2=mkv
container=1
#1=h264 2=h265 3=mpeg4
codec=1
encoder type 0=Hardware 1=Software
enc-type=0
sync=0
bitrate=2000000
#H264 Profile - 0=Baseline 2=Main 4=High
#H265 Profile - 0=Main 1=Main10
profile=0
output-file=out.mp4
source-id=0

[sink2]
enable=1
#Type - 1=FakeSink 2=EglSink 3=File 4=RTSPStreaming 5=nvdrmvideosink
type=4
#1=h264 2=h265
codec=1
encoder type 0=Hardware 1=Software
enc-type=1
sync=0
bitrate=4000000
#H264 Profile - 0=Baseline 2=Main 4=High
#H265 Profile - 0=Main 1=Main10
profile=0
set below properties in case of RTSPStreaming
rtsp-port=8554
udp-port=5400

[osd]
enable=1
border-width=2
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

[streammux]
##Boolean property to inform muxer that sources are live
live-source=1
batch-size=1
##time out in usec, to wait after the first buffer is available
##to push the batch even if the complete batch is not formed
batched-push-timeout=40000
#set muxer output width and height
width=1280
height=720
##If set to TRUE, system timestamp will be attached as ntp timestamp
##If set to FALSE, ntp timestamp from rtspsrc, if available, will be attached
#attach-sys-ts-as-ntp=1

#config-file property is mandatory for any gie section.
#Other properties are optional and if set will override the properties set in
#the infer config file.
[primary-gie]
enable=1
model-engine-file=…/…/models/Primary_Detector/resnet10.caffemodel_b1_gpu0_int8.engine
#Required to display the PGIE labels, should be added even when using config-file
#property
batch-size=1
#Required by the app for OSD, not a plugin property
bbox-border-color0=1;0;0;1
bbox-border-color1=0;1;1;1
bbox-border-color2=0;0;1;1
bbox-border-color3=0;1;0;1
interval=0
#Required by the app for SGIE, when used along with config-file property
gie-unique-id=1
config-file=config_infer_primary.txt

[tests]
file-loop=0

I set the software encoding and run the DeepStream. The result was the same:

*** DeepStream: Launched RTSP Streaming at rtsp://localhost:8554/ds-test ***

0:00:02.741270509 10010 0xaaaae9bf6780 INFO nvinfer gstnvinfer.cpp:680:gst_nvinfer_logger:<primary_gie> 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/configs/deepstream-app/…/…/models/Primary_Detector/resnet10.caffemodel_b1_gpu0_int8.engine
INFO: [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:02.869694208 10010 0xaaaae9bf6780 INFO nvinfer gstnvinfer.cpp:680:gst_nvinfer_logger:<primary_gie> 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/configs/deepstream-app/…/…/models/Primary_Detector/resnet10.caffemodel_b1_gpu0_int8.engine
0:00:02.899625603 10010 0xaaaae9bf6780 INFO nvinfer gstnvinfer_impl.cpp:328:notifyLoadModelStatus:<primary_gie> [UID 1]: Load new model:/opt/nvidia/deepstream/deepstream-6.2/samples/configs/deepstream-app/config_infer_primary.txt sucessfully

Runtime commands:
h: Print this help
q: Quit

p: Pause
r: Resume

NOTE: To expand a source in the 2D tiled display and view object details, left-click on the source.
To go back to the tiled display, right-click anywhere on the window.

** INFO: <bus_callback:239>: Pipeline ready

** INFO: <bus_callback:225>: Pipeline running

**PERF: FPS 0 (Avg) FPS 1 (Avg) FPS 2 (Avg) FPS 3 (Avg) FPS 4 (Avg) FPS 5 (Avg)
**PERF: 26.63 (26.10) 25.29 (25.02) 25.82 (25.54) 26.26 (26.01) 27.31 (27.13) 26.44 (26.35)
**PERF: 25.45 (25.72) 25.49 (25.30) 25.48 (25.43) 25.40 (25.55) 25.41 (25.82) 25.43 (25.64)
**PERF: 24.46 (25.15) 24.48 (25.00) 24.46 (25.08) 24.51 (25.14) 24.53 (25.21) 24.47 (25.11)

(deepstream-app:10010): GLib-GObject-WARNING **: 09:43:54.107: g_object_get_is_valid_property: object class ‘GstUDPSrc’ has no property named ‘pt’
**PERF: 24.88 (25.05) 24.87 (24.94) 24.83 (24.99) 24.84 (25.04) 24.82 (25.14) 24.86 (25.01)
**PERF: 25.23 (25.13) 25.22 (25.00) 25.23 (25.04) 25.24 (25.08) 25.24 (25.16) 25.23 (25.10)
**PERF: 25.40 (25.18) 25.52 (25.07) 25.52 (25.11) 25.51 (25.14) 25.52 (25.20) 25.52 (25.16)
q
Quitting
nvstreammux: Successfully handled EOS for source_id=0
nvstreammux: Successfully handled EOS for source_id=1
nvstreammux: Successfully handled EOS for source_id=2
nvstreammux: Successfully handled EOS for source_id=3
nvstreammux: Successfully handled EOS for source_id=4
nvstreammux: Successfully handled EOS for source_id=5
App run successful

The frame rate is dropping and the VLC is blank and then immediately turns off.

I tried to test hardware encoding separately, but it seems there might be a syntax error in command. I tried different variations, but couldn’t find the right one:

netai@endbox1:~$ gst-launch-1.0 filesrc location=/opt/nvidia/deepstream/deepstream/samples/streams/sample_720p.mp4 ! qtdemux ! h264parse ! nvv4l2decoder ! nvvideoconvert ! ‘video/x-raw(memory:NVMM),format=I420’ ! nvv4l2h264enc bitrate=1000000 ! h264parse ! qtmux ! filesink location=./out.mp4

bash: syntax error near unexpected token `(’

There is no update from you for a period, assuming this is not an issue anymore. Hence we are closing this topic. If need further support, please open a new one. Thanks

from the log, the fps is stable 25, why the fps is dropping?

please enable [sink1] and try again, is the output out.mp4 ok? wondering it is encoding issue or RTSP issue.

correction.
gst-launch-1.0 filesrc location=/opt/nvidia/deepstream/deepstream/samples/streams/sample_720p.mp4 ! qtdemux ! h264parse ! nvv4l2decoder ! nvvideoconvert ! video/x-raw\(memory:NVMM\),format=I420 ! nvv4l2h264enc bitrate=1000000 ! h264parse ! qtmux ! filesink location=./out.mp4

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