How to run a .hef detection model on Raspberry Pi 5 + Hailo AI Hat (IP CAMERA RTSP input)?

Hi everyone — I’m working on a detection project and would really appreciate some guidance.

What I have:

  • Raspberry Pi 5 with a Hailo AI Hat attached

  • A trained detection model that I converted to .hef format

  • An IP camera streaming over RTSP (I want to run inference on the RPi using the camera feed)

What I want to do:

  • Run real-time object detection on the Pi using the Hailo AI Hat and the .hef model, ingesting frames from the IP camera (RTSP).

  • Ideally: a simple example or repo I can clone that shows how to load a .hef, run inference, and process/display/save detection results.

What I’m asking:

  1. Which Git repository(s) / example projects should I clone to get started? (Official Hailo examples, community examples, or a sample app that supports RTSP input would be ideal.)

  2. Any step-by-step guide for deploying .hef on Raspberry Pi 5 + Hailo Hat? Important steps I might miss (SDK/firmware versions, drivers, conversion flags, permissions, runtime commands).

  3. Sample code patterns (Python or C++) for:

    • Opening RTSP stream, decoding frames (OpenCV / GStreamer)

    • Pre-processing to the model input shape

    • Running inference with the Hailo runtime and .hef file

    • Post-processing boxes and drawing results / saving output

  4. Performance tips / pitfalls for RPi5 + Hailo Hat (power, thermal, input size, recommended FPS, networking issues).

  5. Any required environment or versions I should match (Hailo SDK/runtime version, Pi OS, kernel/firmware notes).

Hey @Assachan_sanepaserth,

Welcome to the Hailo Community!

I’d recommend checking out a couple of resources that should help you out:

First, take a look at GitHub - hailo-ai/hailo-apps-infra - just make sure you’re on the dev branch since that’s where you’ll find the RTSP support.

If you’re working with C++, this repo might be more useful: GitHub - hailo-ai/Hailo-Application-Code-Examples

Hope this helps!