Using Mode Connectivity for Loss Landscape Analysis

Akhilesh Gotmare, Nitish Shirish Keskar, Caiming Xiong, Richard SocherarXiv 2018

Abstract

Recent research has challenged the traditional view of neural network loss landscapes as collections of isolated local minima. This paper investigates the robustness of "mode connectivity"—the existence of high-accuracy paths between disparate minima—across various training regimes. By examining models trained with different optimizers, batch sizes, and regularizations, the authors demonstrate that connectivity is a fundamental geometric property. Furthermore, they use these paths to re-evaluate the behavior of Stochastic Gradient Descent with Restarts (SGDR), showing it navigates a connected manifold rather than jumping between isolated basins.

Introduction

The high-dimensional loss landscape of deep neural networks is central to understanding optimization and generalization. While it was long assumed that local minima were separated by high-loss barriers, recent work has shown that many minima are connected by paths of near-constant low loss. This paper addresses two critical extensions of this finding: the resilience of these connections when models are trained under significantly different hyperparameters, and the implications for understanding modern optimizers like SGDR.

Methodology

The authors utilize the Mode Connectivity framework to find paths between two weight sets, $w_a$ and $w_b$. They define a piecewise linear path with a single "bend" at point $\theta$, which is optimized to minimize the average loss along the entire trajectory.

To test the robustness of this phenomenon, a reference VGG16 model (Mode G) was compared against six variants (Modes A-F) on the CIFAR-10 dataset. Each variant altered a single major training hyperparameter:

  • Batch Size: Large (4000) vs. standard (100).
  • Optimizer: Adam vs. SGD.
  • Learning Rate Schedule: Linear vs. Step decay.
  • Regularization: Removal of L2 regularization.
  • Initialization: High-variance random initialization ($3\times$).
  • Data Augmentation: Removal of standard augmentation techniques.

Key Insights: Universal Connectedness and Optimizer Dynamics

The study reveals that mode connectivity is remarkably resilient. High-accuracy paths were successfully found even between models trained with different optimizers (e.g., SGD and Adam), suggesting that the connectivity of the loss landscape is a fundamental property of the network architecture rather than a byproduct of specific training recipes.

A significant finding concerns the mechanism of Stochastic Gradient Descent with Restarts (SGDR). It is often hypothesized that the periodic learning rate spikes in SGDR allow the model to "jump" between isolated basins. However, the authors demonstrate that while SGDR iterates are separated by loss barriers along a straight line, they remain part of a connected, low-loss manifold. This suggests that the optimizer is navigating a complex, continuous structure rather than escaping isolated traps.

Experimental Results

The experiments confirm that high-accuracy paths exist across all tested "extreme" hyperparameter variations. As shown in the validation accuracy curves, the optimized paths maintain high performance (often exceeding 90%) throughout the transition between disparate models, even when those models were initialized poorly or trained without standard augmentations.

Validation accuracy along optimized paths connecting the reference model (Mode G) to variants A-F. High accuracy is maintained across the entire path, demonstrating robust connectivity.

Despite the success in finding low training loss paths, the authors observed a "generalization gap." Paths optimized for training loss often showed higher validation loss, indicating that the specific stochastic noise in standard SGD trajectories is vital for generalization, a property not inherently shared by the smooth paths found via mode connectivity.

Conclusion and Future Directions

This work provides strong evidence that neural network loss landscapes are more interconnected than previously thought. While the study is limited to VGG16 on CIFAR-10, the resilience of mode connectivity suggests it is a pervasive feature. Future research should explore whether these properties hold for larger architectures like Transformers and investigate the theoretical underpinnings of why such high-dimensional landscapes permit these low-loss paths. Additionally, the observed generalization gap suggests that while these paths offer a way to find many low-loss models, they may not yet replace traditional ensembling for practical performance gains.

Summary updated

BibTeX
@misc{gotmare2018using,
  author = {Akhilesh Gotmare and Nitish Shirish Keskar and Caiming Xiong and Richard Socher},
  title = {{Using Mode Connectivity for Loss Landscape Analysis}},
  year = {2018},
  eprint = {1806.06977},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/1806.06977},
}
Figure