You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Improve docstring or behavior for irradiance.get_total_irradiance and irradiance.get_sky_diffuse #949
pvlib.irradiance.get_total_irradiance accepts kwargs dni_extra and airmass, both default to None. However, values for these kwargs are required for several of the irradiance transposition models.
changed the title [-]Improve docstring for `irradiance.get_total_irradiance`[/-][+]Improve docstring for irradiance.get_total_irradiance and irradiance.get_sky_diffuse[/+]on Apr 2, 2020
@mikofski proposed calculating values if needed and not provided.
@kanderso-nrel proposed a couple of solutions to provide more informative error messages: 1. hard coding the failure modes in get_sky_diffuse and 2. using a decorator to communicate the failure modes.
And repeating my take from the thread:
I'd rather not introduce the complexity of decorators to the lower level pvlib functions to solve this problem.
Ideas that I support:
calculate if not provided (Mark's original idea)
reraising a more informative message.
require all of the arguments in get_sky_diffuse and get_total_irradiance regardless of whether or not they're used.
remove the arguments from get_sky_diffuse and get_total_irradiance and do the calculation if it's needed
remove get_sky_diffuse and get_total_irradiance. I'm not convinced they're a net positive for the library. (let's try to fix it before throwing up our hands)
Does someone want to tackle this in 0.8.0 or should we kick it down the road?
I think it's tempting to add it in v0.8, but I'm in favor of freezing features now and pushing out the release sooner with the features we already have queued. It's been a while, and I think we should deploy more often with less features per release. I believe this will make it easier to blame issues and get more testing done on new features and fixes faster.
changed the title [-]Improve docstring for irradiance.get_total_irradiance and irradiance.get_sky_diffuse[/-][+]Improve docstring or behavior for irradiance.get_total_irradiance and irradiance.get_sky_diffuse[/+]on Sep 6, 2020
Activity
[-]Improve docstring for `irradiance.get_total_irradiance`[/-][+]Improve docstring for irradiance.get_total_irradiance and irradiance.get_sky_diffuse[/+]kandersolar commentedon Apr 3, 2020
Consider also specifying it is relative airmass.
wholmgren commentedon Sep 5, 2020
This came up again in @mikofski's thread here.
@mikofski proposed calculating values if needed and not provided.
@kanderso-nrel proposed a couple of solutions to provide more informative error messages: 1. hard coding the failure modes in
get_sky_diffuseand 2. using a decorator to communicate the failure modes.And repeating my take from the thread:
I'd rather not introduce the complexity of decorators to the lower level pvlib functions to solve this problem.
Ideas that I support:
remove get_sky_diffuse and get_total_irradiance. I'm not convinced they're a net positive for the library.(let's try to fix it before throwing up our hands)Does someone want to tackle this in 0.8.0 or should we kick it down the road?
mikofski commentedon Sep 5, 2020
I think it's tempting to add it in v0.8, but I'm in favor of freezing features now and pushing out the release sooner with the features we already have queued. It's been a while, and I think we should deploy more often with less features per release. I believe this will make it easier to blame issues and get more testing done on new features and fixes faster.
mikofski commentedon Sep 5, 2020
I'll volunteer to take this up for v0.8.1, since I was the complainer.
[-]Improve docstring for irradiance.get_total_irradiance and irradiance.get_sky_diffuse[/-][+]Improve docstring or behavior for irradiance.get_total_irradiance and irradiance.get_sky_diffuse[/+]wholmgren commentedon Sep 28, 2020
PVSystem.get_irradiancehas some relevant shim code:pvlib-python/pvlib/pvsystem.py
Lines 289 to 294 in 04a523f