Sharma S. - Activation Functions in Neural Networks
Sharma S. - Activation Functions in Neural Networks
Save
It’s just a thing function that you use to get the output of node. It is also known as Transfer
Function.
It is used to determine the output of neural network like yes or no. It maps the resulting
Open in app Get started
Equation : f(x) = x
Open in app Get started
It makes it easy for the model to generalize or adapt with variety of data and to
differentiate between the output.
The main reason why we use sigmoid function is because it exists between (0 to 1).
Therefore, it is especially used for models where we have to predict the probability as
an output.Since probability of anything exists only between the range of 0 and 1,
sigmoid is the right choice.
The function is differentiable.That means, we can find the slope of the sigmoid curve
at any two points.
The logistic sigmoid function can cause a neural network to get stuck at the training
time.
The softmax function is a more generalized logistic activation function which is used
for multiclass classification.
The advantage is that the negative inputs will be mapped strongly negative and the
zero inputs will be mapped near zero in the tanh graph.
Both tanh and logistic sigmoid activation functions are used in feed-forward nets.
As you can see, the ReLU is half rectified (from bottom). f(z) is zero when z is less than
zero and f(z) is equal to z when z is above or equal to zero.
Range: [ 0 to infinity)
But the issue is that all the negative values become zero immediately which decreases
the ability of the model to fit or train from the data properly. That means any negative
input given to the ReLU activation function turns the value into zero immediately in the
graph, which in turns affects the resulting graph by not mapping the negative values
appropriately.
4. Leaky ReLU
It is an attempt to solve the dying ReLU problem
Open in app Get started
The leak helps to increase the range of the ReLU function. Usually, the value of a is 0.01
or so.
Both Leaky and Randomized ReLU functions are monotonic in nature. Also, their
derivatives also monotonic in nature.
If you liked it
Any comments or if you have any questions, write them in the comment.
12.4K 49
Monte Carlo Tree Search
MCTS For Every Data Science Enthusiast
towardsdatascience.com
Every Thursday, the Variable delivers the very best of Towards Data Science: from hands-on tutorials
and cutting-edge research to original features you don't want to miss. Take a look.