Documentation

Manual and examples

Easy step by step installation

If you are new to Python and don’t really know how to install CIGALE, you can follow these simple steps in a terminal shell:

  1. If Anaconda, a software distribution system for data science, is not installed on you system, install it using the installer proposed on Anaconda web page.
  2. Optionally, you should update the conda software with the command conda update conda.
  3. Download the last CIGALE sources from the download page. Extract the downloaded archive. We will make an editable installation so you’ll need to keep the extracted directory but you may delete the archive file.
  4. Create a conda environment in which you will install CIGALE (for instance with Python 3.10):
    conda create -n cigale python=3.10
  5. Activate this environment, you will need to do this every time you want to use CIGALE (just once, at the beginning of the shell session):
    conda activate cigale
  6. Install some of CIGALE dependencies using conda:
    conda install astropy numpy scipy matplotlib configobj rich
  7. In your terminal shell go inside your CIGALE source folder (cd /path/to/cigale) and build the CIGALE database with:
    python setup.py build
  8. Finally, install CIGALE in the environment:
    python -m pip install -e . or alternatively python setup.py develop (deprecated)

VoilĂ ! CIGALE is installed on your computer. Whenever you need to use it, launch a terminal shell, activate the conda environment with conda activate cigale and you will have access to CIGALE commands (pcigale, pcigale-filters, and pcigale-plots) anywhere on your computer.

Notebook explaining how CIGALE builds its models

If you want to understand how CIGALE build its models, you can download this notebook and open it with Jupyter lab (you’ll need to do conda install jupyterlab ipympl if you used the environment described above).

In the notebook, we build a SED step by step from the star formation history to the redshifting and at the end you have an interactive plot to visualise the effects of the various module parameters on the generated spectrum.

Last Update: October 5th, 2022