On Device Programming
While regular (firmware) on-device development is not possible due to the closed nature of native tooling, we still expose a couple of alternative ways of running custom code:- Scripting - Using Python 3.9 with Script node
- Creating your own NN model to run more computationally heavy features
- Creating custom OpenCL kernels
Using Script node
Using Script node allows you to run custom Python scripts on the device itself, which allows users greater flexibility when constructing pipelines.Script node is also very useful when using multiple neural networks in series and you need to process the output of the first one before feeding an image to the second one. Example here would be face age/gender recognition demo - the first NN would detect faces, pass detections to the Script node which would create ImageManipConfig to crop the original frame and feed the face age/gender recognition NN only the cropped face frame.For running computationally heavy features (e.g., image filters), due to performance reasons you might want to avoid using Script node and rather go with one of the two options described below.Creating custom NN models
You can create custom models with your favorite NN library, convert the model into OpenVINO, and then compile it into the.blob
. More information on this topic can be found in the Converting model to MyriadX blob documentation.Refer to the Computer Vision page to find out more.Supported layers
When converting your model to OpenVINO's IR format (.bin
and .xml
), you have to check if OpenVINO supports the layers that were used. Here are the supported layers and their limitations for various frameworks: