Installation

Installation#

Beorn can be installed using pip. This should ensure that all required dependencies are made available during the installation process. Note that some dependencies may require additional system packages to be installed.

The dependencies for Beorn are listed in the pyproject.toml file located at the root of the project directory.

Dependencies from pyproject.toml#
dependencies = [
    "numpy>=1.26",
    "scipy>=1.15.2",
    "h5py>=3.13.0",
    "mpi4py>=4.1.1",
    "astropy>=7.0.1",
    "matplotlib>=3.10.1",
    "tools21cm>=2.2.10",
    "tqdm>=4.0",
]

Finally, to install Beorn, run the following command:

pip install git+https://github.com/cosmic-reionization/beorn.git

A local, editable installation is also possible using pip (or equivalent). This is useful if you want to modify the code and test your changes without having to reinstall the package each time.

  1. Download or clone the Repository on GitHub

  2. Install in editable mode by running the following command:

    pip install -e /path/to/beorn
    

Additional Dependencies#

The outputs of beorn are strongly linked to the input given by halo catalogs. Beorn can natively read halo catalogs from well-known simulation projects like the Thesan and PkdGrav simulations.

Additionally, beorn can leverage semi-numerical simulation suites to generate synthetic halo catalogs on the fly. Currently, beorn supports the 21cmFAST suite but an additional installation step is required to enable this feature. To install beorn with 21cmFAST support, run the following command:

pip install git+https://github.com/cosmic-reionization/beorn.git[extra]

or directly install 21cmFAST using pip:

pip install 21cmfast

Optional extras (numba, pylians, torch, jax) enable faster or GPU-accelerated backends for particle-to-mesh mapping but are not required for standard use.