What a CNN Actually Does

Convolution

Part of: Computer Vision Basics

In 2012 a network called AlexNet won the ImageNet contest by a margin so wide it ended a debate. The architecture behind it, a convolutional neural network , or CNN : became the engine behind nearly every "is this a dog or a cat" system for the next decade. You won't build one from scratch, but understanding the single idea that makes it work, the convolution , enables everything that follows. The problem CNNs solve Imagine wiring every pixel of a 224×224 image to every neuron in a layer. That's about 50,000 inputs per neuron, and the network would have to separately learn that an edge in the top-left corner looks like an edge in the bottom-right corner. Two flaws: a parameter explosion, and no shared knowledge of what an edge is. The model wastes capacity relearning the same pattern in every location, and it generalizes poorly. A convolution fixes both problems with one trick: a small filter that slides across the whole image . A filter is a tiny pattern detector A filter (also called a kernel ) is a small grid of weights, typically 3×3. You slide it over every position in the image. At each spot you multiply the filter's values by the pixels underneath and add the products into a

Challenge: Find the Strongest Edge