3.4.10 · D1Convolutional Neural Networks

Foundations — DenseNet and EfficientNet

1,894 words9 min readBack to topic

Before we can read a single line of the parent note, we need a shared picture of what a CNN actually moves around. Let us build the vocabulary brick by brick, each brick resting on the one before.


1. The image as a stack of grids

Look at the left panel of the figure below: a grey grid, tall and wide. That is one flat sheet of numbers.

But a colour image is not one sheet — it is three sheets stacked: how red each pixel is, how green, how blue. Each sheet is called a channel.

Figure — DenseNet and EfficientNet

Why does the topic need this? Every quantity the parent talks about — " channels", " channels", "-d vector" — is just how many of these grids are stacked at that point in the network. When DenseNet says a layer "produces feature maps", it means it adds new grids to the stack.


2. Convolution — the sliding stamp

Look at the middle figure: the small magenta stamp sits on the input; the single violet dot on the right is the one number it produces for that position. Slide the stamp across all positions to fill the whole output grid.

Figure — DenseNet and EfficientNet

Why the topic needs it: the parent's parameter counts (like for a conv, or the MBConv "expand , depthwise, project" pipeline) are literally counting the weights inside these stamps.


3. Counting the cost: parameters and FLOPs


4. The layer building blocks: BN, ReLU, pooling

Figure — DenseNet and EfficientNet

5. Concatenation vs. addition — the DenseNet heartbeat

Contrast with addition (), used by ResNet: adding two -channel stacks gives channels where each number is a sum — the originals are merged and lost. The figure shows both: concatenation grows the stack, addition overlays it.

Figure — DenseNet and EfficientNet

6. Symbols for EfficientNet scaling

Recall Why the exponent, not a plain multiply?

Turning the dial should double the FLOPs each time. Repeated doubling is exponential, so growth must be (exponent), giving total FLOP factor . Setting makes each step a clean .


Prerequisite map

Pixel grid H x W

Channel and feature map

Convolution sliding stamp

1x1 conv changes channels

Depthwise conv

Parameters and FLOPs

BN ReLU Pooling

Concatenation vs addition

Growth rate k

Scaling knobs d w r

Compound coefficient phi

DenseNet and EfficientNet


Equipment checklist

State each aloud; if you cannot, re-read that section.

What does a feature map represent, and what shape does a stack of them have?
One channel of learned evidence, an grid; a stack has shape .
Why do we use convolution instead of a full multiply?
One small kernel slides over all positions, so a pattern is detected wherever it appears and weights are shared.
What is the ONLY job of a convolution?
To change the number of channels by mixing them at each single pixel (no neighbours).
How many parameters in a conv from to channels?
(that is ).
Difference between a parameter and a FLOP?
A parameter is a stored learnable number; a FLOP is one multiply/add executed while running.
What does do to and to ?
Sends and keeps (max of and ).
What does stride-2 pooling do to and ?
Halves both by summarising each block into one number.
Concatenation vs addition of two 16-channel stacks — resulting channel count?
Concatenation channels (kept side by side); addition channels (merged, originals lost).
After layers of growth rate starting from , how many channels?
.
What do , , scale, and what constraint links ?
Depth, width, resolution; constraint .