Skip to content
This repository has been archived by the owner on Sep 16, 2024. It is now read-only.

BKM: How to Reduce Size of the OpenVINO Installation in Deployment

xwu2 edited this page Dec 19, 2019 · 1 revision

By default OpenVINO installs binaries and libs regarding all the platform it supports. This might lead to increased size of final Docker image. Once you have built your application, you use deployment manager tool to only ship the needed files optimize the space usage.

  • In Dockerfiles project, only 'dev' dockerfiles comes with the whole OpenVINO package.
  • Rest of the images(analytics-ffmpeg, analytics-gst) have been optimized through deployment manager.

Starting OpenVINO R3, it comes with Deployment Manager.

Create Deployment Package

  • Install OpenVINO through regular installation

  • Run <INSTALL_DIR>/deployment_tools/tools/deployment_manager.py <--targets> [--output_dir] [--archive_name] [--user_data]

    --targets - List of the target devices where you plan to run your application. (cpu gpu vpu hddl)
    --output_dir - (Optional) Path to the output directory. By default, it set to your home directory
    --archive_name - (Optional) Deployment archive name
    --user_data - (Optional) Path to a directory with user data (IRs, models, datasets, etc.) required 
      for inference. By default, it's set to None, which means that the user data are already present on the target host machine.
    

Deploy Package on Target Hosts

  • Transfer the deployment package to the target device

  • Unpack it to the destination directory tar xf openvino_deployment_package.tar.gz -C <destination_dir>

  • To run inference on a target Intel® Movidius™ VPU or Intel® Vision Accelerator Design with Intel® Movidius™ VPUs, you need to install additional dependencies by running the install_openvino_dependencies.sh script:

    <destination_dir>/openvino/install_dependencies/install_openvino_dependencies.sh

  • Before running your application, make sure to initialize OpenVINO environment by

    source <destination_dir>/openvino/bin/setupvars.sh