From 1678f319d8d0929d81db0366054352da6ec848d7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jonas=20H=C3=B6rsch?= Date: Mon, 24 Sep 2018 18:33:04 +0200 Subject: [PATCH] prepare_network: Allow lv=inf to designate a fully cost-optimal expansion --- Snakefile | 2 +- scripts/prepare_network.py | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/Snakefile b/Snakefile index bb85f9b1..4da244ba 100644 --- a/Snakefile +++ b/Snakefile @@ -3,7 +3,7 @@ configfile: "config.yaml" localrules: all # , extract_summaries, plot_network, scenario_comparions wildcard_constraints: - lv="[0-9\.]+", + lv="[0-9\.]+|inf", simpl="[a-zA-Z0-9]*", clusters="[0-9]+m?", sectors="[+a-zA-Z0-9]+", diff --git a/scripts/prepare_network.py b/scripts/prepare_network.py index e98d9ff1..de52ce69 100644 --- a/scripts/prepare_network.py +++ b/scripts/prepare_network.py @@ -115,6 +115,7 @@ if __name__ == "__main__": # if 'Ep' in opts: # add_emission_prices(n) - set_line_volume_limit(n, float(snakemake.wildcards.lv)) + if snakemake.wildcards.lv != 'inf': + set_line_volume_limit(n, float(snakemake.wildcards.lv)) n.export_to_netcdf(snakemake.output[0])