An Interactive Journey Inside Neural Networks
Imagine your brain is made of billions of tiny decision-makers called neurons. Each neuron:
An AI neural network works the same way! It's like a simplified brain made of math. Let's see it in action!
A neural network is a function approximator that transforms inputs through layers of neurons:
Where:
Watch an AI learn the XOR problem in real-time! XOR outputs 1 when inputs are different, 0 when same.
The network makes a prediction by passing data forward through each layer:
When the network is wrong, it learns by adjusting its connections:
For each layer l:
Where a[0] = x (input) and a[L] = ŷ (output)
Loss function (Mean Squared Error):
Gradient computation:
Weight update:
Weights are like volume knobs - they control how much each input matters.
Biases are like thresholds - they decide when a neuron should activate.
These decide if a neuron should "fire" or not:
Imagine you're blindfolded on a hill, trying to reach the bottom:
ReLU:
Sigmoid:
Tanh:
Where: