Sequential Bayesian Neural Subnetwork Ensembles

Sanket Jantre, Shrijita Bhattacharya, Nathan M. Urban, Byung-Jun Yoon, Tapabrata Maiti, Prasanna Balaprakash, Sandeep Madireddy

TL;DR

The paper introduces SeBayS (Sequential Bayesian Neural Subnetwork Ensembles), a highly efficient method that trains diverse, sparse Bayesian neural networks in a single training run. By maintaining network sparsity from day one and using a sequential "explore-exploit" training strategy, SeBayS matches or beats traditional, expensive dense ensembles in accuracy, uncertainty quantification, and adversarial robustness at a fraction of the computational cost.

What Problem Does This Paper Address?

Deep ensembles—combining the predictions of multiple neural networks—are the gold standard for improving accuracy and delivering reliable uncertainty estimates. However, they come with a massive catch: training multiple dense models from scratch is computationally extravagant.

While network pruning (sparsity) can reduce model complexity, traditional sparse training methods still require training a full dense model first before pruning it, saving no time during the training phase. Furthermore, approximate Bayesian Neural Networks (BNNs), which naturally model uncertainty, often struggle to capture the full complexity of the data due to simplifying assumptions made for computational tractability.

The authors tackle this multi-pronged challenge: How can we build an ensemble of diverse, uncertainty-aware Bayesian models without the prohibitive training costs of traditional parallel ensembles?

Methods

The authors propose Sequential Bayesian Neural Subnetwork Ensembles (SeBayS). Instead of training multiple models in parallel, SeBayS generates an ensemble sequentially during a single training pass using two core techniques:

  1. Dynamic Sparsity Learning: The model initializes with a sparse structure using the Erdős-Rényi-Kernel (ERK) method and maintains this target sparsity level throughout the entire training process. It periodically updates its architecture using a "prune-grow" cycle: weights with a low Signal-to-Noise Ratio (SNR) are pruned, and new weights are grown where gradient magnitudes are highest.
  2. Sequential Ensembling Strategy: Training is divided into two distinct phases:
  3. Exploration Phase: The model uses a large constant learning rate to find a high-performing region in the parameter space.
  4. Exploitation Phases: The learning rate is cycled (moderately large to small) to force the model to settle into a local minimum, representing a high-performing subnetwork. This subnetwork is saved as an ensemble member. To find the next member, a large fraction of weights are aggressively pruned and regrown, forcing the model to escape the current minimum and discover a distinct new subnetwork.
Figure 1: Illustration of SeBayS ensemble: Our approach in- cludes an exploration phase followed by multiple exploitation phases to create Bayesian subnetworks. SeBayS ensemble prediction is obtained by combining their predictions.

Datasets

The approach was evaluated on standard image classification benchmarks:

  • CIFAR-10 and CIFAR-100: For standard training and evaluation.
  • CIFAR-10-C and CIFAR-100-C: Corrupted versions of the datasets (featuring blur, frost, compression artifacts, etc.) used to evaluate model robustness under distribution shift.
  • SVHN (Street View House Numbers): Utilized as an out-of-distribution (OoD) dataset to test the ensemble's ability to flag unfamiliar data.

Key Insights and Ideas

  • Sparsity as a Diversity Mechanism: Rather than just a tool for compression, different sparse connectivity patterns naturally cause subnetworks to behave differently, inherently boosting ensemble diversity.
  • The Power of the "Jolt": The aggressive prune-grow step at the end of each exploitation phase acts as a functional "jolt," successfully kicking the sparse BNN out of its current local minimum and guiding it toward a completely different, high-performing region of the energy landscape.
  • Single-Pass Efficiency: SeBayS demonstrates that you don't need multiple independent training runs to achieve the benefits of an ensemble; a single, continuous training trajectory can harvest diverse models if scheduled correctly.

Key Results

SeBayS was benchmarked against several state-of-the-art ensemble methods using a Wide ResNet28-10 architecture:

  • Superior Calibration: On CIFAR-10, a SeBayS ensemble with an ensemble size of $M=7$ and 90% sparsity ($S=0.9$) achieved the lowest Expected Calibration Error (0.006) among all single-pass models, outperforming even dense BNN ensembles.
  • Robustness to Corruption: On corrupted data (CIFAR-10-C), SeBayS ($M=7, S=0.9$) achieved a corrupted accuracy (cAcc) of 78.0% and the lowest corrupted negative log-likelihood (cNLL) of 0.776 among single-pass baselines.
  • Out-of-Distribution Detection & Adversarial Defense: SeBayS demonstrated strong OoD detection performance on SVHN and significantly outperformed other sparse ensembles (like DST and EDST) in defending against Fast Gradient Sign Method (FGSM) adversarial attacks.
Figure 3: Performance of base learners and their ensembles as ensemble size M varies in CIFAR-10 experiment.

Limitations and Future Work

While SeBayS drastically reduces the theoretical computational complexity (FLOPs) during training, the authors note a practical hardware limitation: current GPU architectures are heavily optimized for dense matrix operations. Unstructured sparsity does not always translate directly to wall-clock speedups on standard hardware.

As a next step, the authors suggest exploring structured sparsity (such as fine-grained $N:M$ sparsity patterns) that align better with modern GPU hardware accelerators, alongside developing even more energy-efficient frameworks for large-scale uncertainty estimation.

Summary updated

BibTeX
@misc{jantre2022sequential,
  author = {Sanket Jantre and Shrijita Bhattacharya and Nathan M. Urban and Byung-Jun Yoon and Tapabrata Maiti and Prasanna Balaprakash and Sandeep Madireddy},
  title = {{Sequential Bayesian Neural Subnetwork Ensembles}},
  year = {2022},
  eprint = {2206.00794},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2206.00794},
}
Figure