From 2aa67bdf9fa0c407b96af40a1b98dee19c2d4e7d Mon Sep 17 00:00:00 2001 From: Fabian Neumann Date: Tue, 27 Dec 2022 13:03:12 +0100 Subject: [PATCH 1/2] add atlite control for progressbar to configs --- config.default.yaml | 1 + config.tutorial.yaml | 1 + test/config.test1.yaml | 1 + 3 files changed, 3 insertions(+) diff --git a/config.default.yaml b/config.default.yaml index 0ec5e9fb..b9a30be7 100755 --- a/config.default.yaml +++ b/config.default.yaml @@ -86,6 +86,7 @@ electricity: atlite: nprocesses: 4 + show_progress: false # false saves time cutouts: # use 'base' to determine geographical bounds and time span from config # base: diff --git a/config.tutorial.yaml b/config.tutorial.yaml index a3ffc2a9..4c093a3c 100755 --- a/config.tutorial.yaml +++ b/config.tutorial.yaml @@ -56,6 +56,7 @@ electricity: atlite: nprocesses: 4 + show_progress: false # false saves time cutouts: be-03-2013-era5: module: era5 diff --git a/test/config.test1.yaml b/test/config.test1.yaml index 15dc8e6e..7c9b0896 100755 --- a/test/config.test1.yaml +++ b/test/config.test1.yaml @@ -54,6 +54,7 @@ electricity: atlite: nprocesses: 4 + show_progress: false # false saves time cutouts: be-03-2013-era5: module: era5 From bb1b37e8ef9e8b5125633a6b4cacc4510bf6ec5e Mon Sep 17 00:00:00 2001 From: Fabian Neumann Date: Tue, 27 Dec 2022 13:16:05 +0100 Subject: [PATCH 2/2] address pandas iteritems deprecation --- scripts/simplify_network.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/simplify_network.py b/scripts/simplify_network.py index 2c7f8413..12603647 100644 --- a/scripts/simplify_network.py +++ b/scripts/simplify_network.py @@ -217,7 +217,7 @@ def _adjust_capital_costs_using_connection_costs(n, connection_costs_to_bus, out tech, ", ".join( "{:.0f} Eur/MW/a for `{}`".format(d, b) - for b, d in costs.iteritems() + for b, d in costs.items() ), ) ) @@ -369,7 +369,7 @@ def simplify_links(n, costs, config, output, aggregation_strategies=dict()): n.mremove("Link", all_links) static_attrs = n.components["Link"]["attrs"].loc[lambda df: df.static] - for attr, default in static_attrs.default.iteritems(): + for attr, default in static_attrs.default.items(): params.setdefault(attr, default) n.links.loc[name] = pd.Series(params)