Skip to main content

scdiffeq_logo

PyPI pyversions PyPI version DOI

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

pytorch_logopytorch_lightning_logo neural_diffeqs_logo

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

scdiffeq-1.1.3.tar.gz (4.1 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

scdiffeq-1.1.3-py3-none-any.whl (208.2 kB view details)

Uploaded Python 3

File details

Details for the file scdiffeq-1.1.3.tar.gz.

File metadata

  • Download URL: scdiffeq-1.1.3.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

Hashes for scdiffeq-1.1.3.tar.gz
Algorithm Hash digest
SHA256 a4b32edbd99f7f06fd8e8fd49329c404738504e821fdb0cba2d6f83677cf35d4
MD5 59706f0e04c4299d0db56da0ec235db5
BLAKE2b-256 cf8b2bd3a88a7716a76ff14d04d0bba2be128f1facbafa2704409c04aacf3de2

See more details on using hashes here.

File details

Details for the file scdiffeq-1.1.3-py3-none-any.whl.

File metadata

  • Download URL: scdiffeq-1.1.3-py3-none-any.whl
  • Upload date:
  • Size: 208.2 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

Hashes for scdiffeq-1.1.3-py3-none-any.whl
Algorithm Hash digest
SHA256 da4290f54d3a268bfaf540af57de065647963e3010b5333a43481587a2a22542
MD5 b85f78b8a35e61ec34064081932f11e5
BLAKE2b-256 126096b78cacbf8db48ead9da47de9a8cacf20b3388888de8bdeeaf572f68f36

See more details on using hashes here.

Release history Release notifications | RSS feed

1.1.4

2 files

This release

1.1.3 This release

2 files

1.1.2

2 files

1.1.1

2 files

1.1.0

2 files

1.0.0

2 files

0.1.9

2 files

0.1.8

2 files

0.1.7

2 files

0.1.6

2 files

0.1.5

2 files

0.1.4

2 files

0.1.3

2 files

0.1.2

2 files

0.1.0

2 files

0.0.55

2 files

0.0.54

2 files

0.0.53

2 files

0.0.52

2 files

0.0.51

2 files

0.0.50

2 files

0.0.49

2 files

0.0.48

2 files

0.0.42

2 files

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page