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
Config Design #292
Comments
I know I wasn't asked but I do have some thoughts on this :)
More generally speaking (maybe a bit beyond what this issue was meant for), I think a pain point with using pypsa-eur right now is that, loosely speaking, snakemake isn't "aware" that most network files depend on the config. This leads to situations like when you change the One rough idea I came up with is that snakemake could compute a short hash of the This also brings some problems: maybe not all the files had to be regenerated, and keeping track of configs and their hashes might be a bit of work. There is also the pypsa-eur-sec solution: create different named "run" directories which each can have their own config. I would also appreciate some kind of solution like this for pypsa-eur, in order to be able to work with multiple configs conveniently. The "holy grail" would be for the whole workflow to "be aware" of which config changes affect which files, so that I could for example change the Footnotes
|
I like were you're idea is going @FabianHofmann . I'd suggest a small change which would address the first issue @koen-vg is pointing out:
Changes:
I'll try it in my Regarding @koen-vg second point: I think the most pragmatic solution would indeed be promoting all relevant |
Enable a default config and specific configs overwriting the defaults. See idea from PyPSA/pypsa-eur#292 .
The code above does not work. This one does:
|
Thanks for your thought @euronion, @koen-vg .
Good point! In this case the user has to explicitly create and set the <config_config.yaml>? I like the idea of forcing the user to think about it, on the other hand the default setting should work out of the box. Is it too much if we set configfile per default to
EDIT: |
We could set the default to the tutorial config, that way the mechanism is already shown and it works out of the box.
|
Great idea! |
Should we prep it already for the next version? I can prepare the PR tomorrow. The other issue also mentioned by @koen-vg and discussed by us on Monday off-list should be a separate PR. I believe the |
That would be great! Let's prioritize this issue over #275 since the latter will become easier afterwards (both should be in the next release) |
Add small spelling/maths correction to documentation
close due to other, more promising approaches |
I thought a bit about how to deal with the mixture of
config.default.yaml
,config.yaml
and the code-based parameters which are either keyword arguments in the functions orconfig.get()
-defaults. I think this make the whole workflow hard to track and nasty to update. The best solution I can think of is the following:There are no parameter settings in the code, means no keyword arguments and
dict.get()
-defaults. All the parameter come from the config files. The basis config file is theconfig.default.yaml
, the config.yaml is (by default) an empty file which is only used to update (!) theconfig.default.yaml
. The start of the Snakefile would include thisAdvantages:
config.yaml
.Disadvantages:
Any thought @fneum @euronion @martacki ?
The text was updated successfully, but these errors were encountered: