diff options
Diffstat (limited to 'documentation/openvino.md')
-rw-r--r-- | documentation/openvino.md | 92 |
1 files changed, 92 insertions, 0 deletions
diff --git a/documentation/openvino.md b/documentation/openvino.md new file mode 100644 index 00000000..9794b928 --- /dev/null +++ b/documentation/openvino.md | |||
@@ -0,0 +1,92 @@ | |||
1 | Build a Yocto Image with OpenVINO™ toolkit | ||
2 | ========================================== | ||
3 | |||
4 | Follow the [Yocto Project official documentation](https://docs.yoctoproject.org/brief-yoctoprojectqs/index.html#compatible-linux-distribution) to set up and configure your host machine to be compatible with BitBake. | ||
5 | |||
6 | ## Step 1: Set Up Environment | ||
7 | |||
8 | 1. Clone the repositories. | ||
9 | |||
10 | ``` | ||
11 | git clone https://git.yoctoproject.org/git/poky | ||
12 | git clone https://github.com/openembedded/meta-openembedded | ||
13 | git clone https://git.yoctoproject.org/git/meta-intel | ||
14 | git clone https://github.com/intel/meta-openvino | ||
15 | ``` | ||
16 | |||
17 | |||
18 | 2. Set up the OpenEmbedded build environment. | ||
19 | |||
20 | ``` | ||
21 | source poky/oe-init-build-env | ||
22 | |||
23 | ``` | ||
24 | |||
25 | |||
26 | |||
27 | 3. Add BitBake layers. | ||
28 | |||
29 | |||
30 | ``` | ||
31 | bitbake-layers add-layer ../meta-openembedded/meta-oe | ||
32 | bitbake-layers add-layer ../meta-openembedded/meta-python | ||
33 | bitbake-layers add-layer ../meta-intel | ||
34 | bitbake-layers add-layer ../meta-openvino | ||
35 | |||
36 | ``` | ||
37 | |||
38 | |||
39 | 4. Set up BitBake configurations. | ||
40 | Include extra configuration in the `conf/local.conf` file in your build directory as required. | ||
41 | |||
42 | |||
43 | ``` | ||
44 | MACHINE = "intel-skylake-64" | ||
45 | |||
46 | # Enable building OpenVINO Python API. | ||
47 | # This requires meta-python layer to be included in bblayers.conf. | ||
48 | PACKAGECONFIG:append:pn-openvino-inference-engine = " python3" | ||
49 | |||
50 | # This adds OpenVINO related libraries in the target image. | ||
51 | CORE_IMAGE_EXTRA_INSTALL:append = " openvino-inference-engine" | ||
52 | |||
53 | # This adds OpenVINO samples in the target image. | ||
54 | CORE_IMAGE_EXTRA_INSTALL:append = " openvino-inference-engine-samples" | ||
55 | |||
56 | # Include OpenVINO Python API package in the target image. | ||
57 | CORE_IMAGE_EXTRA_INSTALL:append = " openvino-inference-engine-python3" | ||
58 | |||
59 | ``` | ||
60 | |||
61 | ## Step 2: Build a Yocto Image with OpenVINO Packages | ||
62 | |||
63 | Run BitBake to build your image with OpenVINO packages. For example, to build the minimal image, run the following command: | ||
64 | |||
65 | |||
66 | ``` | ||
67 | bitbake core-image-minimal | ||
68 | |||
69 | ``` | ||
70 | |||
71 | ## Step 3: Verify the Yocto Image | ||
72 | |||
73 | Verify that OpenVINO packages were built successfully. Run the following command: | ||
74 | |||
75 | ``` | ||
76 | oe-pkgdata-util list-pkgs | grep openvino | ||
77 | |||
78 | ``` | ||
79 | |||
80 | |||
81 | If the image build is successful, it will return the list of packages as below: | ||
82 | |||
83 | ``` | ||
84 | openvino-inference-engine | ||
85 | openvino-inference-engine-dbg | ||
86 | openvino-inference-engine-dev | ||
87 | openvino-inference-engine-python3 | ||
88 | openvino-inference-engine-samples | ||
89 | openvino-inference-engine-src | ||
90 | openvino-inference-engine-doc | ||
91 | |||
92 | ``` | ||