Mac/OSX Installation Guide#

Quickstart#

The following commands should be sufficient to get you started with installing and using IDAES. For more information on these steps, see below.

# Set up & activate Conda new environment with IDAES-PSE
conda create --yes --name my-idaes-env -c conda-forge -c IDAES-PSE python=3.10 idaes-pse
conda activate my-idaes-env

# Install IDAES Extensions
idaes get-extensions --extra petsc

# Install and browse IDAES Examples (optional)
pip install idaes-examples
idaesx gui   # OR: jupyter notebook $(idaesx where)

# Run Tests
pytest --pyargs idaes -W ignore

Warning

Currently, the macOS x86_64 binaries do not include HSL linear solvers, k_aug, or dot_sens, so some linear solvers in Ipopt and some uncertainty propagation features may not be available. Some tests may also fail due to missing features.


Installing IDAES#

To get IDAES fully set up on your machine, we’ll go through the steps to get idaes-pse package installed as well as setting up the IDAES extensions, which includes some extra solvers and function libraries, the IDAES example files, and the IDAES tests.

Note

If you want to install multiple versions of IDAES in different environments, you can set the IDAES_DATA environment variable before installing or using IDAES. The easiest way to do this is to set the environment variable as part of activating your environment before installing IDAES. Setting this environment variable will keep binary extensions and configuration files separate for the different IDAES versions. For more information about setting environment variables in conda environments see https://conda.io/projects/conda/en/latest/user-guide/tasks/manage-environments.html#saving-environment-variables. Using virtual environments (venv), the easiest way to set environment variables is to edit the activate script. You can edit the deactivate section to unset the variable when deactivating the environment as well.

Install Prerequisites#

Install Miniconda

  1. Download Miniconda

  2. Open a terminal window & run the downloaded script.

Install IDAES-PSE#

We recommend using Conda to manage your environment & modules.

# Create a new Conda environment (Here named my-idaes-env, but this is up to you)
conda create --yes --name my-idaes-env python=3.10
conda activate my-idaes-env

# Install IDAES Conda package
conda install --yes -c IDAES-PSE -c conda-forge idaes-pse

Note

The command above will install the most recent stable (release) version of IDAES. To install other versions of IDAES, including pre-release versions, refer to the Versioned IDAES Installation guide

Install IDAES Extensions#

Run the idaes get-extensions command to install the compiled binaries. These binaries include solvers and function libraries. The PETSc solver is optional and can be omitted. See Binary Packages for more details

idaes get-extensions --extra petsc

Note

If you are not able to successfully run the idaes get-extensions command due to network security settings or another reason, you can download binary release files from IDAES/idaes-ext, and extract them in the directory indicated by the idaes bin-directory command. You will need both the idaes-lib-* and idaes-solvers-* files appropriate for your operating system.

Install IDAES Examples#

To run the examples on your own computer, follow the instructions on the idaes-examples page on PyPI.

Run IDAES Tests#

Run the IDAES test suite to verify that your installation has been successful.

pytest --pyargs idaes -W ignore

You should see the tests run and all should pass to ensure the installation worked. You may see some “Error” level log messages, but they are okay, and produced by tests for error handling. The number of tests that failed and succeeded is reported at the end of the pytest output. If you do not have the IDAES binary extensions installed, some tests are expected to fail warning you of missing solvers or property functions. Some tests involving solvers may also fail due to differences in solver versions and features available.

You can ask questions using the Github Discussion Forum or report problems on the Github issues page (Please try to be specific about the command and the offending output.)