Training algorithms in deep learning usually treat a mini-batch of samples as a single object; they average gradients over the mini-batch, and then process the average in various ways. Computing other statistics beyond the average may have been seen as prohibitively resource intensive in automatic differentiation (AD) frameworks. We show that this is not the case. Generally, gradient statistics can be implemented through a surgery of the AD graph, which, in some cases, incur almost no computational and memory overheads compared to the mini-batch gradient computation. Additionally, we show that in certain classes of models, including transformers, JAX's vectorization transformation offers a viable implementation for prototyping and experimentation. We then revise our understanding of two nonlinear operations in optimization through the lens of per-example gradient transformations. We first study signSGD and show that the optimal placement of the sign operation in the gradient processing chain is crucial to success and can be predicted with a simple signal-to-noise ratio argument. Next we study per-example variations of the Adam preconditioner, and show that optimization is best served when the preconditioner is dominated by the mean rather than the variance of the gradient distribution - in contrast to conventional wisdom. Overall we demonstrate that per-example gradient information enables new analyses and possibilities for algorithm design.
Improving the Adaptive Moment Estimation (ADAM) stochastic optimizer through an Implicit-Explicit (IMEX) time-stepping approach
Computational Science Laboratory(计算科学实验室);Virginia Tech(弗吉尼亚理工大学);The University of Texas at Austin(德克萨斯大学奥斯汀分校);California State University, Long Beach(加州州立大学长滩分校)
FastAdaBelief: Improving Convergence Rate for Belief-based Adaptive Optimizers by Exploiting Strong Convexity
University of Science and Technology of China(中国科学技术大学);Duke Kunshan University(昆山杜克大学);Edinburgh Napier University(爱丁堡龙比亚大学);Gusu Laboratory of Materials(姑苏材料实验室)
Enhancing Optimizer Stability: Momentum Adaptation of The NGN Step-size
University of Basel(巴塞尔大学);Max Planck Institute for Intelligent Systems(马克斯·普朗克智能系统研究所);ELLIS Institute Tübingen(图宾根ELLIS研究所);Tübingen AI Center(图宾根人工智能中心)
Penalizing Gradient Norm for Efficiently Improving Generalization in Deep Learning
Tsinghua University(清华大学)
如何训练深度神经网络(DNN)以良好地泛化是深度学习的核心问题,特别是对于当今严重过参数化的网络。在本文中,我们提出了一种有效的方法来提高模型的推广,额外的惩罚梯度范数的损失函数在优化过程中。我们证明了限制损失函数的梯度范数可以帮助引导优化器找到平坦的最小值。我们利用一阶近似来有效地实现相应的梯度,以很好地适应梯度下降框架。在我们的实验中,我们证实,当使用我们的方法时,各种模型的泛化性能可以在不同的数据集上得到提高。此外,我们表明,最近的锐度感知最小化方法(Foret et al.,2021)是我们方法的一个特殊但不是最好的情况,我们方法的最好情况可以在这些任务上提供新的最先进的性能。代码可以在{https://github.com/zhaoyang-0204/gnp}上找到。