A Simple Dynamic Learning Rate Tuning Algorithm For Automated Training of DNNs

Koyel Mukherjee, Alind Khare, Ashish VermaarXiv 2019

Abstract

Training neural networks on image datasets generally require extensive experimentation to find the optimal learning rate regime. Especially, for the cases of adversarial training or for training a newly synthesized model, one would not know the best learning rate regime beforehand. We propose an automated algorithm for determining the learning rate trajectory, that works across datasets and models for both natural and adversarial training, without requiring any dataset/model specific tuning. It is a stand-alone, parameterless, adaptive approach with no computational overhead. We theoretically discuss the algorithm's convergence behavior. We empirically validate our algorithm extensively. Our results show that our proposed approach \emph{consistently} achieves top-level accuracy compared to SOTA baselines in the literature in natural as well as adversarial training.

Introduction

Setting the learning rate (LR) is often considered a "black art" in deep learning. If the LR is too high, training diverges; if it is too low, the model crawls toward a mediocre solution or becomes trapped in "sharp" local minima that generalize poorly to unseen data.

While adaptive optimizers like Adam or RMSProp exist to mitigate these issues, they often require their own hyperparameter tuning and have been shown to generalize worse than manually tuned Stochastic Gradient Descent (SGD) in many scenarios. Furthermore, in specialized fields like adversarial training (training models to resist malicious inputs), the optimal LR regime is rarely known beforehand, forcing researchers into expensive, time-consuming grid searches. This paper introduces the Automated Adaptive Learning Rate (AALR) algorithm, a "set-it-and-forget-it" method designed to work across different models and datasets without manual intervention.

The AALR Methodology

The AALR algorithm is a parameterless, reactive approach that operates in two distinct phases to navigate the loss landscape effectively.

Phase 1: Initial LR Exploration

The algorithm begins with a default LR (0.1) and monitors the loss for a specific "patience" period. If the loss fails to improve or if the training diverges (e.g., resulting in NaN values), AALR halves the LR, reloads the previous best checkpoint, and attempts the phase again. This ensures the model starts from a stable and productive baseline.

Phase 2: Optimistic Binary Exploration

This core phase utilizes an "optimistic" strategy, constantly attempting to push the LR as high as the landscape allows. The logic follows a simple doubling and halving heuristic:

  • If the loss improves: The algorithm doubles the LR and resets the patience counter. This helps the model escape saddle points and move toward "flatter" minima, which are known to correlate with better generalization.
  • If the loss plateaus: The algorithm waits. If no improvement occurs after the patience period, it halves the LR and doubles the patience period, allowing for more granular refinement.

Unlike methods such as Cyclical Learning Rate (CLR) or Cosine Annealing, which follow fixed, pre-determined schedules, AALR is purely reactive to the model's current state and requires no additional computational overhead, such as Hessian or gradient-of-gradient calculations.

Experimental Setup

The algorithm was evaluated on standard computer vision benchmarks, specifically CIFAR-10 and CIFAR-100. These datasets were tested across various architectures to ensure robustness, including:

  • ResNet-18 and WideResNet-28-10
  • VGG16 (with and without Batch Normalization)
  • SimpleNetV1

Key Results and Insights

Natural Training

On CIFAR-10 with ResNet-18, AALR achieved 94.94% accuracy, nearly matching the expert hand-tuned baseline (95.28%) and significantly outperforming Adam (93.07%). This demonstrates that AALR can match the performance of manual tuning without the associated human labor.

Adversarial Robustness

AALR showed its greatest strength in adversarial training (specifically White-Box FGSM attacks). Adversarial loss landscapes are notoriously difficult to optimize, yet AALR’s simple doubling/halving heuristic found superior solutions. In FGSM adversarial training on ResNet-18, AALR reached 66.91% accuracy, compared to the standard representative baseline of approximately 56.1%.

Theoretical Convergence

Despite its trial-and-error nature, theoretical analysis shows that AALR is efficient. The algorithm is proven to reach a stable minimum in at most twice the number of epochs required by an "optimal oracle" (a theoretical, perfectly-tuned SGD schedule).

Conclusion and Future Work

AALR provides a robust, autonomous alternative to manual learning rate scheduling. By prioritizing "optimistic" exploration, it navigates complex loss landscapes to find flatter, more generalizable minima. While currently validated on CIFAR-scale datasets, future work will focus on scaling AALR to massive datasets like ImageNet and exploring its efficacy in Natural Language Processing (NLP) tasks. Furthermore, additional research is required to theoretically explain why this specific binary exploration is so effective for the min-max saddle point problems found in adversarial training.

Summary updated

BibTeX
@misc{mukherjee2019simple,
  author = {Koyel Mukherjee and Alind Khare and Ashish Verma},
  title = {{A Simple Dynamic Learning Rate Tuning Algorithm For Automated Training of DNNs}},
  year = {2019},
  eprint = {1910.11605},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/1910.11605},
}
Figure