How to get NVDSINFER_SEGMENTATION_META when using PeopleSegNet

• Hardware Platform (Jetson / GPU) Jetson
• DeepStream Version 6.1
• JetPack Version (valid for Jetson only) Unknown
• TensorRT Version 8.4
• Issue Type( questions, new requirements, bugs) questions


I’m using PeopleSegNet for inference and I want to retrieve NVDSINFER_SEGMENTATION_META in my own gstreamer plugin.

I refer to dsexample source code and my current implementation is

      frame_meta = (NvDsFrameMeta *)(l_frame->data);

      for (l_user = frame_meta->frame_user_meta_list; l_user != NULL;
           l_user = l_user->next)
        user_meta = (NvDsUserMeta *)(l_user->data);

        g_print("************ meta_type is %d\n", user_meta->base_meta.meta_type);
        if (user_meta->base_meta.meta_type == NVDSINFER_SEGMENTATION_META)

This code works without any errors but it doesn’t print any message I set above.

I assume I’m doing wrong.
Could you give me any suggestions?

please refer to PeopleSegNet deepstream demo GitHub - NVIDIA-AI-IOT/deepstream_tao_apps: Sample apps to demonstrate how to deploy models trained with TAO on DeepStream , from the cfg pgie_peopleSegNet_tao_config.txt, you need to set output-instance-mask=1, then Gst-nvinfer attaches instance mask output in object metadata, please refer to attach_metadata_detector of gst-nvinfer\gstnvinfer_meta_utils.cpp. so mask data is in object 's obj_meta->

I’ve already enabled output-instance-mask flag and I was able to retrieve mask from

But my question is
How can i retrieve data from frame_user_meta_list?

I think nvinfer docs say it attaches mask data to frame_user_meta_list.

the nvinfer doc said “Gst-nvinfer attaches instance mask output in object metadata.”, it is in object metadata, frame_user_meta_list is used to save user meta, object meta and user meta are different, please refer to MetaData in the DeepStream SDK — DeepStream 6.1.1 Release documentation

Okay I got it.

Thank you very much!

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