Neural Network Playground
A real neural network, forward and backward pass hand-written (no TensorFlow.js, no autograd library — the same from-scratch philosophy as Build From Scratch — A Neural Network), training live in your browser on whichever toy dataset and architecture you choose.
Interactive
Neural Network Playground
Dataset
Activation
Loss
Epoch 0
Loss —
Shape: 2 → 6 → 6 → 1
A real, hand-written forward/backward pass -- no TensorFlow.js -- training live in your browser on whichever toy dataset and architecture you pick.
What to Try
- Start with Blobs — linearly separable, even a single hidden layer solves it almost instantly.
- Switch to XOR with 1 hidden layer — watch it fail to separate the classes no matter how long you train. This is the textbook argument for why depth matters (Neural Network Fundamentals), made concrete instead of asserted. Add a second hidden layer and watch it succeed.
- Compare ReLU vs. tanh on Circles and Moons — notice which converges faster, and how the decision boundary's shape differs (ReLU's piecewise-linear boundary vs. tanh's smoother curves).
- Push the learning rate slider high and watch training destabilize — the same "too large a learning rate" failure mode from the Gradient Descent Explorer, one layer up in a real (if tiny) network.
- Hit Reset Weights on the same configuration a few times — different random initializations can converge to visibly different decision boundaries, direct evidence that initialization (see Weight Initialization) actually matters.
Back to Visual Lab Overview.