Formula
Formula for Convolution Output Size After Padding
When applying cross-correlation with padding, the spatial dimensions of the output increase. Specifically, if an input tensor of size is padded with a total of rows (divided roughly equally between top and bottom) and a total of columns (divided roughly equally between left and right), and then convolved with a kernel of size , the resulting output shape is given by the formula: .
0
2
Updated 2026-05-12
Tags
Data Science
D2L
Dive into Deep Learning @ D2L