Skip to main content
QUICK REVIEW

[Paper Review] Prior choice affects ability of Bayesian neural networks to identify unknowns

Daniele Silvestro, Tobias Andermann|arXiv (Cornell University)|May 11, 2020
Adversarial Robustness in Machine LearningComputer Science16 citations
TL;DR

This study investigates how prior distributions in Bayesian neural networks (BNNs) affect classification performance and uncertainty estimation, particularly in identifying out-of-distribution (unknown) instances. Using MCMC sampling and Bayes factors across four prior types—uniform, normal, Laplace, and truncated Cauchy—on four datasets, the authors find that prior choice significantly impacts true positive and false positive rates, with no single prior consistently outperforming others across datasets.

ABSTRACT

Deep Bayesian neural networks (BNNs) are a powerful tool, though computationally demanding, to perform parameter estimation while jointly estimating uncertainty around predictions. BNNs are typically implemented using arbitrary normal-distributed prior distributions on the model parameters. Here, we explore the effects of different prior distributions on classification tasks in BNNs and evaluate the evidence supporting the predictions based on posterior probabilities approximated by Markov Chain Monte Carlo sampling and by computing Bayes factors. We show that the choice of priors has a substantial impact on the ability of the model to confidently assign data to the correct class (true positive rates). Prior choice also affects significantly the ability of a BNN to identify out-of-distribution instances as unknown (false positive rates). When comparing our results against neural networks (NN) with Monte Carlo dropout we found that BNNs generally outperform NNs. Finally, in our tests we did not find a single best choice as prior distribution. Instead, each dataset yielded the best results under a different prior, indicating that testing alternative options can improve the performance of BNNs.

Motivation & Objective

  • To evaluate the impact of different prior distributions on the performance of Bayesian neural networks in classification tasks.
  • To assess how prior choice affects the ability of BNNs to assign high confidence to correct in-distribution predictions (true positive rate).
  • To investigate the effect of priors on the detection of out-of-distribution instances (false positive rate).
  • To compare BNNs with Monte Carlo dropout neural networks in terms of uncertainty quantification and prediction reliability.
  • To determine whether a single optimal prior distribution exists across diverse datasets or if performance is dataset-dependent.

Proposed method

  • Implemented a fully connected deep neural network with two hidden layers and ReLU activation, using MCMC (Metropolis-Hastings) to sample from the posterior distribution of weights.
  • Explored four prior distributions: uniform (U(−5,5)), standard normal (N(0,1)), Laplace (Laplace(0,1)), and truncated Cauchy (C(0,1) truncated at ±5).
  • Used softmax output layer to compute class probabilities and evaluated predictions via posterior probabilities and Bayes factors.
  • Trained models on subsets of four distinct datasets (I–IV), excluding one or more classes as out-of-distribution test instances.
  • Conducted 10 independent runs per dataset with different random subsets to assess stability and variability of results.
  • Computed empirical prior probabilities of class labels by sampling from priors and predicting on fixed inputs to assess prior-induced class imbalance.

Experimental results

Research questions

  • RQ1How does the choice of prior distribution affect the true positive rate of Bayesian neural networks in in-distribution classification?
  • RQ2To what extent does prior selection influence the false positive rate in detecting out-of-distribution (unknown) instances?
  • RQ3How do different priors affect the statistical support for predictions, as measured by posterior probabilities and Bayes factors?
  • RQ4How do BNNs with different priors compare to standard neural networks with Monte Carlo dropout in terms of accuracy and uncertainty estimation?
  • RQ5Is there a universally optimal prior distribution across diverse datasets, or does performance depend on dataset-specific characteristics?

Key findings

  • Prior choice significantly affects the true positive rate in BNNs, with performance varying substantially across different priors on the same dataset.
  • The truncated Cauchy prior achieved the highest true positive rate (0.997) on dataset I, while the Laplace prior performed best on dataset II (0.575) and dataset IV (0.753).
  • False positive rates for out-of-distribution detection varied widely by prior: the uniform prior yielded the lowest false positive rate (0.001) on dataset IV, while the Laplace prior showed the highest (0.061).
  • BNNs consistently outperformed standard neural networks with Monte Carlo dropout in both accuracy and uncertainty estimation, particularly in identifying unknowns.
  • No single prior distribution provided the best performance across all datasets; each dataset yielded optimal results under a different prior.
  • Empirical prior probabilities of classes were unbalanced across all tested priors, indicating that prior distributions induce systematic biases in class assignment even before data is observed.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.