-
Notifications
You must be signed in to change notification settings - Fork 34
Modify storage constraint to compute inflows using _profile_aggregate #1371
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
Conversation
This ensures that all profile aggregation is done through that function, which is a requirement for rolling horizon. Closes #1370
🤖 CompareMPS report✅ MPS files match |
Benchmark Results
Benchmark PlotsA plot of the benchmark results have been uploaded as an artifact to the workflow run for this PR. |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #1371 +/- ##
==========================================
+ Coverage 98.50% 98.61% +0.11%
==========================================
Files 38 38
Lines 1404 1372 -32
==========================================
- Hits 1383 1353 -30
+ Misses 21 19 -2 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, @abelsiqueira, it is looking good so far. I would like to use this change to add a test to this constraint. Maybe you can leverage Claude to get it done fast. The test is that it creates the constraints with a setup where we have:
- 4 seasonal storages:
- 1 with inflows and initial storage level
- 1 without inflows and initial storage level
- 1 without inflows but with initial storage level
- 1 with inflows and without initial storage level
- 1 non-seasonal storage
- 2 milestone years (e.g., 2030 and 2040)
- 2 representative periods per year
- You can have just a week (or a couple of days) in the timeframe to keep it small and simple (check the setup in the Storage Example for the RPs and the timeframe)
The idea is to check that the constraints are the right ones. I hope it is not much of a hassle. It is to cover this edge case that is not currently tested because changes like the ones in this PR will not show any error/problem.
Amazing that we gain in speed 😄 even if it is just a bit 😁 |
|
Hi @datejada, indeed it would be good to test these constraints, although it would make sense to have the tests first, then make the change and see that the tests don't break. I realize that the inflows are only for the over_clustered_years profiles, and I found a way yesterday to only create rolling parameters for rep_period. |
Regarding your comments:
So, I think this is how we should proceed:
What do you think? |
|
Thanks, @datejada. The plan looks good, except that maybe we don't even need this PR anymore. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@abelsiqueira I am approving this PR to merge it, since I will start working again in Tulipa for the #1082 after the release of v0.5.0 in Tulipa Clsutering. So, I will need a new case study such that the one I mentioned in the comments. I will double-check there constraints. This PR is already an improvement on performance, see benchmark. So, I prefer to start from this the new changes in those constraints.
Thanks!
This ensures that all profile aggregation is done through that function, which is a requirement for rolling horizon.
Related issues
Closes #1370
Checklist