Access NvDsMetadata in GStreamer plugin buffer

How are NvDsMetadata moved through GStreamer buffers?
i.e., I want to access the signed frame_number of a frame in another branch on it’s fakesink for example, I seem to not be able to access the batch metadata…

def ex_probe(pad, info, user_data):
    gst_buffer = info.get_buffer()
    if not gst_buffer:
        print("Unable to get GstBuffer")
        return Gst.PadProbeReturn.OK

    batch_meta = pyds.gst_buffer_get_nvds_batch_meta(hash(gst_buffer))
    if not batch_meta:   ### <<<< ----- this is always true
        print("No batch meta found")
        return Gst.PadProbeReturn.OK

    try:
        for l_frame in batch_meta.frame_meta_list:
           (...)
           (...)

r_fakesink = pipeline.get_by_name("r_fakesink")
sinkpad_r_fakesink = r_fakesink.get_static_pad("sink")
if not sinkpad_r_fakesink:
    sys.stderr.write("Unable to get fakesink R")
else:
    sinkpad_r_fakesink.add_probe(Gst.PadProbeType.BUFFER, ex_probe, 0)

• Hardware Platform (Jetson / GPU) Jetson Xavier AGX
• DeepStream Version 6.3
• JetPack Version (valid for Jetson only) 5.1.2
• Issue Type( questions, new requirements, bugs) Question

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

What is your pipeline? The code looks fine.
Can you provide sample code that reproduces the problem?

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