NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

Neural Conditional Probability for Uncertainty Quantification

Vladimir R Kostic, gregoire pacreau, Giacomo Turri, Pietro Novelli, Karim Lounici, Massimiliano Pontil

Executive Summary

Neural Conditional Probability (NCP) is a novel operator-theoretic framework that learns conditional distributions through a single, unconditional training phase. By focusing on the conditional expectation operator rather than direct density estimation, NCP allows researchers to extract means, quantiles, and confidence regions analytically. Remarkably, it matches or outperforms complex state-of-the-art models like Diffusion and Normalizing Flows using only a simple 2-hidden-layer neural network.

The Challenge of Uncertainty Quantification

Predicting an outcome $Y$ given a condition $X$ is a foundational task in machine learning. However, providing a single "best guess" is insufficient for high-stakes fields like finance, medicine, or climate modeling, where quantifying uncertainty is critical.

Traditionally, learning the conditional distribution $P(Y|X)$ falls into four categories, each with notable drawbacks:

  1. Bayesian methods: Often suffer from the "curse of dimensionality."
  2. Localization: Requires computationally expensive retraining every time the conditioning point $X$ changes.
  3. Direct Learning: Relies heavily on the manual selection of appropriate basis functions or kernels.
  4. Conditional Training: Computationally demanding, requiring massive datasets to cover every possible partition of the input space.

The authors identify a critical gap: the field needs a method that is computationally efficient, theoretically grounded, and flexible enough to handle complex distributions without constant retraining or degrading in high dimensions.

Methodology: An Operator-Theoretic Approach

The core innovation of NCP is shifting the perspective from density estimation to operator theory.

Instead of attempting to learn the probability density function $p(y|x)$ directly, NCP learns the conditional expectation operator. This operator acts as a versatile mathematical tool: once learned, it can be applied to any function $f(y)$ to analytically extract desired conditional statistics, such as the mean, variance, or the probability that $Y$ falls into a specific range.

Key technical components of this approach include:

  • Truncated SVD: The method approximates the operator using a finite-rank Singular Value Decomposition (SVD). It learns two sets of embeddings (one for $X$, one for $Y$) and a corresponding set of singular values.
  • Principled Loss Function: The authors propose a loss based on the "least squares density ratio," which shares mathematical links with deep Canonical Correlation Analysis (deepCCA). It includes a penalty term to ensure the learned basis functions remain orthonormal.
  • Minimalist Architecture: Unlike the deep, complex architectures required by Diffusion models, the authors demonstrate that a simple Multi-Layer Perceptron (MLP) with just two hidden layers is sufficient when paired with this operator-theoretic loss.

Experimental Setup

The authors rigorously evaluated NCP against 10 competing methods across a variety of settings:

  • Synthetic Benchmarks: Six standard models including LinearGaussian, EconDensity (heteroscedastic), ArmaJump (time-series style), and LGGMD (high-dimensional regression).
  • High-Dimensional Synthetic Data: Experiments scaling up to $d=1000$ dimensions to test robustness against the curse of dimensionality.
  • Real-World Data: The Student Performance dataset from Kaggle, used to evaluate 90% prediction intervals.
  • Scientific Application: A molecular dynamics dataset tracking Protein folding (Chignolin), where the model predicts transition probabilities between metastable states.

Key Insights

  • The "Train Once, Infer Anywhere" Advantage: Because NCP learns the underlying operator, there is no need to retrain or run expensive Monte Carlo simulations to obtain different statistics. Quantiles, means, and probabilities are extracted analytically from the same trained model.
  • Simplicity Wins: A striking finding is that a 2-hidden-layer MLP with a theoretically sound loss function can outperform state-of-the-art Normalizing Flows and Diffusion models. This suggests that for uncertainty quantification, the objective function may be more critical than architectural depth.
  • Robustness to Degeneracy: Normalizing Flows often struggle when the conditional distribution is degenerate (e.g., at $x=0$). NCP remains stable in these regions because it does not rely on the existence of a diffeomorphism (a smooth, invertible mapping).
  • Efficiency in High Dimensions: NCP scales remarkably well. Increasing the input dimensionality from 100 to 1000 resulted in only a ~20% increase in computation time while maintaining strong statistical accuracy.

Key Results

In terms of Kolmogorov-Smirnov (KS) distance—a measure of how close the estimated distribution is to the ground truth—NCP-W (the whitened version of NCP) proved highly competitive.

Performance comparison across synthetic datasets

As shown in the benchmark table above, NCP-W was the top performer on 4 out of 6 synthetic datasets and secured a close second on the remaining tasks, consistently beating out complex models like DDPM and Normalizing Flows (NF).

Beyond synthetic benchmarks, NCP demonstrated strong real-world reliability. On the Student Performance dataset, NCP achieved a 91.02% coverage for a 90% prediction interval, indicating well-calibrated uncertainty that is neither too conservative nor too risky. In the Chignolin protein folding task, NCP successfully captured the increased variance during transition states, providing a clear visualization of the system's uncertainty regarding its next configuration.

Limitations and Future Work

While powerful, the authors note a few caveats to the current NCP framework:

  • Sample Size: NCP is a "data-hungry" generalist. It typically requires a relatively large sample size ($n \gtrsim 10^4$) to begin outperforming specialized methods.
  • Prior Knowledge: The current version is purely data-driven. A promising future direction involves baking physical or mathematical constraints (prior knowledge) into the operator learning process to improve data efficiency.
  • Multi-dimensional Outputs: While the underlying theory supports it, the current experimental focus was largely on scalar or low-dimensional outputs ($Y$). Extending this framework to high-dimensional $Y$ (such as image-to-image uncertainty) remains an open frontier for future research.

Summary updated

BibTeX
@inproceedings{kostic2024neural,
  author = {Vladimir R Kostic and gregoire pacreau and Giacomo Turri and Pietro Novelli and Karim Lounici and Massimiliano Pontil},
  title = {{Neural Conditional Probability for Uncertainty Quantification}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2024},
  url = {https://openreview.net/forum?id=zXfhHJnMB2},
}
Figure