Deep learning (DL) has become an integral part of solutions to various important problems, which is why ensuring the quality of DL systems is essential. One of the challenges of achieving reliability and robustness of DL software is to ensure that algorithm implementations are numerically stable. DL algorithms require a large amount and a wide variety of numerical computations. A naive implementation of numerical computation can lead to errors that may result in incorrect or inaccurate learning and results. A numerical algorithm or a mathematical formula can have several implementations that are mathematically equivalent, but have different numerical stability properties. Designing numerically stable algorithm implementations is challenging, because it requires an interdisciplinary knowledge of software engineering, DL, and numerical analysis. In this paper, we study two mature DL libraries PyTorch and Tensorflow with the goal of identifying unstable numerical methods and their solutions. Specifically, we investigate which DL algorithms are numerically unstable and conduct an in-depth analysis of the root cause, manifestation, and patches to numerical instabilities. Based on these findings, we launch, the first database of numerical stability issues and solutions in DL. Our findings and provide future references to developers and tool builders to prevent, detect, localize and fix numerically unstable algorithm implementations. To demonstrate that, using {\it DeepStability} we have located numerical stability issues in Tensorflow, and submitted a fix which has been accepted and merged in.
Unstable Rankings in Bayesian Deep Learning Evaluation
Department of Mathematical and Statistical Sciences(数学与统计学系);Marquette University(马凯特大学);Cornell University(康奈尔大学);The University of Melbourne(墨尔本大学);University of Illinois Urbana-Champaign(伊利诺伊大学厄巴纳-香槟分校);Tongji University(同济大学)
Reconstruction of Unstable Heavy Particles Using Deep Symmetry-Preserving Attention Networks
Department of Physics and Astronomy, University of California, Irvine(加州大学尔湾分校物理与天文学系);Department of Computer Science, University of California, Irvine(加州大学尔湾分校计算机科学系);Institute of High Energy Physics, Chinese Academy of Sciences(中国科学院高能物理研究所);Institute of Modern Physics, Fudan University(复旦大学现代物理研究所);Department of Physics, National Tsing Hua University(国立清华大学物理学系);Department of Physics and Astronomy, University of Washington(华盛顿大学物理与天文学系)
Recurrent Kalman Networks: Factorized Inference in High-Dimensional Deep Feature Spaces
University of Lincoln(林肯大学);University of Birmingham(伯明翰大学);Lancaster University(兰卡斯特大学);Bosch Center for Artificial Intelligence(博世人工智能中心)
为了将不确定性估计集成到深度时间序列建模中,卡尔曼滤波器(KF)(Kalman et al.,1960)已经与深度学习模型集成,然而,这样的方法通常依赖于近似推理技术,例如变分推理,这使得学习更复杂并且由于近似误差而通常可扩展性较低。我们提出了一种新的深度卡尔曼滤波方法,可以使用反向传播以端到端的方式直接学习,而无需额外的近似。我们的方法使用了高维分解的潜在状态表示,卡尔曼更新简化为标量操作,从而避免了难以反向传播,计算量大,可能不稳定的矩阵求逆。此外,我们使用局部线性动态模型,有效地传播的潜在状态到下一个时间步。由此产生的网络架构,我们称之为递归卡尔曼网络(RKN),可用于任何时间序列数据,类似于LSTM(Hochreiter & Schmidhuber,1997),但使用显式表示不确定性。如我们的实验所示,RKN获得比LSTM或门控递归单元(GRU)更准确的不确定性估计(Cho等人,2014),同时还显示出略微改善的预测性能,并且在图像填补任务上优于各种最近的生成模型。
Variance Reduction for Deep Q-Learning using Stochastic Recursive Gradient
Gaoling School of Artificial Intelligence, Renmin University of China(中国人民大学高瓴人工智能学院);Baidu Inc.(百度公司);Huawei Technologies(华为技术有限公司)
深度Q-学习算法经常遭受具有过大方差的差的梯度估计,导致不稳定的训练和差的采样效率。已应用SVRG等随机方差缩减梯度方法来降低估计方差(Zhao等人,2019)。然而,由于强化学习的在线实例生成特性,直接将SVRG应用于深度Q学习面临着锚点估计不准确的问题,这极大地限制了SVRG的潜力。为了解决这个问题,并受到递归梯度方差缩减算法SARAH(Nguyen et al. 2017)的启发,本文提出引入递归框架来更新深度Q学习中的随机梯度估计,实现一种名为SRG-DQN的新算法。与基于SVRG的算法不同,SRG-DQN设计了随机梯度估计的递归更新。参数更新是利用过去的随机梯度信息沿着累积方向进行的,因此可以摆脱作为锚的全梯度的估计。此外,SRG-DQN涉及Adam过程以进一步加速训练过程。理论分析和著名的强化学习任务的实验结果表明,所提出的SRG-DQN算法的效率和有效性。