Skip to content

Installation

Quick Start

  1. Set up your environment – Create a fresh conda/mamba environment using the cloe-org-environments repository. Then, clone cloelib:
git clone https://github.com/cloe-org/cloelib.git
cd cloelib
  1. Check out the latest release (optional but recommended):
git checkout <latest-tag>  # Find tags in "Releases"
  1. Install cloelib – Get the core library up and running:
pip install .
  1. Add optional dependencies – Enhance with external codes and tools:
pip install .[camb,classy,hmcode2020emu,comet-emu,pbjcosmo,pylevin,mpmath,tensorflow,pyinstrument,react]

Note: Some shells require quoting the argument when brackets are present:

pip install ".[camb,classy,hmcode2020emu,comet-emu,pbjcosmo,pylevin,mpmath,tensorflow,pyinstrument,react]"

The installation is now complete.

Optional Dependencies

Several optional dependencies enhance cloelib capabilities:

  • pyinstrument – Time profiling for performance optimization
  • pylevin, mpmath – Required for specific observational probes (e.g., COSEBIs)
  • tensorflow – Needed for certain emulator backends (e.g., HMCode2020emu)
  • react – Installs MGEmu plus the TensorFlow support needed by the ReACT modified-gravity boost module

These are not included in the default installation but can be added as shown above as other external cosmological codes.