WHY MATHEMATICS?
Why Mathematics? | STAGATE Spatial Domains: Neighbour Networks, Graph Attention, Tied Autoencoders and Reconstruction Loss
How STAGATE learns unequal weights for nearby tissue spots, reconstructs normalized expression and turns the embedding into cautiously validated spatial domains.
Why mathematics is important becomes easier to see when a real decision depends on it. This guide follows the mechanism from definitions and dimensions to a worked calculation, validation, practical learning and responsible use. It keeps factual evidence separate from interpretation and treats every illustrative scenario as an example rather than a promise of results.
Choose a reading route
- Build a radius-based spatial neighbour network
- Calculate source-receiver attention and softmax weights
- Tie encoder and decoder parameters while reconstructing expression
- Separate useful attention from causal explanation
Chapter map
- 1. Normalized expression input
- 2. Radius graph
- 3. Self-loop
- 4. Linear feature map
- 5. Source score
- 6. Receiver score
- 7. Sigmoid edge score
- 8. Neighbour softmax
- 9. Attention aggregation
- 10. Encoder depth
- 11. Tied decoder matrix
- 12. Shared attention in decoder
- 13. Reconstruction loss
- 14. Cell-type-aware graph
- 15. Alpha graph mixture
- 16. Domain validation
Visit the How Mathematics Works hub for the wider series and its connections to education, reasoning, science, computing, design and careers.
1. Normalized expression input
This step deserves a careful pause. Every spot begins with a scaled gene vector.
A concrete situation
Five hundred genes form xi.
What the mathematics does not license
Normalization changes relative distances. A trustworthy workflow records the choice before seeing the final test result.
Try it, check it, transfer it
Version the transformation. Then explain the result to someone who has not seen the formula. If the explanation needs a hidden assumption, add that assumption to the model record.
2. Radius graph
The useful question is not only how to calculate, but what the calculation assumes. Coordinates and a radius determine permitted edges.
A concrete situation
Spot i has seven neighbours.
What the mathematics does not license
One radius fits dense and sparse regions differently. Evidence becomes stronger when the limitation is tested instead of hidden.
Try it, check it, transfer it
Compare adaptive kNN. Then explain the result to someone who has not seen the formula. If the explanation needs a hidden assumption, add that assumption to the model record.
3. Self-loop
A small example makes the mechanism visible. A spot contributes its own transformed features.
A concrete situation
i belongs to its neighbour set Si.
What the mathematics does not license
Self-information can dominate neighbours. Keeping this boundary clear makes the result easier to audit and transfer.
Try it, check it, transfer it
Inspect diagonal attention. Then explain the result to someone who has not seen the formula. If the explanation needs a hidden assumption, add that assumption to the model record.
4. Linear feature map
This is where modelling choices begin to affect evidence. A trainable matrix projects neighbour embeddings.
A concrete situation
W maps 512 inputs to 30 outputs.
What the mathematics does not license
Projection can discard rare signals. A trustworthy workflow records the choice before seeing the final test result.
Try it, check it, transfer it
Test latent width. Then explain the result to someone who has not seen the formula. If the explanation needs a hidden assumption, add that assumption to the model record.
Did You Know? In this chapter, the most important number is useful only together with its construction rule. Changing scaling, sample membership or validation design can change the numerical answer without changing the arithmetic.
5. Source score
The central mathematical idea is concrete. A trainable vector scores the receiving spot representation.
A concrete situation
vs transpose Whi contributes 0.6.
What the mathematics does not license
Source and receiver roles are model conventions. Evidence becomes stronger when the limitation is tested instead of hidden.
Try it, check it, transfer it
Reverse-edge audit. Then explain the result to someone who has not seen the formula. If the explanation needs a hidden assumption, add that assumption to the model record.
6. Receiver score
Here the geometry becomes operational. A second trainable vector scores the sending neighbour.
A concrete situation
vr transpose Whj contributes 0.3.
What the mathematics does not license
Scores are not calibrated similarities. Keeping this boundary clear makes the result easier to audit and transfer.
Try it, check it, transfer it
Compare score distributions. Then explain the result to someone who has not seen the formula. If the explanation needs a hidden assumption, add that assumption to the model record.
7. Sigmoid edge score
This step deserves a careful pause. A nonlinear function bounds the raw source-receiver sum.
A concrete situation
Sigmoid of 0.9 is about 0.711.
What the mathematics does not license
Saturation weakens gradients. A trustworthy workflow records the choice before seeing the final test result.
Try it, check it, transfer it
Monitor score ranges. Then explain the result to someone who has not seen the formula. If the explanation needs a hidden assumption, add that assumption to the model record.
8. Neighbour softmax
The useful question is not only how to calculate, but what the calculation assumes. Exponentiated edge scores normalize over a neighbourhood.
A concrete situation
Weights 0.5, 0.3 and 0.2 sum to one.
What the mathematics does not license
More neighbours dilute fixed mass. Evidence becomes stronger when the limitation is tested instead of hidden.
Try it, check it, transfer it
Report degree and entropy. Then explain the result to someone who has not seen the formula. If the explanation needs a hidden assumption, add that assumption to the model record.
Did You Know? In this chapter, the most important number is useful only together with its construction rule. Changing scaling, sample membership or validation design can change the numerical answer without changing the arithmetic.
9. Attention aggregation
A small example makes the mechanism visible. Weighted transformed neighbours update the spot embedding.
A concrete situation
Two strong edges contribute most.
What the mathematics does not license
High weight can reflect reconstruction convenience. Keeping this boundary clear makes the result easier to audit and transfer.
Try it, check it, transfer it
Avoid causal labels. Then explain the result to someone who has not seen the formula. If the explanation needs a hidden assumption, add that assumption to the model record.
10. Encoder depth
This is where modelling choices begin to affect evidence. Successive layers compress expression into a latent vector.
A concrete situation
A 512-to-30 architecture is used.
What the mathematics does not license
Multiple layers can oversmooth. A trustworthy workflow records the choice before seeing the final test result.
Try it, check it, transfer it
Track neighbour similarity by layer. Then explain the result to someone who has not seen the formula. If the explanation needs a hidden assumption, add that assumption to the model record.
11. Tied decoder matrix
The central mathematical idea is concrete. Decoder weights equal encoder transposes.
A concrete situation
W-hat equals W transpose.
What the mathematics does not license
Tying restricts possible reconstructions. Evidence becomes stronger when the limitation is tested instead of hidden.
Try it, check it, transfer it
Compare untied ablation. Then explain the result to someone who has not seen the formula. If the explanation needs a hidden assumption, add that assumption to the model record.
12. Shared attention in decoder
Here the geometry becomes operational. The decoder reuses learned encoder attention coefficients.
A concrete situation
att-hat equals att.
What the mathematics does not license
The reverse task may need different weights. Keeping this boundary clear makes the result easier to audit and transfer.
Try it, check it, transfer it
Inspect residuals by boundary. Then explain the result to someone who has not seen the formula. If the explanation needs a hidden assumption, add that assumption to the model record.
Did You Know? In this chapter, the most important number is useful only together with its construction rule. Changing scaling, sample membership or validation design can change the numerical answer without changing the arithmetic.
13. Reconstruction loss
This step deserves a careful pause. Euclidean residuals compare normalized input and output.
A concrete situation
A spot residual norm is 1.7.
What the mathematics does not license
Large genes can dominate without scaling. A trustworthy workflow records the choice before seeing the final test result.
Try it, check it, transfer it
Audit gene-wise error. Then explain the result to someone who has not seen the formula. If the explanation needs a hidden assumption, add that assumption to the model record.
14. Cell-type-aware graph
The useful question is not only how to calculate, but what the calculation assumes. Pre-clusters prune edges likely to cross coarse cell-type borders.
A concrete situation
Louvain resolution 0.2 defines coarse groups.
What the mathematics does not license
Wrong pre-clusters can harden wrong borders. Evidence becomes stronger when the limitation is tested instead of hidden.
Try it, check it, transfer it
Run with and without pruning. Then explain the result to someone who has not seen the formula. If the explanation needs a hidden assumption, add that assumption to the model record.
15. Alpha graph mixture
A small example makes the mechanism visible. Alpha blends spatial and aware attention systems.
A concrete situation
Alpha 0.5 gives equal mixture.
What the mathematics does not license
Mixture scale is a modelling choice. Keeping this boundary clear makes the result easier to audit and transfer.
Try it, check it, transfer it
Sweep alpha. Then explain the result to someone who has not seen the formula. If the explanation needs a hidden assumption, add that assumption to the model record.
16. Domain validation
This is where modelling choices begin to affect evidence. mclust or Louvain clusters latent embeddings and markers test them.
A concrete situation
A narrow layer matches held-out markers.
What the mathematics does not license
Clustering adds new parameters and seeds. A trustworthy workflow records the choice before seeing the final test result.
Try it, check it, transfer it
Use section-level replication. Then explain the result to someone who has not seen the formula. If the explanation needs a hidden assumption, add that assumption to the model record.
Did You Know? In this chapter, the most important number is useful only together with its construction rule. Changing scaling, sample membership or validation design can change the numerical answer without changing the arithmetic.
A seven-day practice lab
- Day 1: define the decision, observation unit, X variables and Y or reference condition.
- Day 2: reproduce the smallest worked example and check every dimension, unit and sign.
- Day 3: build a transparent baseline and write what it assumes.
- Day 4: fit the main method inside a training-only pipeline; record every parameter.
- Day 5: challenge one assumption with a deliberately difficult dataset or operating regime.
- Day 6: compare validation metrics with the practical workload created by errors.
- Day 7: present one supported conclusion, one unresolved uncertainty and one safe next experiment.
Questions for a student, parent or mentor
- Which part of the model is a mathematical definition, and which part is a choice?
- What small calculation would catch a sign, scale or dimension error?
- What evidence comes from training, validation and the untouched test?
- What benign condition could look like a fault or prediction failure?
- How would the answer change for another response, asset, school project or time period?
- What should a human review before acting on the score?
A method-specific audit before deployment
STAGATE begins with a spatial neighbour network built from spot coordinates and a chosen radius. The network determines which observations may exchange information. An optional cell-type-aware network prunes edges using coarse expression pre-clusters, helping preserve boundaries in low-resolution assays. That option can also reinforce a mistaken pre-cluster, so the original and pruned networks should be compared.
A graph attention autoencoder transforms normalized gene expression into a low-dimensional embedding and reconstructs it. At an attention layer, a spot receives transformed messages from itself and its neighbours. Trainable source and receiver vectors produce edge scores; a softmax makes the scores over a neighbourhood comparable and sum to one. The learned coefficients decide which nearby spots matter most instead of assigning every edge the same weight.
The decoder mirrors the encoder. STAGATE ties decoder weights to transposed encoder weights and reuses attention coefficients, reducing the number of free parameters. Training minimizes expression reconstruction error, using the paper’s reported two-layer 512-to-30 encoder, ELU activations, Adam, weight decay and repeated iterations. The embedding can then feed mclust, Louvain, UMAP or trajectory analysis.
Attention is not a causal explanation of tissue biology. A large learned edge weight means that the trained reconstruction found that edge useful under the specified graph, features and objective. Radius, pre-clustering, alpha for the optional network, initialization and downstream clustering all affect the final domains. Strong validation therefore includes graph sensitivity, boundary checks, multiple seeds, held-out sections and independent markers.
Frequently asked questions
What is STAGATE?
STAGATE is a graph attention autoencoder that integrates normalized expression with a spatial neighbour network to learn embeddings for spatial-domain analysis.
What is a spatial neighbour network?
It is a graph whose edges connect spots within a declared radius, including self-connections used by the encoder.
What does attention learn?
It learns normalized edge coefficients that control how much each permitted neighbour contributes to a spot representation.
What is the cell-type-aware option?
It prunes or supplements the spatial graph using coarse expression pre-clusters and mixes the two attention systems with alpha.
How is the network trained?
The decoder reconstructs normalized expression and training minimizes reconstruction error using tied encoder-decoder parameters.
Do attention weights prove interaction?
No. They are model-dependent message weights, not evidence of causal cell communication.
Primary source and fact-check note
Kangning Dong and Shihua Zhang, “Deciphering spatial domains from spatially resolved transcriptomics with an adaptive graph attention auto-encoder,” Nature Communications 13, 1739 (2022), DOI 10.1038/s41467-022-29439-6. Definitions and core claims in this article were checked against this primary publication. Calculations shown here were independently recomputed. Examples are educational illustrations; they are not reported industrial performance results.
Useful next reading
- CCST contrastive graph clustering
- SpaGCN histology-weighted graphs
- Giotto neighbour-graph domains
- How Mathematics Works
Keep the options open. Mathematics education supports clearer questions, transferable problem-solving skills and informed choices across science, engineering, computing, AI, statistics, design and many other careers. It does not guarantee intelligence, income, admission or employment; those outcomes depend on far more than one subject or model.
Extended laboratory: topic-specific validation and responsible use
Graph audit
Publish coordinates, units, radius, degree and components.
Attention audit
Inspect score range, weight entropy and self-loop mass.
Boundary audit
Compare original and cell-type-aware networks.
Architecture audit
Record dimensions, activations, tying and iterations.
Did You Know? A sophisticated adjustment can be algebraically correct and still answer the wrong scientific question when samples, labels, batches or validation boundaries are wrong.
Loss audit
Keep gene-wise and spot-wise reconstruction residuals.
Clustering audit
Version mclust or Louvain settings and seeds.
Transfer audit
Hold out complete tissue sections and platforms.
Final claim
Attention weights are not causal interaction strengths.
Did You Know? A sophisticated adjustment can be algebraically correct and still answer the wrong scientific question when samples, labels, batches or validation boundaries are wrong.
Mechanism workshop: calculate, challenge and transfer
Workshop 1: Normalized expression input
Begin with this mechanism: Every spot begins with a scaled gene vector. Recreate the concrete case: Five hundred genes form xi. Write coordinates, adjacency entries, transformed features, source scores, receiver scores, sigmoid values, softmax denominators, attention weights, aggregated messages, latent vectors, reconstructed genes and boundary residuals with direction, dimensions, units, denominators and assumptions. Calculate the smallest non-trivial example by hand, then reproduce it in a spreadsheet or short program. Challenge this limitation: Normalization changes relative distances. Complete the transfer step: Version the transformation. Change exactly one gene filter, PC dimension, cluster count, prior, gamma, degrees of freedom, lattice edge, initialization, chain length, burn-in, jitter scale, subspot layout, radius, graph degree, attention score, alpha mixture, latent width, tied parameter, mask rate, mask pattern, KL weight, cluster target, corruption rule, negative sample, pairwise distance normalization, Leiden resolution, pseudotime root, tissue section or random seed. Explain which mathematical object changes, which conclusion survives and which claim must weaken. Keep observation, preprocessing, graph, prior, objective, optimization, posterior or embedding, clustering, biological interpretation and independent validation on separate notebook lines. Reserve whole donors, slides, tissues, patients or platforms outside tuning when testing transfer.
Workshop 2: Radius graph
Begin with this mechanism: Coordinates and a radius determine permitted edges. Recreate the concrete case: Spot i has seven neighbours. Write coordinates, adjacency entries, transformed features, source scores, receiver scores, sigmoid values, softmax denominators, attention weights, aggregated messages, latent vectors, reconstructed genes and boundary residuals with direction, dimensions, units, denominators and assumptions. Calculate the smallest non-trivial example by hand, then reproduce it in a spreadsheet or short program. Challenge this limitation: One radius fits dense and sparse regions differently. Complete the transfer step: Compare adaptive kNN. Change exactly one gene filter, PC dimension, cluster count, prior, gamma, degrees of freedom, lattice edge, initialization, chain length, burn-in, jitter scale, subspot layout, radius, graph degree, attention score, alpha mixture, latent width, tied parameter, mask rate, mask pattern, KL weight, cluster target, corruption rule, negative sample, pairwise distance normalization, Leiden resolution, pseudotime root, tissue section or random seed. Explain which mathematical object changes, which conclusion survives and which claim must weaken. Keep observation, preprocessing, graph, prior, objective, optimization, posterior or embedding, clustering, biological interpretation and independent validation on separate notebook lines. Reserve whole donors, slides, tissues, patients or platforms outside tuning when testing transfer.
Workshop 3: Self-loop
Begin with this mechanism: A spot contributes its own transformed features. Recreate the concrete case: i belongs to its neighbour set Si. Write coordinates, adjacency entries, transformed features, source scores, receiver scores, sigmoid values, softmax denominators, attention weights, aggregated messages, latent vectors, reconstructed genes and boundary residuals with direction, dimensions, units, denominators and assumptions. Calculate the smallest non-trivial example by hand, then reproduce it in a spreadsheet or short program. Challenge this limitation: Self-information can dominate neighbours. Complete the transfer step: Inspect diagonal attention. Change exactly one gene filter, PC dimension, cluster count, prior, gamma, degrees of freedom, lattice edge, initialization, chain length, burn-in, jitter scale, subspot layout, radius, graph degree, attention score, alpha mixture, latent width, tied parameter, mask rate, mask pattern, KL weight, cluster target, corruption rule, negative sample, pairwise distance normalization, Leiden resolution, pseudotime root, tissue section or random seed. Explain which mathematical object changes, which conclusion survives and which claim must weaken. Keep observation, preprocessing, graph, prior, objective, optimization, posterior or embedding, clustering, biological interpretation and independent validation on separate notebook lines. Reserve whole donors, slides, tissues, patients or platforms outside tuning when testing transfer.
Workshop 4: Linear feature map
Begin with this mechanism: A trainable matrix projects neighbour embeddings. Recreate the concrete case: W maps 512 inputs to 30 outputs. Write coordinates, adjacency entries, transformed features, source scores, receiver scores, sigmoid values, softmax denominators, attention weights, aggregated messages, latent vectors, reconstructed genes and boundary residuals with direction, dimensions, units, denominators and assumptions. Calculate the smallest non-trivial example by hand, then reproduce it in a spreadsheet or short program. Challenge this limitation: Projection can discard rare signals. Complete the transfer step: Test latent width. Change exactly one gene filter, PC dimension, cluster count, prior, gamma, degrees of freedom, lattice edge, initialization, chain length, burn-in, jitter scale, subspot layout, radius, graph degree, attention score, alpha mixture, latent width, tied parameter, mask rate, mask pattern, KL weight, cluster target, corruption rule, negative sample, pairwise distance normalization, Leiden resolution, pseudotime root, tissue section or random seed. Explain which mathematical object changes, which conclusion survives and which claim must weaken. Keep observation, preprocessing, graph, prior, objective, optimization, posterior or embedding, clustering, biological interpretation and independent validation on separate notebook lines. Reserve whole donors, slides, tissues, patients or platforms outside tuning when testing transfer.
Did You Know? A sophisticated adjustment can be algebraically correct and still answer the wrong scientific question when samples, labels, batches or validation boundaries are wrong.
Workshop 5: Source score
Begin with this mechanism: A trainable vector scores the receiving spot representation. Recreate the concrete case: vs transpose Whi contributes 0.6. Write coordinates, adjacency entries, transformed features, source scores, receiver scores, sigmoid values, softmax denominators, attention weights, aggregated messages, latent vectors, reconstructed genes and boundary residuals with direction, dimensions, units, denominators and assumptions. Calculate the smallest non-trivial example by hand, then reproduce it in a spreadsheet or short program. Challenge this limitation: Source and receiver roles are model conventions. Complete the transfer step: Reverse-edge audit. Change exactly one gene filter, PC dimension, cluster count, prior, gamma, degrees of freedom, lattice edge, initialization, chain length, burn-in, jitter scale, subspot layout, radius, graph degree, attention score, alpha mixture, latent width, tied parameter, mask rate, mask pattern, KL weight, cluster target, corruption rule, negative sample, pairwise distance normalization, Leiden resolution, pseudotime root, tissue section or random seed. Explain which mathematical object changes, which conclusion survives and which claim must weaken. Keep observation, preprocessing, graph, prior, objective, optimization, posterior or embedding, clustering, biological interpretation and independent validation on separate notebook lines. Reserve whole donors, slides, tissues, patients or platforms outside tuning when testing transfer.
Workshop 6: Receiver score
Begin with this mechanism: A second trainable vector scores the sending neighbour. Recreate the concrete case: vr transpose Whj contributes 0.3. Write coordinates, adjacency entries, transformed features, source scores, receiver scores, sigmoid values, softmax denominators, attention weights, aggregated messages, latent vectors, reconstructed genes and boundary residuals with direction, dimensions, units, denominators and assumptions. Calculate the smallest non-trivial example by hand, then reproduce it in a spreadsheet or short program. Challenge this limitation: Scores are not calibrated similarities. Complete the transfer step: Compare score distributions. Change exactly one gene filter, PC dimension, cluster count, prior, gamma, degrees of freedom, lattice edge, initialization, chain length, burn-in, jitter scale, subspot layout, radius, graph degree, attention score, alpha mixture, latent width, tied parameter, mask rate, mask pattern, KL weight, cluster target, corruption rule, negative sample, pairwise distance normalization, Leiden resolution, pseudotime root, tissue section or random seed. Explain which mathematical object changes, which conclusion survives and which claim must weaken. Keep observation, preprocessing, graph, prior, objective, optimization, posterior or embedding, clustering, biological interpretation and independent validation on separate notebook lines. Reserve whole donors, slides, tissues, patients or platforms outside tuning when testing transfer.
Workshop 7: Sigmoid edge score
Begin with this mechanism: A nonlinear function bounds the raw source-receiver sum. Recreate the concrete case: Sigmoid of 0.9 is about 0.711. Write coordinates, adjacency entries, transformed features, source scores, receiver scores, sigmoid values, softmax denominators, attention weights, aggregated messages, latent vectors, reconstructed genes and boundary residuals with direction, dimensions, units, denominators and assumptions. Calculate the smallest non-trivial example by hand, then reproduce it in a spreadsheet or short program. Challenge this limitation: Saturation weakens gradients. Complete the transfer step: Monitor score ranges. Change exactly one gene filter, PC dimension, cluster count, prior, gamma, degrees of freedom, lattice edge, initialization, chain length, burn-in, jitter scale, subspot layout, radius, graph degree, attention score, alpha mixture, latent width, tied parameter, mask rate, mask pattern, KL weight, cluster target, corruption rule, negative sample, pairwise distance normalization, Leiden resolution, pseudotime root, tissue section or random seed. Explain which mathematical object changes, which conclusion survives and which claim must weaken. Keep observation, preprocessing, graph, prior, objective, optimization, posterior or embedding, clustering, biological interpretation and independent validation on separate notebook lines. Reserve whole donors, slides, tissues, patients or platforms outside tuning when testing transfer.
Workshop 8: Neighbour softmax
Begin with this mechanism: Exponentiated edge scores normalize over a neighbourhood. Recreate the concrete case: Weights 0.5, 0.3 and 0.2 sum to one. Write coordinates, adjacency entries, transformed features, source scores, receiver scores, sigmoid values, softmax denominators, attention weights, aggregated messages, latent vectors, reconstructed genes and boundary residuals with direction, dimensions, units, denominators and assumptions. Calculate the smallest non-trivial example by hand, then reproduce it in a spreadsheet or short program. Challenge this limitation: More neighbours dilute fixed mass. Complete the transfer step: Report degree and entropy. Change exactly one gene filter, PC dimension, cluster count, prior, gamma, degrees of freedom, lattice edge, initialization, chain length, burn-in, jitter scale, subspot layout, radius, graph degree, attention score, alpha mixture, latent width, tied parameter, mask rate, mask pattern, KL weight, cluster target, corruption rule, negative sample, pairwise distance normalization, Leiden resolution, pseudotime root, tissue section or random seed. Explain which mathematical object changes, which conclusion survives and which claim must weaken. Keep observation, preprocessing, graph, prior, objective, optimization, posterior or embedding, clustering, biological interpretation and independent validation on separate notebook lines. Reserve whole donors, slides, tissues, patients or platforms outside tuning when testing transfer.
Did You Know? A sophisticated adjustment can be algebraically correct and still answer the wrong scientific question when samples, labels, batches or validation boundaries are wrong.
Workshop 9: Attention aggregation
Begin with this mechanism: Weighted transformed neighbours update the spot embedding. Recreate the concrete case: Two strong edges contribute most. Write coordinates, adjacency entries, transformed features, source scores, receiver scores, sigmoid values, softmax denominators, attention weights, aggregated messages, latent vectors, reconstructed genes and boundary residuals with direction, dimensions, units, denominators and assumptions. Calculate the smallest non-trivial example by hand, then reproduce it in a spreadsheet or short program. Challenge this limitation: High weight can reflect reconstruction convenience. Complete the transfer step: Avoid causal labels. Change exactly one gene filter, PC dimension, cluster count, prior, gamma, degrees of freedom, lattice edge, initialization, chain length, burn-in, jitter scale, subspot layout, radius, graph degree, attention score, alpha mixture, latent width, tied parameter, mask rate, mask pattern, KL weight, cluster target, corruption rule, negative sample, pairwise distance normalization, Leiden resolution, pseudotime root, tissue section or random seed. Explain which mathematical object changes, which conclusion survives and which claim must weaken. Keep observation, preprocessing, graph, prior, objective, optimization, posterior or embedding, clustering, biological interpretation and independent validation on separate notebook lines. Reserve whole donors, slides, tissues, patients or platforms outside tuning when testing transfer.
Workshop 10: Encoder depth
Begin with this mechanism: Successive layers compress expression into a latent vector. Recreate the concrete case: A 512-to-30 architecture is used. Write coordinates, adjacency entries, transformed features, source scores, receiver scores, sigmoid values, softmax denominators, attention weights, aggregated messages, latent vectors, reconstructed genes and boundary residuals with direction, dimensions, units, denominators and assumptions. Calculate the smallest non-trivial example by hand, then reproduce it in a spreadsheet or short program. Challenge this limitation: Multiple layers can oversmooth. Complete the transfer step: Track neighbour similarity by layer. Change exactly one gene filter, PC dimension, cluster count, prior, gamma, degrees of freedom, lattice edge, initialization, chain length, burn-in, jitter scale, subspot layout, radius, graph degree, attention score, alpha mixture, latent width, tied parameter, mask rate, mask pattern, KL weight, cluster target, corruption rule, negative sample, pairwise distance normalization, Leiden resolution, pseudotime root, tissue section or random seed. Explain which mathematical object changes, which conclusion survives and which claim must weaken. Keep observation, preprocessing, graph, prior, objective, optimization, posterior or embedding, clustering, biological interpretation and independent validation on separate notebook lines. Reserve whole donors, slides, tissues, patients or platforms outside tuning when testing transfer.
Workshop 11: Tied decoder matrix
Begin with this mechanism: Decoder weights equal encoder transposes. Recreate the concrete case: W-hat equals W transpose. Write coordinates, adjacency entries, transformed features, source scores, receiver scores, sigmoid values, softmax denominators, attention weights, aggregated messages, latent vectors, reconstructed genes and boundary residuals with direction, dimensions, units, denominators and assumptions. Calculate the smallest non-trivial example by hand, then reproduce it in a spreadsheet or short program. Challenge this limitation: Tying restricts possible reconstructions. Complete the transfer step: Compare untied ablation. Change exactly one gene filter, PC dimension, cluster count, prior, gamma, degrees of freedom, lattice edge, initialization, chain length, burn-in, jitter scale, subspot layout, radius, graph degree, attention score, alpha mixture, latent width, tied parameter, mask rate, mask pattern, KL weight, cluster target, corruption rule, negative sample, pairwise distance normalization, Leiden resolution, pseudotime root, tissue section or random seed. Explain which mathematical object changes, which conclusion survives and which claim must weaken. Keep observation, preprocessing, graph, prior, objective, optimization, posterior or embedding, clustering, biological interpretation and independent validation on separate notebook lines. Reserve whole donors, slides, tissues, patients or platforms outside tuning when testing transfer.
Workshop 12: Shared attention in decoder
Begin with this mechanism: The decoder reuses learned encoder attention coefficients. Recreate the concrete case: att-hat equals att. Write coordinates, adjacency entries, transformed features, source scores, receiver scores, sigmoid values, softmax denominators, attention weights, aggregated messages, latent vectors, reconstructed genes and boundary residuals with direction, dimensions, units, denominators and assumptions. Calculate the smallest non-trivial example by hand, then reproduce it in a spreadsheet or short program. Challenge this limitation: The reverse task may need different weights. Complete the transfer step: Inspect residuals by boundary. Change exactly one gene filter, PC dimension, cluster count, prior, gamma, degrees of freedom, lattice edge, initialization, chain length, burn-in, jitter scale, subspot layout, radius, graph degree, attention score, alpha mixture, latent width, tied parameter, mask rate, mask pattern, KL weight, cluster target, corruption rule, negative sample, pairwise distance normalization, Leiden resolution, pseudotime root, tissue section or random seed. Explain which mathematical object changes, which conclusion survives and which claim must weaken. Keep observation, preprocessing, graph, prior, objective, optimization, posterior or embedding, clustering, biological interpretation and independent validation on separate notebook lines. Reserve whole donors, slides, tissues, patients or platforms outside tuning when testing transfer.
Did You Know? A sophisticated adjustment can be algebraically correct and still answer the wrong scientific question when samples, labels, batches or validation boundaries are wrong.
Workshop 13: Reconstruction loss
Begin with this mechanism: Euclidean residuals compare normalized input and output. Recreate the concrete case: A spot residual norm is 1.7. Write coordinates, adjacency entries, transformed features, source scores, receiver scores, sigmoid values, softmax denominators, attention weights, aggregated messages, latent vectors, reconstructed genes and boundary residuals with direction, dimensions, units, denominators and assumptions. Calculate the smallest non-trivial example by hand, then reproduce it in a spreadsheet or short program. Challenge this limitation: Large genes can dominate without scaling. Complete the transfer step: Audit gene-wise error. Change exactly one gene filter, PC dimension, cluster count, prior, gamma, degrees of freedom, lattice edge, initialization, chain length, burn-in, jitter scale, subspot layout, radius, graph degree, attention score, alpha mixture, latent width, tied parameter, mask rate, mask pattern, KL weight, cluster target, corruption rule, negative sample, pairwise distance normalization, Leiden resolution, pseudotime root, tissue section or random seed. Explain which mathematical object changes, which conclusion survives and which claim must weaken. Keep observation, preprocessing, graph, prior, objective, optimization, posterior or embedding, clustering, biological interpretation and independent validation on separate notebook lines. Reserve whole donors, slides, tissues, patients or platforms outside tuning when testing transfer.
Workshop 14: Cell-type-aware graph
Begin with this mechanism: Pre-clusters prune edges likely to cross coarse cell-type borders. Recreate the concrete case: Louvain resolution 0.2 defines coarse groups. Write coordinates, adjacency entries, transformed features, source scores, receiver scores, sigmoid values, softmax denominators, attention weights, aggregated messages, latent vectors, reconstructed genes and boundary residuals with direction, dimensions, units, denominators and assumptions. Calculate the smallest non-trivial example by hand, then reproduce it in a spreadsheet or short program. Challenge this limitation: Wrong pre-clusters can harden wrong borders. Complete the transfer step: Run with and without pruning. Change exactly one gene filter, PC dimension, cluster count, prior, gamma, degrees of freedom, lattice edge, initialization, chain length, burn-in, jitter scale, subspot layout, radius, graph degree, attention score, alpha mixture, latent width, tied parameter, mask rate, mask pattern, KL weight, cluster target, corruption rule, negative sample, pairwise distance normalization, Leiden resolution, pseudotime root, tissue section or random seed. Explain which mathematical object changes, which conclusion survives and which claim must weaken. Keep observation, preprocessing, graph, prior, objective, optimization, posterior or embedding, clustering, biological interpretation and independent validation on separate notebook lines. Reserve whole donors, slides, tissues, patients or platforms outside tuning when testing transfer.
Workshop 15: Alpha graph mixture
Begin with this mechanism: Alpha blends spatial and aware attention systems. Recreate the concrete case: Alpha 0.5 gives equal mixture. Write coordinates, adjacency entries, transformed features, source scores, receiver scores, sigmoid values, softmax denominators, attention weights, aggregated messages, latent vectors, reconstructed genes and boundary residuals with direction, dimensions, units, denominators and assumptions. Calculate the smallest non-trivial example by hand, then reproduce it in a spreadsheet or short program. Challenge this limitation: Mixture scale is a modelling choice. Complete the transfer step: Sweep alpha. Change exactly one gene filter, PC dimension, cluster count, prior, gamma, degrees of freedom, lattice edge, initialization, chain length, burn-in, jitter scale, subspot layout, radius, graph degree, attention score, alpha mixture, latent width, tied parameter, mask rate, mask pattern, KL weight, cluster target, corruption rule, negative sample, pairwise distance normalization, Leiden resolution, pseudotime root, tissue section or random seed. Explain which mathematical object changes, which conclusion survives and which claim must weaken. Keep observation, preprocessing, graph, prior, objective, optimization, posterior or embedding, clustering, biological interpretation and independent validation on separate notebook lines. Reserve whole donors, slides, tissues, patients or platforms outside tuning when testing transfer.
Workshop 16: Domain validation
Begin with this mechanism: mclust or Louvain clusters latent embeddings and markers test them. Recreate the concrete case: A narrow layer matches held-out markers. Write coordinates, adjacency entries, transformed features, source scores, receiver scores, sigmoid values, softmax denominators, attention weights, aggregated messages, latent vectors, reconstructed genes and boundary residuals with direction, dimensions, units, denominators and assumptions. Calculate the smallest non-trivial example by hand, then reproduce it in a spreadsheet or short program. Challenge this limitation: Clustering adds new parameters and seeds. Complete the transfer step: Use section-level replication. Change exactly one gene filter, PC dimension, cluster count, prior, gamma, degrees of freedom, lattice edge, initialization, chain length, burn-in, jitter scale, subspot layout, radius, graph degree, attention score, alpha mixture, latent width, tied parameter, mask rate, mask pattern, KL weight, cluster target, corruption rule, negative sample, pairwise distance normalization, Leiden resolution, pseudotime root, tissue section or random seed. Explain which mathematical object changes, which conclusion survives and which claim must weaken. Keep observation, preprocessing, graph, prior, objective, optimization, posterior or embedding, clustering, biological interpretation and independent validation on separate notebook lines. Reserve whole donors, slides, tissues, patients or platforms outside tuning when testing transfer.
