RTSP stream delay

I am using Docker image from nvcr.io/nvidia/deepstream:5.0.1-20.09-devel
• Hardware Platform (Jetson / GPU) GPU
• DeepStream Version 5.0.1
• JetPack Version (valid for Jetson only)
• TensorRT Version
• NVIDIA GPU Driver Version (valid for GPU only) 11.1
• Issue Type( questions, new requirements, bugs) questions
• How to reproduce the issue ? (This is for bugs. Including which sample app is using, the configuration files content, the command line used and other details for reproducing)
• Requirement details( This is for new requirement. Including the module name-for which plugin or for which sample application, the function description)

I’m using deepstream 5.0 python version to process a single RTSP stream. I am not able to make it run in real time without modifying interval property of the primary-gie. I my camera runs at 30 fps and my model at 10 fps, setting interval=3 results in real time performane (it is actually skipping 2 out of 3 frames). This approach forces you to know model performance and camera frame rate which I cannot afford for my current application.

I have tried to setting live-source=True in streammux and sync=0 in RTSP sink, but this results in large delays. I am checking performance by adding a timestamp to the IP camera stream, so I can compare camera server stream with Deepstream output.

Is there anyway to fix this problem?

The model is the bottleneck, when the model is slow, the whole pipeline is slow. It can not reach so-called “real time” by setting the pipeline parameters.

Yes I understand that. The question refers to the possibility of obtaining always the last available frame without suffering delays, this is, force the pipeline to work at model speed without knowing camera frame rate

By setting live-source=True in streammux and sync=0 in RTSP sink, you have already make “force the pipeline to work at model speed without knowing camera frame rate”.

What kind of delay do you mean?

Well, that doesn’t work as it should. Time difference between IP camera video and deepstream output is about 10 seconds

You can adjust rtspsrc latency by setting “latency” in [source] group for your rtsp source. DeepStream Reference Application - deepstream-app — DeepStream 6.3 Release documentation
The delay is also related to the slow model. The processing time of the model is part of the delay.

Hello @Fiona.Chen , I adjust rtspsrc latency by setting “latency” in [source] group for your rtsp source. to > 0 made corrupt frame affter decode, and if set to latency 0 will not corrupt frame but the delay stream too hight. I dont know why to handle this

Hi trild-vietnam,

Please help to open a new topic if haven’t root cause it.

Thanks