2.0 KiB
2.0 KiB
Build OpenVINO™ Runtime for Raspbian Stretch OS
Note
: Since 2023.0 release, you can compile OpenVINO Intel CPU plugin on ARM platforms.
Hardware Requirements
-
Raspberry Pi 2 or 3 with Raspbian Stretch OS (32 or 64-bit).
Note
: Despite the Raspberry Pi CPU is ARMv8, 32-bit OS detects ARMv7 CPU instruction set. The default
gcccompiler applies ARMv6 architecture flag for compatibility with lower versions of boards. For more information, run thegcc -Q --help=targetcommand and refer to the description of the-march=option.
Compilation
You can perform native compilation of the OpenVINO Runtime for Raspberry Pi, which is the most straightforward solution. However, it might take at least one hour to complete on Raspberry Pi 3.
- Install dependencies:
sudo apt-get update
sudo apt-get install -y git cmake scons build-essential
- Clone the repository:
git clone --recurse-submodules --single-branch --branch=master https://github.com/openvinotoolkit/openvino.git
- Go to the cloned
openvinorepository:
cd openvino/
- Create a build folder:
mkdir build && cd build/
- Build the OpenVINO Runtime:
cmake -DCMAKE_BUILD_TYPE=Release \
-DARM_COMPUTE_SCONS_JOBS=$(nproc --all) \
.. && cmake --build . --parallel
Additional Build Options
- To build Python API, install
libpython3-dev:armhfandpython3-pippackages usingapt-get; then installnumpyandcythonpython modules viapip3, adding the following options:-DENABLE_PYTHON=ON \ -DPYTHON_EXECUTABLE=/usr/bin/python3.7 \ -DPYTHON_LIBRARY=/usr/lib/arm-linux-gnueabihf/libpython3.7m.so \ -DPYTHON_INCLUDE_DIR=/usr/include/python3.7