Build Neural Network From Scratch
Neuron arithmetic, weights as dials, and vectorized NumPy operations.

How does a single artificial neuron convert an input vector into an activated scalar output?
Open lesson →
What actually is a weight, and why does changing it rotate a decision boundary in space?
Open lesson →
How does an error at the final output know which specific weight in the first layer caused the mistake?
Open lesson →
Why is `np.dot` orders of magnitude faster than a Python `for` loop, and what hardware mechanics make it possible?
Open lesson →
Why did simple gradient descent fail on deep landscapes, and how did Adam solve it?
Open lesson →
Why do stacks of pure linear layers collapse into a single trivial matrix multiplication, and how do non-linear activations warp vector space to solve non-linear problems?
Open lesson →
How do input feature vectors propagate forward through multi-layer parameter matrices and non-linearities to produce calibrated output scores?
Open lesson →
How do unconstrained scalar outputs get converted into calibrated probability distributions, and why does categorical cross-entropy provide the optimal loss surface for classification?
Open lesson →
How do partial derivatives combine into gradient vectors that navigate high-dimensional non-convex loss surfaces, and why is gradient descent infinitely superior to random search?
Open lesson →
Why do high-dimensional error surfaces dominate with saddle points and ill-conditioned ravines rather than isolated local minima?
Open lesson →
How does the multivariate chain rule reverse-propagate error gradients from a scalar loss back through hundreds of matrix multiplications and non-linearities?
Open lesson →
How does the chain rule decompose multi-layer neural network credit assignment into local gear ratios?
Open lesson →
Why does standard gradient descent oscillate helplessly in high-curvature valleys, and how do physical momentum and adaptive coordinate scaling unite into Adam and AdamW?
Open lesson →
Why do fully-connected layers fail catastrophically on 2D images, and how do localized kernels, stride, and padding extract translation-invariant spatial features?
Open lesson →
Why do deep networks suffer from unstable gradient flow when layer input distributions shift during training, and how does normalization smooth the loss landscape?
Open lesson →
Why do deep neural networks overfit when individual neurons co-adapt to fix each other's mistakes, and how does randomly zeroing activations force robust, distributed representations?
Open lesson →
How do mathematical penalties on weight magnitudes prevent overfitting, and why does L1 create exact zeros while L2 shrinks weights smoothly?
Open lesson →
Why is a static learning rate catastrophic for deep neural convergence, and how do step decay versus continuous exponential schedules dynamically balance fast exploration with asymptotic refinement?
Open lesson →
How do non-linear activation functions modulate backward error flow, and why does ReLU masking preserve gradient highway conductivity while Sigmoid triggers exponential vanishing?
Open lesson →
How do prediction errors transform into initial gradient vectors at the exit of a neural network during backpropagation?
Open lesson →
How does the miracle cancellation softmax cross entropy (coming in some time) solve the underlying computational bottleneck?
Open lesson →
Master mini-batch SGD optimization dynamics, gradient covariance noise, learning rate scaling laws, and high-dimensional parameter trajectories.
Open lesson →
Why does vanilla SGD oscillate wildly in ill-conditioned ravines, and how does physical momentum accumulate velocity along consistent gradient directions?
Open lesson →
How does AdaGrad dynamically scale learning rates coordinate-by-coordinate, and why does monotonic sum-of-squares accumulation kill learning prematurely?
Open lesson →
How does replacing AdaGrad's infinite sum with an Exponential Moving Average prevent learning rate suffocation, and how does leaky memory stabilize non-convex optimization?
Open lesson →
How does the 4 step rolling bowling ball journey (coming in some time) solve the underlying computational bottleneck?
Open lesson →
Why does driving training loss to zero frequently ruin test set performance, and how do empirical risk minimization versus true risk diverge?
Open lesson →
How does K-Fold Cross-Validation produce low-variance performance estimates on small datasets without data leakage?
Open lesson →
Why does the geometric intersection of loss contours with constraint norms force weights to exact zero under L1 while shrinking them smoothly under L2?
Open lesson →
How does randomly dropping neurons during training mathematically approximate an ensemble of 2^N subnetworks with shared weights?
Open lesson →
How do data normalization, multi-layer forward propagation, cross-entropy backpropagation, and Adam optimization unite to classify complex real-world clothing images?
Open lesson →
How do hardware abstraction layers, dynamic computational graphs, and GPU CUDA kernels elevate deep learning from pure Python to scalable production systems?
Open lesson →
How do neural architectures adapt from discrete probability classification to continuous unbounded regression, and how do Mean Squared Error loss and R^2 coefficient quantify performance?
Open lesson →