e3x.nn.activations.selu
- e3x.nn.activations.selu(x)[source]
Scaled exponential linear unit activation.
Computes the gated linear activation with:
\[\begin{split}\mathrm{gate}(x) = \lambda \begin{cases} 1, & x > 0\\ \frac{\alpha}{x} \left(\exp(x) - 1\right), & x \le 0 \end{cases}\end{split}\]where \(\lambda = 1.0507009873554804934193349852946\) and \(\alpha = 1.6732632423543772848170429916717\).
For scalar inputs, this is equivalent to:
\[\begin{split}\mathrm{selu}(x) = \lambda \begin{cases} x, & x > 0\\ \alpha \left(\exp(x) - 1\right), & x \le 0 \end{cases}\end{split}\]For more information, see Self-Normalizing Neural Networks.
- Parameters:
x (
Union[Float[Array, '... 1 (max_degree+1)**2 num_features'], Float[Array, '... 2 (max_degree+1)**2 num_features']]) – Input features to which the nonlinearity is applied.- Return type:
- Returns:
The result of applying the nonlinearity to the input features.