Neural Network — Seeing the Mistakes and Fixing the Connections Little by Little

Watch, with pictures and motion, how a network fixes the thickness of its lines (the strength of its connections) little by little while looking at its mistakes against the colors of the points.

With a small network, follow one step at a time, with numbers, the forward pass that computes the output from the input, backpropagation that distributes the gradient of the loss from the output side, and the update that moves the weights along the gradient. Next, change the number of hidden units, the activation function, the learning rate, the minibatch, and the weight decay to observe how training proceeds and the “basis functions that move to fit the data,” and finally check that the backpropagation gradient agrees with the finite-difference approximation.

Can a network separate points of two colors?

The network on the left is a calculating machine that answers “red or blue?” from the position of a point (across and up). Press “▶ Learn” and the thickness of the lines changes little by little, and the answer map on the right comes to match the colors of the points.

These are synthetic data for teaching purposes (the positions and colors of the points are made up).

Back to Machine Learning — From Probability to GPT (Contents) | Text: Chapter 14, Section 14.5, Chapter 15, Section 15.3 | Equations and explanation (explanation page) | Equations are typeset with the browser’s built-in MathML (no external library).