arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2402.11025cs.LGstat.ML
收藏

使用稀疏子空间变分推断训练贝叶斯神经网络

Training Bayesian Neural Networks with Sparse Subspace Variational Inference

Purdue University(普渡大学)

Junbo Li, Zichen Miao, Qiang Qiu, Ruqi Zhang

AI总结:

提出首个完全稀疏的贝叶斯神经网络框架SSVI,通过交替优化稀疏子空间基选择与参数,在训练和推断全程保持高稀疏性,大幅降低训练成本并实现10-20倍模型压缩且性能损失极小。

摘要:

贝叶斯神经网络(BNNs)提供不确定性量化,但缺点是训练和推断成本大幅增加。人们已经研究了稀疏BNNs以实现高效推断,通常的做法要么是在整个训练过程中缓慢引入稀疏性,要么是对密集BNNs进行训练后压缩。如何削减庞大的训练成本这一困境依然存在,特别是在需要学习不确定性的情况下。为了解决这一挑战,我们引入了稀疏子空间变分推断(SSVI),这是第一个在训练和推断阶段始终保持高度稀疏贝叶斯模型的完全稀疏BNN框架。从随机初始化的低维稀疏子空间出发,我们的方法交替优化稀疏子空间基选择及其相关参数。虽然基选择被描述为一个不可微问题,但我们使用移除与添加策略来近似最优解,该策略由基于权重分布统计的新颖标准指导。我们广泛的实验表明,SSVI在构建稀疏BNNs方面树立了新基准,例如,与密集VI训练相比,实现了模型大小10-20倍的压缩且性能下降不到3%,训练期间FLOPs减少高达20倍。值得注意的是,SSVI还表现出对超参数的更强鲁棒性,减少了VI中复杂调优的需求,有时甚至在准确性和不确定性指标上超越了VI训练的密集BNNs。

英文摘要:

Bayesian neural networks (BNNs) offer uncertainty quantification but come with the downside of substantially increased training and inference costs. Sparse BNNs have been investigated for efficient inference, typically by either slowly introducing sparsity throughout the training or by post-training compression of dense BNNs. The dilemma of how to cut down massive training costs remains, particularly given the requirement to learn about the uncertainty. To solve this challenge, we introduce Sparse Subspace Variational Inference (SSVI), the first fully sparse BNN framework that maintains a consistently highly sparse Bayesian model throughout the training and inference phases. Starting from a randomly initialized low-dimensional sparse subspace, our approach alternately optimizes the sparse subspace basis selection and its associated parameters. While basis selection is characterized as a non-differentiable problem, we approximate the optimal solution with a removal-and-addition strategy, guided by novel criteria based on weight distribution statistics. Our extensive experiments show that SSVI sets new benchmarks in crafting sparse BNNs, achieving, for instance, a 10-20x compression in model size with under 3\% performance drop, and up to 20x FLOPs reduction during training compared with dense VI training. Remarkably, SSVI also demonstrates enhanced robustness to hyperparameters, reducing the need for intricate tuning in VI and occasionally even surpassing VI-trained dense BNNs on both accuracy and uncertainty metrics.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑