Skip to content

Latest commit

 

History

53 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

PyPI Downloads Documentation Status

PAST: a Prior-based self-Attention method for Spatial Transcriptomics

Find more details and tutorials on the Documentation of PAST. All the data used in the tutorial are available at TsinghuaCloudDisk.

Overview

Rapid advances in spatial transcriptomics (ST) have revolutionized the interrogation of spatial heterogeneity and increase the demand for comprehensive methods to effectively characterize spatial domains. As a prerequisite for ST data analysis, spatial domain characterization is a crucial step for downstream analyses and biological implications. Here we propose PAST, a variational graph convolutional auto-encoder for ST, which effectively integrates prior information via a Bayesian neural network, captures spatial patterns via a self-attention mechanism, and enables scalable application via a ripple walk sampler strategy. Through comprehensive experiments on datasets generated by different technologies, we demonstrated that PAST could effectively characterize spatial domains and facilitate various downstream analyses, including ST visualization, spatial trajectory inference and pseudo-time analysis. Besides, we also highlight the advantages of PAST for multi-slice joint embedding and automatic annotation of spatial domains in newly sequenced ST data. Compared with existing methods, PAST is featured as the first ST method which integrates reference data to analyze ST data and we anticipate that PAST will open up new horizons for researchers to decipher ST data with customized reference data, which dramatically expands the applicability of ST technology.

Getting Started

Installation

PAST is available on PyPI here and can be installed via

pip install bio-past

You can also install PAST from GitHub via

git clone https://github.com/lizhen18THU/PAST.git
cd PAST
python setup.py install

Dependency

numba   
numpy   
pandas   
scipy   
scikit-learn   
scanpy   
torch

These dependencies will be automatically installed along with PAST. To implement the mclust algorithm with python, the rpy2 package and the mclust package is needed. See rpy2 and mclust for detail.

Citation

Zhen Li, Xiaoyang Chen, Xuegong Zhang, Rui Jiang, and Shengquan Chen. "Latent feature extraction with a prior-based self-attention framework for spatial transcriptomics." Genome Research (2023). doi:10.1101/gr.277891.123.

About

PAST: a Prior-based self-Attention method for Spatial Transcriptomics

Resources

Stars

13 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages