Abstract
We introduce a deep learning model that can universally approximate regular conditional distributions (RCDs). The proposed model operates in three phases: first, it linearizes inputs from a given metric space $\mathcal{X}$ to $\mathbb{R}^d$ via a feature map, then a deep feedforward neural network processes these linearized features, and then the network's outputs are then transformed to the $1$-Wasserstein space $\mathcal{P}_1(\mathbb{R}^D)$ via a probabilistic extension of the attention mechanism. Our model, called the probabilistic transformer (PT), can approximate any continuous function from $\mathbb{R}^d $ to $\mathcal{P}_1(\mathbb{R}^D)$ uniformly on compact sets, quantitatively. We identify two ways in which the PT avoids the curse of dimensionality when approximating $\mathcal{P}_1(\mathbb{R}^D)$-valued functions.
Introduction
In machine learning, the goal is often to predict a single value (point estimation). However, many real-world applications require understanding the entire probability distribution of an outcome $Y$ given an input $X$, known as a Regular Conditional Distribution (RCD). While deep learning has excelled at point estimation, creating a model that can rigorously approximate any distribution-valued function has remained an open theoretical challenge.
Standard neural networks output vectors in Euclidean space, but RCDs reside in the 1-Wasserstein space—an infinite-dimensional metric space of probability measures. This research introduces a framework to bridge this gap, designing a network whose outputs are valid probability measures and proving its "universality" in approximating any continuous distribution-valued function.
The Probabilistic Transformer (PT) Architecture
The authors propose the Probabilistic Transformer (PT), which operates in three distinct phases to map inputs to probability measures.
- Linearization (Encoding): Non-Euclidean data from a metric space $\mathcal{X}$ is mapped to $\mathbb{R}^d$ using a "Bi-Hölder" feature map $\phi$. This step ensures the input is compatible with standard neural architectures.
- Processing (Feedforward): A deep feedforward neural network processes these features. The final layer uses a softmax activation to map the output to a high-dimensional simplex (a set of weights summing to 1).
- Decoding (Probabilistic Attention): The weights from the simplex are used to create a convex combination of "quantized" probability measures (atoms). Unlike classical attention, which computes a weighted average of vectors, this mechanism computes a weighted average of measures.
For more complex functions, the Tall Probabilistic Transformer stacks multiple attention mechanisms to approximate "Tree-Class" functions—complex mappings built by piecing together simpler components.
Theoretical Insights: Overcoming the Curse of Dimensionality
A significant contribution of this work is the quantitative proof that the PT can avoid the curse of dimensionality. The authors identify two primary strategies:
- Tree-Class Functions: By targeting specific "Tree-Class" functions, the PT can approximate complex mappings with efficient parameter scaling.
- Localization: If approximation is only required near the training data (compact subsets), the number of parameters needed grows polynomially rather than exponentially.
The model also provides PAC (Probably Approximately Correct) guarantees, ensuring that with sufficient data and parameters, the model converges to the true conditional distribution.
Empirical Validation
The PT was evaluated against classical models (Elastic-Net, GBRF, DNN) and distribution-specific models (Gaussian Process Regression, Mixture Density Networks) across several benchmarks:
- Stochastic Differential Equations (SDEs): Simulating paths driven by Brownian motion.
- MC-Dropout: Learning epistemic uncertainty distributions. In this task, the PT achieved a $W_1$ error of $\approx 2.09 \times 10^{-6}$, significantly outperforming GPR ($1.0 \times 10^{-3}$).
- Financial Data: Predicting AAPL stock returns based on 11 other major stocks.
The results demonstrate that the PT maintains high precision and stability even in high-dimensional settings (up to $d=500$) where traditional measure-valued models often degrade.
Conclusion
The Probabilistic Transformer represents a bridge between deep learning and rigorous probability theory. While it offers strong theoretical guarantees and empirical performance, future work remains in optimizing feature map selection and developing end-to-end differentiable methods for selecting probability "atoms."
Summary updated