What is vanishing gradient and how does LSTM solve it?medium

Type
conceptual
Topic
is-vanishing-gradient-and-how-does-lstm-solve-it
Frequency
common
Tags
deep-learning, what, vanishing, gradient, and, how
Answer

In deep RNNs, gradients shrink exponentially through time — early timesteps get near-zero updates.

Explanation

In deep RNNs, gradients shrink exponentially through time — early timesteps get near-zero updates. LSTM introduces a cell state with additive updates (not multiplicative) and gates (input, forget, output) that regulate what to remember. The forget gate can stay near 1 to preserve gradient flow, avoiding vanishing. GRU is a simpler variant with the same key idea.

Follow-upCan you give a production example?