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

fixed bug where power curve losses was shifting power curve to the le… #424

Merged
merged 1 commit into from
Sep 6, 2023

Conversation

grantbuster
Copy link
Member

…ft to acheive losses

@codecov-commenter
Copy link

codecov-commenter commented Sep 6, 2023

Codecov Report

Patch coverage: 91.42% and project coverage change: +0.04% 🎉

Comparison is base (ddc70df) 86.98% compared to head (3a00de5) 87.03%.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #424      +/-   ##
==========================================
+ Coverage   86.98%   87.03%   +0.04%     
==========================================
  Files         122      122              
  Lines       16950    16990      +40     
==========================================
+ Hits        14744    14787      +43     
+ Misses       2206     2203       -3     
Flag Coverage Δ
unittests 87.03% <91.42%> (+0.04%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files Changed Coverage Δ
reV/losses/power_curve.py 93.84% <87.50%> (-0.52%) ⬇️
tests/test_losses_power_curve.py 98.63% <100.00%> (+0.03%) ⬆️

... and 12 files with indirect coverage changes

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Collaborator

@ppinchuk ppinchuk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I tried to poke holes in this but it seems to cover all the cases I could think of so good job! Maybe real data out there will reveal something I overlooked but we can cross that bridge when we get there

new_power_curve = transformation.apply(strength)
mask = new_power_curve.wind_speed >= real_power_curve.wind_speed[-10]
assert (new_power_curve[mask] == 0).all()


@pytest.mark.parametrize('TransClass', TRANSFORMATIONS.values())
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That is a CLEAN test. And tests any future transformations too. Love it.

@grantbuster grantbuster merged commit 4991c3f into main Sep 6, 2023
10 checks passed
@grantbuster grantbuster deleted the gb/power_curve_losses branch September 6, 2023 14:51
@grantbuster
Copy link
Member Author

grantbuster commented Sep 6, 2023

I tried to poke holes in this but it seems to cover all the cases I could think of so good job! Maybe real data out there will reveal something I overlooked but we can cross that bridge when we get there

Just finished CONUS onshore+offshore runs for both Sup3rCC datasets with 0 errors or warnings, i'm encouraged! going to merge.

github-actions bot pushed a commit that referenced this pull request Sep 6, 2023
fixed bug where power curve losses was shifting power curve to the le…
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

Successfully merging this pull request may close these issues.

3 participants