Convolution Layer#

Note

A neural network that use convolution layers is often called a CNN, a convolution neural network.

What do convolution layers do?#

Taking image processing for example, a convolution layer compute the local features (whether there’s an edge here, a dot there, etc), and aggregate the result into another image, which can sometimes be visualized. There are different kinds of convolution layers. We often use the 1-dimension version for text processing, 2-dimension version for image processing (most common).

When to use a convolution layer?#

Convolution layers are often used to directly process inputs, which means they are often places in the front of a model. Use of convolution in image processing is very common (usually paired with linear layers and pooling layers for classification). Convolution layers are also quite common in text processing.