Machine Learning & AI
Intermediate

Hinge Loss (SVM)

Loss for support vector machines; zero once a point is correctly classified with margin.

Formula

L=max(0,1yy^)L = \max(0,\,1 - y\,\hat{y})

Variables

yTrue label (-1/+1)
\hat{y}Raw score

Example

y=1, score=1.5: L=0

Did You Know?

Hinge loss only cares about points near or inside the margin — the "support vectors".

Share this formula