ACE Journal

Uncertainty Quantification in Deep Learning

Abstract

Deep neural networks are confidently wrong with surprising regularity: a softmax classifier returns a near-certain probability on inputs far outside its training distribution, while a well-calibrated model would instead return a diffuse, high-entropy prediction. Uncertainty quantification (UQ) addresses this gap by equipping models with principled mechanisms to estimate when they do not know. The distinction between aleatoric uncertainty - noise intrinsic to the data-generating process - and epistemic uncertainty - uncertainty reducible with more data - underlies most UQ methodology. In high-stakes deployment settings such as medical imaging, autonomous driving, and scientific simulation, UQ is increasingly treated as a system requirement rather than a research nicety.

Bayesian Approaches and Their Approximations

Exact Bayesian inference over neural network weights is computationally intractable for modern architectures. Practical Bayesian deep learning uses approximate posterior inference. Monte Carlo Dropout (Gal and Ghahramani, 2016) retains dropout at inference time, treating each stochastic forward pass as a sample from an implicit posterior, and aggregating predictions across samples to estimate predictive variance. Deep Ensembles (Lakshminarayanan et al., Google Brain, 2017) train multiple independently initialized models and combine their outputs; despite lacking a formal Bayesian justification, ensembles consistently achieve strong calibration and are considered a practical baseline. Variational inference methods such as Bayes by Backprop (Blundell et al.) parameterize weight distributions and optimize the ELBO, but tend to underfit on complex tasks compared to ensembles. Stochastic Weight Averaging - Gaussian (SWAG, Maddox et al.) fits a Gaussian to the trajectory of SGD iterates near convergence, providing a cheap posterior approximation that matches ensembles on many benchmarks with a single training run.

Conformal Prediction as a Distribution-Free Alternative

Conformal prediction (Vovk et al.) produces prediction sets with guaranteed coverage under minimal distributional assumptions: given a calibration set and a user-specified error rate alpha, conformal methods output a set of labels that contains the true label with probability 1 - alpha, without assuming the model is well-specified. This distribution-free guarantee is attractive for deployment because it applies to any trained model without retraining. Split conformal prediction is computationally light: score a held-out calibration set, compute the (1 - alpha) quantile of non-conformity scores, and use that quantile to threshold prediction sets on new inputs. RAPS and APS are recent variants that reduce prediction set size through adaptive scoring. Conformal prediction has been applied to regression (producing prediction intervals), object detection (producing bounding-box sets), and protein structure prediction, the last attracting interest from computational biology groups seeking calibrated confidence for AlphaFold2-predicted structures.

Calibration Metrics and Practical Measurement

Expected Calibration Error (ECE) measures the average gap between predicted confidence and empirical accuracy across confidence bins. A well-calibrated classifier produces ECE close to zero: when it predicts 70% probability, it is correct roughly 70% of the time. Temperature scaling (Guo et al., 2017) is a post-hoc recalibration method that fits a single scalar parameter on a held-out validation set to soften or sharpen the softmax distribution; it consistently improves ECE at negligible cost and is now a standard final step in classification pipelines. For regression, proper scoring rules such as the Continuous Ranked Probability Score (CRPS) measure the quality of distributional predictions. Modern benchmarks including WILDS (Koh et al.) and the UQ in Deep Learning benchmark (Ovadia et al.) facilitate apples-to-apples comparison of UQ methods under covariate and label shift.

Deployment Considerations

UQ adds overhead - multiple forward passes for ensembles or MC Dropout, or a calibration set for conformal methods - that must be budgeted at design time. Selective prediction (abstaining when uncertainty exceeds a threshold) requires pairing UQ estimates with a coverage-accuracy operating curve to set the threshold appropriately for the deployment risk profile. Regulatory guidance in the EU AI Act and FDA’s proposed framework for AI-based medical devices both reference uncertainty communication, suggesting that UQ will increasingly intersect with compliance obligations for high-stakes AI systems.