Hailo rpi5 examples cpu load

Hi all,

I followed all the steps to install the AI KIT on Pi5.

Running:

basic_pipeline/detection.py --input rpi -f

I got a cpu load of 106%, while using the cmd

 rpicam-hello --post-process ...

the cpu load is about 20%.

Anyone can confirm that the python script performs less then rpicam-hello?

Hello @mattia.pnet,

Welcome to the Hailo Community. Let me clarify the difference between the two examples you’re referring to:

  1. rpicam-hello: This is a simple “hello world” equivalent for cameras. It primarily focuses on starting a camera preview stream and displaying it on the screen. It’s a basic demonstration of camera functionality.
  2. Basic Pipeline repository: This contains more complex examples of pipelines for Hailo’s RPi5 platform. These examples showcase advanced computer vision tasks such as:
  • Object detection
  • Human pose estimation
  • Instance segmentation

The repository is designed to provide you with a foundation for building your own projects using these sophisticated vision capabilities.

Given the complexity of the tasks, the detection.py script will indeed place a heavier load on the CPU compared to the simple camera preview. This is due to the additional processing required for detection and analysis tasks.

Let me know if you need any further explanation or have questions about implementing these examples in your projects.

Regards

Hi @omria ,

thank you for your quick reply.
I’m not sure to understand your point because the cmd:

rpicam-hello -t 0 --post-process-file ~/rpicam-apps/assets/hailo_yolov8_inference.json --lores-width 640 --lores-height 640

not perform only a camera preview, but use HAILO library to make object detection and the others stuff.

Maybe top is not the right measuring tool?

Let’s look at it this way:
The rpicam app is a C++ application optimized for the RPi5, resulting in lower CPU load. It efficiently uses the Hailo8L and Hailo library. In contrast, the detection.py script is a GStreamer and Python-based example, which naturally has a heavier CPU load and runs slightly slower due to Python’s nature. However, this Python script offers more features and is easier to adapt for real-world applications.

1 Like