Skip to main content
© 2026 ePowerAI. All rights reserved.
CoursesContact
eAI
CoursesContact
Week 13: Landscapes and Implicit Bias
Adv. Optimization
01Week 1: Optimality Conditions Revisited
02Week 2: Lagrangian Duality in Depth
03Week 3: KKT and Sensitivity
04Week 4: LP, QP, and Conic Form
05Week 5: Semidefinite Programming
06Week 6: Interior-Point Methods
07Week 7: Proximal Methods and ADMM
08Week 8: Newton and Quasi-Newton
09Week 9: Variance Reduction
10Week 10: Large-Batch and Distributed Training
11Week 11: Automatic Differentiation
12Week 12: Sharpness and SAM
13Week 13: Landscapes and Implicit Bias
14Week 14: Capstone — Structure Meets Scale
Week 13· Adv. Optimization· Geometry & training science22 min read

Week 13: Landscapes and Implicit Bias

✦Learning Outcomes
  • Contrast saddles vs local minima in high dimension (intuition, not proof)
  • Explain overparameterisation: many global minimisers
  • Define implicit bias: the algorithm itself selects among interpolating solutions
  • List open gaps between convex guarantees and deep learning practice
◆Prerequisites

Background: Week 12 (sharpness, SAMSharpness-Aware Minimization, flat vs sharp minima). Week 8 (convergence rates, Newton vs first-order). Intermediate Optim Week 12 (nonconvex optimisation intro). Comfort with the idea that deep nets have nonconvex loss surfaces.

Later weeks: The implicit bias concepts here feed directly into the Week 14 capstone's decision flow — when to trust structure, when to trust scale, and what theoretical gaps remain.

High-Dimensional Landscapes#

In 1D and 2D, nonconvex functions look intimidating — peaks, valleys, saddles, sharp ridges. Our intuition from low dimensions suggests that gradient descent should frequently get trapped in poor local minima. Yet deep neural networks routinely train to near-zero training loss with simple first-order methods. Why?

The saddle point prevalence. In high dimensions (d≫1d \gg 1d≫1), critical points of random Gaussian fields (a crude model for loss surfaces) are overwhelmingly saddles, not local minima. A random critical point has roughly equal numbers of positive and negative Hessian eigenvalues. For a critical point to be a local minimum, all ddd eigenvalues must be nonnegative — an exponentially rare event in truly random landscapes unless the index (the number of negative eigenvalues) is zero.

Intuition. At a saddle, there exists at least one direction of negative curvature — a direction downhill. Gradient descent, with even a small amount of noise (SGDStochastic Gradient Descent), can escape saddles by following these negative-curvature directions. The Hessian at a strict saddle has at least one negative eigenvalue, and gradient noise perturbs the iterate away from the ridge, allowing it to slide down.

Escaping saddles is easy; bad local minima are rarer than we think. This does not mean every critical point in a deep net loss landscape is a global minimum — far from it. But it suggests that for large overparameterised networks, all local minima may be nearly as good as the global minimum. The real challenge is not getting stuck in a bad minimum but navigating the proliferation of saddle points efficiently.

Overparameterisation#

A model is overparameterised when it has more parameters than necessary to fit the training data. In this regime:

  • The training loss can be driven to (near) zero — the model interpolates the training data.
  • There are infinitely many weight configurations that achieve zero training loss — the set of global minimisers is a high-dimensional manifold, not a discrete set of isolated points.
  • Generalisation depends on which of these many solutions the optimiser finds.

Overparameterised linear regression is the simplest example: min⁡w  ∥Xw−y∥22\min_w \; \|Xw - y\|_2^2minw​∥Xw−y∥22​ with d>nd > nd>n. There are infinitely many www that satisfy Xw=yXw = yXw=y exactly (the nullspace of XXX has dimension d−rank⁡(X)d - \operatorname{rank}(X)d−rank(X)). Among them, which one does gradient descent find?

Implicit Bias of GD/SD#

Implicit bias is the phenomenon that optimisation algorithms, when run to convergence without explicit regularisation, nevertheless converge to a specific solution among the many minimisers. The algorithm's dynamics itself imposes a preference.

Linear regression with d>nd > nd>n. Gradient descent initialised at w0=0w_0 = 0w0​=0 on min⁡w∥Xw−y∥22\min_w \|Xw - y\|_2^2minw​∥Xw−y∥22​ converges to:

w∗=XT(XXT)−1y=arg⁡min⁡Xw=y∥w∥2w^* = X^T(XX^T)^{-1}y = \arg\min_{Xw = y} \|w\|_2w∗=XT(XXT)−1y=argminXw=y​∥w∥2​

This is the minimum ℓ2\ell_2ℓ2​-norm interpolant — among all www that achieve zero training error, GD selects the one with smallest Euclidean norm. The proof: every GD step is a linear combination of the rows of XXX (since ∇f(w)=XT(Xw−y)\nabla f(w) = X^T(Xw - y)∇f(w)=XT(Xw−y)), so the iterates stay in the row space of XXX. The limit is the minimum-norm solution in the row space, which is exactly XT(XXT)−1yX^T(XX^T)^{-1}yXT(XXT)−1y.

Deep linear networks. GD on deep linear networks (composition of weight matrices) with ℓ2\ell_2ℓ2​ loss exhibits an implicit bias toward low-rank solutions — effectively performing nuclear norm regularisation without an explicit regulariser.

Classification with separable data. GD on logistic regression with linearly separable data drives the weights to infinity (to push the sigmoid to 0/1) but the direction w/∥w∥w / \|w\|w/∥w∥ converges to the ℓ2\ell_2ℓ2​ max-margin classifier — the same solution as a hard-margin SVM. This is implicit bias toward maximum margin solutions.

Key point. The optimiser's choice of solution is not random. It is determined by the algorithm (GD vs SGDStochastic Gradient Descent vs AdamAdaptive Moment Estimation (optimizer)), the step size, the initialisation, and the architecture. Understanding this implicit bias helps explain why overparameterised models generalise: the bias guides the optimiser toward solutions with good inductive properties (low norm, max margin, low rank) even when the loss landscape is full of alternatives.

What Convex Theory Still Gives You#

This course spent seven weeks (Weeks 1–7) on convex optimisation. Those tools remain essential, even when your ultimate problem is nonconvex:

  • Step-size tuning: The Lipschitz constant LLL and strong convexity parameter μ\muμ bound the safe step size. Even for nonconvex problems in the interpolating regime, the smoothness constant guides convergence.
  • Conditioning diagnostics: Ill-conditioned Hessians slow all methods — first-order, second-order, and stochastic. The convex analysis of conditioning transfers directly.
  • Structured subproblems: In ADMM, IPM, and proximal methods, the subproblems are often convex even when the overall problem is not. Each subproblem solver leverages convex guarantees.
  • Dual bounds: The dual of a nonconvex problem is always convex and always provides a lower bound (weak duality). These lower bounds certify optimality or reveal infeasibility.

Honest Gaps#

The theoretical understanding of deep learning optimisation is incomplete:

  • No full theory of deep net training. We can prove that SGD converges to a stationary point for smooth nonconvex objectives (gradient norm →0\to 0→0), but we cannot guarantee which local minimum (or saddle) it reaches, nor can we predict generalisation from optimisation dynamics alone.

  • Implicit bias in nonlinear networks. For deep nonlinear networks, the implicit bias is understood only in restricted settings (homogeneous activations like ReLU, specific initialisation scales, gradient flow limit). The general case remains an active research area.

  • Sharpness vs flatness. As Week 12 discussed, the relationship between geometric flatness and generalisation is empirical, not proven.

  • The scaling regime matters. The "lazy training" regime (where weights barely move and the network behaves like its linearisation, the NTK) has different dynamics from the "feature learning" regime where weights change substantially. Our convex tools transfer well to the lazy regime; the feature-learning regime is where the gaps are largest.

These gaps are not reasons to abandon convex theory — they are the frontier that makes optimisation research exciting. Every tool in this course has a role in navigating that frontier.

Exercise · Fill in the blank

Implicit bias means that when many weight configurations achieve zero training loss, the optimisation ____ selects a particular one.

Question 1 of 3

In high-dimensional random landscapes critical points are mostly:

Local minima
Saddles
Local maxima
Global minima

Browser lab#

For underdetermined least squares (X∈R20×50X \in \mathbb{R}^{20 \times 50}X∈R20×50, d=50>n=20d = 50 > n = 20d=50>n=20), demonstrate that GD initialised at w0=0w_0 = 0w0​=0 converges to the minimum ℓ2\ell_2ℓ2​-norm solution. Compare GD's final weights with the analytic min-norm solution from pinv.

python · runs in browser
import numpy as np
import matplotlib.pyplot as plt

np.random.seed(42)
n, d = 20, 50
X = np.random.randn(n, d)
w_opt = np.random.randn(d)
y = X @ w_opt + 0.05 * np.random.randn(n)  # underdetermined: d > n

# Analytic minimum-norm solution
w_pinv = X.T @ np.linalg.solve(X @ X.T + 1e-10 * np.eye(n), y)
# Alternatively: w_pinv = np.linalg.pinv(X) @ y

# GD from zero
eta = 0.05
n_steps = 2000
w_gd = np.zeros(d)
path_loss = []
path_dist = []  # distance to min-norm solution

for _ in range(n_steps):
    g = X.T @ (X @ w_gd - y) / n
    w_gd = w_gd - eta * g
    path_loss.append(0.5 * np.sum((X @ w_gd - y)**2) / n)
    path_dist.append(np.linalg.norm(w_gd - w_pinv))

print(f"Final GD loss: {path_loss[-1]:.2e}")
print(f"Distance GD to min-norm: {path_dist[-1]:.4f}")
print(f"|GD norm|: {np.linalg.norm(w_gd):.4f}, |min-norm|: {np.linalg.norm(w_pinv):.4f}")

# Random interpolant for comparison
# Any solution w = w_pinv + v where Xv = 0 is also an interpolant
null_vec = np.random.randn(d)
null_vec = null_vec - X.T @ np.linalg.solve(X @ X.T + 1e-10 * np.eye(n), X @ null_vec)
w_random_interp = w_pinv + 5.0 * null_vec / np.linalg.norm(null_vec)
print(f"|random interpolant norm|: {np.linalg.norm(w_random_interp):.4f}")
print(f"Random interpolant loss: {0.5 * np.sum((X @ w_random_interp - y)**2) / n:.2e}")

fig, (ax1, ax2) = plt.subplots(1, 2, figsize=(12, 5))

ax1.semilogy(path_loss, "b-", linewidth=1)
ax1.set_xlabel("Iteration")
ax1.set_ylabel("Training loss (log scale)")
ax1.set_title("GD converges to zero loss")
ax1.grid(True, alpha=0.3)

ax2.semilogy(path_dist, "r-", linewidth=1)
ax2.set_xlabel("Iteration")
ax2.set_ylabel("$\|\|w_k - w^*_{\min}\|\|$ (log scale)")
ax2.set_title("GD approaches min-norm solution")
ax2.grid(True, alpha=0.3)

plt.tight_layout()
plt.show()
← Previous
Week 12: Sharpness and SAM
Next →
Week 14: Capstone — Structure Meets Scale
On this page
  • High-Dimensional Landscapes
  • Overparameterisation
  • Implicit Bias of GD/SD
  • What Convex Theory Still Gives You
  • Honest Gaps
  • Browser lab