An analysis framework for modeling dynamical single-cell data with neural differential equations, most notably stochastic differential equations allow us to build generative models of single-cell dynamics.
Quickstart
Please see the scDiffEq website for a quickstart notebook: link
Install the development package
Install generally only takes a few seconds.
Using uv (recommended)
git clone https://github.com/scDiffEq/scDiffEq.git; cd ./scDiffEq;
# Install uv if you haven't already: curl -LsSf https://astral.sh/uv/install.sh | sh
uv sync
Using pip
git clone https://github.com/scDiffEq/scDiffEq.git; cd ./scDiffEq;
pip install -e .
Optional dependency groups
| Extra | Contents |
|---|---|
optional |
Lazily-imported integrations: umap-learn, pillow, ipython, psutil, wandb |
docs |
Sphinx and theme packages for building the documentation |
test |
pytest, for running the test suite |
dev |
Jupyter, ipykernel, and pytest for interactive development |
# Using uv
uv sync --extra docs
# Using pip
pip install -e ".[docs]"
Datasets
import scdiffeq as sdq
adata = sdq.datasets.larry()
Datasets are downloaded on first use and cached under
<data_dir>/scdiffeq_data/. They are hosted on Zenodo
(10.5281/zenodo.21947161); downloads
need no authentication and are verified against the record's md5 checksums.
The record redistributes data published by other groups — please cite the original publications, listed on the data page and in the Zenodo record.
Main API
import scdiffeq as sdq
model = sdq.scDiffEq(adata=adata)
model.fit(train_epochs = 1500)
Built on
System requirements
- Developed on linux20.04 and MacOS (with Apple Silicon), using Python3.11.
- Software dependencies are listed in pyproject.toml.
- Tested with NVIDIA GPUs (A100, T4) and Apple Silicon. Most datasets likely only require an NVIDIA Tesla T4 (free in Google Colab).
Reproducibility
- All results described in the manuscript detailing scDiffEq can be reproduced using notebooks in the companion repository: scdiffeq-analyses
Citation
@article{vinyard2025scdiffeq,
title = {Learning cell dynamics with neural differential equations},
author = {Vinyard, Michael E. and Rasmussen, Anders W. and Li, Ruitong
and Klein, Allon M. and Getz, Gad and Pinello, Luca},
journal = {Nature Machine Intelligence},
volume = {7},
number = {12},
pages = {1969--1984},
year = {2025},
doi = {10.1038/s42256-025-01150-3}
}
If you use the packaged datasets, please also cite their original publications (see the data page).
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file scdiffeq-1.1.2.tar.gz.
File metadata
- Download URL: scdiffeq-1.1.2.tar.gz
- Upload date:
- Size: 4.1 MB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via:
uv/0.12.5 {"installer":{"name":"uv","version":"0.12.5","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
912d10f636a56557fa25fe3f2b43b8057face81252b6c1374c880125d7c71028
|
|
| MD5 |
e734603af212efedab8c134d77172a1e
|
|
| BLAKE2b-256 |
fd8ef7db5b4ad2a2ee2ab1986f9838e06ccdb463f032661c3f1dd1d557070e54
|
File details
Details for the file scdiffeq-1.1.2-py3-none-any.whl.
File metadata
- Download URL: scdiffeq-1.1.2-py3-none-any.whl
- Upload date:
- Size: 207.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via:
uv/0.12.5 {"installer":{"name":"uv","version":"0.12.5","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d228b28950f3577b4449a06dafdea670f6de427e8d03be1ab115d1b7afc46951
|
|
| MD5 |
6c6a61abff068e398e827f2e65d7a386
|
|
| BLAKE2b-256 |
26145b7ef40181eb2104c0519b9eb3f792b3b4dc43b82a46c44839aa8170d662
|