Backprop in Python

Math Fundamentals

A glimpse of Backprop in Python

A model predicts y = wx + b. Its input is x; w and b are numbers we can adjust. We want the prediction to match a target, t.

Use x = 2, w = 3, b = 1 and t = 5. The model predicts 7, which is 2 too high. Squaring that error gives a loss, L = (y − t)² = 4.

Continue learning

Pro unlocks guided learning, complete notes, practical walkthroughs, exercises, and every AI Research lesson.