Contents

leakyReLU(negativeSlope:)

Creates an instance of a leaky ReLU activation layer using the angle of the negative slope you specify.

Declaration

class func leakyReLU(negativeSlope: Float) -> Self

Parameters

  • negativeSlope:

    The angle of the negative slope.

Return Value

A new MLCActivationLayer instance.

Discussion

The leakyReLU(negativeSlope:) factory type method creates an activation descriptor using init(type:a:), where type = MLCActivationType.relu and a = negativeSlope, and passes that descriptor to init(descriptor:).

See Also

Factory Methods