Setting Hailo venv for pycharm [using run/debug config]

I have recently got my rpi5 ai kit.
I tried working using pychram, mainly for its great debugger, indexing and the convenience of an IDE.

:small_orange_diamond:The target is being able to run the “basic pipelines examples” scripts.
I struggled making the venv to work with pycharm using its run/debug config,

I couldn’t find any guide for it, so I’ll try describe the process here, hoping it can help similar cases in the future.
:small_orange_diamond:I am sure there are better ways to configure it dynamically and globally.
:small_orange_diamond:I couldn’t find any post about it when searching this platform (and Google) for “Pycharm”, so I figured it worth sharing.
:small_orange_diamond:It is likely I forgot something, please comment if you find missing steps or a better way :sunglasses:

  1. Enter pychram’s setting > Project > Python interpreter > Add interpreter > direct it to /hailo-rpi5-examples/venv_hailo_rpi5_examples/bin/python3. That will allow you pick it from the run/debug window

  1. on run/debug:

the text from the environment variables: PYTHONUNBUFFERED=1;TAPPAS_POST_PROC_DIR=/usr/lib/aarch64-linux-gnu/hailo/tappas/post-process/

it is obviously depend by your installation, but I did it as the “getting started” suggests, I assume you will too.

  1. on the py file, under get_pipeline_string, replace line 106 with 105:
    + f"hailofilter so-path=/usr/lib/aarch64-linux-gnu/hailo/tappas/post-process/libyolo_hailortpp_post.so qos=false ! "

  2. Now the app runs via pycharm:

  1. NOTE: the debugger triggered properly by breakpoints,
    Except for breakpoints the app_callback which are being “overlooked” and I haven’t figured it out yet. (will update here once I’ll fix it)

Thank you for this Guide Omer!