Kyushik / Predictive-Uncertainty-Estimation-using-Deep-Ensemble

This repository is the code for Predictive Uncertainty Estimation using Deep Ensemble
148 stars 31 forks source link

The warning "raise ValueError('There is Nan in loss')" #2

Open Leezzzz opened 3 years ago

Leezzzz commented 3 years ago

Hello, I'm having some problems.There's always a warning "raise ValueError('There is Nan in loss')".This may be due to the presence of infinity in the calculation of the exp(),but i don't kown how to solved it. Could you help me?

Kyushik commented 3 years ago

Hello. Can you tell me which code has that value error??

Leezzzz commented 3 years ago

Here is the code,it It appears in the "training","raise ValueError('There is Nan in loss')"

TengMichael commented 3 years ago

I also have the same problem, please fix it.

TengMichael commented 3 years ago

I have fixed it by replacing "tf.contrib.layers.xavier_initializer()" with "tf.truncated_normal_initializer(stddev=0.01)".

Leezzzz commented 3 years ago

Thank you very much!!!!!

ameeguy commented 1 year ago

Hello, I am also getting the "raise ValueError('There is Nan in loss')" when I tried to adapt the (Ensemble Regression RealData.ipynb) with my data. Can you please suggest a way to fix the code?