Path: blob/master/templates/api/layers/activations.md
3297 views
Layer activation functions
Usage of activations
Activations can either be used through an Activation
layer, or through the activation
argument supported by all forward layers:
This is equivalent to:
All built-in activations may also be passed via their string identifier:
Available activations
{{autogenerated}}
Creating custom activations
You can also use a callable as an activation (in this case it should take a tensor and return a tensor of the same shape and dtype):
About "advanced activation" layers
Activations that are more complex than a simple function (eg. learnable activations, which maintain a state) are available as Advanced Activation layers.