Level 0: Foundation
★☆☆☆☆ Introductory⏱ 5 minGeneral audience. No mathematics required.Look at several scales at once
Should a layer use small 1 × 1 filters, medium 3 × 3, or large 5 × 5? GoogLeNet’s answer: all of them, side by side, and let training decide which to use. Each Inception module sends its input through four parallel branches and stacks their outputs. The trick that makes this affordable is to shrink the number of channels with cheap 1 × 1 convolutions before the expensive branches. Nine such modules, stacked 22 layers deep, won ImageNet 2014 with fewer parameters than AlexNet.
| stage | output C × H × W | parameters | multiply–adds |
|---|---|---|---|
| stem | 192 × 28 × 28 | 124.7 k | 477.68 M |
| 3a | 256 × 28 × 28 | 164.1 k | 128.05 M |
| 3b | 480 × 14 × 14 | 389.4 k | 304.27 M |
| 4a | 512 × 14 × 14 | 376.8 k | 73.61 M |
| 4b | 512 × 14 × 14 | 449.8 k | 87.91 M |
| 4c | 512 × 14 × 14 | 510.8 k | 99.85 M |
| 4d | 528 × 14 × 14 | 606.1 k | 118.52 M |
| 4e | 832 × 7 × 7 | 869.4 k | 170.00 M |
| 5a | 832 × 7 × 7 | 1.04 M | 51.08 M |
| 5b | 1024 × 7 × 7 | 1.45 M | 70.70 M |
| head | 1000 × 1 × 1 | 1.02 M | 1.02 M |
| AlexNet | 61.10 M parameters | 714.19 M MACs |
| VGG-16 | 138.36 M parameters | 15.47 G MACs |
| GoogLeNet (Inception v1) | 7.01 M parameters | 1.58 G MACs |
GoogLeNet showed that careful design can buy accuracy without buying parameters or compute, the idea behind every efficient network that runs on drones, phones and satellites.
- 1. An Inception module runs branches…
- 2. 1 × 1 convolutions in Inception mainly…
- 3. GoogLeNet has about … AlexNet's parameters.
Level 1: Beginner
★★☆☆☆ Basic⏱ 20 minSecondary-school mathematics: arithmetic and elementary algebra.By hand
-
Module 3a on 192 × 28 × 28 has four branches:
- 1 × 1 to 64 channels;
- 1 × 1 to 96, then 3 × 3 to 128;
- 1 × 1 to 16, then 5 × 5 to 32;
- 3 × 3 max pooling, then 1 × 1 to 32.
The output has 64 + 128 + 32 + 32 = 256 channels, and the module has 163,696 parameters with biases.
-
Saving on the 5 × 5 branch: directly on 192 channels it needs 28²·25·192·32 ≈ 120.4 M multiply–adds. With a 1 × 1 reduction to 16 it needs 28²·(192·16 + 25·16·32) ≈ 12.4 M, 9.7 times less.
-
Naive module: without reductions, the pooling branch passes all 192 input channels through, so 3a would output 64 + 128 + 32 + 192 = 416 channels, and every later module would output more.
-
Auxiliary classifiers: during training, losses from two side classifiers (on 4a and 4d) are added with weight 0.3: L = L_main + 0.3(L_aux1 + L_aux2).
- 1. Output channels of module 3a:
- 2. Saving from the 1 × 1 reduction on 3a's 5 × 5 branch:
- 3. Auxiliary losses are weighted by…
Level 2: Intermediate
★★★☆☆ Intermediate⏱ 25 minUndergraduate students and practising engineers.Inception in code
Exercise 1.
- Module 3a turned a 192-channel input into 256 channels, all non-negative after ReLU.
- It had exactly 163,696 parameters.
- Same-padded 3 × 3 max pooling behaved as expected at the borders.
Practice.
- torchvision’s
googlenetadds BatchNorm after every convolution and, because of a long-standing quirk in the reference implementation, uses 3 × 3 in place of 5 × 5 in the third branch. It has 6.6 M parameters and is a reasonable lightweight backbone. - The auxiliary classifiers are used only in training and discarded at test time. Later work (Inception v3) found they act mainly as regularisers.
- The original training used asynchronous SGD with momentum 0.9, reducing the learning rate by 4% every 8 epochs, with Polyak averaging of the weights.
- The competition entry averaged 7 models over 144 crops per image.
model = torchvision.models.googlenet(weights="IMAGENET1K_V1") # aux classifiers off at inference- 1. Auxiliary classifiers are used…
- 2. torchvision's GoogLeNet adds…
- 3. The competition entry averaged…
Level 3: Advanced
★★★★☆ Advanced⏱ 25 minGraduate level, with full derivations and proofs.Theory
Why parallel branches. Objects and their parts appear at many scales. A module that offers several receptive fields at once lets each layer pick the useful mixture. The authors motivated this by Arora et al.’s analysis of sparse networks: approximate an optimal sparse structure by dense, hardware-friendly blocks of different sizes.
Why reductions are essential. Concatenation means output channels are the sum of the branches. A pooling branch preserves its input channels, so without a projection the width can only grow from module to module. The expensive 3 × 3 and 5 × 5 branches then run on ever wider inputs, and compute explodes (exercise 2). A 1 × 1 reduction before each expensive branch, and a 1 × 1 projection after pooling, keep both width and cost under control.
Training a deep network before BatchNorm. At 22 layers, gradients to early layers were weak. The auxiliary classifiers inject gradient into the middle of the network and add regularisation.
Global average pooling. As in NiN (E8-5), the network ends with global average pooling, a dropout layer and one linear layer. The authors reported that this gave 0.6% better top-1 accuracy than fully connected layers.
- 1. Without projections, module width…
- 2. Auxiliary classifiers help by…
- 3. GAP instead of fc layers improved top-1 by about…
Level 4: Expert
★★★★★ Expert⏱ 30 minResearchers: original papers and open problems.What do the 1 × 1 reductions buy?
History.
- C. Szegedy et al. (2015) introduced GoogLeNet, which won ILSVRC 2014 classification with 6.67% top-5 error. The name honours LeNet; “Inception” comes from the film’s “we need to go deeper”.
- S. Arora et al. (2014) analysed sparse deep representations, the stated theoretical motivation.
- S. Ioffe and C. Szegedy (2015) introduced BatchNorm with Inception v2, and later versions followed (E8-7).
Exercise 2. This is a cost calculation, not a training run. It computes the channels, parameters and multiply–adds of GoogLeNet’s nine Inception modules (on the stem’s 192 × 28 × 28 output) with the paper’s widths, in two versions:
- with the 1 × 1 reductions;
- “naive” modules: 1 × 1, 3 × 3 and 5 × 5 directly on the input, plus a pooling branch that passes its channels through.
| modules | parameters | multiply–adds | channels after 3a → 5b |
|---|---|---|---|
| with 1 × 1 reductions | 5,849,136 | 1.10 G | 256 → 1,024 |
| naive | 92,456,592 | 12.09 G | 416 → 4,944 |
- The naive network would cost 11 times more compute and 16 times more parameters. Its width grows by the whole input at every module, and its 3 × 3 and 5 × 5 branches run on that growing width.
- The largest single cost is module 4e’s, 3.3 G multiply–adds in the naive version against 0.17 G with reductions.
- This shows only cost, not accuracy. Whether reductions hurt accuracy is an empirical question. The paper’s result is that the reduced network won the competition at about 1.5 G multiply–adds in total.
Inception in AI, robotics and aerospace
- Efficient perception: Inception-style multi-branch blocks appear in detectors for aerial imagery, where objects vary greatly in size.
- Transfer learning: Inception v3 features (E8-7) were widely used for medical, agricultural and remote-sensing classification.
- Design lesson: budgeting compute per block, rather than stacking ever wider layers, guides network design for embedded hardware.
References
- C. Szegedy et al. (2015). “Going deeper with convolutions.” Proc. CVPR.
- S. Arora, A. Bhaskara, R. Ge, T. Ma (2014). “Provable bounds for learning some deep representations.” Proc. ICML.
- M. Lin, Q. Chen, S. Yan (2014). “Network in network.” Proc. ICLR.