L2 regularization

Optimization · Formula · Appears in 1 lesson

Ltotal=L+λ∥θ∥22L_{\text{total}} = L + \lambda \|\theta\|_2^2

Adds the squared size of the weights to the loss, so the optimiser pays for complexity. It shrinks every weight toward zero without quite reaching it, which spreads influence across features rather than concentrating it.

Symbols

λ\lambda
The regularisation strength.
∥θ∥22\|\theta\|_2^2
The sum of squared weights.
Esc
↑↓ navigate↵ open? shortcuts

Keyboard shortcuts

Press Esc to close

Anywhere

⌘K
Search and commands
/
Search
?
This sheet
Esc
Close

Reading a lesson

J
Next lesson
K
Previous lesson
B
Bookmark