Installation

Installation

๐ŸŒ Optimum can be installed using pip as follows:

Copied

python -m pip install optimum

If youโ€™d like to use the accelerator-specific features of ๐ŸŒ Optimum, you can install the required dependencies according to the table below:

Accelerator
Installation

pip install --upgrade-strategy eager install optimum[onnxruntime]

pip install --upgrade-strategy eager optimum[neural-compressor]

pip install --upgrade-strategy eager optimum[openvino,nncf]

pip install --upgrade-strategy eager optimum[habana]

pip install --upgrade-strategy eager optimum[furiosa]

The --upgrade-strategy eager option is needed to ensure the different packages are upgraded to the latest possible version.

If youโ€™d like to play with the examples or need the bleeding edge of the code and canโ€™t wait for a new release, you can install the base library from source as follows:

Copied

python -m pip install git+https://github.com/boincai/optimum.git

For the accelerator-specific features, you can install them by appending optimum[accelerator_type] to the pip command, e.g.

Copied

python -m pip install optimum[onnxruntime]@git+https://github.com/boincai/optimum.git

Last updated