sparse gradient in text classification with pytorch

76 views Asked by At

I am trying to train a text classification module.

When I use Adam, RAdam, or RMSProp for my optimizer, I get the following error:

RuntimeError: Adam/RAdam/RMSProp does not support sparse gradients

So I tried using SparseAdam and I got this error:

RuntimeError: SparseAdam does not support dense gradients, please consider Adam instead

How can I solve this issue?

0

There are 0 answers