✳ BETWEEN QUESTIONS ML STUDY ATLAS

A QUESTION-LED LESSON

ResNet: Why Add a Shortcut Across Layers?

As networks get deeper, training can become harder. Can a shortcut give information another path?

The residual idea

A residual block can write its output as y = x + F(x). The branch F learns a change relative to the input. If F outputs zero and dimensions match, this block returns its input.

A tiny block

In the example F(x) = ax. The output is (1 + a)x. You can change a and see the direct path and residual branch combine. A real ResNet contains many layers and uses more than this scalar operation. The two paths meet at addition: the input can travel directly while the branch contributes a change.

INTERACTIVE EXPLORATION

Compare the paths

For x = 2 and F(x) = ax, adjust the residual parameter a.

Why does this help?

Residual connections helped researchers train deeper image recognition networks. They are not a promise that all deeper networks will train well, and the skip path may require a projection when dimensions change.

Check your understanding

If the residual branch is zero and dimensions match, what is the block output?

It equals the input.

Keep exploring

How does a residual connection work? ↗How does a CNN detect patterns? ↗

Further reading

Source and further reading ↗