Gradient Clipping
What is Gradient Clipping?
In one sentence: Gradient clipping limits how large gradients can get, so one bad batch cannot cause a huge, damaging update.
Sometimes gradients suddenly become enormous, which can wreck a model's learning in one step. Clipping caps them at a maximum size, like a speed limit for updates.
What does Gradient Clipping look like?
If a gradient's size hits 50 but the clip limit is 1, it is shrunk down to size 1 while keeping its direction.
Why does Gradient Clipping matter?
Clipping keeps training stable, especially for large language models.
Last updated · Fact-checked by The AI Math
Linking to this page from a lesson or article? <a href="https://getaimath.com/dictionary/gradient-clipping/">Gradient Clipping, explained simply</a> (The AI Math Dictionary)