Package Installation#

This page describes how to install opinf locally.

Important

Like most Python packages, opinf has a few software dependencies. To avoid conflicts with other installed packages, we recommend installing opinf within a new conda environment (recommended) or virtual Python environment .

# Make a fresh conda environment and install Python 3.11.
conda create -n opinf3.11 python=3.11

Be sure to activate the environment before using pip or other installation tools.

# Activate the conda environment (updates the PATH).
$ conda activate opinf3.11

# Verify python is now linked to the conda environment.
$ which python3
/path/to/your/conda/envs/opinf3.11/bin/python3
$ python3 --version
Python 3.11.8

Tip

To check if the package is already installed in the current Python environment, run the following in the command line.

$ python3 -m pip freeze | grep opinf
9:opinf==0.5.1

No output means the package was not found.

Latest Commit to Main Branch#

The following command installs the latest version from the main branch, which may or may not be associated with an official release. This requires git.

conda activate opinf3.11
python3 -m pip install git+https://github.com/Willcox-Research-Group/rom-operator-inference-Python3.git

Source Code#

The final option is to download the entire repository (including tests, documentation, etc.) and install the package from source. This also requires git and is the first step for contributing. See the Developer Guide if you are interested in contributing.

git clone https://github.com/Willcox-Research-Group/rom-operator-inference-Python3.git
conda activate opinf3.11
python3 -m pip install rom-operator-inference-Python3