Python Packages

The SalvusMesh, SalvusFlow, and SalvusOpt packages are Python modules and they therefore demand a Python environment. Additionally there is the SalvusFEM helper module.

Please note that Python is not necessary for SalvusCompute and we don't recommend installing the Python packages on an HPC system or other big cluster by default.

Single Python package in the future

Starting with version 0.11 there will only be a single Salvus Python package. User impact will be minimal but installation and upgrading will be easier and less error prone.

Setting up Python

Salvus currently requires an installation of Python 3.7. There are differnet possibilities to achieve this and most should work fine. We recommend to install the latest Miniconda distribution.

Please note that the use of conda is optional, and that the user is responsible for complying with the licenses provided by any Python package used.

If you follow our recommended installation procedure you will first install conda and then create a new conda environment in which to finally install Salvus and all dependencies. In case this is new to you there are a lot of guides and instructions around, e.g. this one.

Installing the Dependencies

Assuming you are following our recommendations of using conda, please download this environment.yml file (right click -> Save Link As...). It describes a conda envionment containing everything required to run Salvus. Additionally it contains the Jupyter project which we recommend as an interface to Salvus.

After installing conda and downloading the file just run:

# Create a new environment with all required dependencies.
conda env create -n salvus -f environment.yml
# Activate that environment.
conda activate salvus
# Activating this plug-in results in nicer error traces in the notebooks.
jupyter nbextension enable skip-traceback/main

By now there should be some indication in your shell that you have an active Salvus conda environment. Remember to always activate it, otherwise Salvus will not be available.

Installating the Salvus Python Packages

Download the Python packages using the Mondaic Downloader and install them (assuming the default installation path) with:

pip install ~/Salvus/python_packages/salvus_*.whl

Installing SalvusToolbox (Optional)

Included by default in the future

Starting with Salvus version 0.11 the toolbox will be included in the default Salvus Python installation to ease the process. The source code to the toolbox will nonetheless still be accessible to you to learn from it and adapt it to your own use cases.

Mondaic supports an open-source repository with various tools for model handling and conversion, which you might find useful to get started with your own simulations. Some of the tutorials make use of it, so feel free to download and install it:

git clone
cd salvus_toolbox
pip install -v -e .