Foundations to Frontier
Tests
E. Deep Learning › E8 CNN Architectures (one page each)

Wide ResNet

Wide Residual Networks (Zagoruyko and Komodakis, 2016) asked whether ResNets need to be so deep and thin. Widening each block by a factor k and cutting depth, as in WRN-28-10 with 28 layers and 36.5 million parameters, gave better CIFAR accuracy than a 1,001-layer ResNet, and trained several times faster on GPUs, which handle wide layers efficiently. This page covers the WRN-n-k family, how width scales parameters and compute, and dropout inside blocks. In the exercises you derive WRN parameter counts, then compare residual networks with the same 4,096 block weights on spirals: a thin 66-layer network (width 8) failed to fit, while 18- and 6-layer networks of width 16 and 32 reached about 0.9 test accuracy.

Level 0: Foundation

★☆☆☆☆ Introductory⏱ 5 minGeneral audience. No mathematics required.

Fewer, fatter layers

After ResNet, the race was for depth: 152 layers, then 1,001. Each layer was thin, though, and much of that depth did little work. Zagoruyko and Komodakis tried the opposite: make each residual block several times wider and the network much shallower. A 16-layer wide network matched a 1,001-layer thin one, and a 28-layer wide network beat it. Graphics processors handle a few wide layers far better than many thin ones, so the wide networks also trained several times faster.

Architecture explorer: shapes, parameters and compute
stageoutput C × H × Wparametersmultiply–adds
stem64 × 56 × 56
9.5 k
118.01 M
stage2256 × 56 × 56
634.4 k
1.98 G
stage3512 × 28 × 28
3.48 M
2.88 G
stage41024 × 14 × 14
20.74 M
4.21 G
stage52048 × 7 × 7
41.97 M
2.21 G
head1000 × 1 × 1
2.05 M
2.05 M
Total: 68,883,240 parameters (68.88 M), 11.40 G multiply–adds per image at 224 × 224.
ResNet-5025.56 M parameters4.09 G MACs
Wide ResNet-50-268.88 M parameters11.40 G MACs
Bars show each row's share of the total. Convolutions dominate compute because they run at every position; fully connected layers dominate parameters in older designs (AlexNet, VGG). Changing the input size changes the compute of every convolution but not its parameters. Parameter counts include biases and BatchNorm scale and shift and match torchvision's implementations.
Why engineers care

On real hardware latency depends on depth, because layers run one after another, while width parallelises. For a robot’s fixed time budget, a wider, shallower network is often the better use of compute.

📝 Quick check (Level 0)
0/3 answered
  1. 1. Wide ResNets make blocks…
  2. 2. Wide networks trained faster because GPUs…
  3. 3. WRN-28-10 has how many layers?

Level 1: Beginner

★★☆☆☆ Basic⏱ 20 minSecondary-school mathematics: arithmetic and elementary algebra.

By hand

  • WRN-n-k: the depth is n and the widening factor is k.
    • There are three stages of (n − 4)/6 pre-activation basic blocks, with widths 16k, 32k and 64k, after a 16-channel stem.
    • WRN-28-10 therefore has 4 blocks per stage and widths 160, 320 and 640.
  • Scaling: widening every convolution by k multiplies its weights and its multiply–adds by k². A 3 × 3 convolution at 32 × 32 needs 32²·9·16² ≈ 2.4 M multiply–adds at 16 channels and 32²·9·160² ≈ 236 M at 160 channels.
  • Parameters, with BatchNorm:
    • WRN-28-10: 36,479,194;
    • WRN-16-8: 10,961,370;
    • WRN-40-4: 8,949,210;
    • WRN-28-1 (an ordinary thin ResNet): 369,498.
  • Equal budgets: 32 blocks of width 8 use 32·2·8² = 4,096 weights; so do 8 blocks of width 16 and 2 blocks of width 32.
📝 Quick check (Level 1)
0/3 answered
  1. 1. Blocks per stage in WRN-28-10:
  2. 2. Widening by k multiplies a conv's weights by…
  3. 3. WRN-28-10's widths:

Level 2: Intermediate

★★★☆☆ Intermediate⏱ 25 minUndergraduate students and practising engineers.

Wide ResNets in code

Exercise 1.

  • The parameter formula reproduced the published sizes: 36.5 M for WRN-28-10, 11.0 M for WRN-16-8 and 8.9 M for WRN-40-4.
  • WRN-28-1 has 0.37 M, about 100 times fewer than WRN-28-10, as the k² rule predicts.

Practice.

  • CIFAR recipe:
    • SGD with Nesterov momentum 0.9 and weight decay 5·10⁻⁴, batch 128;
    • learning rate 0.1, multiplied by 0.2 at epochs 60, 120 and 160, over 200 epochs.
  • Dropout: 0.3 between the two convolutions of each block helped wide networks.
  • ImageNet: torchvision’s wide_resnet50_2 doubles the bottleneck width of ResNet-50, giving 68.9 M parameters and about 11.4 G multiply–adds.
model = torchvision.models.wide_resnet50_2(weights="IMAGENET1K_V2")   # bottleneck width 128 instead of 64
🐍 Exercise 1: WRN parameter counts
Count the parameters of WRN-n-k and list its widths.
📝 Quick check (Level 2)
0/3 answered
  1. 1. Where does WRN put dropout?
  2. 2. wide_resnet50_2 parameters:
  3. 3. The CIFAR learning rate is multiplied by 0.2 at…

Level 3: Advanced

★★★★☆ Advanced⏱ 25 minGraduate level, with full derivations and proofs.

Theory

Diminishing feature reuse. In very deep thin ResNets, the shortcut lets gradients bypass blocks, so many blocks learn little, and only a few contribute useful features. Wider blocks give each block more capacity, so fewer blocks are needed.

Depth versus width at fixed parameters. The authors compared many depths and widths. With similar parameter counts, wider and shallower networks were as accurate or more accurate:

  • WRN-40-4 (8.9 M) reached 4.97% error, against 4.92% for pre-activation ResNet-1001 (10.2 M);
  • WRN-28-10 reached 4.17%, or 3.89% with dropout.

Depth still mattered: very shallow wide networks were worse.

Hardware. Layers run sequentially, so latency grows with depth. A wide layer is one large matrix multiplication, which a GPU executes efficiently. WRN-40-4 trained about 8 times faster than ResNet-1001.

Limits. Width costs k² in parameters and memory. On small datasets very wide networks overfit without dropout. Later work (EfficientNet, E8-20) scaled depth, width and resolution together.

📝 Quick check (Level 3)
0/3 answered
  1. 1. Diminishing feature reuse means…
  2. 2. WRN-40-4 trained about how much faster than ResNet-1001?
  3. 3. Width costs…

Level 4: Expert

★★★★★ Expert⏱ 30 minResearchers: original papers and open problems.

Deep and thin, or shallow and wide?

History.

  • S. Zagoruyko and N. Komodakis (2016) introduced Wide Residual Networks at BMVC.
  • WRN-28-10 became a standard strong CIFAR baseline, used in semi-supervised learning (FixMatch) and robustness research.
  • M. Tan and Q. Le (2019) proposed compound scaling of depth, width and resolution (EfficientNet).

Exercise 2. The data are three-class spirals. Three residual networks have the same 4,096 weights in their blocks: width 8 with 32 blocks, width 16 with 8 blocks, and width 32 with 2 blocks. Each is trained with full-batch Adam for 300 steps and tested on 1,000 new points:

width × blocks layers final training loss (seeds 0, 1) test accuracy
8 × 32 66 0.895, 0.865 0.373, 0.432
16 × 8 18 0.020, 0.015 0.903, 0.884
32 × 2 6 0.010, 0.030 0.919, 0.889
  • The thin, deep network failed. At equal budget, the 66-layer width-8 network could not fit the spirals in 300 steps. In seeds 2 to 4 it reached 0.32, 0.87 and 0.80, so it is erratic rather than always failing.
  • The wider networks succeeded with far fewer layers. Between widths 16 and 32 there was no consistent winner (seeds 2 to 4: 0.89, 0.93, 0.90 against 0.91, 0.93, 0.90).
  • Width 8 is also a narrow bottleneck for a 2-D, three-class problem. So this result mixes two effects: depth makes optimisation harder, and a narrow width limits what each layer can represent. WRN’s experiments controlled for this across many configurations; this toy shows the direction.
🐍 Exercise 2 (research): deep and thin, or shallow and wide?
Train residual networks with equal block weights but different width and depth, and compare training loss and test accuracy.

Wide networks in AI, robotics and aerospace

  • Latency-bound systems: for real-time perception on robots and vehicles, shallower and wider networks often meet deadlines better than deep, thin ones of similar size.
  • Semi-supervised and robust learning: WRN-28-10 is the standard backbone in research on learning from few labels and on adversarial robustness, relevant to safety-critical vision.
  • Hardware-aware design: measure latency on the target accelerator; parameter counts alone mislead.

References

  1. S. Zagoruyko, N. Komodakis (2016). “Wide residual networks.” Proc. BMVC.
  2. K. He, X. Zhang, S. Ren, J. Sun (2016). “Identity mappings in deep residual networks.” Proc. ECCV.
  3. K. Sohn et al. (2020). “FixMatch: simplifying semi-supervised learning with consistency and confidence.” Advances in NeurIPS.