Hello everyone,
Im working on the detection hailo rpi5 examples : GitHub - hailo-ai/hailo-rpi5-examples
Is there a way to adjust the thickness of the rectangle surrounding detected objects or change the font size of the labels?
thanks for your help
Hello everyone,
Im working on the detection hailo rpi5 examples : GitHub - hailo-ai/hailo-rpi5-examples
Is there a way to adjust the thickness of the rectangle surrounding detected objects or change the font size of the labels?
thanks for your help
hello,
does somebody knows how to do it please ?
Hey @user82 ,
Hailo’s GStreamer-based inference uses hailonet for inference, and post-processing is handled by the hailooverlay element.
Modifying Bounding Box Thickness in Post-Processing
Since hailooverlay does not provide a direct thickness option, you need to modify the C++ post-processing code that generates the overlay.
hailo_common.hpp or hailo_objects.hpp that creates bounding boxes:cv::rectangle(frame, cv::Point(xmin, ymin), cv::Point(xmax, ymax), color, thickness);
thickness parameter:cv::rectangle(frame, cv::Point(xmin, ymin), cv::Point(xmax, ymax), color, 4);
thickness value makes bounding boxes thicker.By modifying the thickness parameter in the C++ post-processing code, you can control the thickness of the bounding boxes generated by hailooverlay. Adjust the value according to your preferences and test the pipeline to achieve the desired visual appearance.
Remember to recompile the post-process before re-running.
If you encounter any issues or need further assistance, please let me know!
hi @omria,
thanks for your answer
I searched on the hailo github and i found that those file are there tappas/core/hailo/general at 7e36ff78bb99c32700efe5dad3820271210c3f58 · hailo-ai/tappas · GitHub
But I dont understand how to apply those changement to my code because those files are not in the file of my code
@user82
If you are open to using DeGirum PySDK, I can guide you to show how to do this. We have overlay_line_width and overlay_font_scale parameters in our model info that allow you to control overlay properties.
if the solution of @omria is easy to do i prefer to follow it
Hey @user82,
The files are located in our infrastructure repository at GitHub - hailo-ai/hailo-apps-infra. When you install the examples package, this repository is automatically installed in your virtual environment.
To make your changes:
If you need help with any of these steps or encounter any issues during the process, please don’t hesitate to ask for assistance.
Thanks @omria, but i dont find the files hailo_common.hpp or hailo_objects.hppin GitHub - hailo-ai/hailo-apps-infra. I only find them here : tappas/core/hailo/general at 7e36ff78bb99c32700efe5dad3820271210c3f58 · hailo-ai/tappas · GitHub
hi @omria ,
do you know where i can modify those files, i’m still searching for them
thanks
I can’t find them either. I can only find /usr/lib/aarch64-linux-gnu/hailo/tappas/post_processes and I really want to be able to modify line 84 of gstreamer_helper_pipelines.py so I can rotate my video camera 90 degrees. But God help me I’m hours into trying to locate that file somewhere on my system.