Hey,
I am trying to compile custom trained YOLOv8m with P2 head model to hef file. But even though i have made changes in .yaml file and given nodes name according to my model :
parser:
nodes:
null
/model.28/Concat_4
end-node-names:
/model.28/cv2.0/cv2.0.2/Conv
/model.28/cv3.0/cv3.0.2/Conv
/model.28/cv2.1/cv2.1.2/Conv
/model.28/cv3.1/cv3.1.2/Conv
/model.28/cv2.2/cv2.2.2/Conv
/model.28/cv3.2/cv3.2.2/Conv
/model.28/cv2.3/cv2.3.2/Conv
/model.28/cv3.3/cv3.3.2/Conv
when I am doing : hailomz compile --yaml yolov8m.yaml --ckpt yolo8m.onnx --hw-arch hailo8 --calib-path ThermalImages --classes 13
or trying to parse the hailomz parse --yaml yolov8m.yaml --ckpt yolo8m.onnx --hw-arch hailo8
the generated .har file should have output layer 1, output layer 2 and so on. But It is not able to generate that instead it is being concatenated.
You’re getting one big concatenated output instead of separate detection layers because the parser is diving too deep into your YOLOv8 model - it’s going past your intended stopping point and picking up Ultralytics’ built-in postprocessing layers (things like Concat, Sigmoid, DFL, etc.).
Could you share your alls and yaml files for this compilation?
The easiest way for me to help is if you can provide the alls and yaml files, and then I can take a look at what’s going on!
@omria I got the solution for above. But i wanted to know is there a way to reduce context of heavy models like yolov8m or 8l which has 3 and 4 contexts.
i tried reducing parameters and number of layers but still same result.
To reduce the number of contexts for large models on Hailo devices, the most effective approaches are:
Increasing the compression level
Enabling performance mode
Reducing input resolution
Keep in mind that for very large models, hardware limitations may prevent them from fitting into a single context, even with these optimizations applied.