How it works:
A Convolution is a sliding window operation. In the code you provided:
- Kernel Size (3): The size of the "window" looking at the data.
- Stride (2): How many steps the window jumps. A stride of 2 skips every other position, which downsamples (shrinks) the output.
- Padding (1): Adding "fake" zeros around the edges to allow the kernel to center on edge pixels.
Hover over the green Output cells to see which Input pixels the kernel is currently "looking at."