Generative Distribution Embeddings: Lifting Autoencoders to the Space of Distributions
TL;DR
Generative Distribution Embeddings (GDE) is a novel framework that "lifts" autoencoders from operating on individual data points to entire distributions. By coupling distributionally invariant encoders with conditional generative models, GDEs learn latent representations where distances mirror optimal transport (Wasserstein) metrics, and linear paths correspond to smooth, physically natural transitions between populations.
The Challenge: Modeling Multiscale Data
In fields like genomics, drug discovery, and climate science, the most critical unit of analysis is rarely a single data point (like one cell or one weather reading). Instead, it is the distribution those points come from (like a patient’s entire immune system or a region's climate).
Standard machine learning models often struggle with this multiscale nature. They typically either collapse distributions into simple averages—losing vital information about variance and rare subpopulations—or fail to scale when a single "sample" (e.g., a patient) consists of millions of individual observations. There is a pressing need for a framework that can learn robust, denoised representations of these high-dimensional distributions while remaining computationally efficient.
Generative Distribution Embeddings (GDE)
The GDE framework reimagines the traditional autoencoder to handle sets of samples rather than individual points:
- The Encoder ($\mathcal{E}$): Instead of processing one point, the encoder takes a set of samples. Crucially, it must be distributionally invariant, meaning its output does not change if the samples are reordered (permutation invariance) or if every sample is duplicated proportionally (proportional invariance). This ensures the model learns the underlying probability measure rather than the specific size or order of the dataset.
- The Generator ($\mathcal{G}$): Replacing the standard decoder, this component is a conditional generative model (such as a VAE, Diffusion model, or Transformer). Given a latent embedding $z$, it aims to reconstruct the entire input distribution.
The model is trained using a "plug-in loss," where the generator is optimized to match the empirical distribution of the input set. This allows the model to be trained efficiently on small subsamples while scaling to millions of points during inference.
Key Insights & Theoretical Properties
- Predictive Sufficient Statistics: GDEs act as a data-driven version of "Rao-Blackwellization." They filter out the sampling noise inherent in small sets to recover the true underlying distribution. As the set size increases, the embeddings concentrate around a population value with Gaussian fluctuations.
- Wasserstein Geometry: A striking finding is that the Euclidean distance ($L_2$) in the GDE latent space naturally approximates the 2-Wasserstein ($W_2$) distance between distributions.
- Optimal Transport Trajectories: When interpolating linearly between two points in the GDE latent space, the decoded distributions follow paths that closely resemble Optimal Transport (OT) geodesics. In other words, the model learns the most "physically natural" way to morph one population into another.
- Prior Weighting: The latent space is weighted by the "meta-distribution" (how often certain types of distributions appear in the training data). This allows GDEs to allocate more resolution to common or biologically important regions of the distribution space.
Applications & Benchmarks
The authors demonstrate GDE's versatility across a massive scale of biological and synthetic data:
- Superior Benchmarking: GDEs consistently outperformed existing methods like Kernel Mean Embeddings (KME) and Wasserstein Wormholes in reconstructing distributions across synthetic tasks (Multivariate Normals, GMMs, MNIST).
- Zero-Shot Prediction: In biological perturbation tasks (evaluating 1 million transcriptomes and 20 million single-cell images), GDEs achieved significantly higher $R^2$ scores and lower Mean Squared Error (MSE) when predicting the effects of unseen genetic knockouts compared to models that only predict mean expression levels.
- Semi-Supervised Learning: By training on a mix of labeled and unlabeled donor data (6 million nuclei from the human prefrontal cortex), GDEs improved the accuracy of predicting patient disease status from single-cell data. This proves that the generative task helps learn better representations even when labels are scarce.
Limitations and Future Work
The authors acknowledge several areas for future growth:
- Prior Sensitivity: The performance of a GDE depends heavily on how sets are constructed (the "meta-distributional prior"). Choosing an inappropriate grouping strategy can lead to suboptimal embeddings.
- Exchangeability Assumption: The current theory assumes samples within a set are exchangeable (i.e., their order doesn't matter). Future work could extend this to non-i.i.d. data, such as spatial or temporal sequences where the relative position of points carries meaning.
- Engineering Challenges: Propagating gradients through very deep generators back to the encoder can be difficult, sometimes leading to "information bottlenecks" that require careful architectural tuning.
Summary updated