Installation

pip install "spatial-smooth[all]"

Note

[all] pulls every optional backend. For a minimal install, drop the extra (pip install spatial-smooth) and add only the extras you need (see below). To install the development version straight from the repository: pip install "spatial-smooth[all] @ git+https://github.com/settylab/spatial-smooth".

Only numpy, scipy, pandas and anndata are hard requirements. Everything else is an extra, imported lazily, and reported with the exact pip install line when missing.

extra

brings

needed for

dm

kompot

the Gaussian-process step (KompotGP)

embedding

palantir

computing the diffusion map

plot

scanpy, matplotlib

plotting

squidpy

squidpy

the squidpy plotting backend

kde

KDEpy

the fine-grid FFT smoother (Kde)

Check where you stand at any time:

import spatial_smooth as ss
ss.check_dependencies()
spatial_smooth v0.1.0 -- dependency check
  numpy       2.4.6       ok
  pandas      2.3.3       ok
  scipy       1.18.0      ok
  anndata     0.12.17     ok
  kompot      -           missing: pip install "kompot>=0.7.0" (optional)
  ...

Every missing optional dependency raises where it is first needed, naming the package, what it is for, and how to install it – never a bare ModuleNotFoundError from deep in a call stack.

Reading a smoothed object needs none of the extras: a colleague can open your .h5ad and plot it with scanpy alone.