Title: HOW DOES LEARNING RATE DECAY HELP MODERN NEURAL NETWORKS?

Abstract: Learning rate decay (lrDecay) is a de facto technique for training modern neural networks. It starts with a large learning rate and then decays it multiple times. It is empirically observed to help both optimization and generalization. Common beliefs in how lrDecay works come from the optimization analysis of (Stochastic) Gradient Descent: 1) an initially large learning rate accelerates training or helps the network escape spurious local minima; 2) decaying the learning rate helps the network converge to a local minimum and avoid oscillation. Despite the popularity of these common beliefs, experiments suggest that they are insufficient in explaining the general effectiveness of lrDecay in training modern neural networks that are deep, wide, and nonconvex. We provide another novel explanation: an initially large learning rate suppresses the network from memorizing noisy data while decaying the learning rate improves the learning of complex patterns. The proposed explanation is validated on a carefully-constructed dataset with tractable pattern complexity. And its implication, that additional patterns learned in later stages of lrDecay are more complex and thus less transferable, is justified in realworld datasets. We believe that this alternative explanation will shed light into the design of better training strategies for modern neural networks.

1. INTRODUCTION:

Modern neural networks are deep, wide, and nonconvex. They are powerful tools for representation learning and serve as core components of deep learning systems. They are top-performing models in language translation (Sutskever et al., 2014) , visual recognition (He et al., 2016) , and decision making (Silver et al., 2018) . However, the understanding of modern neural networks is way behind their broad applications. A series of pioneering works (Zhang et al., 2017; Belkin et al., 2019; Locatello et al., 2019) reveal the difficulty of applying conventional machine learning wisdom to deep learning. A better understanding of deep learning is a major mission in the AI field.

One obstacle in the way of understanding deep learning is the existence of magic modules in modern neural networks and magic tricks to train them. Take batch normalization module (Ioffe & Szegedy, 2015) for example, its pervasiveness in both academia and industry is undoubted. The exact reason why it expedites training and helps generalization, however, remains mysterious and is actively studied in recent years (Bjorck et al., 2018; Santurkar et al., 2018; Kohler et al., 2019) . Only when we clearly understand these magical practices can we promote the theoretical understanding of modern neural networks.

Learning rate is "the single most important hyper-parameter" (Bengio, 2012) in training neural networks. Learning rate decay (lrDecay) is a de facto technique for training modern neural networks, where we adopt an initially large learning rate and then decay it by a certain factor after pre-defined epochs. Popular deep networks such as ResNet (He et al., 2016) , DenseNet (Huang et al., 2017b) are all trained by Stochastic Gradient Descent (SGD) with lrDecay. Figure 1 (a) is an example of lrDecay, with the learning rate decayed by 10 every 30 epochs. The training is divided into several stages by the moments of decay. These stages can be easily identified in learning curves (such as Figure 1(b) ), where the performance boosts sharply shortly after the learning rate is decayed. The lrDecay enjoys great popularity due to its simplicity and general effectiveness.

Common beliefs in how lrDecay works are derived from the optimization analysis in (Stochastic) Gradient Descent (LeCun et al., 1991; Kleinberg et al., 2018) . They attribute the effect of an initially large learning rate to escaping spurious local minima or accelerating training and attribute the effect of decaying the learning rate to avoiding oscillation around local minima. However, these common beliefs are insufficient to explain our empirical observations from a series of carefully-designed experiments in Section 4.

In this paper, we provide an alternative view: the magnitude of the learning rate is closely related to the complexity of learnable patterns. From this perspective, we propose a novel explanation for the efficacy of lrDecay: an initially large learning rate suppresses the memorization of noisy data while decaying the learning rate improves the learning of complex patterns. This is validated on a carefully-constructed dataset with tractable pattern complexity. The pattern complexity in realworld datasets is often intractable. We thus validate the explanation by testing its implication on real-world datasets. The implication that additional patterns learned in later stages of lrDecay are more complex and thus less transferable across different datasets, is also justified empirically. A comparison between the proposed explanation and the common beliefs is summarized in Table 1 .

Our explanation is supported by carefully-designed experiments and provides a new perspective on analyzing learning rate decay.

The contribution of this paper is two-fold:

• We demonstrate by experiments that existing explanations of how lrDecay works are insufficient in explaining the training behaviors in modern neural networks. • We propose a novel explanation based on pattern complexity, which is validated on a dataset with tractable pattern complexity, and its implication is validated on real-world datasets.

The explanation also suggests that complex patterns are only learnable after learning rate decay. Thus, when the model learns all simple patterns, but the epoch to decay has not reached, immediately decaying the learning rate will not hurt the performance. This implication is validated in Section A.1.

2. RELATED WORK:



2.1. UNDERSTANDING THE BEHAVIOR OF SGD:

Recently, researchers reveal the behavior of SGD from multiple perspectives (Li et al., 2019; Mangalam & Prabhu, 2019; Nakkiran et al., 2019) . They respect the difference among data items rather than treat them as identical samples from a distribution. They study the behavior of SGD in a given dataset. In Mangalam & Prabhu (2019) , they show that deep models first learn easy examples classifiable by shallow methods. The mutual information between deep models and linear models is measured in Nakkiran et al. (2019) , which suggests deep models first learn data explainable by linear models. Note that they are not relevant to learning rates. Li et al. (2019) analyze a toy problem to uncover the regularization effect of an initially large learning rate. Their theoretical explanation is, however, based on a specific two-layer neural network they design. Different from these works, Section 5 studies the behavior of SGD induced by lrDecay in a modern WideResNet (Zagoruyko & Komodakis, 2016) , finding that learning rate decay improves learning of complex patterns. We formally define pattern complexity by expected class conditional entropy, while the measure of pattern complexity in Mangalam & Prabhu (2019) ; Nakkiran et al. (2019) relies on an auxiliary model.

2.2. ADAPTIVE LEARNING RATE METHODS:

Adaptive learning rate methods such as AdaGrad (Duchi et al., 2011 ), AdaDelta (Zeiler, 2012) , and ADAM (Kingma & Ba, 2015) are sophisticated optimization algorithms for training modern neural networks. It remains an active research field to study their behaviors and underlying mechanisms (Reddi et al., 2018; Luo et al., 2019) . However, we focus on learning rate decay in SGD rather than on the adaptive learning rate methods. On the one hand, SGD is the de facto training algorithm for popular models (He et al., 2016; Huang et al., 2017b) while lrDecay is not common in the adaptive methods; On the other hand, many adaptive methods are not as simple as SGD and even degenerate in convergence in some scenarios (Wilson et al., 2017; Liu et al., 2019) . We choose to study SGD with lrDecay, without introducing adaptive learning rate to keep away from its confounding factors.

2.3. OTHER LEARNING RATE STRATEGIES:

Besides the commonly used lrDecay, there are other learning rate strategies. Smith (2017) proposes a cyclic strategy, claiming to dismiss the need for tuning learning rates. Warm restart of learning rate is explored in Loshchilov & Hutter (2017) . They achieve better results when combined with Snapshot Ensemble (Huang et al., 2017a) . These learning rate strategies often yield better results at the cost of additional hyperparameters that are not intuitive. Consequently, it is still the de facto to decay the learning rate after pre-defined epochs as in Figure 1 (a). We stick our analysis to lrDecay rather than to other fancy ones because of its simplicity and general effectiveness.

2.4. TRANSFERABILITY OF DEEP MODELS:

Training a model on one dataset that can be transferred to other datasets has long been a goal of AI researches. 

3. COMMON BELIEFS IN EXPLAINING LRDECAY:



3.1. GRADIENT DESCENT EXPLANATION:

The practice of lrDecay in training neural networks dates back to LeCun et al. (1998) . The most popular belief in the effect of lrDecay comes from the optimization analysis of Gradient Descent (GD) (LeCun et al., 1991) . Although SGD is more practical in deep learning, researchers are usually satisfied with the analysis of GD considering that SGD is a stochastic variant of GD.

Figure 2 : Gradient Descent explanation. From left to right: 1) learning rate is small enough to converge around a minimum, 2) moderate so that it bounces among minima, 3) too large to converge.

Specifically, LeCun et al. (1991) analyze the property of a quadratic loss surface which can be seen as a second-order approximation around a local minimum in nonconvex optimization. Learning rates are characterized by the relationship with eigenvalues of the Hessian at a local minimum. Denote η the learning rate, H the Hessian, λ an eigenvalue of H, and v an eigenvector of λ. The behavior of the network along the direction v can be characterized as (1ηλ) k v, with k the iteration number.

Convergence in the direction of v requires 0 < η < 2/λ, while η > 2/λ leads to divergence in the direction of v. If 0 < η < 2/λ holds for every eigenvalue of the Hessian, the network will converge quickly (Figure 2 left). If it holds for some directions but not for all directions, the network will diverge in some directions and thus jump into the neighborhood of another local minimum (Figure 2 middle). If the learning rate is too large, the network will not converge (Figure 2 right). In particular, when oscillation happens, it means the learning rate is too large and should be decayed. The effect of lrDecay hence is to avoid oscillation and to obtain faster convergence. Note LeCun et al. (1991) only analyze a simple one-layer network. It may not hold for modern neural networks (see Section 4.1).

3.2. STOCHASTIC GRADIENT DESCENT EXPLANATION:

Another common belief is the Stochastic Gradient Descent explanation, arguing that "with a high learning rate, the system is unable to settle down into deeper, but narrower parts of the loss function."1 Although it is common, this argument has not been formally analyzed until very recently. 2018)). The first plot: an initially large learning rate helps escape spurious local minima. From the second to the fourth plots: after more rounds of learning rate decay, the probability of reaching the minimum becomes larger.

Under some assumptions, Kleinberg et al. (2018) prove SGD is equivalent to the convolution of loss surface, with the learning rate serving as the conceptual kernel size of the convolution. With an appropriate learning rate, spurious local minima can be smoothed out, thus helping neural networks escape bad local minima. The decay of learning rate later helps the network converge around the minimum. Figure 3 is an intuitive one-dimensional example. The first plot shows that a large learning rate helps escape bad local minima in both sides. The lrDecay in subsequent plots increases the probability of reaching the global minimum. Although intuitive, the explanation requires some assumptions that may not hold for modern neural networks (see Section 4.2).

4. EXPERIMENTS AGAINST EXISTING EXPLANATIONS:

Although the (Stochastic) Gradient Descent explanations in Section 3 account for the effect of lrDecay to some extent, in this section, we show by carefully-designed experiments that they are insufficient to explain the efficacy of lrDecay in modern neural networks. In all the experiments except for Section 6, we use a modern neural network named WideResNet (Zagoruyko & Komodakis, 2016) . It is deep, wide, nonconvex, and suitable for datasets like CIFAR10 (Krizhevsky & Hinton, 2009) .

4.1. EXPERIMENTS AGAINST THE GRADIENT DESCENT EXPLANATION:

We train a WideResNet on CIFAR10 dataset with GD, decay the learning rate at different epochs, and report the training loss (optimization) as well as the test accuracy (generalization) in Figure 4 . WideResNet and CIFAR10 are commonly used for studying deep learning (Zhang et al., 2017) . CIFAR10 is not too large so that we can feed the whole dataset as a single batch using distributed training, computing the exact gradient rather than estimating it in mini-batches. Experiments show that lrDecay brings negligible benefit to either optimization or generalization. No matter when the learning rate is decayed, the final performances are almost the same. The instability in the beginning is related to the high loss wall described in Pascanu et al. (2013) , which is not the focus of this paper. The above observation contradicts directly with the GD explanation in Section 3.1. The contradiction arises from the fact that LeCun et al. (1991) only analyze simple linear networks, and no wonder the explanation fails in modern non-linear deep networks. Recent studies (Keskar et al., 2017; Yao et al., 2018) The GD explanation in Section 3.1 attributes the effect of lrDecay to avoiding oscillation. Oscillation means there is a small divergence in some directions of the landscape so that the network bounces among nearby minima. However, the divergence factor 1ηλ for the largest eigenvalue (≈ 200) is too large even for a small growth of learning rate. Thus, the learning rate is either small enough to converge in a local minimum or large enough to diverge. It is hardly possible to observe the oscillation in learning curves (Figure 2 middle), and diverging learning curves (Figure 2 right) can be discarded during hyperparameter tuning. Therefore, only stable solutions are observable where η is small enough (Figure 2 left), leaving no necessity for learning rate decay. Indeed, when the learning rate is increased mildly, we immediately observe diverging learning curves (Section A.2). In short, the GD explanation cannot explain the effect of lrDecay in training modern neural networks. induced by the SGD explanation: best performances before and after decay are comparable.

4.2. EXPERIMENTS AGAINST THE STOCHASTIC GRADIENT DESCENT EXPLANATION:

We follow the experiment setups in Section 4.1, but replace GD with SGD in Figure 7 . According to the SGD explanation in Section 3.2, the effect of learning rate decay is to increase the probability of reaching a good minimum. If it is true, the model trained before decay can also reach minima, only by a smaller probability compared to the model after decay. In other words, the SGD explanation indicates the best performances before and after decay are the same. It predicts learning curves like Figure 6 . However, Figure 7 does not comply with the SGD explanation: the best performances before and after lrDecay are different by a noticeable margin. Without lrDecay (the rightmost column in Figure 7 ), the performance plateaus and oscillates, with no chance reaching the performance of the other columns after decay. The performance boost after learning rate decay is widely observed (Figure 1(b) for example). However, possibly due to the violation of its assumptions (Kleinberg et al., 2018) , the SGD explanation cannot explain the underlying effect of lrDecay. 

5. AN EXPLANATION FROM THE VIEW OF PATTERN COMPLEXITY:

Section 4 uncovers the insufficiency of common beliefs in explaining lrDecay. We thus set off to find a better explanation. Mangalam & Prabhu (2019) ; Nakkiran et al. (2019) reveal that SGD (without learning rate decay) learns from easy to complex. As learning rates often change from large to small in typical learning rate strategies, we hypothesize that the complexity of learned patterns is related to the magnitude of learning rates. Based on this, we provide a novel explanation from the view of pattern complexity: the effect of learning rate decay is to improve the learning of complex patterns while the effect of an initially large learning rate is to avoid memorization of noisy data. To justify this explanation, we carefully construct a dataset with tractable pattern complexity, and record model accuracies in simple and complex patterns separately with and without lrDecay.

5.1. PATTERN SEPARATION 10 (PS10) DATASET WITH TRACTABLE PATTERN COMPLEXITY:

The explanation we propose involves pattern complexity, which is generally conceptual and sometimes measured with the help of a simple auxiliary model as in Mangalam & Prabhu (2019) ; Nakkiran et al. ( 2019). Here we try to formalize the idea of pattern complexity: the complexity of a dataset is defined as the expected class conditional entropy: C({(x i , y i )} n i=1 ) = E y H(P (x|y)), where H denotes the entropy functional. The complexity of patterns depends on the complexity of the dataset they belong to. Higher C means larger complexity because there are averagely more patterns in each class to be recognized (consider an animal dataset with 10 subspecies in each species vs. an animal dataset with 100 subspecies in each species). 

5.2. THE EFFECT OF DECAY: IMPROVE LEARNING OF MORE COMPLEX PATTERNS:

To reveal the effect of decaying the learning rate, we compare experiments with and without lrDecay.

For those without lrDecay, we set the learning rates equal to the learning rate of each stage in lrDecay. We measure not only the total accuracy but also the accuracies on simple and complex patterns separately. These accuracies are plotted in Figure 9 .

The first plot in Figure 9 clearly shows the model first learns simple patterns quickly. The boost in total accuracy mainly comes from the accuracy gain on complex patterns when the learning rate is decayed. Plots 2, 3, and 4 show the network learns more complex patterns with a smaller learning rate, leading to the conclusion that learning rate decay helps the network learn complex patterns.

5.3. THE EFFECT OF AN INITIALLY LARGE LEARNING RATE: AVOID FITTING NOISY DATA:

Figure 9 seems to indicate that an initially large learning rate does nothing more than accelerating training: in Plot 4, a small constant learning rate can achieve roughly the same accuracy compared with lrDecay. However, by adding 10% noisy data to mimic real-world datasets, we observe something interesting. Figure 10 shows the accuracies on simple patterns, complex patterns, and noise data when we add noise into the dataset. Plot 2 in Figure 10 shows an initially large learning rate helps the accuracy on complex patterns. Plot 3 in Figure 10 further shows the accuracy gain on complex patterns comes from the suppression of fitting noisy data. (Note that a larger accuracy on noisy data implies overfitting the noisy data, which is undesirable.) In short, the memorizing noisy data hurts the learning of complex patterns but can be suppressed by an initially large learning rate. Empirically, Li et al. (2019) report that an initially large learning rate with decay outperforms a small and constant learning rate. They suspect that the network starting with an initially small learning rate will be stuck at some spurious local minima. Our experiments provide an alternative view that spurious local minima may stem from noisy data. And the regularization effect of an initially large learning rate is to suppress the memorization of noisy data.

6. THE IMPLICATION OF LRDECAY ON MODEL TRANSFERABILITY:

Section 5 examines the proposed explanation on the PS10 dataset. Now we further validate the explanation on real-world datasets. Because there are no clearly separated simple and complex patterns in real-world datasets, it is difficult to directly validate the explanation. The proposed explanation suggests that SGD with lrDecay learns patterns of increasing complexity. Intuitively, more complex patterns are less transferable, harder to generalize across datasets. Thus an immediate implication is that SGD with lrDecay learns patterns of decreasing transferability. We validate it by transfer-learning experiments on real-world datasets, to implicitly support the proposed explanation.

The transferability is measured by transferring a model from ImageNet to different target datasets.

To get models in different training stages, we train a ResNet-50 on ImageNet from scratch and save checkpoints of models in different stages. The learning rate is decayed twice, leading to three stages. Target datasets for transferring are: (1) Caltech256 (Griffin et al., 2007) with 256 general object classes; (2) CUB-200 (Wah et al., 2011) with 200 bird classes; (3) MITIndoors (Quattoni & Torralba, 2009) with 67 indoor scenes; (4) Sketch250 (Eitz et al., 2012) with sketch painting in 250 general classes. Sketch250 is the most dissimilar to ImageNet because it contains sketch paintings.

We study two widely-used strategies of transfer learning: "fix" (ImageNet snapshot models are only used as fixed feature extractors) and "finetune" (feature extractors are jointly trained together with task-specific layers). Let acc i denotes the accuracy of stage i snapshot model on ImageNet and tacc i denotes the accuracy of transferring the snapshot to the target dataset, then the transferability of additional patterns learned in stage i is defined as tacci-tacci-1 acci-acci-1 , i = 2, 3. By definition, the transferability of patterns from ImageNet to ImageNet is 1.0, complying with common sense. The transferability is plotted in Figure 11 . Table 2 contains the accuracies used to compute it. In all experiments, we find that the transferability of additional patterns learned in stage 3 is less than that in stage 2. Besides, in Sketch250 dataset, the transferability of additional patterns learned in stage 3 is negative. These findings support our claim that additional patterns learned in later stages of lrDecay are more complex and thus less transferable. They also suggest deep model-zoo developer provide pre-trained model snapshots in different stages so that downstream users can select the most transferable snapshot model according to their tasks.

7. CONCLUSION:

In this paper, we dive into how learning rate decay (lrDecay) helps modern neural networks. We uncover the insufficiency of common beliefs and propose a novel explanation: the effect of decaying learning rate is to improve the learning of complex patterns, and the effect of an initially large learning rate is to avoid memorization of noisy data. It is supported by experiments on a dataset with tractable pattern complexity as well as on real-world datasets. It would be interesting to further bridge the proposed explanation and the formal analysis of optimization procedure.

A APPENDIX:

A.1 AUTODECAY Experiments in Section 5.2 implies that not all complex patterns are learnable under a constant learning rate. The training under a certain learning rate has no effect when the loss plateaus. This indicates we can expedite the training process by killing the over-training of each stage (decay the learning rate when the loss plateaus) with little influence on the performance. To validate the implication, we propose AutoDecay to shorten the useless training and check if the performance of the model can be untouched. In Figure 7 , it appears obvious to decide the optimal moment to decay when we have a big picture of the training process. The problem is, however, how can we make a decision to decay depending on the current and past observations. It is a non-trivial problem given that the statistics exhibit noticeable noise.

A.1.1 PROBLEM FORMULATION:

We formalize the observed training loss into two parts: ˆ (t) = (t) + (t), with (t) the ground truth loss (unobservable) and (t) the noise introduced by SGD. Here t indicates the training process (typically the epoch number) and takes value in N = {1, 2, 3, . . .}. To simplify the problem, we assume (t) is independent with t and (t) is independent of (t )(t = t) in SGD. The nature of noise gives rise to the zero-expectation property E (t) = 0. Denote σ 2 = Var (t) the variance of the noise. Due to the noise of SGD, the observed training loss usually vibrates in a short time window but decreases in a long time window. Our task is to find out whether the loss value is stable in the presence of noise.

A.1.2 PROBLEM SOLUTION:

Exponential Decay Moving Average (EDMA) with Bias Correction. Observations with lower variance are more trustworthy. However, there is nothing we can do about the variance of ˆ (t).

We consider computing a low-variance statistic about ˆ (t). We adopt moving average with bias correction (Kingma & Ba, 2015) . Let g(t) be the moving average of (t) and ĝ(t) be the moving average of ˆ (t). The explicit form is in Equation 1, where β ∈ (0, 1) is the decay factor in EDMA.

EQUATION

The recursive (and thus implicit) form is in Equation 2. It enables us to compute the statistic ĝ online (without storing all the previous { ˆ (i)|i < t}) at the cost of maintaining f (t).

EQUATION

As ĝ(t) is a linear combination of { ˆ (i)|i ≤ t}, it is easy to show ĝ(t) is unbiased:

Eĝ(t) = E t-1 i=0 β i ˆ (t -i) t-1 i=0 β i = t-1 i=0 β i E ˆ (t -i) t-1 i=0 β i = t-1 i=0 β i (t -i) t-1 i=0 β i = g(t)

The variance of ĝ(t) is

EQUATION

The fact that β ∈ (0, 1) indicates Varĝ(t) is monotonically decreasing. Typically β = 0.9 (Figure 13 ), and the variance can rapidly converge to 0.05σ 2 , much smaller than the variance of the noise. ĝ(t) well represents the unobservable g(t). If (t) gets stable, we shall observe that ĝ(t) is stable, too.

Criterion of Being Stable. We only want to decay the learning rate when the loss plateaus, i.e. when the loss is stable. For observed values of G = {ĝ(i)|i -W + 1 ≤ i ≤ t} within the window size of W , we call them stable if max G-min G min G+ < η, where is a small constant that prevents zero-division error, and η indicates the tolerance of variation.

Criterion of Significant Drop. When we keep decaying the learning rate, there comes a time when the learning rate is too small and the network cannot make any progress. When it happens, we should terminate the training. Termination is adopted when their is no significant drop between the stable value and the original value ĝ(0). To be specific, the criterion of significant drop is ĝ(t)+ ĝ(0)+ ≤ ζ, where is a small constant that prevents zero-division error, and ζ indicates the degree of drop.

The entire procedure of AutoDecay is described in Figure 12 .

t W ?:

< l a t e x i t s h a 1 _ b a s e 6 4 = " s 9 p 7 + h 5 J 7 P j / R c f 5 o U A c u E 4 R E v M = " > A A A B + X i c b V D L S g N B E J y N r x h f q x 6 9 D A b B U 9 i N g t 4 M e v E Y w T w g u 4 T Z S S c Z M v t g p j c Y l v y J F w + K e P V P v P k 3 T p I 9 a G J B Q 1 H V T X d X k E i h 0 X G + r c L a + s b m V n G 7 t L O 7 t 3 9 g H x 4 1 d Z w q D g 0 e y 1 i 1 A 6 Z B i g g a K

F B C O 1 H A w k B C K x j d z f z W G J Q W c f S I k w T 8 k A 0 i 0 R e c o Z G 6 t o 3 U G w B t U Q / h C b O b a d c u O x V

n D r p K 3 J y U S Y 5 6 1 / 7 y e j F P Q 4 i Q S 6 Z 1 x 3 U S 9 D O m U H A J 0 5 K X a k g Y H 7 E B d A y N W A j a z + a X T + m Z U X q 0 H y t T E d K 5 + n s i Y 6 H W k z A w n S H D o V 7 2 Z u J / X i f F / r W f i S h J E S K + W N R P J c W Y z m K g P a G A o 5 w Y w r g S 5 l b K h 0 w x j i a s k g n B X X 5 5 l T S r F f e i U n 2 4 L N d u 8 z i K 5 I S c k n P i k i t S I / e k T h q E k z F 5 J q / k z c q s F + v d + l i 0 F q x 8 5 p j 8 g f X 5 A 5 L S k v o = < / l a t e x i t > G stable? 

i d c d 1 E v A z o o B T w c Z F L 9 U s I X R I + q x j q C Q R 0 3 4 2 P X 6 M j 4 z S w 2 G s z J O A p + r v R E Y i r U d R Y C Y j A g M 9 7 0 3 E / 7 x O C u G 5 n 3 G Z p M A k n S 0 K U 4 E h x p M m c I 8 r R k G M D C F U c X M r p g O i C A X T V 9 G U 4 M

5 / e Z E 0 q x X 3 p F K 9 O y 3 X r v I 6 C u g A H a J j 5 K I z V E O 3 q I 4 a i K I R e k a v 6 M 1 6 s l 6 s d + t j N r p k 5 Z k S + g P r 8 w c B 4 Z R e < / l a t e x i t > ˆ(t)

< l a t e x i t s h a 1 _ b a s e 6 4 = " Y W H a G u 1 g m s / e I Q v d M Y i y 0 q s + 9 h k = " > A A A B 9 H i c b V B N S 8 N A E N 3 U r 1 q / q h 6 9 B I t Q L y W p g h 6 L X j x W s L X Q h L L Z T t q l m 0 3 c n R R K 6 O / w 4 k E R r / 4 Y b / 4 b t 2 0 O 2 v p g 4 P H e D D P z g k R w j Y 7 z b R X W 1 j c 2 t 4 r b p Z 3 d v f 2 D 8 u F R W 8 e p Y t B i s Y h V J 6 A a B J f Q Q o 4 C O o k C G g U C H o P R 7 c x / H I P S P J Y P O E n A j + h A 8 p A z i k b y v S H F z A M h p l U 8 7 5 U r T s 2 Z w 1 4 l b k 4 q J E e z V / 7 y + j F L I 5 D I B N W 6 6 z o J + h l V y J m A a c l L N S S U j e g A u o Z K G o H 2 s / n R U / v M K H 0 7 j J U p i f Z c / T 2 R 0 U j r S R S Y z o j i U C 9 7 M / E / r 5 t i e O 1 n X C Y p g m S L R W E q b I z t W Q J 2 n y t g K C a G U K a 4 u d V m Q 6 o o Q 5 N T y Y T g L r + 8 S t r 1 m n t R q 9 9 f V h o 3 e R x F c k J O S Z W 4 5 I o 0 y B 1 p k h Z h 5 I k 8 k 1 f y Z o 2 t F + v d + l i 0 F q x 8 5 p j 8 g f X 5 A 4 c F k e 8 = < / l a t e x i t > ĝ(t)

< l a t e x i t s h a 1 _ b a s e 6 4 = " C W j 9 A g t e / C h P 9

v r i K s G R w E M o Z a o = " > A A A B 8 X i c b V D L S g N B E O y N r x h f U Y 9 e B o M Q L 2 E 3 C n o M e v E Y w T w w W c L s Z J I M m Z 1 d Z n q F s O Q v v H h Q x K t / 4 8 2 / c Z L s Q R M L G o q q b

r q 7 g l g K g 6 7 7 7 e T W 1 j c 2 t / L b h Z 3 d v f 2 D 4 u F R 0 0 S J Z r z B I h n p d k A N l 0 L x B g q U v B 1 r T s N A 8 l Y w v p 3 5 r S e u j Y j U A 0 5 i 7 o d 0 q M R A M I p W e u y O K K b D a R n P e 8 W S W 3 H n I K v E y 0 g J M t R 7 x a 9 u P 2 J J y B U y S Y 3 p e G 6 M f k o 1 C i b 5 t N B N D I 8 p G 9 M h 7 1 i q a M i N n 8 4 v n p I z q / T J I N K 2 F J K 5 + n s i p a 

E x k z C w n S H F k V n 2 Z u J / X i f B w b W f C h U n y B V b L B o k k m B E Z u + T v t C c o Z x Y Q p k W 9 l b C R l R

j Q h G 3 / o Q 7 / 8 Z p m 4 W 2 H r h w O O d e 7 r 3 H i w V X Y F n f x s L i 0 v L K a m G t u L 6 x u b V t 7 u w 2 V Z R I y h o 0 E p F s e 0 Q x w U P W A A 6 C t W P J S O A J 1 v K G 1 2 O / d c + k 4 l F 4 B 6 O Y u Q H p h 7 z H K Q E t d c 1 9 Z 0 A g 7 W d l O M b O B X a A P U D q y y i + z L p m y a p Y E + B 5 Y u e k h H L U u + a X 4 0 c 0 C V g I V B C l O r Y V g 5 s S C Z w K l h W d R L G Y 0 C H p s 4 6 m I Q m Y c t P J D x k + 0 o q P e 5 H U F Q K e q L 8 n U h I o N Q o 8 3 R k Q G K h Z b y z + 5 3 U S 6 J 2 7 K Q / j B F h I p 4 t 6 i c A Q 4 X E g 2 O e S U R A j T Q i V X N + K 6 Y B I Q k H H V t Q h 2 L M v z 5 N m t W K f V K q 3 p 6 X a V R 5 H A R 2 g Q 1 R G N j p D N X S D 6 q i B K H p E z + g V v R l P x o v x b n x M W x e M f G Y P / Y H x + Q N V v Z d U < / l a t e x i t > Keep < l a t e x i t s h a 1 _ b a s e 6 4 = " D y b j m 8 / n 7 D 2 v S 1 4 Z U / / A k k K G 3 5 Q = " > A A A B 8 n i c b V B N S 8 N A E N 3 4 W e t X 1 a O X x S J 4 K k k V 9 F j 0 I n i p Y D + g D W W z n b R L N 5 u w O x F L 6 M / w 4 k E R r / 4 a b / 4 b t 2 0 O 2 v p g 4 P H e D D P z g k Q K g 6 7 7 7 a y s r q 1 v b B a 2 i t s 7 u 3 v 7 p Y P D p o l T z a H B Y x n r d s A M S K G g g Q I l t B M N L A o k t I L R z d R v P Y I 2 I l Y P O E 7 A j 9 h A i V B w h l b q d B G e M L s D S C a 9 U t m t u D P Q Z e L l p E x y 1 H u l r 2 4 / 5 m k E C r l k x n Q 8 N 0 E / Y x o F l z A p d l M D C e M j N o C O p Y p F Y P x s d v K E n l q l T 8 N Y 2 1 J I Z + r v i Y x F x o y j w H Z G D I d m 0 Z u K / 3 m d F M M r P x M q S R E U n y 8 K U 0 k x p t P / a V 9 o 4 C j H l j C u h b 2 V 8 i H T j K N N q W h D 8 B Z f X i b N a s U 7 r 1 T v L 8 q 1 6 z y O A j k m J + S M e O S S 1 M g t q Z M G 4 S Q m z + S V v D n o v D j v

t M g R Q Q t F C i h m y h g o S + h 4 4 9 v p n 7 n E Z Q W c f S A W Q J e y I a R C A R n a C T X R X j C / B Y 4 y y b 9 S t W u 2 T P Q Z e I U p E o K N P u V L 3 c Q 8 z S E C L l k W v c c O 0 E v Z w o F l z A p u 6 m G h P E x G 0 L P 0 I i F o L 1 8 d v O E n h p l Q I N Y m Y q Q z t T f E z k L t c 5 C 3 3 S G D E d 6 0 Z u K / 3 m 9 F I M r L x d R k i J E f L 4 o S C X F m E 4 D o A O h g K P M D G F c C X M r 5 S O m G E c T U 9 m E 4 C y + v E z a 9 Z p z X q v f X 1 Q b 1 0 U c J X J M T s g Z c c g l a Z A 7 0 i Q t w k l C n s k r e b N S 6 8 V 6 t z 7 m r S t W M X N E / s D 6 / A F 2 B 5 H 1 < / l a t e x i t > Terminate < l a t e x i t s h a 1 _ b a s e 6 4 = " D 4 7 B 7 R / w A 5 D O l n z x 6 s j o P T 2 V i j 8 = " > A A A B + X i c b V B N S 8 N A E N 3 U r 1 q / o h 6 9 B I v g q S R V 0 G P R i 8 c K / Y I 2 l M 1 2 0 i 7 d b M L u p F h C / 4 k X D 4 p 4 9 Z 9 4 8 9 + 4 b X P Q 1 g c D j / d m m J k X J I J r d N 1 v q 7 C x u b W 9 U 9 w t 7 e 0 f H B 7 Z x y c t H a e K Q Z P F I l a d g G o Q X E I T O Q r o J A p o F A h o B + P 7 u d + e g N I 8 l g 2 c J u B H d C h 5 y B l F I / V t u 4 f w h F k D V M Q l R Z j 1 7 b J b c R d w 1 o m X k z L J U

A.1.3 EXPERIMENTS:

We try AutoDecay on ImageNet (Russakovsky et al., 2015) to test whether it can expedite the training without hurting the performance. We are not trying to set up a new state-of-the-art record. We train a ResNet-50 model on ImageNet following the official code of PyTorch. The only change is we replace the StepDecay strategy with the proposed AutoDecay strategy. Each experiment costs roughly two days with 8 TITAN X GPUs. The results in Table 14 show that AutoDecay can shorten the training time by 10% without hurting the performance (even bringing a slight improvement), successfully vaidates the proposed explanation in this paper. When we increase the learning rate mildly for Gradient Descent, we immediately observe diverging learning curves (Figure 15 ), which echos with the reason mentioned in Section 4.1 why the Gradient Descent explanation fails to work in modern neural networks: modern neural networks have a very large spectrum norm at a local minimum, and even a small growth of learning rate can lead to divergence. In other words, training modern neural networks with GD must use a small enough learning rate, dismissing the value of learning rate decay. 

:

http://cs231n.github.io/neural-networks-3/#anneal

Thanks to the advances ofXu et al. (2018);Yao et al. (2018), we can compute the eigenvalues directly.

Figures and Tables:

Figure 1: Training error in (b) is shown by thin curves, while test error in (b) by bold curves.

Figure 3: SGD explanation (taken fromKleinberg et al. (2018)). The first plot: an initially large learning rate helps escape spurious local minima. From the second to the fourth plots: after more rounds of learning rate decay, the probability of reaching the minimum becomes larger.

Figure 4: Training of WideResNet on CIFAR10 with Gradient Descent. X-axis indicates the number of epochs (in 10 3 ). Arrows indicate the epoch with learning rate decay.

reveal that large-batch training of modern networks can lead to very sharp local minima. Gradient Descent (the extreme of large batch training) can lead to even sharper local minima. In Figure 5, we calculate the largest ten eigenvalues 2 of the Hessian as well as the convergence interval (0 < η < 2/λ) for each eigenvalue for a trained WideResNet. The top eigenvalues reach the order of ≈ 200. By contrast, eigenvalues of simple networks in LeCun et al. (1991) often lie in [0, 10] (Figure 1 in their original paper). The spectrum of eigenvalues in modern networks is very different from that in simple networks analyzed by LeCun et al. (1991): the Hessian of modern networks has a much larger spectral norm.

Figure 5: The largest ten eigenvalues λ (blue curve) and converge intervals (0, 2 λ ) (bar) for WideResNet trained with Gradient Descent.

Figure 7: Training of WideResNet on CIFAR10 with SGD. X-axis indicates the number of epochs. Arrows show the moment of learning rate decay. The rightmost plots show results without decay.

Figure 8: The PS10 dataset. (a) Simple patterns: 10 patterns per category, complexity log 2 10. (b) Complex patterns: 100 patterns per category, complexity log 2 100. (c) Data composition: half of the data only contain simple patterns while another half only contain complex patterns.

Figure10: Comparison between lrDecay and a constant small learning rate on the PS10 dataset with 10% noise. Accuracies on simple patterns, complex patterns, and noise data are plotted respectively.

Figure 11: Transferability of additional patterns learned in each stage w.r.t different target datasets.

< l a t e x i t s h a 1 _ b a s e 6 4 = " C X E 4 U w s PA W A t R B q t O X D S c K n o i I Y = " > A A A B / H i c b V D L S s N A F J 3 4 r P U V 7 d L N Y B F c l a Q K C i 4 s u t B l B f u A J p T J d N I O n U z C z I 1 Y Q v 0 V N y 4 U c e u H u P N v n L Z Z a O u B g c M 5 9 3 D v n C A R X I P j f F t L y y u r a + u F j e L m 1 v b O r r 2 3 3 9 R x q i h r 0 F j E q h 0 Q z Q S X r A E c B G s n i p E o E K w V D K 8 n f u u B Kc 1 j e Q + j h P k R 6 U s e c k r A S F 2 7 d I O 9 C + w B e 4 R M A z G x y 3 H X L j s V Z w q 8 S N y c l F G O e t f + 8 n o x T S M m g Q q

T h j a k g g 3 B W 3 5 5 l T S r F e + i U r 2 / L N V u s j j y c A K n U A Y P r q A G d 1 C H B j B Q 8 A y v 8 O Y Y 5 8 V 5 d z 4 W r T k n m z m G P 3 A + f w A 6 6 Z C f < / l a t e x i t > ĝ(t) drop? < l a t e x i t s h a 1 _ b a s e 6 4 = " w 4 h H U x X 4 U o J 4 Y 0 J K 4 w 7 4 z 2 m Y 9 W M = " > A A A C A 3 i c b V D L S s N A F J 3 4 r P U V d a e b w S L U T U m q o O D C o h u X F e w D m l A m k 2 k 7 d P J g 5 k Y s I e D G X 3 H

z s e 8 d c X J Z 4 7 I H z i f P 7 m p k Y o = < / l a t e x i t > Decay < l a t e x i t s h a 1 _ b a s e 6 4 = " l W + t n 3 G Q P 2 3 E P A 6 q U N 3 I Y h b z b l 8 = " > A A A B 8 3 i c b V D L S g N B E J z 1 G e M r 6 t H L Y B A 8 h d 0 o 6 D G o B 4 8 R z A O y S 5 i d 9 C Z D Z h / M 9 I r L k t / w 4 k E R r / 6 M N / / G S b I H T S x o K K q 6 6 e 7 y E y k 0 2 v a 3 t b K 6 t r 6 x W d o q b + / s 7 u 1 X D g 7 b O k 4 V h x a P Z a y 6 P

Figure 12: Decision Procedure of AutoDecay. The counter t is reset to 0 the action of "Decay".

Figure 13: Variance reduction when β = 0.9

Figure 15: Training of WideResNet on CIFAR10 by Gradient Descent with a mildly larger learning rate. X-axis indicates number of epochs. Arrows and texts show the moment of learning rate decay.

Comparison of explanations on why lrDecay helps training neural networks. The column "supported" means whether the explanation is supported by the empirical experiments in this paper.

Table content: <table><tr><td>explanation</td><td>perspective</td><td>initially large lr</td><td>supported</td><td>lr decay</td><td>supported</td></tr><tr><td>LeCun et al. (1991)</td><td>optimization</td><td>accelerates training</td><td/><td>avoids oscillation</td><td/></tr><tr><td>Kleinberg et al. (2018)</td><td>optimization</td><td>escapes bad local minima</td><td/><td>converges to local minimum</td><td/></tr><tr><td>Proposed</td><td>pattern complexity</td><td>avoids fitting noisy data</td><td/><td>learns more complex patterns</td><td/></tr></table>

A.3 ACCURACIES TO COMPUTE THE TRANSFERABILITY IN SECTION 6

Table content: <table><tr><td>Dataset</td><td/><td/><td>Finetune</td><td/><td/><td/><td/><td>Fix</td><td/><td/></tr><tr><td/><td colspan="10">stage1 stage2 stage2 stage3 stage3 stage1 stage2 stage2 stage3 stage3</td></tr><tr><td>ImageNet</td><td>54.01</td><td>69.33</td><td>1.00</td><td>75.91</td><td>1.00</td><td>54.01</td><td>69.33</td><td>1.00</td><td>75.91</td><td>1.00</td></tr><tr><td>Caltect256</td><td>77.87</td><td>82.73</td><td>0.32</td><td>84.20</td><td>0.22</td><td>74.10</td><td>79.79</td><td>0.37</td><td>81.95</td><td>0.33</td></tr><tr><td>CUB 200</td><td>75.89</td><td>79.74</td><td>0.25</td><td>81.34</td><td>0.24</td><td>58.11</td><td>63.95</td><td>0.38</td><td>66.09</td><td>0.33</td></tr><tr><td colspan="2">MITIndoors 72.91</td><td>77.09</td><td>0.27</td><td>78.73</td><td>0.25</td><td>61.34</td><td>67.54</td><td>0.40</td><td>69.78</td><td>0.34</td></tr><tr><td>Sketch250</td><td>77.80</td><td>79.92</td><td>0.14</td><td>80.64</td><td>0.11</td><td>64.34</td><td>64.58</td><td>0.02</td><td>64.18</td><td>-0.06</td></tr></table>

Accuracy and transferability of ImageNet models in different stages. Normal values indicate accuracy and bold values indicate transferability.

Table content: <table/>

Peer review (iclr2020):
Contributions: This paper investigates the use of learning rate decay in deep neural networks. The main contribution is an empirical analysis trying to understand lr decay. Authors claim that the high-learning rate phase provides regularization and prevents the network to fit/memorize noisy data initially to focus on simple patterns. Authors design a set of experiments showing that lr decay allows SGD to first fit ‘simple patterns’ instead of more complex/noisy one. They also show that the model transferability decreases through training. In addition to those experiments, authors provide experimental results which aims at contradicting common beliefs on lr decay. Novelty/Significance: My main concern is about the novelty/significance of the paper. Similar argument has already been made in (Nakiran et al., 2019) or (Li et al. 2019), which are cited in the paper, and other works such as “On the Spectral Bias of Neural Networks”. In addition, prior to this work, the paper “Three factors Influencing Minima in SGD” empirically showed that the noise in SGD (which is controlled by the learning rate) prevents memorization (see Figure 6 in their paper). Although the latter work did not focus the lr decay, it is not clear to me how the main argument of the current paper differs from it. Additional comments: - It is unclear to me why the model the model before and after decay should have the same training performance in section 4.2. This would assume a specific geometry of the loss function (i.e. that the loss surface is not significantly narrower so that you can reach it with a high-learning rate), but authors do not provide evidence of it. - It would be nice to provide more details about the experimental settings. What is the base learning rate? Did you try different learning rate? Do you use with SGD-momentum, weight-decay? - How to combine the current explanation of lr decay with the observation that learning rate warm-up has been a successful way to train neural network in the large batch setting? - The transferability experiment confounds two factors: the number of iteration steps and the learning rates. Does training a model with low learning rate, but with a number a step equal to high learning rate lead to lower transferability? - It would be nice to validate the hypothesis on more datasets/models.