Skip to main content

Module softmax

Module softmax 

Source
Expand description

Softmax kernel: numerically stable exponential normalization.

Matches softmax-kernel-v1.yaml. Four phases: find_max -> exp_subtract -> sum_exp -> normalize.

Functions§

softmax_avx2
AVX2 SIMD implementation of numerically stable softmax.
softmax_ptx
PTX assembly for softmax kernel.
softmax_scalar
Scalar reference implementation of numerically stable softmax.