Paper commentary
Deep Networks with Stochastic Depth
Random layer drops speed up training of deep ResNets
- Problem Very deep networks are slow to train and their gradients and features fade with depth. Depth that helps at test time is hard to use during training.
- Method Stochastic depth randomly bypasses whole residual blocks in each mini-batch using the identity function. Unlike standard training, it runs the full-depth network at test time, scaling each block by its survival probability.
- Results A 1202-layer ResNet trained with stochastic depth reaches 4.91% test error on CIFAR-10. The constant-depth 1202-layer ResNet reaches 6.67%.
Why very deep residual networks are hard to train
Deeper convolutional networks followed the shift to CNNs in computer vision, with AlexNet at 5 convolutional layers, VGG and GoogLeNet at 19 and 22 layers, and ResNet at 152 layers. The authors group the difficulties of very deep models into three problems: vanishing gradients in backward propagation, diminishing feature reuse in forward propagation, and long training time.
Vanishing gradients arise because each backward step multiplies the gradient by weights that are often small, so the signal reaching earlier layers becomes weak. The forward analogue is that features from the input or from earlier layers are progressively washed out by repeated transformation, which makes it hard for later layers to learn useful directions.
Forward and backward passes cost time in proportion to network depth, and the 152-layer ResNet needs several weeks to train on ImageNet even on several GPUs. This creates a dilemma: short networks train quickly and propagate information well, but they lack the capacity for complex vision concepts, while very deep networks have the capacity but are hard to train.
Residual connections and Dropout as starting points
A residual layer computes H_l = ReLU(f_l(H_{l-1}) + id(H_{l-1})), so an identity path carries features and gradients across the layer. Highway Networks use gated skip connections whose parameters are learned, while ResNets replace these gates with mostly identity shortcuts, which makes training more efficient and feature reuse more direct.
Dropout multiplies each hidden activation by an independent Bernoulli random variable, which reduces co-adaptation of hidden nodes. Stochastic depth applies the same random-removal idea at the level of whole layers, making the network shorter instead of thinner, and it is motivated by the problem of depth rather than by co-adaptation.
Skipping residual blocks per mini-batch
Each residual block l has a Bernoulli variable b_l that is 1 when the block is active and 0 when it is bypassed, and its survival probability is p_l = Pr(b_l = 1). The network keeps the skip connections of the ResNet architecture and redraws which blocks are active for each mini-batch, so the connection pattern changes from one update to the next.
The modified update rule multiplies the residual transformation by the Bernoulli variable, giving H_l = ReLU(b_l f_l(H_{l-1}) + id(H_{l-1})). When b_l is 0, the block reduces to the identity, so its transformation and its gradient computation are skipped for that update.
The identity reduction holds because the input to each block is non-negative: for blocks after the first it is the output of a final ReLU, and for the first block it comes from a Conv-BN-ReLU sequence, where ReLU acts as an identity on non-negative inputs. The CIFAR networks have three groups of residual blocks with 16, 32 and 64 filters, while the ImageNet model uses the bottleneck block of He et al.
Assigning survival probabilities
The formula is \[ p_\ell = 1 - \frac{\ell}{L}(1 - p_L) \], which keeps early blocks more reliably active. The authors motivate this by the idea that early layers extract low-level features that later layers depend on, and they set p_L = 0.5 throughout after finding stochastic depth stable with respect to p_L.
The expected number of active blocks during training is the sum of the survival probabilities over all blocks. Under linear decay with p_L = 0.5 this sum equals (3L - 1)/4, or about 3L/4 for large L, so the 110-layer network with L = 54 trains with about 40 blocks on average and is used at test time with all 54.
Full-depth inference and the implicit ensemble view
At test time every residual function stays active, and its output is multiplied by its survival probability before it is added to the identity path, which compensates for the fraction of updates in which the block was present. The test-time rule is \[ H^{\mathrm{Test}}_\ell = \mathrm{ReLU}\big(p_\ell f_\ell(H^{\mathrm{Test}}_{\ell-1}; W_\ell) + H^{\mathrm{Test}}_{\ell-1}\big) \].
Since each of the L blocks is either active or inactive, there are 2^L possible sub-networks that share weights, and each mini-batch samples one of them for training. Unlike the ensemble view of Dropout, the sub-networks differ in depth as well as in which units are kept.
Training time savings
Measured clock times in Table 2 show CIFAR10+ training at 20h 42m for constant depth and 15h 7m for stochastic depth, with CIFAR100+ at 20h 51m and 15h 20m, and SVHN at 33h 43m and 25h 33m.
CIFAR-10 and CIFAR-100 results
Horizontal flipping and translation by 4 pixels are the standard augmentations used here.
The constant-depth ResNet reaches 6.41% test error and stochastic depth reaches 5.25%, which the authors describe as an 18% relative improvement. The authors compare this with the best single-model result they cite at the time, 6.05%, and note that their result is lower without the massive data augmentation used in that prior work.
Without data augmentation, constant depth reaches 13.63% on CIFAR-10 and 44.74% on CIFAR-100, and stochastic depth gives 11.66% and 37.8%, which the authors describe as improvements of about 15% on both datasets.
SVHN and ImageNet results
SVHN has 73,257 training digits, 26,032 test digits and 531,131 extra samples, and the experiments use all training samples without data augmentation, with a validation set of 6,000 samples. The 152-layer baseline is trained for 50 epochs with the learning rate divided by 10 after epochs 30 and 35, and it overfits in the second phase. The baseline reaches 1.80% and stochastic depth reaches 1.75%, which the authors describe as the second-best published result on SVHN after one prior method.
Because the 25% saving leaves room for more epochs, stochastic depth trained for 120 epochs with the learning rate lowered to 1e-4 at epoch 90 reaches 21.98%, and the baseline run for 30 more epochs reaches 21.78%. The authors note that the current ImageNet models are in a different regime from CIFAR, and they expect possible benefits with larger models, so no immediate gain is shown here.
A 1202-layer ResNet on CIFAR-10
He et al. reported 7.93% for a 1202-layer ResNet, which is worse than their 110-layer network, and the authors repeat this setting for 300 epochs with a warm-up at learning rate 0.01 for the first 10 epochs, then 0.1 with divisions at epochs 150 and 225. The constant-depth 1202-layer ResNet reaches 6.67%, which is worse than the 6.41% of the constant-depth 110-layer ResNet.
With stochastic depth the 1202-layer network reaches 4.91%, a 27% relative improvement over its constant-depth counterpart, and it improves on the 110-layer stochastic depth result of 5.25%. The authors report no sign of overfitting in this run, and they describe the result as the lowest known CIFAR-10 test error with moderate augmentation at the time of submission and the first network with more than 1000 layers shown to reduce test error further.
This architecture was trained on CIFAR-10 only and is therefore not part of the cross-dataset comparison table.
Gradient magnitude in the first layer
The authors record the mean gradient magnitude of the first convolutional layer of the first residual block on CIFAR-10 at every epoch, with and without stochastic depth. The gradient magnitude stays larger with stochastic depth throughout training, and the gap is most visible after learning rate drops. The authors also note that the constant-depth test error plateaus after the first learning rate drop while the stochastic depth test error keeps improving.
Sensitivity to the survival probability and depth
The authors sweep p_L for the 110-layer ResNet on CIFAR-10 under both linear decay and uniform assignment. Both rules beat the constant-depth baseline when p_L is set properly, and the linear decay rule beats the uniform rule at every tested value. Linear decay stays competitive for p_L between 0.4 and 0.8, and with p_L = 0.2 it still performs well while cutting training time by 40%.
A heatmap over p_L and network depth shows that deeper networks do best with p_L = 0.5, and that the lowest-error region lies along the diagonal. A sufficiently deep model is needed for stochastic depth to clearly beat the baseline, although shorter networks can still benefit from less aggressive skipping.
Dropout on ResNets with Batch Normalization
The authors report that Dropout has been observed to lose effectiveness when combined with Batch Normalization. In their own experiments on CIFAR-10 with various Dropout rates, Dropout gives practically no improvement on the 110-layer ResNet with Batch Normalization.
Limitations
ResNets trained with stochastic depth fluctuate more in test error during training than constant-depth ResNets, which the authors attribute to the random depth. Shallow models gain less, so the benefit depends on the network being deep enough.
The main setting uses p_L = 0.5 with linear decay throughout, and the sensitivity sweep covers only the 110-layer ResNet on CIFAR-10. The 1202-layer result is on CIFAR-10 only, and ImageNet was run on the 152-layer bottleneck ResNet, where stochastic depth did not improve validation error at equal training budget. The implicit ensemble explanation is offered by the authors as one interpretation, and the experiments here do not isolate it.
Paper info
- Authors
- Gao Huang, Yu Sun, Zhuang Liu, Daniel Sedra, Kilian Weinberger
- Venue
- arXiv · Preprint
- First published
- 2016-3-30
- Added
- 2026-11-12
- Updated
- 2016-7-28
- Version
- v3
- arXiv
- 1603.09382
- Category
- cs.LG · cs.CV · cs.NE
- Original paper terms
- arXiv non-exclusive 1.0
- What we show
- Paper info and commentary
AI commentary is a separate explanation from the original paper and may contain errors. The original paper and figures follow each source's terms of use and any rights noted separately.
Quote from the paper
Gao Huang, Yu Sun, Zhuang Liu, Daniel Sedra, Kilian Weinberger (2016). Deep Networks with Stochastic Depth. arXiv:1603.09382v3. https://arxiv.org/abs/1603.09382v3
BibTeX
@misc{huang2016deep,
title = {{Deep Networks with Stochastic Depth}},
author = {Gao Huang and Yu Sun and Zhuang Liu and Daniel Sedra and Kilian Weinberger},
year = {2016},
eprint = {1603.09382},
archivePrefix = {arXiv},
url = {https://arxiv.org/abs/1603.09382v3}
}