pingswept/pysolar

RuntimeWarning: invalid value encountered in true_divide KT = (ghi_data / EXTR1)

Opened this issue · 1 comments

Cannot figure out what's causing this warning during testing:

[...]\pysolar\util.py:690: RuntimeWarning: invalid value encountered in true_divide
KT = (ghi_data / EXTR1)

Somehow unit testing succeeds, even though it reads ominously

I’d guess that it’s a divide-by-zero error.

EXTR1 represents extraterrestrial radiation. Generally, that should be around 1366 W/m^2, so it’s probably just being tested weirdly, rather than a real bug in operation.

The line of code in question is here:

KT = (ghi_data / EXTR1)

Patches welcome from everyone, as always.