Segmentation fault on Hailo8L using raspberrypi5 with rpi cam

Actually we are using raspberry pi 5 by fixing hailo 8l, and by using this link we set the things up! “GitHub - Seeed-Projects/Benchmarking-YOLOv8-on-Raspberry-PI-reComputer-r1000-and-AIkit-Hailo-8L: This repository provides benchmarks and performance evaluations of the YOLO (You Only Look Once) model running on the Raspberry Pi Compute Module 4 (CM4) with an AI kit.
by running this in live camera, we are facing segmentation fault and all seems to be good in memory too…
The error message displayed like this :

Frame count: 128771
Detection: person 0.90
Left eye: x: 237.00 y: 237.00 Right eye: x: 233.00 y: 237.00
Detection: person 0.83
Left eye: x: 505.00 y: 200.00 Right eye: x: 505.00 y: 200.00
Detection: person 0.87
Left eye: x: 544.00 y: 223.00 Right eye: x: 548.00 y: 223.00

./run.sh: line 28: 7499 Segmentation fault python3 “$1”.py --input rpi

2 Likes

@omria any update on this?

i too facing the same issue. @omria please give an update

Hi @kirank,

Welcome to the Hailo Community!

I’d like to clarify that the project you’re asking about isn’t an official Hailo project, but a community-driven one. It would be best to ask your question in the same topic where the project was originally published.

That being said, I can offer some general advice about the segmentation fault you’re experiencing with YOLOv8 on Hailo 8L and Raspberry Pi 5. This error often points to memory issues or hardware interaction problems. Here are some troubleshooting steps:

  1. Check for memory leaks using Valgrind:

    sudo apt-get install valgrind
    valgrind python3 your_script.py
    
  2. Ensure proper Hailo-8L integration:

    • Restart camera services:
      sudo systemctl restart libcamera-daemon
      
  3. Monitor resource usage with htop or top during runtime.

  4. Try lowering the input frame rate or resolution.

In your Python code, handle exceptions properly:

try:
    while True:
        # Your detection logic
except Exception as e:
    print(f"Error: {e}")
    cleanup_resources()  # Ensure hardware resources are properly released

If the problem continues, try running simpler parts of your pipeline separately (e.g., camera-only or inference-only) to isolate the issue.

I recommend using the official examples as a baseline since they perform similar tasks. They should provide a good starting point for your project.

Let us know how it goes or if you need further assistance!

I have tried the official examples GitHub - hailo-ai/hailo-rpi5-examples, This is shown segmentation fault after some time
The error displayed like this:
Frame count: 154151
Detection: person 0.88
Left eye: x: 457.00 y: 162.00 Right eye: x: 452.00 y: 166.00
Detection: person 0.79
Left eye: x: 223.00 y: 324.00 Right eye: x: 219.00 y: 329.00

Segmentation fault
(venv_hailo_rpi5_examples) test1@rasp:~/hailo-rpi5-examples $