The original article is in Chinese. The English version is automatically translated by AI.
0x00 Preface
This article focuses on convergence analysis in deep learning. As the second part, it mainly covers convergence proofs for gradient descent under (strongly convex smooth / smooth convex / non-smooth convex / smooth non-convex / non-convex) settings. I won’t repeat the earlier definitions here—readers can check Convergence Analysis in Deep Learning (Part 1) first. Much of this draws on 1, 2, 3, and 4, with a bit from 5.
0x01 Definition of Convergence
Usually, an optimization problem in deep learning can be written as
where $w$ is the parameter to optimize and $f(w)$ is the objective function. In deep learning, we typically use gradient descent to solve this problem, i.e.,
Convergence of a gradient method can be defined in three ways:
Objective value convergence to the optimum: $\mathbb{E} f(w_T) - f^* \leq \epsilon(T)$, where $f^*$ is the optimal objective value.
Iterate convergence to the optimal solution: $\mathbb{E} ||w_T - w^*||^2 \leq \epsilon(T)$, where $w^*$ is the optimal parameter.
If $\epsilon(T) \to 0$, we say this gradient method is convergent. Different convergent optimization algorithms can converge at different rates; typically, the convergence rate is defined by how fast $\log \epsilon(T)$ decays:
- If $\log \epsilon(T)$ is of the same order as $-T$, we say the algorithm has a linear convergence rate.
- If $\log \epsilon(T)$ decays slower than $-T$, we say the algorithm has a sublinear convergence rate.
- If $\log \epsilon(T)$ decays faster than $-T$, we say the algorithm has a superlinear convergence rate; further, if $\log \log \epsilon(T)$ is of the same order as $-T$, we say it has a quadratic convergence rate.
In non-convex optimization, because there may be multiple local minima and finding the global optimum is hard, we instead ask whether the algorithm converges to a stationary point where the gradient is 0.
- Using the ergodic gradient norm as the metric: $\min_{t=1,\cdots,T} \mathbb{E} ||\nabla f(w_t)||^2 \leq \epsilon(T)$, or $\frac{1}{T}\sum_{t=1}^{T}\mathbb{E}||\nabla f(w_{t})||^2$ tending to 0.
info
Below we start from the strongest assumptions (strongly convex + smooth) and gradually relax the conditions.
0x02 Smooth Strongly Convex with GD
defination
Suppose the objective $f$ is $\mu$-strongly convex and $L$-smooth on $R^{d}$. When the step size satisfies $\eta \leq \frac{1}{L}$ and the starting point is $w_0$, after $t$ steps of iteration, $f(w_t)$ is bounded as:$$ f\left(w_{t}\right)-f^{*} \leq (1-\eta \mu)^{t}\left(f\left(w_{0}\right)-f^{*}\right) $$
Proof:
tip
Let's outline the overall proof strategy first—most of the proofs below follow the same pattern: first prove a one-step bound, then use induction to prove the multi-step bound. Along the way we constrain the choice of $\eta$ (usually via the vertex of a quadratic function, or a hyperbola-style tradeoff). Also note that smoothness gives an upper bound on the function while strong convexity gives a lower bound; sometimes we negate terms to align the inequality signs. Also, even under the exact same assumptions on the function, different choices of $\eta$ and different bounds can yield different convergence rates.
First look at a single step:
Here we pull out a negative sign on both terms, use the vertex of the quadratic to pick $\eta$, and bring in the property implied by strong convexity:
Thus we get
Setting $\eta \leq \frac{1}{L}$ gives $(1-\frac{L}{2} \eta ) \geq \frac{1}{2}$, so
Notice both sides involve $f(x)$; adding and subtracting $f^*$ on the left gives
Then we unroll by induction:
Now that we have the bound, let’s compute the complexity.
By the definition of complexity, set $f(w_t)-f^* \leq \epsilon$:
tip
Here $Q=\frac{L}{\mu}$ is commonly called the condition number. From 0x02 and 0x03, we can make the following remarks on the convergence of gradient descent: 1. When the objective is strongly convex, gradient descent converges linearly; when it is merely convex, the convergence rate is sublinear. In other words, strong convexity greatly speeds up gradient descent. Furthermore, the stronger the convexity (larger $\mu$), the smaller the condition number $Q$, and the faster the convergence. 2. Smoothness speeds up gradient descent in both convex and strongly convex cases: smaller $L$ (smaller condition number $Q$ in the strongly convex case) yields faster convergence.
0x03 Smooth Convex with GD
defination
Suppose the objective $f$ is convex and $L$-smooth on $R^{d}$. With step size $\eta =\frac{1}{L}$ and starting point $w_0$, after $T$ steps of iteration, $f(w_T)$ is bounded as:$$ f\left(w_{T}\right)-f^{*} \leq \frac{L}{2T} || w_{0} - w^{*} ||^{2} $$
Proof:
From the proof above, we already know that under $L$-smoothness,
By convexity,
From gradient descent we have the identity
Substituting $\nabla f(w_{t})^{\top}(w_{t}-w^{*})$ from the GD identity into convexity gives
Notice here that setting $\eta = \frac{1}{L}$ cancels the $||\nabla f(w_{t})||^2$ term. This choice comes from the $f(w_{t+1})-f(w_{t})$ inequality (taking the minimum), while the second part is just an identity substitution and doesn’t constrain $\eta$.
Seeing this form, you can probably guess the next step—just sum it up:
Note that the left-hand side can be lower-bounded further, giving
Q.E.D.
Now that we have the bound, let’s compute the complexity.
By the definition of complexity, setting $f(w_t)-f^* \leq \epsilon$ gives
This is a sublinear convergence rate.
0x04 Non-smooth Convex with GD
If we only have convexity left, we must add the bounded-gradient assumption to bound the error and guarantee convergence, which gives the following result:
defination
Suppose the objective $f$ is convex on $R^{d}$. When the step size is $\eta =\frac{||w_{0}-w^{*}||}{\sqrt{T+1}G}$ and the starting point is $w_{0}$, after $T$ steps of iteration, $f(w_{t})$ is bounded as:$$ \min_{t=0,\cdots,T} f\left(w_{t}\right)-f^{*} \leq \frac{G||w_{0}-w^{*}||}{\sqrt{T+1}} $$
Proof:
Pretty much the same idea as above:
Again, summing both sides gives
That is,
By the elementary checkmark function (AM-GM), when $\eta = \sqrt{\frac{||w_{0}-w^{}||^{2}}{G^{2}(T+1)}}=\frac{||w_{0}-w^{}||}{G\sqrt{T+1}}$, we get
Q.E.D.
The complexity is easy to read off:
This is a sublinear convergence rate.
There is also an alternative approach—it’s easier to work backwards, and personally I find it hard to come up with directly from the front.
defination
Suppose the objective $f$ is convex on $R^{d}$. When the step size is $\eta = \frac{f(w_{t})-f^{*}}{||\nabla f(w_{t})||^2}$ and the starting point is $w_{0}$, after $t$ steps of iteration, $f(w_{t})$ is bounded as:$$ \min_{t=0}^{T} f(w_{t})-f^{*}\leq \frac{G\left \| w_{0}-w^{*}\right \|}{\sqrt{T+1}} $$
Proof:
Starting from gradient descent:
This is a quadratic function in $\eta$. Setting $\eta = \frac{f(w_{t})-f^{*}}{||\nabla f(w_{t})||^2}$ directly—also known as the Polyak step size—gives
Rearranging gives
Different choice of $\eta$ from the method above, but the same convergence rate.
0x05 Smooth non-convex with GD
defination
Suppose the objective $f$ is $L$-smooth on $R^{d}$. When the step size is $\eta =\frac{1}{L}$ and the starting point is $w_0$, after $t$ steps of iteration, $f(w_t)$ is bounded as:$$ \min_{t=0,\cdots,T} \left\|\nabla f(w_{t})\right\|^{2} \leq \frac{2L (f(w_{0})-f(w^{*}))}{(T+1)} $$
Proof:
Starting directly from the earlier inequality, we have
Maximizing the left-hand side at $\eta = \frac{1}{L}$ gives
Simply sum and bound:
Q.E.D.
0x06 Strongly Convex and Non-smooth with GD
Alright, only one last case left—note that besides strong convexity, we also need $L$-Lipschitz continuity, which is equivalent to uniformly bounded gradients so at least the gradient can’t just blow up…
defination
Suppose the objective $f$ is $\mu$-strongly convex and $L$-Lipschitz continuous on $R^{d}$. When the step size is $\eta_{t} =\frac{2}{\mu (t+1)}$ and the starting point is $w_0$, after $T$ steps of iteration, $f(w_t)$ is bounded as:$$ \min_{t=0,\cdots,T} f(w_{t})-f^{*} \leq \frac{2L^{2}}{\mu (T+1)} $$
Proof:
From GD and strong convexity,
By $L$-Lipschitz continuity,
Therefore,
Ordinary summation and bounding may only give a slower sublinear rate; by matching coefficients for telescoping, we can obtain a tighter bound. Solving for the coefficient of the $t$ term as $c\cdot (t-1)$ (noting there is a constant term at the end that needs multiplying by $t$ for easy bounding), we have
Solving gives
That is, $\frac{1}{\eta_{t}} = \frac{\mu(t+1)}{2}$, so $\eta_{t} = \frac{2}{\mu (t+1)}$, giving
Notice the left-hand side is now an arithmetic series, so
Q.E.D.
0x07 Conclusion
There is also a non-convex non-smooth case, though in that setting gradient descent does not necessarily converge…
We used the bounded-gradient assumption for non-smooth convex and non-smooth strongly convex functions. It’s clear that non-smoothness is a rather unfriendly setting for convergence, whereas strong convexity usually guarantees a very good convergence rate—smooth strongly convex yields linear convergence, and while non-smooth strongly convex is still sublinear at $O(1/T)$, it is much faster than general non-smooth convex.
Reference
Convergence Analysis of Gradient Methods under Different Conditions 1—(Non)convex+(Non)smooth (in Chinese), https://zhuanlan.zhihu.com/p/92385493 ↩︎
Distributed Machine Learning: Algorithms, Theory, and Practice (in Chinese), Tie-Yan Liu et al. ↩︎
ZJU-CSE Summer School 2021, Ying Sun ↩︎
First-order methods in optimization, Beck, A. ↩︎

