What is backpropagation in a neural network, and what roles do the forward pass and the backward pass play during training?

Deep learning, Backpropagation
Level L1 Beginner. Length Short. Nature Th Theoretical.

What's being asked

Whether you understand how a neural network assigns blame for its errors across layers before computing chain-rule derivatives by hand.

Key idea

Backpropagation (short for backward propagation of errors) is an efficient algorithm that uses the calculus chain rule to compute how much each weight in a network contributed to the final loss. It works in two stages: a forward pass that computes the prediction and loss while saving intermediate activations, followed by a backward pass that sends error signals from the output back to the first layer.

Steps

  1. Explain the forward pass: feed an input batch through the network layer by layer to produce a prediction y^ and measure the loss L against the true target y, caching each layer's intermediate values for the return trip.
  2. Explain the backward pass: starting at the loss L, apply the chain rule layer by layer in reverse to find each weight's gradient ∂L/∂w (how much nudging that weight changes the error).
  3. Give the intuition behind going backward: like a relay race or team review, you first see how wrong the final score is, then pass credit or blame one step back at a time instead of re-running the whole network once per weight.
  4. Separate gradient calculation from weight updates: backpropagation only computes the gradients ∂L/∂w; an optimiser such as stochastic gradient descent (SGD) or Adam then uses those gradients to actually update the weights.

Common mistakes

How long your answer should be

About 2 minutes: define backprop, contrast forward vs backward pass, and separate it from the optimiser.

Read this

Previous in Deep learning: Why can a deep network with no non-linear activation functions represent nothing more than a single linear (affine) layer?
Next in Deep learning: A neural network is trained on 2000 labelled examples with a batch size of 50. What are an epoch, a batch and an iteration, and how many iterations make up one epoch?