Skip to main content
QUICK REVIEW

[Paper Review] DNN's Sharpest Directions Along the SGD Trajectory.

Stanisław Jastrzȩbski, Zachary Kenton|arXiv (Cornell University)|Jul 13, 2018
Stochastic Gradient Optimization TechniquesComputer Science6 citations
TL;DR

This paper investigates the role of the sharpest curvature directions in stochastic gradient descent (SGD) trajectories during DNN training. It reveals that SGD initially moves toward increasingly sharp regions due to large steps relative to curvature, and that reducing the learning rate specifically along these directions accelerates training and yields sharper, better-generalizing models than standard SGD.

ABSTRACT

Stochastic Gradient Descent (SGD) based training of neural networks with a large learning rate or a small batch-size typically ends in well-generalizing, flat regions of the weight space, as indicated by small eigenvalues of the Hessian of the training loss. However, the curvature along the SGD trajectory is poorly understood. An empirical investigation shows that initially SGD visits increasingly sharp regions, reaching a maximum sharpness determined by both the learning rate and the batch-size of SGD. When studying the SGD dynamics in relation to the sharpest directions in this initial phase, we find that the SGD step is large compared to the curvature and commonly fails to minimize the loss along the sharpest directions. Furthermore, using a reduced learning rate along these directions can improve training speed while leading to both sharper and better generalizing solutions compared to vanilla SGD. In summary, our analysis of the dynamics of SGD in the subspace of the sharpest directions shows that they influence the regions that SGD steers to (where larger learning rate or smaller batch size result in wider regions visited), the overall training speed, and the generalization ability of the final model.

Motivation & Objective

  • Understand how curvature along the sharpest directions in weight space affects SGD trajectory and model generalization.
  • Investigate why large learning rates or small batch sizes lead to flatter, better-generalizing solutions despite initial movement toward sharper regions.
  • Explore whether adapting learning rates along the sharpest directions can improve training efficiency and model performance.
  • Characterize the relationship between SGD step size, batch size, learning rate, and the sharpness of visited regions in weight space.

Proposed method

  • Empirically track the evolution of the Hessian's largest eigenvalues (sharpness) along the SGD trajectory during training.
  • Identify the sharpest directions in weight space using the eigenvectors corresponding to the largest Hessian eigenvalues.
  • Analyze the magnitude of SGD updates relative to curvature in the sharpest directions, revealing a mismatch between step size and local geometry.
  • Implement a modified training strategy that applies a reduced learning rate specifically along the sharpest directions.
  • Compare training speed, final loss, sharpness, and generalization performance between standard SGD and the modified approach.

Experimental results

Research questions

  • RQ1How does the sharpness of the loss landscape evolve along the SGD trajectory during training?
  • RQ2Why do large learning rates or small batch sizes lead to better generalization despite SGD moving toward sharper regions?
  • RQ3To what extent does the SGD update size exceed the curvature in the sharpest directions, and what are the consequences?
  • RQ4Can reducing the learning rate along the sharpest directions improve training speed and generalization performance?
  • RQ5How do the sharpest directions influence the final region of the weight space that SGD converges to?

Key findings

  • SGD initially moves toward increasingly sharp regions of the loss landscape, reaching a maximum sharpness determined by the learning rate and batch size.
  • The SGD update step is often much larger than the local curvature along the sharpest directions, leading to inefficient minimization in those directions.
  • Applying a reduced learning rate specifically along the sharpest directions results in faster training convergence compared to standard SGD.
  • The modified training strategy produces models that are not only sharper but also generalize better than those trained with vanilla SGD.
  • Larger learning rates or smaller batch sizes lead to SGD visiting wider, flatter regions of the loss landscape, but the initial trajectory is dominated by increasing sharpness.
  • The sharpest directions significantly influence the final model's generalization ability and the trajectory's dynamics, despite being poorly minimized by standard SGD.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.