Skip to main content
QUICK REVIEW

[论文解读] Revisiting Gradient Clipping: Stochastic bias and tight convergence guarantees

Anastasia Koloskova, Hadrien Hendrikx|arXiv (Cornell University)|May 2, 2023
Stochastic Gradient Optimization TechniquesComputer Science被引用 3
一句话总结

本文通过分析梯度裁剪引入的随机偏差,为裁剪的随机梯度下降(SGD)提供了紧密的收敛保证。结果表明,裁剪SGD在梯度范数上收敛到大小为 $\min\{\sigma, \sigma^2/c\}$ 的邻域内,且上下界匹配;证明了在确定性设置下,裁剪阈值 $c$ 仅影响高阶项,从而在无需对噪声或裁剪值施加严格假设的前提下,提供了精确且通用的收敛界。

ABSTRACT

Gradient clipping is a popular modification to standard (stochastic) gradient descent, at every iteration limiting the gradient norm to a certain value $c >0$. It is widely used for example for stabilizing the training of deep learning models (Goodfellow et al., 2016), or for enforcing differential privacy (Abadi et al., 2016). Despite popularity and simplicity of the clipping mechanism, its convergence guarantees often require specific values of $c$ and strong noise assumptions. In this paper, we give convergence guarantees that show precise dependence on arbitrary clipping thresholds $c$ and show that our guarantees are tight with both deterministic and stochastic gradients. In particular, we show that (i) for deterministic gradient descent, the clipping threshold only affects the higher-order terms of convergence, (ii) in the stochastic setting convergence to the true optimum cannot be guaranteed under the standard noise assumption, even under arbitrary small step-sizes. We give matching upper and lower bounds for convergence of the gradient norm when running clipped SGD, and illustrate these results with experiments.

研究动机与目标

  • 理解裁剪阈值 $c$ 在确定性和随机梯度下降中对收敛的影响。
  • 解决在标准噪声假设下,裁剪SGD缺乏紧密且通用的收敛保证的问题。
  • 表明由于裁剪带来的持续偏差,裁剪SGD在随机情况下不会收敛到真实最优解。
  • 推导出与噪声分布或 $c$ 的具体假设无关的梯度范数收敛的匹配上下界。
  • 提供一个统一的分析框架,适用于任意 $c > 0$,并揭示收敛对 $c$ 和噪声方差 $\sigma^2$ 的精确依赖关系。

提出的方法

  • 在一般噪声假设下分析裁剪SGD,包括重尾分布,无需有界梯度或均匀噪声的假设。
  • 通过光滑性和方差假设推导出期望梯度范数收敛的上界,表明其收敛至 $\min\{\sigma, \sigma^2/c\}$。
  • 通过构造具有伯努利噪声的反例建立匹配的下界,证明了上界的紧致性。
  • 分别独立分析确定性和随机设置,表明在确定性情况下,裁剪仅影响瞬态阶段。
  • 通过引入高斯噪声,将分析适配于DP-SGD,推导出同时包含裁剪偏差和差分隐私噪声的收敛速率。
  • 采用一种新颖的偏差项 $\mathbb{E}[\|\text{clip}_c(\nabla f_\xi) - \nabla f\|]$ 分解方法,将裁剪的影响与随机噪声的影响分离开来。

实验结果

研究问题

  • RQ1在确定性设置下,裁剪阈值 $c$ 如何影响裁剪SGD的收敛速率?
  • RQ2在随机设置下,梯度裁剪引入的精确偏差是什么?它如何依赖于 $c$ 和噪声方差 $\sigma^2$?
  • RQ3能否在不施加强假设(如梯度有界或角度受限条件)的情况下,为裁剪SGD推导出收敛保证?
  • RQ4收敛邻域大小 $\min\{\sigma, \sigma^2/c\}$ 是否紧致?能否通过下界构造实现匹配?
  • RQ5在随机情况下,裁剪SGD是否收敛到真实最优解,还是仅收敛到一个邻域?

主要发现

  • 在确定性设置下,裁剪梯度下降收敛到与标准GD相同的临界点,且 $c$ 仅影响高阶项;主导收敛速率保持不变。
  • 对于随机梯度,裁剪SGD收敛到最优解的一个邻域,其中期望梯度范数被限制在 $\min\{\sigma, \sigma^2/c\}$ 以内,且该界是紧致的。
  • 裁剪引入的偏差被定量刻画为 $\min\{\sigma, \sigma^2/c\}$,且该界可通过下界构造实现匹配。
  • 即使在步长任意小时,由于裁剪带来的持续偏差,裁剪SGD在随机情况下也无法收敛到真实最优解。
  • 该分析表明,有界梯度的标准假设不足以保证在裁剪下收敛到真实最优解。
  • 通过将裁剪偏差与差分隐私噪声相结合,推导出DP-SGD的收敛速率,总误差项为 $O(\sigma_{\text{DP}}^2 / c + \sqrt{\sigma_{\text{DP}} \eta} + \min\{\sigma, \sigma^2/c\} + \cdots)$。

阅读本论文

在 Nubint 阅读器中打开原文,边读边就任意段落提问。

在 Nubint 中阅读本论文

本解读由 AI 根据论文原文生成,引用前请核对原文。