Please provide complete information as applicable to your setup.
• Hardware Platform (Jetson / GPU) GPU
• DeepStream Version 6.1
• JetPack Version (valid for Jetson only)
• TensorRT Version 8.2.5.1
• NVIDIA GPU Driver Version (valid for GPU only) 510
• Issue Type( questions, new requirements, bugs) question
Hi, I’m trying to visualize circles with pyds.NvDsDisplayMeta along with its num_circles
and circle_params
attributes. I read the post DEEPSTREAM 5.0 draw circles, and I tried to implement an equivalent python implementation:
frame_object_list = nvds_infer_parse_custom(layers_info)
display_meta = pyds.nvds_acquire_display_meta_from_pool(batch_meta)
display_meta.num_circles = len(frame_object_list)
for idx, frame_object in enumerate(frame_object_list):
circle_params = display_meta.circle_params[idx]
# circle_params = pyds.NvOSD_CircleParams()
circle_params.xc = int(frame_object.left)
circle_params.yc = int(frame_object.top)
circle_params.radius = 100
circle_params.circle_color.set(1, 0, 0, 1)
circle_params.has_bg_color = True
circle_params.bg_color.set(1, 0, 0, 1)
However, it seems that even I set display_meta.num_circles = len(frame_object_list)
before manipulating display_meta.circle_params[idx]
, it still cannot work. In this way, it is successful for the first 16th frame_object but it cannot work for the 17th+ frame_object with an error of IndexError. I tried to print len(display_meta.circle_params)
before and after I set display_meta.num_circles = len(frame_object_list)
, and it is always equal to 16. So, I am considering whether there is anyway to increase the len of display_meta.circle_params
to be larger than 16 so that I can add more circles. Do you have any idea?