Skip to main content

Cellpin: A Student–Teacher Variational Model for Spatial Transcriptomics Imputation and Encoding

Project description

CellPin overview

cellpin

Documentation

cellpin is a lightweight probabilistic model that reconstructs and denoises spatial transcriptomes from single-cell RNA-seq references. It enables transcriptome-wide imputation, robust atlas-to-spatial label-transfer, and improved biological interpretation of both targeted-panel and full-transcriptome spatial datasets. Read the documentation for detailed tutorials.

Quickstart

import cellpin
from torch.utils.data import DataLoader

sc_ds, st_ds = cellpin.pp.setup_data(sc_adata, st_adata)
model = cellpin.CellPin(sc_ds)
model.fit(sc_ds)

loader = DataLoader(st_ds, batch_size=256, shuffle=False)
adata_out = model.impute(loader, obs_adata=st_adata)

Installation

pip

pip install cellpin

uv

uv pip install cellpin

For SpatialData support add the spatial extras:

pip install "cellpin[spatial]"
# or
uv pip install "cellpin[spatial]"

Documentation

Full documentation, tutorials, and API reference: cellpin.readthedocs.io

Citation

If you use cellpin in your research, please cite:

Putze P*, Lucarelli D*, Wellappili D, Bahrami M, Luecken MD, Theis FJ, Saur D. Cellpin enables reference-based imputation and denoising of spatial transcriptomes. bioRxiv 2026.06.02.729566. doi: 10.64898/2026.06.02.729566

* Shared first authorship

@article{putze2026cellpin,
  title   = {Cellpin enables reference-based imputation and denoising of spatial transcriptomes},
  author  = {Putze, Philipp and Lucarelli, Daniele and Wellappili, Deelaka and Bahrami, Mojtaba and Luecken, Malte D. and Theis, Fabian J. and Saur, Dieter},
  journal = {bioRxiv},
  year    = {2026},
  doi     = {10.64898/2026.06.02.729566},
  url     = {https://doi.org/10.64898/2026.06.02.729566}
}

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

cellpin-0.1.1.tar.gz (18.1 MB view details)

Uploaded Source

Built Distribution

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

cellpin-0.1.1-py3-none-any.whl (47.9 kB view details)

Uploaded Python 3

File details

Details for the file cellpin-0.1.1.tar.gz.

File metadata

  • Download URL: cellpin-0.1.1.tar.gz
  • Upload date:
  • Size: 18.1 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for cellpin-0.1.1.tar.gz
Algorithm Hash digest
SHA256 1fa7982b0c016632a53e5eb45afe8dd23a1951764e9b4e9bacad03bd549b4184
MD5 c940f5ab228818f5c488f9208071986c
BLAKE2b-256 9293f8f21b1574d786e1f7c52df02e58b4a057c04b80505db6165044be41d9ce

See more details on using hashes here.

Provenance

The following attestation bundles were made for cellpin-0.1.1.tar.gz:

Publisher: release.yml on Saur-Lab/cellpin

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file cellpin-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: cellpin-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 47.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for cellpin-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 0595f19fcce5759ef1b256ec1576c2d615a83b98f6bf77925a11c5a3a979011c
MD5 7a3a54bb50cc38f9a6193b8ffc2b7876
BLAKE2b-256 25ec6bd538f768611d8d3ee71a8a223c82960251a1faa634cd6d7406d347d242

See more details on using hashes here.

Provenance

The following attestation bundles were made for cellpin-0.1.1-py3-none-any.whl:

Publisher: release.yml on Saur-Lab/cellpin

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

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