ggml_soft_max_ext_inplace: Extended Softmax Inplace (Graph)

View source: R/operations.R

ggml_soft_max_ext_inplaceR Documentation

Extended Softmax Inplace (Graph)

Description

Creates a graph node for extended softmax, modifying input tensor in place. Returns a view of the input tensor.

Usage

ggml_soft_max_ext_inplace(ctx, a, mask = NULL, scale = 1, max_bias = 0)

Arguments

ctx

GGML context

a

Input tensor (typically attention scores)

mask

Optional attention mask tensor (F16 or F32). NULL for no mask. Shape must be broadcastable to input tensor.

scale

Scaling factor, typically 1/sqrt(head_dim)

max_bias

Maximum ALiBi bias (0.0 to disable ALiBi)

Value

View of input tensor with softmax applied in place

See Also

Other softmax: ggml_soft_max_ext_back_inplace()


ggmlR documentation built on July 14, 2026, 1:08 a.m.