All models

conST

Graph-based contrastive learning framework that embeds the spots of spatial transcriptomics data.

Molecules, proteins and genomics · 36 operations Checked

100%

Showing the top corner; full diagram not loaded yetShowing a small copy; full diagram not loaded yetLarge diagram, not loaded yet

Open SVG

Loading diagram (49 KB)

Open in a new tab

Click or tap a spot to read it up close. Scroll or drag inside the diagram to move through it. Zoom with + and − or Ctrl and scroll. Press 0 for the whole graph. Swipe inside the diagram to move through it. Use + and − to zoom.

At a glance

Parameters
45.2K
Operations
36
Framework
PyTorch
Recurrent
No
Published
2022, bioRxiv
Cited by
113 (as of 28 October 2026)
Authors
Yongshuo Zong, Tingyang Yu, Xuesong Wang and others
License
MIT
Checked
Passed: the trace was replayed operation by operation and matched the model's own output for this input.

Files

The diagram is a drawing of a TorchLens trace of the source code. It contains no code or weights.

Details
Stable ID
m21594
Graph hash
4552682308f0481833b8099dbd4a4667e466cd5760b82947f5033d03b2e17e71
Skeleton hash
820eff3ca76fc9cb51a00eb29f1c7a860a64e484d5d3f8fc253975aa46e7c8c0
Architecture hash
3ccbd3bdc69fee66ead00581c2a483b72ca287186e1c28b1d0b44123026d5751
Diagram SHA-256
604bf0d2864692e0a7efa28d602cd28df68ded92cb64eb9d688ff5ede7386d1f
TorchLens version
2.36.0
Renderer
graphviz 2.43.0+pyvips 3.2.0+libvips 8.18.7+render-opts@06c1f0d3
Check
Forward pass replayed in PyTorch

What it is

conST is a framework for analyzing spatially resolved transcriptomics (SRT) data, which measure a gene expression matrix together with its spatial information. It learns low-dimensional embeddings by integrating gene expression, spatial information and, if applicable, morphology. The embeddings can then be used for downstream tasks including clustering, trajectory and pseudotime inference, and cell-to-cell interaction.

The data are treated as a graph built from the K-Nearest Neighbor distance of the spot coordinates, where spots are nodes whose attributes are gene expression and morphology features. Graph convolutional networks do the encoding. Training has two stages. A pretraining stage initializes the weights of the encoder by reconstruction loss. The major training stage then uses contrastive learning at three levels: local-local, local-context and local-global. Morphology features are extracted by a pretrained MAE model, and when morphology is not available the framework takes gene expression and spatial information as input.

For interpretation the authors use GNNExplainer to identify the subgraphs and node attributes that contribute most to the predictions. The paper reports up to 10% improvement in clustering ARI on a commonly used benchmark dataset. The repository includes a clustering demo on slice 151673 of the spatialLIBD dataset and releases trained weights for it.

Key idea. The paper proposes conST, which learns spot embeddings from gene expression, spatial information and morphology using graph networks and contrastive learning at three levels.

  • conST
  • spatial transcriptomics
  • spatially resolved transcriptomics
  • SRT
  • contrastive learning
  • multi-modal
  • spot embedding
  • spatial clustering
  • graph contrastive learning

AI-written summary, based on the paper and checked automatically against it; not reviewed by a person. Corrections welcome.

Cite the paper

@article{Zong_2022, title={conST: an interpretable multi-modal contrastive learning framework for spatial transcriptomics}, url={http://dx.doi.org/10.1101/2022.01.14.476408}, DOI={10.1101/2022.01.14.476408}, publisher={openRxiv}, author={Zong, Yongshuo and Yu, Tingyang and Wang, Xuesong and Wang, Yixuan and Hu, Zhihang and Li, Yu}, year={2022}, month=Jan }