Hi,
I’m compiling a custom-trained YOLOv8m-pose model (17 keypoints, 1 class - fall detection) using DFC
3.30.0, and the compiler always selects 3 contexts, resulting in 56 FPS on Hailo-8.
However, the official yolov8m_pose.hef from the Model Zoo runs with 2 contexts at 65 FPS — a 16%
performance gap.
Compilation log (key section)
[info] Trying to compile the network in a single context
[info] Single context flow failed: Recoverable single context error
[info] Using Multi-context flow
[info] Resources optimization params: max_control_utilization=60%, max_compute_utilization=60%,
max_memory_utilization=60%
Found valid partition to 2 contexts
Found valid partition to 2 contexts, Performance improved by 13.7%
Found valid partition to 2 contexts, Performance improved by 11.2%
Found valid partition to 3 contexts, Performance improved by 4.7% ← switches to 3 here
…
[info] Partitioner finished after 220 iterations
[info] Applying selected partition to 3 contexts…
The compiler does find valid 2-context partitions, but then switches to 3 contexts because it estimates ~4.7% better theoretical performance. In practice, the context switching overhead makes 3 contexts slower than 2.
What I’ve tried
- context_switch_param(max_control_utilization=0.6, max_compute_utilization=0.6,
max_memory_utilization=0.6, max_utilization=0.8) — still 3 contexts - Setting utilization values higher — compiler still prefers 3 contexts
- I noticed yolov8n.alls in the Model Zoo uses:
allocator_param(width_splitter_defuse=disabled, spatial_defuse_legacy=True) - But when I try spatial_defuse_legacy=True in my model script, it fails with an error (not recognized in public DFC).
Questions
- Is there a supported way to limit max contexts to 2 (e.g., max_contexts=2 parameter)?
- Is spatial_defuse_legacy available in public DFC releases, or is it internal-only?
- Any other approach to force the compiler to keep the 2-context partition it already found?
Environment
- DFC version: 3.30.0
- Target: Hailo-8
- Model: Custom YOLOv8m-pose (ONNX export from Ultralytics, 17 keypoints, 1 class)
- Platform: RK3588 + Hailo-8 M.2
Thanks in advance