custom yolov8 greater input size error conversion to hef

Hi,
I’m trying to convert a custom YOLOv8s model (exported to ONNX) for object detection with the following specs:

  • Input size: 1024x768
  • Number of classes: 1
  • Standard Ultralytics export

When I run hailomz compile (or through the Jupyter notebook pipeline), I get a parsing error:

ParsingWithRecommendationException: Parsing failed.
UnsupportedShuffleLayerError in op /model.22/dfl/Reshape:
Failed to determine type of layer to create in node /model.22/dfl/Reshape

Hailo recommends using /model.22/Concat_3 as end node. If I do that by editing the output nodes in the Jupiter Notebook

…then parsing succeeds (and suggests me to remove a lot of output layers agin and so on). But at that point I don’t know how to proceed:

  • I’m unsure how to properly configure the rest of the pipeline (e.g., NMS, decoding).
  • I’m also concerned that removing postprocess layers may break inference or outputs, as happened yet.
  • The official examples don’t cover this edge case with YOLOv8 + custom input size + stripped output node.

:red_question_mark:Request

Is there someone available (Hailo team or community) who I could privately send:

  • the .onnx model
  • the calibration dataset (1024+ real RGB frames)

and in return:

  • get the model successfully converted (.hef)
  • along with a minimal working inference script
  • and an explanation of how to treat these cases?


It’s just a bounding box of a single object.
Thanks in advance!

When bringing your own model, you should use the standard workflow instead of the Model Zoo. If you haven’t already, I recommend going through the tutorials to understand the complete process. Within the AI Software Suite Docker container, run the following command to start a Jupyter Notebook server. This server includes notebooks for each step of the workflow.

hailo tutorial

That is just a suggestion and may not necessarily be correct. YOLO models typically have multiple outputs. I recommend taking a look at the models in the Model Zoo. You can download and parse them using the following command:

hailomz parse yolov8m

Open the HAR file in netron or use the hailo visualizer to create an SVG (see tuorial).

https://netron.app/

When part of the model like NMS cannot run on the Hailo device, it needs to be implemented on the host. For YOLO models you can add NMS using the model script or you can run it as part of your application.

GitHub - Hailo Model Zoo - Yolov8s.alls
GitHub - Hailo Model Zoo - Yolov8s_nms_config.json