What is a convolutional filter?
A convolutional filter, also called a kernel, is a small grid of numbers, often 3 by 3, that a model slides across an image. At each position the filter multiplies its weights by the pixel values beneath it and sums the result into one value. Repeating this everywhere produces a feature map that lights up wherever the image matches the filter’s pattern. A filter with positive weights on the left and negative on the right responds strongly to vertical edges.
Engineers once designed filters by hand for blurring and edge detection. In a convolutional neural network (CNN), the weights are learned from training data through backpropagation. Early layers learn edge and color detectors, middle layers combine them into textures and parts, and deep layers respond to whole objects such as a bolt head or a face.
Why convolutional filters matter
One filter is reused at every position, so the network learns a pattern once and finds it anywhere in the frame with few parameters. A model trained to find scratches on steel coil will find them at the edge or the center of the frame, but not automatically at a different scale or under lighting it never saw in training.
What to watch for
- If visualized early-layer filters look like noise, the model may be undertrained.
- Filters are tuned to their training resolution, so changing cameras or downscaling images changes what they see.
- Vision transformers replace filters with attention over image patches, but CNNs remain the practical choice for fast inspection on edge hardware.