Convolutional Networks
An image classifier should recognize an edge in different parts of an image. A convolutional layer applies the same small filter at each position, sharing weights across the image. We will derive this operation and examine how its output changes when the input shifts.
Receptive Fields
Locality saves parameters, but one layer cannot immediately combine distant evidence. Depth supplies that reach. The receptive field of an output is the set of original inputs that can influence it.
A later layer combines neighboring outputs whose input windows overlap. Their union reaches farther than any single window.
The receptive-field width depends on both kernel width and depth.
Claim: On an unbounded signal with stride one, no dilation, integer \(k\geq1\), and integer \(L\geq0\), the maximum receptive-field width after \(L\) width-\(k\) layers is \[ 1+L(k-1). \]
Proof
Before any convolution, one representation depends on one input, so \(R^{(0)}=1\). If an output after \(l\) layers can depend on a contiguous block of width \(R^{(l)}\), the next width-\(k\) layer reads \(k\) adjacent such outputs. Consecutive blocks start one input position apart, so their union begins with the first block and extends \(k-1\) positions beyond it. Therefore \[ R^{(l+1)}=R^{(l)}+(k-1). \] Starting from \(R^{(0)}=1\) and applying the recurrence \(L\) times gives \(R^{(L)}=1+L(k-1)\). This proves the formula.
If a decision needs evidence separated by more than \(L(k-1)\) positions, an \(L\)-layer width-\(k\) stack has no path that can combine it.
The receptive field contains inputs that can affect the output. An input inside the field may have little effect after learned weights and nonlinearities. An input outside it has no computational path to the output. Distant interactions can therefore require many local layers.
Translation Equivariance
Weight sharing has a mathematical consequence. If the input shifts by one position, every local window shifts by one position and the output shifts with it. This is translation equivariance: \[ \operatorname{Conv}(\operatorname{Shift}(\mathbf x)) =\operatorname{Shift}(\operatorname{Conv}(\mathbf x)). \] Equivariance means the representation moves predictably with the input. It differs from invariance, in which the final answer does not move at all. A classifier can obtain approximate shift invariance later by pooling or averaging spatial responses, but the convolutional layers first preserve where a feature was found.
Segmentation usually needs equivariance because shifting an object should shift its predicted mask. Classification often seeks invariance because the final label should remain unchanged.
Boundaries require a convention because an ordinary shift can discard data. Circular indexing temporarily removes that ambiguity, so the following result isolates what weight sharing itself guarantees before a padding rule complicates the edges.
Claim: With circular wraparound, a shared convolution \(\mathbf C\) commutes with every integer shift \(\mathbf S_q\): \[ \mathbf C\mathbf S_q=\mathbf S_q\mathbf C. \]
Proof
Index a length-\(n\) signal modulo \(n\), so \(x_{i+n}=x_i\) for every integer \(i\). For any integer \(q\), define the circular shift by \((\mathbf S_q\mathbf x)_i=x_{i-q}\) for \(i=1,\ldots,n\). The circular convolution has \(n\) outputs and is a weighted sum of shifts: \[ \mathbf C=\sum_{j=1}^k w_j\mathbf S_{1-j}, \qquad \mathbf C,\mathbf S_q\in\mathbb R^{n\times n}, \] because \((\mathbf S_{1-j}\mathbf x)_i=x_{i+j-1}\). Shifts commute: for any integers \(p,q\), composing them adds their offsets, so \(\mathbf S_p\mathbf S_q=\mathbf S_{p+q}=\mathbf S_q\mathbf S_p\). Distributing through the finite sum therefore gives \[ \begin{aligned} \mathbf C\mathbf S_q &=\sum_{j=1}^k w_j\mathbf S_{1-j}\mathbf S_q\\ &=\sum_{j=1}^k w_j\mathbf S_q\mathbf S_{1-j} =\mathbf S_q\mathbf C. \end{aligned} \] Weight sharing makes the coefficients \(w_j\) independent of position, which is what lets convolution use this fixed combination of shifts.
The comparison below uses a circular input shift in both cases.
A circular convolution commutes with a circular shift. Zero padding changes boundary neighborhoods and can break that equality.
Circular convolution respects the circular shift. Zero padding creates an edge where the operations can disagree.
Zero padding or cropping breaks exact shift symmetry at an ordinary image boundary, while the shared kernel remains equivariant in the interior.
A convolution learns one local rule and applies it across positions. Depth enlarges the region those rules can combine, and translation equivariance states how their representation moves with the input.