Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pvwattsv8 broken with major version upgrade from 3.0.2 to 4.x #156

Closed
joules-michael opened this issue Jul 12, 2023 · 7 comments
Closed

Comments

@joules-michael
Copy link

Hello, I am finding that my Pvwattsv8 models are outputting all zeroes after upgrading the package from version 3.0.2 to any of the currently available versions 4.x.

Repro case shown in Google Colab. I can get results comparable to those from the online calculator with 3.0.1 and 3.0.2, but not 4.0.0 through 4.2.0.

None of the parameters referenced in the change log for Pvwattsv8 since 3.0.1 appear to be causing the issue.

@cpaulgilman
Copy link
Collaborator

@joules-michael I confirmed these results and am investigating. Will follow up as soon as I know more.

@brtietz
Copy link
Collaborator

brtietz commented Jul 13, 2023

This rhymes with NREL/ssc#973. That said I'm having trouble identifying which inputs would have changed between versions.

@cpaulgilman
Copy link
Collaborator

This is caused by NREL/ssc#830, which breaks pvwattsv8 for non-annual simulations.

A temporary workaround is to use the output ac_pre_adjust in place of gen.

@joules-michael
Copy link
Author

joules-michael commented Jul 13, 2023

Thank you for your suggestion.

I am finding that I get slightly different results across the two major versions when I compare ac_pre_adjust. Is this expected?

I modified the final line of the forecast function in the repro case, from

        return np.array(system_model.Outputs.gen).reshape(-1, 1)

to

        ac_pre_adjust = np.array(system_model.Outputs.ac_pre_adjust).reshape(-1, 1)
        gen = np.array(system_model.Outputs.gen).reshape(-1, 1) * 1000.0
        return np.concatenate((ac_pre_adjust, gen), axis=1)

So it looks like ac_pre_adjust is equivalent to gen (at least for my toy example), but the values of ac_pre_adjust differ across version 3.x vs 4.x

@cpaulgilman
Copy link
Collaborator

cpaulgilman commented Jul 13, 2023

PySAM Version 4.2.0 (SSC 280) includes this fix to the solar position algorithm that causes small differences in the calculated output for the Pvwattsv8 and other solar performance modules compared to older versions.

@joules-michael
Copy link
Author

Great, thank you for clarifying!

@dguittet
Copy link
Collaborator

@joules-michael We fixed another issue with non-annual simulations for version 5.0.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants