Model Conversion
Overview
To deploy your custom models on Luxonis devices, it's essential to convert them from their initial frameworks (such as PyTorch, TFLite, etc.) into a format compatible with the RVC Platform you aim to run them on. The conversion process involves the following steps:- Prepare the model source;
- Prepare calibration data (optional);
- Convert the model to one of the RVC compiled formats.
Preparation
Model Source
The model of interest should be prepared in one of the following formats:- ONNX (
.onnx
), - OpenVINO IR (
.xml
and.bin
), or - TensorFlow Lite (
.tflite
).
Models already converted for the RVC platform cannot be reused as conversion sources. To migrate between RVC platforms, you must use the original model (e.g. Pytorch or ONNX) and re-convert it.If the original source is unavailable, you can look for (similar) models in public repositories such as:
Calibration Data
Calibration data is used to guide the model quantization. You can read more about the process on the Concepts page. If you do not plan to quantize your model during conversion, you can skip this step.Conversion for RVC Platform
Once the model source and calibration data are prepared, you can proceed with conversion for the RVC Platform you aim to utilize (RVC compiled format). We have prepared tools that support both online and offline conversion. Online conversion particularly convinient as it requires no system preparation and can be done in a few clicks. Offline conversion runs on your system and is useful in settings with limited internet access or for integrating the conversion into your workflow. Additionally, to allow full customability, we explain steps for manual conversion.- Online conversion:
- HubAI (recommended) - conversion for all RVC platforms,
- BlobConverter (legacy) - conversion for RVC2 and RVC3 platforms.
- YOLO Simplified Conversion (legacy) - conversion of YOLO models for RVC2 and RVC3 platforms.
- Offline conversion:
- ModelConverter (recommended) - conversion for all RVC platforms,
- Manual conversion for RVC2/RVC3 and RVC4 platforms.