Installation

Note

This section is written for ZEN-garden users who exclusively use the model as a black-box. Users have no access to the code base and must work within existing functionalities. Alternatively, see the installation guide for developers for instructions on how to fork the ZEN-garden repository in a way that allows you to modify and contribute to the code.

ZEN-garden is written in Python and is available as a package. You can install the package via pip in a terminal or command prompt.

We recommend working from a conda environment for the installation. If you have not installed Anaconda, you can download it from the Anaconda website. For the general installer and beginner documentation of Python, please visit Python.org. You can check if you have Anaconda installed by running the following command in a terminal (MacOS)/command prompt (Windows)

conda --version

You can quickly create an environment with the command below. Here, “zen-garden-env” is the name of the newly created environment:

conda create -n zen-garden-env python==3.13

Activate the environment with the following command

conda activate zen-garden-env

Now you can install the zen-garden package with the following command

pip install zen-garden

To test whether the installation was successful, type:

conda list

into the command prompt. This will print a list of all installed packages. You should see zen_garden in the list.

Warning

ZEN-garden currently only supports Python versions 3.11 through 3.13.

Warning

The directory in which you install Anaconda should not contain any blank spaces in its file path. Otherwise, the installation of ZEN-garden might fail.

Activate Conda environment

After installing ZEN-garden, you need to activate the ZEN-garden environment each time you open a new terminal. To activate the environment, type

conda activate zen-garden-env

into the terminal in which you would like to run ZEN-garden. At any time, you can deactivate the environment by typing:

conda deactivate

Install a Solver

To run ZEN-garden, you also need to install an optimization solver. Two options are:

  1. HiGHS

  2. Gurobi

Per default, ZEN-garden selects the open source solver HiGHS. Academic licenses for Gurobi are available for free and allow you to access all of Gurobi’s functionalities. You can get your Gurobi license from the Gurobi webpage. Follow the instructions to retrieve your Gurobi license key and activate the license for your computer.

Important

If you are planning to use Gurobi, make sure that the version of your Gurobi solver license and your Gurobi installation align.