Post-Training Optimization Toolkit Installation Guide

Prerequisites

The minimum and the recommended requirements to run the Post-training Optimization Toolkit are the same as in OpenVINO™.

Install and Set Up Post-Training Optimization Toolkit

In the instructions below, <INSTALL_DIR> is the directory where the Intel® distribution of OpenVINO™ toolkit is installed. Post-training Optimization Toolkit (POT) is distributed as a part of the OpenVINO™ release package, and to use POT as a command-line tool, you need to install OpenVINO™ as well as POT dependencies, namely Model Optimizer and Accuracy Checker. POT source files are available from the <INSTALL_DIR>/deployment_tools/tools/post_training_optimization_toolkit directory after the OpenVINO™ installation. It is recommended to create a separate Python* environment before installing the OpenVINO™ and its components. To set up the POT in your environment, follow the steps below.

Set up the Model Optimizer and Accuracy Checker components

  • To set up the Model Optimizer:
    1. Go to <INSTALL_DIR>/deployment_tools/model_optimizer/install_prerequisites.
    2. Run the script to configure the Model Optimizer:
      sudo ./install_prerequisites.sh
    3. To verify that the Model Optimizer is installed, run <INSTALL_DIR>/deployment_tools/model_optimizer/mo.py -h.
  • To set up the Accuracy Checker:
    1. Go to <INSTALL_DIR>/deployment_tools/open_model_zoo/tools/accuracy_checker.
    2. Run the setup.py script:
      python3 setup.py install
    3. Now the Accuracy Checker is available in the command line by the accuracy_check alias. To verify it, run accuracy_check -h.

Set up the POT

  1. Go to <INSTALL_DIR>/deployment_tools/tools/post_training_optimization_toolkit.
  2. On Linux*, run the setup.py script:

    python3 setup.py install

    On Windows* or macOS*, run the following command:

    pip3 install scipy==1.2.1 jstyleson==0.0.2 numpy==1.16.3 pandas==0.24.2 hyperopt==0.1.2 addict==2.2.1 chainer==7.7.0 && pip3 install . --no-deps
  3. Now the POT is available in the command line by the pot alias. To verify it, run pot -h.