[P] A small MLP from scratch in NumPy with a GUI to look inside it while it trains (weight distributions, t-SNE per layer, neuron ablation...) [P]
Mirrored from r/MachineLearning for archival readability. Support the source by reading on the original site.
| Hi everyone, I built an educational tool that shows what happens inside a small MLP while it trains, and I'd like some feedback from people who teach ML. Everything is plain NumPy, no autograd: manual backprop, SGD with momentum, L2, dropout, cosine decay and 4 activations. On MNIST it gets to about 98.5% with the full training set. During training you see the loss per mini-batch and per epoch, the gradient norm of each layer with the % of inactive neurons, the weight distributions now vs at init and the receptive fields of the first layer. Then there's: • a PCA / t-SNE of the test set (in NumPy too), layer by layer, with a line from each wrong prediction to the cluster of the digit it was confused with • robustness curves for noise and rotation, plus a confidence threshold that shows coverage vs accuracy • a lab where you ablate or rescale single neurons, prune, add noise to the weights or change the softmax temperature, and the test accuracy updates right away I'd like it to be useful to students, from high school to intro ML courses, to people who learn on their own and to teachers who want to show a network in class. [link] [comments] |
More from r/MachineLearning
-
How can I turn an industry ML project into a publication? [R]
Sep 28
-
Are there any good research papers around Text clustering using LLMs [R]
Sep 28
-
Free, open-source AI engineering course where you build each algorithm by hand: 523 lessons, now as EPUB/PDF books [P]
Sep 28
-
Two-stage shelf audit: YOLO finds the products, embeddings can't tell sibling SKUS apart. What should Stage 2 be? [P]
Sep 27
Discussion (0)
Sign in to join the discussion. Free account, 30 seconds — email code or GitHub.
Sign in →No comments yet. Sign in and be the first to say something.