champ icon indicating copy to clipboard operation
champ copied to clipboard

Guidance Encoder received nan gradient during training

Open Jaeger416 opened this issue 4 months ago • 0 comments

When I look in to each parameter's gradient, I found all attention blocks except for the last one in guidance encoder get nan gradient. If not use accelerate just torch distributed, this will lead to error. And then after looking into the encoder's code, I found lots of attention block are initialized, saved or loaded but only the last layer is used in forward process.

Jaeger416 avatar Oct 02 '24 06:10 Jaeger416