-
Notifications
You must be signed in to change notification settings - Fork 211
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
Align structure of the components with PyPSA consistency checks #1315
Conversation
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 for taking care of this!
A possible comment and we are ready to go!
Please add a line in the release note
scripts/base_network.py
Outdated
@@ -492,6 +492,10 @@ def base_network( | |||
lines_ac = lines[lines.tag_frequency.astype(float) != 0].copy() | |||
lines_dc = lines[lines.tag_frequency.astype(float) == 0].copy() | |||
|
|||
# avoiding the conflicts in processing the network model |
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.
Instead of dropping tag_frequency here, we could drop it in build_osm_nwtwork and rely on the "dc" column in base_networl instead.
What do you think?
In build osm, we have both the dc and tag_frequency columns that are passed to base_network.
Probably, we can drop tag frequency in build and rely on dc column
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.
Ahh, I see! We now have calculation of dc
column directly in clean_osm
script, so it's basically a duplication in base_network
! Agree, no need then to keep tag_frequency
up to base_network
. Thanks a lot for checking it!
Revised 🙂
Thanks @ekatef :D |
A possible solution of the issues caused by AssertionErrors in PyPSA, like #1308.
Changes proposed in this Pull Request
The updated PyPSA version has more strict requirements towards the component structure which can easily lead to errors in case when
n.lines
andn.buses
contains any "extra" fields. The PR aims to drop all the columns afterbase_network
to make the workflow more robust.Checklist
envs/environment.yaml
anddoc/requirements.txt
.config.default.yaml
andconfig.tutorial.yaml
.test/
(note tests are changing the config.tutorial.yaml)doc/configtables/*.csv
and line references are adjusted indoc/configuration.rst
anddoc/tutorial.rst
.doc/release_notes.rst
is amended in the format of previous release notes, including reference to the requested PR.