CNNs Quiz
Check your understanding of convolutional networks — what weight sharing buys you, how output sizes are computed, and why pretrained features transfer.
Exercise
What is the main benefit of weight sharing in a convolutional layer?
Need a hint?
The same 3×3 kernel slides across the whole image.
Exercise
A 32×32 input goes through a 5×5 convolution with stride 1 and no padding. What's the output size?
Need a hint?
Output = (N − F)/S + 1.
Exercise
What does max pooling contribute to a CNN?
Need a hint?
It keeps the strongest activation in each window and throws away its exact position.
Exercise
How does the receptive field of a neuron change with network depth?
Need a hint?
A neuron in layer 2 sees a window of layer-1 outputs, each of which saw a window of pixels.
Exercise
Why does transfer learning from ImageNet work for, say, medical images?
Need a hint?
What do the first few conv layers of any vision network learn?
Exercise
FGSM perturbs an image by ε·sign(∇ₓL). Why use the SIGN of the gradient instead of the gradient itself?
Need a hint?
The attack budget is a max-per-pixel constraint (L∞), not a total-energy constraint.
Exercise
Why do depthwise separable convolutions (MobileNet) use far fewer parameters than standard convolutions?
Need a hint?
They split one job into two: filter within channels, then mix across channels.
Exercise
A CNN shares one small filter across every position instead of learning independent weights per pixel (translation equivariance). Which slot of the ML project loop is that choice?
Need a hint?
It's a built-in assumption about the function family — an inductive bias.
Exercise
Transfer test — a technique this course did NOT teach: class-weighting the loss so a rare tumor class contributes more per example. Which slot does it modify?
Need a hint?
It reweights the loss to care more about certain errors.