Deep learning visualizer
Activation Functions Visualizer
Explore how activation functions transform neuron values.
TypeNon-linear TransformUsed inHidden & Output LayersInputxOutputf(x)
Activation Function
Activation Function: ReLU
ReLUSigmoidTanhLeaky ReLUSoftmaxGELU
Neuron Example (using ReLU)
Inputs
x10.60x1.20x2-0.40x-0.80x31.00x0.46Weighted sumz = sum(w_i*x_i) + bz = 1.52
Activation (ReLU)a = f(z)a = 1.52
Next layer input1.52Passed forward
Compute weighted sum z = sum(w_i * x_i) + bApply activation function to weighted sumPass output to the next layerOptionally compute derivativeContinue forward or backward pass
Activation Functions Summary
| Function | Description | Formula | Range | Common use |
|---|---|---|---|---|
| ReLU | Fast default activation for deep neural networks. | max(0, x) | [0, infinity) | Hidden layers |
| Sigmoid | Useful for binary classification outputs. | 1 / (1 + e^-x) | (0, 1) | Binary output |
| Tanh | Common in recurrent and older dense networks. | tanh(x) | (-1, 1) | RNNs, hidden layers |
| Leaky ReLU | A ReLU variant that avoids completely zero gradients. | max(0.1x, x) | (-infinity, infinity) | Deep nets |
| Softmax | Used in the output layer for multi-class classification. | e^x_i / sum(e^x_j) | (0, 1) | Multi-class output |
| GELU | Popular in transformers and modern NLP architectures. | x * Phi(x) | (-infinity, infinity) | Transformers |