So far, we have intuitively understood how a CNN works. But how exactly does a CNN learn? How does it find the optimal values for the filter using backpropagation? To answer this question, we will explore mathematically how the CNN works. Unlike in the Chapter 5, Improvements to the RNN, the math behind a CNN is pretty simple and very interesting.
The math behind CNNs
Forward propagation
Let's begin with the forward propagation. We have already seen how forward propagation works and how a CNN classifies the given input image. Let's frame this mathematically. Let's consider an input matrix, X, and filter, W, with values shown as follows:
First, let's familiarize ourselves with the notations. Whenever we...