TL;DR
Inferring spatial gene expression from cheap, routine microscope slides could save labs enormous amounts of time and money, yet current AI models treat tissue like a scattershot of isolated dots—blurring sharp boundaries and washing out rare, localized signals. Carta reframes this task as reconstructing a continuous molecular field: it first sketches broad regional expression states from tissue morphology and progressively refines them down to fine-grained local details. By combining this hierarchical approach with a distribution-shaping transport loss, Carta captures elusive, sparse gene patterns across 16 different organ and cancer tasks.
What Problem Does This Paper Address?
If you want to know which genes are active where inside a tumor or organ, you turn to spatial transcriptomics (ST). It maps molecular activity directly onto tissue architecture, which is vital for studying cancer microenvironments and disease progression. The catch? Sequencing-based ST assays are expensive, slow, and hard to scale. Meanwhile, standard hematoxylin-and-eosin (H&E) stained histology slides are cheap, standardized, and sitting in pathology archives by the millions.
Naturally, researchers have tried training deep learning models to predict ST gene expression directly from H&E images. However, existing methods—whether using graph networks, retrieval, or diffusion—are anchored to coordinate-level supervision. They treat the assay's sampled spots as isolated regression targets.
Tissue doesn't work like a collection of independent pixels. Gene expression behaves like a continuous field shaped by broad anatomical regions (like tumor vs. stroma) and fine-tuned by local cellular neighborhoods. When you train a model purely to minimize average error at individual coordinates, it takes the safe route: it blurs sharp regional boundaries and smooths away sparse genes (genes active in only a tiny fraction of spots), because missing a rare, localized spike barely hurts the average loss.
Methods
The authors formulate gene expression prediction as morphology-conditioned field reconstruction and introduce Carta, an architecture inspired by coarse-to-fine scale-wise autoregressive vision models.
Here is what is standard vs. what is new:
- Standard visual backbone: Carta extracts local image patch features at measured coordinates using frozen, off-the-shelf Pathology Foundation Models (PFMs), defaulting to UNI. Final spot-level predictions are still supervised with standard Mean Squared Error (MSE).
- Novel coordinate-derived spatial hierarchy: Instead of operating on a rigid image pixel grid, Carta builds a sequence of coarse-to-fine spatial layouts directly from the irregular ST coordinates by partitioning them into spatial bins. At coarse scales, regional nodes average features across broad areas; at the finest scale, nodes match the exact assayed spots.
- Novel regional-to-local state propagation: Starting from a learnable Gaussian prior at the coarsest scale, Carta predicts explicit gene expression states at each level and passes them down to the next finer scale via distance-weighted interpolation. At each scale, cross-attention fuses local histology features with these propagated regional priors, followed by a geometry-aware Transformer encoder.
- Novel Bidirectional Conditional Transport (BCT) objective: To prevent the model from washing out rare signals, Carta adds a distribution-level regularizer across all scales. Rather than inventing noisy pseudo-labels for coarse regional bins, BCT treats the rows of the shared output decoder layer as "gene anchors." It computes soft optimal-transport assignments in two directions (nodes-to-genes and genes-to-nodes) with an online-updated prior, forcing the reconstructed field to preserve realistic expression tails and local heterogeneity.
Datasets
Carta is evaluated on 16 organ-specific prediction tasks (50 highly variable genes per task, totaling 800 gene targets) drawn from two major paired H&E–ST resources using strict patient-disjoint splits:
- HEST-1k: 10 cancer-specific tasks (including invasive ductal carcinoma, prostate, pancreatic, lung, colorectal, kidney, liver, and skin cancers) evaluated via patient-disjoint cross-validation.
- STImage-1K4M: 6 newly constructed organ-level tasks (Brain, Breast, Heart, Liver, Pancreas, and Skin) using an 80/20 patient-disjoint slide split. Notably, all hyperparameters were tuned on HEST-1k and locked in for STImage-1K4M without retuning.
Key Insights and Ideas
- Predict explicit expression, not abstract latents, across scales: In ablation studies, propagating explicit intermediate gene expression predictions from coarse to fine scales beat propagating hidden latent vectors. Forcing intermediate layers into biological expression space acts as a strong structural prior.
- How you factorize space matters as much as the image encoder: When holding the visual backbone (UNI) completely fixed across competing generative and hierarchical models (like STFlow and HiST), Carta still wins. The bottleneck wasn't visual feature extraction—it was how spatial predictions were structured and supervised.
- Transport losses rescue the "long tail" of biology: Coordinate-wise MSE is notoriously blind to rare events. Adding the gene-anchored BCT objective specifically prevented performance collapse on medium-to-high sparsity genes, preserving sharp boundaries where biomarker expression turns on and off.
Key Results
Carta was benchmarked against 14 baselines spanning foundation-model regression, contrastive retrieval, graph networks, and flow/diffusion models:
- Overall Accuracy: Across all 16 tasks, Carta improved average Pearson Correlation Coefficient (PCC) by 12.9 points over the UNI foundation model baseline and 2.3 points over the strongest baseline (STFlow). Specifically, it achieved 0.425 mean PCC on HEST-1k (vs. 0.401 for STFlow; winning 9 of 10 tasks) and 0.653 on STImage-1K4M (vs. 0.632 for STFlow; winning 5 of 6 tasks).
- Clinical Biomarkers: On six localized marker genes (UBE2C, MET, KRTDAP, PTPRC, GATA3, ERBB2), Carta won on all six, reaching 0.842 average PCC compared to STFlow's 0.825.
- Ablations: Starting from a barebones baseline using UNI features (0.398 PCC on HEST), adding BCT alone bumped PCC to 0.406, adding the multi-scale hierarchy alone pushed it to 0.413, and combining both reached 0.425—showing clean, complementary gains that also held up when swapping UNI for Ciga or Gigapath backbones.
Limitations and Future Work
Not discussed in the paper. (The authors note in the conclusion that limitations and broader impacts are deferred to Supplementary Material E, which is outside the provided main text.)
Summary updated