Closed InfinityBox closed 2 years ago
I think it is ok to add a small value in this line. Since the following layers are fully learnable, I think it may also be ok to add any positive constant to the denominator of global_x
(e.g., 1) to avoid nan
values.
Thank you so much for your quick response!
It would happen randomly in any epoch. And it still appears after setting a lower learning rate or turning off the amp.
Then I found it usually occurs in module 'PredictorLG', if 'policy' is an all-zero matrix, there will be nan in global_x.
Is it ok to add a very small value in the denominator of the global_x, e.g. 1e-6?