A residual block computes
y=F(x,{Wi})+x — the layer learns the residual
F(x)=H(x)−x instead of the direct map
H(x). In backprop,
∂x∂y=1+∂x∂F: the identity shortcut gives a gradient highway along which the gradient can flow through any number of layers via the constant 1 term, mitigating vanishing gradients (equivalent to ensembling many shallow networks). Degradation: a 56-layer plain network has higher training error than a 20-layer one, and not due to overfitting — the identity map is simply hard to learn; residuals rewrite the goal as 'learn F→0', so deep networks are at least no worse than shallow ones, which is why ResNet-152 trains stably.