Documentation
¶
Index ¶
Constants ¶
View Source
const ( MethodMinMax = "minmax" // 最小-最大归一化(线性缩放) MethodZScore = "zscore" // Z-Score标准化 MethodRobust = "robust" // 鲁棒标准化 MethodL2 = "l2" // L2正则化(单位向量) MethodLog = "log" // 对数变换 MethodQuantileUniform = "quantile_uniform" // 映射到均匀分布 MethodQuantileNormal = "quantile_normal" // 映射到正态分布 )
归一化方法常量定义
Variables ¶
View Source
var ( ErrEmptyData = errors.New("data cannot be empty") ErrInvalidMethod = errors.New("invalid normalization method") ErrConstantFeature = errors.New("feature has constant value (zero variance)") ErrInsufficientData = errors.New("insufficient data points for quantile transformation") )
自定义错误类型
Functions ¶
func Normalize ¶ added in v0.8.6
Normalize 归一化入口函数 方法选择建议:
- 异常值多 → 鲁棒标准化、分位数变换
- 稀疏数据 → L2正则化、绝对最大值归一化
- 深度学习 → 最小-最大(适配Sigmoid/ReLU)
- 正态假设 → Z-Score或分位数正态变换
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.