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.
★☆☆☆☆ 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
stage
output C × H × W
parameters
multiply–adds
stem
64 × 56 × 56
9.5 k
118.01 M
stage2
256 × 56 × 56
634.4 k
1.98 G
stage3
512 × 28 × 28
3.48 M
2.88 G
stage4
1024 × 14 × 14
20.74 M
4.21 G
stage5
2048 × 7 × 7
41.97 M
2.21 G
head
1000 × 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-50
25.56 M parameters
4.09 G MACs
Wide ResNet-50-2
68.88 M parameters
11.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. Wide ResNets make blocks…
2. Wide networks trained faster because GPUs…
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. Blocks per stage in WRN-28-10:
2. Widening by k multiplies a conv's weights by…
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. Where does WRN put dropout?
2. wide_resnet50_2 parameters:
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. Diminishing feature reuse means…
2. WRN-40-4 trained about how much faster than ResNet-1001?
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
S. Zagoruyko, N. Komodakis (2016). “Wide residual networks.” Proc. BMVC.
K. He, X. Zhang, S. Ren, J. Sun (2016). “Identity mappings in deep residual networks.” Proc. ECCV.
K. Sohn et al. (2020). “FixMatch: simplifying semi-supervised learning with consistency and confidence.” Advances in NeurIPS.
At equal block weights, a 66-layer width-8 network failed where 6- and 18-layer wider ones succeeded.
Practice
Show:
Level 0
Problem 1Level 0
Widening factor of WRN-28-10?
10.
Problem 2Level 0
Stages in a CIFAR WRN?
3.
Problem 3Level 0
Blocks per stage in WRN-28-10?
(28 − 4)/6 = 4.
Level 1
Problem 4Level 1
Width of WRN-28-10’s last stage?
64·10 = 640.
Problem 5Level 1
Factor by which widening by 10 multiplies a convolution’s weights?
10² = 100.
Problem 6Level 1
Blocks per stage in WRN-40-4?
(40 − 4)/6 = 6.
Problem 7Level 1
Multiply–adds of a 3 × 3 conv 160 → 160 at 32 × 32?
32²·9·160² = 235929600.
Level 2
Problem 8Level 2
Parameters of WRN-28-10 (with BatchNorm)?
36479194.
Problem 9Level 2
Ratio of WRN-28-10’s parameters to WRN-28-1’s (369,498), one decimal?
36,479,194/369,498 ≈ 98.7.
Problem 10Level 2
Test accuracy of the width-8 network, seed 0, in exercise 2?
0.373.
Problem 11Level 2
Test accuracy of the width-32 network, seed 0?
0.919.
Problem 12Level 2
Layers in the width-8 network (input, 64 hidden, output)?
66.
Problem 13Level 2
Blocks of width 16 with the same weights as 32 blocks of width 8?
32·64/256 = 8.
Level 3
Problem 14Level 3
Show that widening a convolution’s input and output channels by k multiplies its weights by k².
A k_s × k_s convolution from C_in to C_out channels has k_s²·C_in·C_out weights. Replacing C_in by kC_in and C_out by kC_out gives k_s²·kC_in·kC_out = k²·(k_s²·C_in·C_out). ∎
Problem 15Level 3
Explain two reasons why the width-8, 66-layer network failed in exercise 2.
First, optimisation: 64 sequential layers without normalisation make the loss landscape hard for Adam in 300 steps, even with identity-initialised blocks. Second, capacity per layer: 8 units can represent only a few separating directions at each layer, so many layers must cooperate to bend the space enough for three interleaved spirals. Exercise 2 cannot separate the two effects. ∎
Problem 16Level 3
Compare WRN-40-4 and pre-activation ResNet-1001 on parameters, accuracy and training speed.
WRN-40-4 has 8.9 million parameters against 10.2 million, about the same CIFAR-10 error (4.97% against 4.92%), and trained about 8 times faster on GPUs. Its 40 layers run sequentially instead of 1,001, and each wide layer uses the GPU efficiently. ∎
Problem 17Level 3
Advise how to fit a classifier into a robot’s 10 ms inference budget on an embedded GPU.
Measure, do not assume. Try a shallower, wider variant (fewer blocks, more channels per block) and a deeper, thinner one at similar parameter counts. Profile latency on the actual device at the deployment resolution and batch size 1, and keep the most accurate model that meets the budget. Wide, shallow models usually win on GPUs; on CPUs and microcontrollers the trade-off can differ. ∎
Level 4
Problem 18Level 4
WRN-28-10’s CIFAR-10 error without dropout, in percent?
4.17.
Problem 19Level 4
Test accuracy of the width-16 network, seed 1, in exercise 2?
0.884.
Problem 20Level 4
Block weights shared by all three networks in exercise 2?
4096.
Coding practice
🐍 Code 1 (Level 0): blocks per stage
(n − 4)/6.
🐍 Code 2 (Level 0): widths
16, 16k, 32k, 64k.
🐍 Code 3 (Level 0): width scaling
k².
🐍 Code 4 (Level 1): equal budget
Blocks with the same weights at a new width.
🐍 Code 5 (Level 1): multiply–adds
H²·k²·c².
Topic test
A timed test drawn at random from this topic's question bank. Each attempt gets new questions. For a longer test across the whole chapter, see the chapter test, or mix topics in the question bag.
Wide ResNet: topic test
10 questions, drawn at random from a bank of 21. Every attempt is different.
⏱ Time limit: 15 minutes. The test submits itself when time runs out.
Levels covered: 0, 1, 2, 3, 4. No hints or solutions until you submit.