Installation#

modality is currently supported on Linux and MacOS.

Prerequisites#

The Python programming language is required to run modality. Python version 3.11 is recommended, while version 3.10 is also supported.

Quickstart#

Below you can find a step-by-step guide to set up your environment and install modality.

If you already have Python installed, first create a Python virtual environment, and then install modality using pip from the biomodal package repository:

# example for creating and activating a virtual environment
> python3 -m venv venv
> source venv/bin/activate

# install modality
pip install --extra-index-url https://europe-python.pkg.dev/prj-biomodal-modality/modality-pypi/simple modality

If you have already installed modality and want to upgrade to the latest version, use the following command:

pip install --extra-index-url https://europe-python.pkg.dev/prj-biomodal-modality/modality-pypi/simple modality --upgrade

Optional: install non-python dependencies, tabix and bgzip with conda through the htslib library to leverage additional performance gains#

This section is not required to run modality but will provide you with additional performance gains for particular workflows where bgzip (block compression) and tabix (quick index look up) can be leveraged. Therefore, we recommend the installation of the htslib library using conda, please see the conda install instructions with specific instructions for your operating system.

The following code describes how to install htslib with conda. Run each line individually.

conda init --all

conda activate base

conda install -c bioconda htslib

You can now test that the dependencies are installed and verify the version by running the following commands.