Installation

You may install the core or the full features set of GEMSEO. See Dependencies for more information. There are different ways to install GEMSEO depending on your platform and Python version.

Requirements

To install GEMSEO, you need a Python environment. We strongly recommend to use Anaconda to create a dedicated environment for GEMSEO.

Anaconda

Anaconda is a free multi-platform Python distribution (for commercial use and redistribution) that facilitates the installation of Python and non-Python packages, since it handles pre-compiled packages. Furthermore, it does not require any administrator privilege. You may install Anaconda and learn how to use it.

Python 3 installation

For Python 3, install the full feature set in an anaconda environment named gemseo for python 3.8 with

conda create -c conda-forge -n gemseo python=3.8 gemseo

You can change the Python version to 3.6, 3.7 or 3.9.

Python 2.7 installation

For Python 2.7, use this file.

Then, activate this environment with:

conda activate gemseo

and you can now proceed with the installation of GEMSEO, see Install from Pypi.

You may leave the Anaconda environment with:

conda deactivate

Install from Pypi

Create an environment, then install the core features of the latest version with:

pip install gemseo

or the full features with:

pip install gemseo[all]

Install from an archive

Create an environment, then install the core features from an archive with:

pip install gemseo-x.y.z.zip

or the full features with:

pip install gemseo-x.y.z.zip[all]

Install the development version

Create an environment, then install the core features of the development version with:

pip install git+https://gitlab.com/gemseo/dev/gemseo.git@develop

or the full features with:

pip install git+https://gitlab.com/gemseo/dev/gemseo.git@develop#egg=gemseo[all]

Test the installation

Basic test

To check that the installation is successful, try to import the module:

python -c "import gemseo"

Warning

If you obtain the error:

“Traceback (most recent call last): File “<string>”, line 1, in <module> ImportError: No module named gemseo“

then the installation failed.

Test the GEMSEO dependencies with the API

You can use the function print_configuration() to print the successfully loaded modules and the failed imports with the reason.

from gemseo.api import print_configuration

print_configuration()

This function is useful when only some of the GEMSEO features appear to be missing. Usually this is related to external libraries that were not installed because the user did not request full features. See Dependencies for more information.

Test with examples

The gallery of examples contains many examples to illustrate the main features of GEMSEO. For each example, you can download a Python script or a Jupyter Notebook, execute it and experiment to test the installation.

Test with unit tests

Run the tests with:

pip install gemseo[all,test]
pytest

Please have a look at the contributing section for more information on testing.