Bug: Incorrect PTS values when seeking using nvv4l2decoder decoder

• Hardware Platform (Jetson / GPU) GPU
• DeepStream Version 6.4
• TensorRT Version8.6.1.6
• NVIDIA GPU Driver Version (valid for GPU only) 535.171.04
Issue Type( questions, new requirements, bugs) Bug

We have a gstreamer pipeline

uridecodebin -> streammuxer -> pgie -> tracker -> osd -> fakesink

We have implemented a method to process certain video segments of a video using Gstreamer seeking controls

We have noticed that when we use the hardware decoder (nvv4l2decoder) with Gstreamer Seeking, the pts values reported are incorrect and not monotonically increasing. Example below ( take a look at the pts values for frame 2,3,4, and 5

frame num = 0 and frame pts = 66666666
frame num = 1 and frame pts = 6200000000
frame num = 2 and frame pts = 6333333333
frame num = 3 and frame pts = 6333333333
frame num = 4 and frame pts = 6333333333
frame num = 5 and frame pts = 6333333333
frame num = 6 and frame pts = 6400000000
frame num = 7 and frame pts = 6400000000
frame num = 8 and frame pts = 6433333333

However when we use the software decoder, we get the correct monotonically increasing pts values

frame num = 0 and frame pts = 6200000000
frame num = 1 and frame pts = 6233333333
frame num = 2 and frame pts = 6266666666
frame num = 3 and frame pts = 6300000000
frame num = 4 and frame pts = 6333333333
frame num = 5 and frame pts = 6366666666
frame num = 6 and frame pts = 6400000000
frame num = 7 and frame pts = 6433333333
frame num = 8 and frame pts = 6466666666

Using the hardware decoder is important since the software decoder results in a drop in processing speed which is important for our usecase. Please investigate and let me know how i can resolve this

sample code on how we create a seek event

  source_bin = pipeline.get_by_name("source")
    

  seek_start_time_ns = int(seek_start_time * Gst.SECOND) 
  seek_stop_time_ns = int(seek_stop_time * Gst.SECOND)

  seek_event = source_bin.seek(
      1.0,
      Gst.Format.TIME,
      Gst.SeekFlags.FLUSH | Gst.SeekFlags.KEY_UNIT | Gst.SeekFlags.ACCURATE,
      Gst.SeekType.SET,
      seek_start_time_ns,
      seek_type_stop,
      seek_stop_time_ns,
  )

Could you please help confirm the following questions?

  1. Which plugin did you get the pts from
  2. Is there a problem with the pts if you don’t seek
  3. Could you provide a simple demo to reproduce this issue

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

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