Lesson 10.1 · 7 min read · about 50 min to master at a very slow pace
From Fully Connected to Convolutional
Why a fully connected layer is a poor fit for images, and the two ideas that fix it: local connectivity and weight sharing. With the parameter count that shows the difference.
The problem with fully connected layers on images
In a fully connected (FC) layer every output unit connects to every input value. For an image that ignores two facts:
- Locality: nearby pixels are related; a pixel in the top-left corner says little about one in the bottom-right.
- Translation: the same pattern (an edge, an eye) can appear anywhere, and should be detected the same way wherever it is.
Two ideas
| Idea | What it means | Effect |
|---|---|---|
| Local connectivity | Each output looks only at a small patch of the input (e.g. 3×3) | Far fewer connections |
| Weight sharing | The same small filter is applied at every position | Parameters don't depend on image size; a pattern is detected anywhere |
Worked example: parameter count
A 32×32 colour image has values.
- Fully connected to 100 units: parameters.
- Convolutional, 16 filters of size 3×3×3: parameters.
The convolutional count depends on the filter size and the number of filters, not on the number of positions the filters slide over.
Rule: a conv layer with filters of size over input channels has parameters.
Stuck? Common doubts
Questions real learners asked while studying this lesson. They stay closed so they don't spoil your own thinking: open only the ones you need.
First passDo fewer parameters make a CNN less powerful?
Not for images. The parameters it gives up encode connections that don't help (distant pixels, position-specific copies of the same detector). Building locality and translation into the architecture makes learning far more data-efficient, which is why CNNs beat FC networks on images while being much smaller.
Cheatsheet
Why convolutions
Conv layer parameters
Check your understanding
Score 75% or more to master this lesson and earn XP. Answer first, then check.