-
Notifications
You must be signed in to change notification settings - Fork 267
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
Add an option to overwrite cost attributes from the configuration file. #1532
base: master
Are you sure you want to change the base?
Conversation
…and load_costs (PyPSA#23) * overwrite cost table attributes specified in config in prepare_costs and load_costs * add custom fuel prices from EEE project --------- Co-authored-by: Thomas Gilon <[email protected]> (cherry picked from commit 926f763)
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.
LGTM
@@ -851,7 +851,7 @@ costs: | |||
lifetime: 25 | |||
"CO2 intensity": 0 | |||
"discount rate": 0.07 | |||
# Marginal and capital costs can be overwritten | |||
# Marginal and capital costs, investment, lifetime, FOM, VOM, efficiency and fuel can be overwritten |
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.
wondering if those overwrites could be packaged into
costs:
overwrites:
marginal_cost: ...
even though this would be a breaking change for marginal_cost
and capital_cost
.
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.
This is why I avoided it. But I had the same idea, to be honest. As you prefer
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.
Let's hear another opinion @FabianHofmann @lkstrp
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.
I would prefer a dedicated section, too. and this breaking change would be "softened" by the json schema since the user will get a clear message that the old place is not supported 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.
Agree, that should go in overwrites
. But I would leave it non breaking for now (just move new attributes to overwrites
and break once we have the deprecation messages.
Also, shouldn't fill_values
(defaults
is a better name here) and overwrites
then allow for the exact same keys?
Changes proposed in this Pull Request
This PR suggests to add an options to overwrite investment, lifetime, FOM, VOM, efficiency and fuel attributes from the configuration file. This mimics the existing capital and marginal cost behaviour.
Checklist
envs/environment.yaml
.config/config.default.yaml
.doc/configtables/*.csv
.doc/data_sources.rst
.doc/release_notes.rst
is added.