Documentation
¶
Overview ¶
Package math provides SIMD-accelerated mathematical transforms for the dataset engines.
Slice transforms apply a transcendental function element-wise to an entire slice using SIMD vectorization (AVX-512, AVX2, NEON, or scalar fallback).
Vector-level functions operate on individual SIMD register vectors for use in custom compute kernels.
All functions are generic over hwy.Floats (float32, float64, Float16, BFloat16) and provide ~4 ULP accuracy.
Index ¶
- func Cos[T hwy.Floats](dst, src []T)
- func Erf[T hwy.Floats](dst, src []T)
- func Exp[T hwy.Floats](dst, src []T)
- func Log[T hwy.Floats](dst, src []T)
- func Sigmoid[T hwy.Floats](dst, src []T)
- func Sin[T hwy.Floats](dst, src []T)
- func Tanh[T hwy.Floats](dst, src []T)
- type Vec
- func AcoshVec[T hwy.Floats](v Vec[T]) Vec[T]
- func AsinhVec[T hwy.Floats](v Vec[T]) Vec[T]
- func AtanhVec[T hwy.Floats](v Vec[T]) Vec[T]
- func CosVec[T hwy.Floats](v Vec[T]) Vec[T]
- func CoshVec[T hwy.Floats](v Vec[T]) Vec[T]
- func ErfVec[T hwy.Floats](v Vec[T]) Vec[T]
- func Exp2Vec[T hwy.Floats](v Vec[T]) Vec[T]
- func ExpVec[T hwy.Floats](v Vec[T]) Vec[T]
- func Log2Vec[T hwy.Floats](v Vec[T]) Vec[T]
- func Log10Vec[T hwy.Floats](v Vec[T]) Vec[T]
- func LogVec[T hwy.Floats](v Vec[T]) Vec[T]
- func PowVec[T hwy.Floats](base, exp Vec[T]) Vec[T]
- func SigmoidVec[T hwy.Floats](v Vec[T]) Vec[T]
- func SinVec[T hwy.Floats](v Vec[T]) Vec[T]
- func SinhVec[T hwy.Floats](v Vec[T]) Vec[T]
- func TanhVec[T hwy.Floats](v Vec[T]) Vec[T]
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Vec ¶
Vec is the SIMD vector type re-exported for convenience.
func SigmoidVec ¶
SigmoidVec computes 1/(1+e^(-v)) element-wise on a SIMD vector.
Click to show internal directories.
Click to hide internal directories.