Unit 6 — Activation functions
Give the hidden neuron a rule for negative numbers.
By Charles Joseph · Updated
Share
Share
Copy Link
In this article
Close
An activation function is a rule a neuron applies to its result. Our hidden neuron multiplies, adds its bias, then applies a rule called ReLU.
ReLU stands for rectified linear unit. Here's the whole rule.
- If the number is negative, return 0.
- Otherwise, return the number itself.
See the bend at zero? Bends like this let a network learn patterns a straight line would miss.
| Before ReLU | After ReLU |
|---|---|
| −3 | 0 |
| 0 | 0 |
| 3 | 3 |
Give our hidden neuron 1. With a weight of 1 and a bias of 0, it gets (1 × 1) + 0 = 1. ReLU passes that 1 to the output neuron.
Exercise
What comes out if −2 goes into ReLU? Try it. Then try 2.
QUOTE:
"Amateurs hack systems, professionals hack people."