pvlib-python icon indicating copy to clipboard operation
pvlib-python copied to clipboard

CEC module library is behind current version in SAM

Open kandersolar opened this issue 3 years ago • 7 comments

As discussed in https://github.com/pvlib/pvlib-python/discussions/1344, the CEC module table shipped with pvlib (SAM 2018.11.11 r2, 1/3/2019) is behind the latest version shipped with SAM (SAM 2020.2.29 r3, 11/25/2020).

@mikofski in https://github.com/pvlib/pvlib-python/issues/440 you brought up pvfree -- any thoughts there this time around?

Relevant:

  • https://github.com/NREL/SAM/issues/17
  • https://github.com/pvlib/pvlib-python/issues/769
  • https://github.com/pvlib/pvlib-python/issues/761

kandersolar avatar Nov 29 '21 17:11 kandersolar

It's possible to update pvfree by clicking the admin pulldown, selecting upload, and uploading the desired csv. IMO some advantages of using pvfree or something similar:

  1. library updates don't require a pvlib re-release if the two are decoupled
  2. pvfree db doesn't allow integrity or validation errors, meaning, you can't upload the same file twice or put a string in a number field
  3. human readable, searchable, filterable
  4. API has built in filters that make it easier to locate desired module(s) or inverter(s)
  5. uses off the shelf, vanilla packages (django, tastypie) and 3rd party zero-admin webhosting and deployment (github, heroku) and database tools (elephantSQL). This means pvfree has built in convenience tools like admin page, filtering, security updates, etc. which lowers maintainer burden.

mikofski avatar Nov 29 '21 22:11 mikofski

see https://github.com/BreakingBytes/pvfree/issues/34 might need to update this table in the source, easy pr

mikofski avatar Dec 01 '21 01:12 mikofski

library updates don't require a pvlib re-release if the two are decoupled

+1. But that feels like a breaking change even if it's not a real API issue, so I'll make the same suggestion for a short term solution as in #440: make a minor pvlib release with the new files AND update pvfree.

https://github.com/pvlib/pvmodules is also relevant. I don't recall if there was a block other than lack of time. @cwhanse?

wholmgren avatar Dec 01 '21 15:12 wholmgren

I don't recall if there was a block other than lack of time.

That's mostly it. NREL also wants to open source the production of the CEC module file. @janinefreeman

cwhanse avatar Dec 01 '21 16:12 cwhanse

library updates don't require a pvlib re-release if the two are decoupled

+1. But that feels like a breaking change

Perhaps that concern could be addressed by pvfree exposing multiple versions of the CEC table via a new API parameter, similar to how the PSM3 API has tmy-2018 and such. Then code that specifies cecdb='2018.11.11' (or whatever) would behave the same even after a new version of the table is added.

kandersolar avatar Jan 24 '22 01:01 kandersolar

As an interim, we could update the file distributed with pvlib-python to the current SAM release.

cwhanse avatar Mar 24 '22 19:03 cwhanse

SAM 2022.11.21 is released with updated module and inverter libraries: https://github.com/NREL/SAM/tree/patch/deploy/libraries

cwhanse avatar Dec 09 '22 19:12 cwhanse