TL;DR
This paper introduces SeBayS, a novel method for creating diverse and robust Bayesian neural network ensembles by sequentially training sparse subnetworks. This approach significantly reduces computational cost while achieving state-of-the-art performance in accuracy, uncertainty estimation, and adversarial robustness.
What Problem Does This Paper Address?
Deep learning models, despite their impressive performance, often struggle with reliably estimating uncertainty and maintaining robustness, especially in critical applications like autonomous driving and healthcare. While deep ensembles offer a solution by leveraging model diversity, they are typically computationally expensive, requiring multiple independent model trainings. Traditional methods for inducing sparsity in neural networks, which can reduce complexity and improve robustness, often incur training costs comparable to dense models. This paper addresses the challenge of creating diverse and robust ensembles efficiently, particularly within the Bayesian framework, which is inherently better suited for uncertainty quantification. The authors aim to bridge the gap between the computational cost of traditional ensembles and the need for robust, uncertainty-aware models by proposing a sequential ensembling strategy that leverages dynamic sparsity.
Methods
The core of the proposed method, SeBayS (Sequential Bayesian Neural Subnetwork Ensembles), lies in its sequential ensembling strategy combined with dynamic sparsity learning. Instead of training multiple independent models in parallel, SeBayS trains a series of Bayesian neural subnetworks sequentially within a single forward pass.
The process involves:
- Exploration Phase: An initial phase where the model explores the parameter space with a high learning rate to identify high-performing regions. This phase aims to find a sparse connectivity pattern that leads to good predictive performance.
- Exploitation Phases: Following the exploration, multiple exploitation phases are conducted. In each phase, the model's sparsity is dynamically adjusted (pruning and growing weights) to encourage convergence to different local minima in the energy landscape. This process generates diverse Bayesian subnetworks.
- Dynamic Sparsity Learning: This technique is central to reducing model complexity. It involves initializing a sparse connectivity and then iteratively pruning less significant weights and regrowing new ones. This is guided by a Signal-to-Noise Ratio (SNR) criterion, which considers both the magnitude and variance of weights.
- Bayesian Neural Networks (BNNs): The method leverages BNNs, which inherently provide uncertainty estimates through probabilistic modeling. Variational Inference (VI) is used for approximating the posterior distribution of model parameters.
This sequential approach contrasts with traditional parallel ensembles and also differs from deterministic sparse methods by integrating sparsity induction directly into the Bayesian learning process.
Datasets
The paper uses the following datasets for training and evaluation:
- CIFAR-10: A standard benchmark dataset for image classification.
- CIFAR-100: A more challenging version of CIFAR-10 with a larger number of classes.
- SVHN (Street View House Numbers): Used as an out-of-distribution (OoD) dataset for evaluating the models' ability to detect unfamiliar data.
- CIFAR-10-C and CIFAR-100-C: Corrupted versions of CIFAR-10 and CIFAR-100, used for robustness testing.
Key Insights and Ideas
- Sequential Sparsity for Diversity: The paper demonstrates that sequentially training sparse subnetworks, with dynamic pruning and growing, can effectively generate diverse models that converge to distinct local optima in the function space. This diversity is crucial for ensemble performance.
- Computational Efficiency: By training subnetworks sequentially within a single forward pass, SeBayS significantly reduces the computational cost compared to traditional parallel ensembles, making it more scalable.
- Sparsity as a Regularizer for Diversity: The dynamic sparsity mechanism not only reduces model complexity but also acts as a form of regularization that encourages exploration of different parts of the parameter space, leading to more diverse subnetworks.
- Bayesian Framework Enhances Robustness: The integration of Bayesian principles with sparse subnetworks leads to improved uncertainty estimation and adversarial robustness, outperforming many deterministic ensemble methods.
- Exploration-Exploitation Strategy: The two-phase approach (exploration then exploitation) is key to finding good sparse configurations and then generating diverse subnetworks from those configurations.
Key Results
The SeBayS ensemble demonstrated strong performance across various metrics:
- Accuracy: On CIFAR-10, SeBayS ensembles achieved accuracy up to 96.6%, outperforming many baseline methods, including dense BNN ensembles. On CIFAR-100, SeBayS ensembles reached up to 82.7% accuracy.
- Uncertainty Estimation (NLL and ECE): SeBayS consistently achieved low negative log-likelihood (NLL) and expected calibration error (ECE), indicating well-calibrated uncertainty estimates. For instance, on CIFAR-10, it achieved the lowest ECE among many models.
- Out-of-Distribution (OoD) Detection: SeBayS ensembles outperformed static sparse and DST ensembles in OoD detection (measured by ROC-AUC), showing improved ability to distinguish between in-distribution and out-of-distribution data.
- Adversarial Robustness: SeBayS ensembles showed comparable or superior adversarial robustness compared to static sparse, DST, and EDST ensembles, and were competitive with dense DNN and BNN models.
- Diversity: The paper quantifies diversity using prediction disagreement (ddis) and KL divergence (dKL), showing that SeBayS ensembles achieve competitive diversity metrics, even surpassing some multi-pass ensemble methods.
Limitations and Future Work
- Limitations:
- The paper notes that while SeBayS achieves high performance, the diversity of its subnetworks can be slightly closer compared to parallel ensembles (as visualized by t-SNE trajectories).
- The computational efficiency, while improved, still relies on GPU hardware, and optimizing sparse structures for current GPU architectures is an ongoing challenge.
- Future Work:
- Explore energy-efficient large-scale uncertainty estimation frameworks.
- Investigate structured sparsity (e.g., fine-grained N:M sparsity) for further optimization and potential hardware acceleration.
- Further research into optimizing sparse structures for current GPU hardware.
Summary updated