I’m seeing a reproducible DFC export failure on an RTX 5070 Laptop GPU (Compute Capability 12.0) with Hailo DFC 3.34.0.
Initially DFC reported:
No GPU chosen and no suitable GPU found, falling back to CPU
and export completed successfully, producing a valid HEF.
Later DFC reported:
No GPU chosen, Selected GPU 0
and export failed immediately with:
CUDA_ERROR_INVALID_HANDLE
After investigation I found the GPU selection logic in:
hailo_model_optimization/acceleras/utils/nvidia_smi_gpu_selector.py
which automatically selects a GPU whenever:
usage_ratio <= 0.05
(5% GPU memory utilization).
I verified this is not model-related by reproducing the problem with multiple models, including the exact same model that had previously exported successfully.
I then isolated the issue further with a standalone TensorFlow 2.18.0 test in a freshly rebuilt container:
import tensorflow as tf
a = tf.constant([1.0]) b = tf.constant([2.0])
print(a + b)
TensorFlow successfully detects the RTX 5070, creates the GPU device, and reports Compute Capability 12.0, but outputs:
TensorFlow was not built with CUDA kernel binaries compatible with compute capability 12.0. CUDA kernels will be jit-compiled from PTX.
and then fails with:
CUDA_ERROR_INVALID_PTX
followed by:
CUDA_ERROR_INVALID_HANDLE
This occurs before any Hailo export is attempted.
Environment:
Windows 11 running a docker for windows container
Ultralytics 8.4.191
hailo-dataflow-compiler 3.34.0
TensorFlow 2.18.0
CUDA Toolkit 12.5
cuDNN 9.6
RTX 5070 Laptop GPU
NVIDIA Driver 592.82
I also traced the Hailo GPU selection path and found that GPU selection can be bypassed by setting:
export CUDA_VISIBLE_DEVICES=99
for the export process only.
This appears to force CPU-only operation (as referenced in Hailo source comments about using a non-existent GPU ID).
After setting this variable:
DFC no longer reports “Selected GPU 0”
The TensorFlow GPU error does not occur
Export proceeds successfully on CPU
HEF generation succeeds
No GPU activity is observed in nvidia-smi or Windows Task Manager during export
One important note: CUDA_VISIBLE_DEVICES=99 must only be used for export, since it also disables GPU-based training in PyTorch.
My current hypothesis is that TensorFlow GPU execution on Compute Capability 12.0 (RTX 50-series / Blackwell) is failing, while CPU export works correctly.
Has Hailo validated DFC/TensorFlow operation on RTX 50-series GPUs (Compute Capability 12.0)?
Is this a known issue, and is there a planned fix or officially recommended workaround beyond forcing CPU mode with:
export CUDA_VISIBLE_DEVICES=99?