leaky_relu

dragon.vm.tensorflow.nn.leaky_relu(
  features,
  alpha=0.2,
  name=None,
  **kwargs
)[source]

Apply the leaky rectified linear unit.

The LeakyReLU function is defined as:

\[\text{LeakyReLU}(x) = \begin{cases} x, & \text{ if } x \geq 0 \\ \alpha * x, & \text{ otherwise } \end{cases} \]
Parameters:
  • features (dragon.Tensor) The input tensor.
  • alpha (number, optional, default=0.2) The value to \(\alpha\).
  • name (str, optional) The operation name.
Returns:

dragon.Tensor The output tensor.