e3x.nn.activations.soft_sign
- e3x.nn.activations.soft_sign(x)[source]
Soft-sign activation function.
Computes the gated linear activation with:
\[\mathrm{gate}(x) = \frac{1}{|x| + 1}\]For scalar inputs, this is equivalent to:
\[\mathrm{soft\_sign}(x) = \frac{x}{|x| + 1}\]- 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.