Current uncertainty quantification is memory and compute expensive, which hinders practical uptake. To counter, we develop Sketched Lanczos Uncertainty (SLU): an architecture-agnostic uncertainty score that can be applied to pre-trained neural networks with minimal overhead. Importantly, the memory use of SLU only grows logarithmically with the number of model parameters. We combine Lanczos' algorithm with dimensionality reduction techniques to compute a sketch of the leading eigenvectors of a matrix. Applying this novel algorithm to the Fisher information matrix yields a cheap and reliable uncertainty score. Empirically, SLU yields well-calibrated uncertainties, reliably detects out-of-distribution examples, and consistently outperforms existing methods in the low-memory regime.
翻译:当前不确定性量化方法在内存和计算上代价高昂,阻碍了实际应用。为此,我们开发了草绘Lanczos不确定性(SLU)评分:一种与架构无关的不确定性度量方法,可应用于预训练神经网络且仅需最小开销。重要的是,SLU的内存使用量仅随模型参数数量呈对数增长。我们将Lanczos算法与降维技术相结合,以计算矩阵主导特征向量的草图。将此新颖算法应用于费舍尔信息矩阵,可得到经济可靠的不确定性评分。实证表明,SLU能产生校准良好的不确定性估计,可靠检测分布外样本,并在低内存环境下持续优于现有方法。