Installation#

LIANA+ requires Python 3.12 or newer.

pip install liana
uv add liana
conda install bioconda::liana

This installs the ligand-receptor methods, the spatial and multi-modal metrics, the prior knowledge resources and the plots.

Extras#

Functionality that only part of the user base needs sits behind the extras group:

pip install 'liana[extras]'

It pulls in decoupler, muon, mofax and mofapy2 for multi-view and multi-sample analyses, omnipath to query prior knowledge, pydeseq2 for differential expression, gseapy for enrichment, corneto, cvxpy and PySCIPOpt for the causal network inference, squidpy for the spatial neighborhoods, as well as cell2cell and kneed.

LIANA+ imports these when they are first used, so a missing one surfaces when you call the function that needs it.

Running the tutorials#

The notebooks need a few plotting packages on top of the extras:

pip install 'liana[tutorials]'

The two heaviest notebooks (inflow_mofaflex and liana_c2c) additionally need torch, mofaflex and tensorly:

pip install 'liana[tutorials-gpu]'

Development install#

git clone https://github.com/scverse/liana.git
cd liana
uv sync --all-extras

The contributing guide describes the environments, the test matrix and the docs build.