Skip to content

Activations

Source: nn/Activations.luau

Activation functions (functional, no params).

Methods

relu(x: any) -> any

silu(x: any) -> any

gelu(x: any) -> any

tanh(x: any) -> any

sigmoid(x: any) -> any

softmax(x: any, dim: number?) -> any

Softmax over the last dim by default (dim may be given as positive index).