mlx.nn.CELU#

class CELU(alpha=1.0)#
Applies the Continuously Differentiable Exponential Linear Unit.

Applies \(\max(0, x) + \min(0, \alpha * (\exp(x / \alpha) - 1))\) element wise.

See celu() for the functional equivalent.

Parameters:

alpha – the \(\alpha\) value for the CELU formulation. Default: 1.0

Methods