Version confusions and discrepancies: PVWatts API v6 vs. PySAM v5 vs. v8

  • Kate
  • Topic Author
More
20 May 2022 18:56 #10978 by Kate
Hello, 

We're having confusion about version numbers in the different wrappers for PVWatts. Are the version numbers for PySAM and the PVWatts API correlated or not? For example, it appears the PVWatts API v6 is most current, but PySAM has v5, v7, and v8, but no v6. Is PySAM v8 calling the same underlying version of PVWatts as the PVWatts API v6? 

Here's the background and motivation for this question: we recently did some comparisons of calling TMY data through the PVWatts API to running either TMY or AMY data through PySAM, after downloading the weather data directly from the NSRDB. So, we're comparing using the PVWatts API here:
developer.nrel.gov/docs/solar/pvwatts/v6/
to the pipeline shown here:
Python Examples API | NREL: Developer Network
The Python example calls PySAM v5, which seems to be out of date, and we were concerned by consistent differences in PV power magnitude the PVWatts API v6 and the PySAM outputs. Switching to PySAM v8 appears to have resolved some of those discrepancies. Can you speak to this, and verify what versions to use for consistency between the two pipelines? 

Thank you!

Please Log in or Create an account to join the conversation.

  • Paul Gilman
More
20 May 2022 22:12 - 02 Jun 2022 17:38 #10980 by Paul Gilman
Hi Kate,

PVWatts is a "compute module" or "module" of the SAM Simulation Core (SSC).

There are several ways to access SSC:

  • PySAM is a package for Python programmers.
  • The SAM Software Development Kit ( SDK ) is a set of developer tools for several programming languages, including C++, C#, Java, and others.
  • SAM is a desktop application for energy modelers.

Now for PVWatts version numbers:

  • PVWatts is available in SSC as pvwattsv1, pvwattsv5, pvwattsv7, and pvwattsv8. (There are also "_1ts" versions that run a single-time-step instead of a one-year simulation, and a "_poa" version that uses POA irradiance as input instead of DNI and DHI.)
  • It is available in PySAM as Pvwattsv1, Pvwattsv5, Pvwattsv7, and Pvwattsv8.
  • The PVWatts V6 API and online PVWatts calculator run pvwattsv5.
  • SAM runs pvwattsv8.

The PVWatts V6 API and online PVWatts calculator use a special set of weather files that is different from the files that you can download from the NREL National Solar Radiation Database API and Data Viewer . The special set of files includes data from an early version of the NSRDB and additional files from other sources for locations outside of the NSRDB area.


To get the same results from the PVWatts V6 API and PySAM with Pvwattsv5, use the weather data from the API results as input to PySAM Pvwattsv5. You can use the lat, lon, elev, tz, dn, df, tamb, tcell, and wspd results from the API to either construct a SAM CSV weather file for the PySAM solar_resource_file input, or to construct a dictionary for the solar_resource_data input.

Sorry this is so confusing!

Best regards,
Paul.
Last edit: 02 Jun 2022 17:38 by Paul Gilman.

Please Log in or Create an account to join the conversation.

  • Kate
  • Topic Author
More
20 May 2022 22:52 #10981 by Kate
Hi Paul,

Thank you for the response! A few follow up questions:

"The PVWatts V6 API and online PVWatts calculator use a special set of weather files that is different from the files that you can download from the NREL National Solar Radiation Database  API  and  Data Viewer  . The special set of files includes NSRDB data from 2005 and additional files from other sources for locations outside of the NSRDB area."
This is good to know -- I wondered why you couldn't access AMY data through the PVWatts API. By a "special set of files," do you mean that the TMY data accessible through the PVWatts API is legacy weather data that precedes the Physical Solar Model (PSM) and this gridded TMY version history  NSRDB | Version History (nrel.gov)

"To get the same results from the PVWatts V6 API and PySAM with Pvwattsv5, use the weather data from the API results as input to PySAM Pvwattsv5."
To be sure I understand, does this mean use the weather data that comes along with the PVWatts API, as opposed to weather data from the NSRDB API, as inputs to PySAM? So, the only way to see consistency is to use the legacy TMY weather data, as opposed to the current 1998--2017 TMY weather data, because of the limitations of what weather data you can access with the PVWatts v6 API?

Thank you again!
Cheers,
Kate

Please Log in or Create an account to join the conversation.

  • Paul Gilman
More
23 May 2022 17:45 - 25 May 2022 23:49 #10985 by Paul Gilman
Hi Kate,

The PVWatts weather data is legacy NSRDB data from an early PSM version. I'll need to investigate to be sure, but I think it is from PSM V1 listed in the NSRDB version history.

Yes. If you want to get the same results in PySAM as those from the PVWatts API or online calculator, you have to use the same version of PVWatts and the same weather data. The only way to get the PVWatts weather data is from the PVWatts API results as I describe above. The PVWatts weather data is not available from the NSRDB API because it provides access to PSM V3 data, but not to earlier versions.

To better align the PVWatts API and online calculator weather data with the NSRDB, we plan to update the PVWatts API and online calculator this summer to use PSM V3 TMY weather data (and pvwattsv8). Going forward, depending on available resources, we hope to update the PVWatts weather data each year to use the newest available TMY year. For example, the newest available TMY year now is TMY-2020.

Best regards,
Paul.
Last edit: 25 May 2022 23:49 by Paul Gilman.

Please Log in or Create an account to join the conversation.

Moderators: Paul Gilman
Powered by Kunena Forum