1.常用损失函数公式
平方差损失
L ( y , f ( x ; θ ) ) = ( y − f ( x ; θ ) ) 2 L(y,f(x;\theta))=(y-f(x; \theta))^2 L(y,f(x;θ))=(y−f(x;θ))2
绝对值损失
L ( y , f ( x ; θ ) ) = ∣ ∣ y − f ( x ; θ ) ∣ ∣ L(y,f(x;\theta))=||y-f(x; \theta)|| L(y,f(x;θ))=∣∣y−f(x;θ)∣∣
指数损失
L ( y , f ( x , θ ) ) = e − y f ( x ; θ ) L(y,f(x,\theta))=e^{-yf(x;\theta)} L(y,f(x,θ))=e−yf(x;θ)
log-likelihood (对数似然)
K分类问题:(两种写法)
log-likelihood表达的是已知样本X在分类Y的情况下,使概率P(Y|X)达到最大值,每种样本属于真实标记的概率越大越好
L ( y , p ( Y = y ∣ x ; θ ) ) = − log p ( y ∣ x ; θ ) L(y,p(Y=y|x;\theta))=-\log_{ }p(y|x;\theta) L(y