From b5b88c65547a7a407bcab4c116c00891121de8c4 Mon Sep 17 00:00:00 2001 From: Fabian Neumann Date: Fri, 16 Sep 2022 16:14:30 +0200 Subject: [PATCH 1/3] lift rasterio restriction to allow atlite 0.2.9 --- envs/environment.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/envs/environment.yaml b/envs/environment.yaml index 8cb8e565..dbe1bb25 100644 --- a/envs/environment.yaml +++ b/envs/environment.yaml @@ -46,7 +46,7 @@ dependencies: # GIS dependencies: - cartopy - descartes - - rasterio<=1.2.9 # 1.2.10 creates error https://github.com/PyPSA/atlite/issues/238 + - rasterio!=1.2.10 # PyPSA-Eur-Sec Dependencies - geopy From a9c8d8b037008f2efd9355bea3db4a8c6952d281 Mon Sep 17 00:00:00 2001 From: Fabian Neumann Date: Fri, 16 Sep 2022 16:20:03 +0200 Subject: [PATCH 2/3] lift ipopt env restriciton --- .github/workflows/ci.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index c753deab..d50fc35f 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -57,7 +57,7 @@ jobs: - name: Add solver to environment run: | - echo -e " - glpk\n - ipopt<3.13.3" >> envs/environment.yaml + echo -e " - glpk\n - ipopt" >> envs/environment.yaml - name: Setup Mambaforge uses: conda-incubator/setup-miniconda@v2 From e2a414066398ec56e1ccb40937eca0ca468c6ac7 Mon Sep 17 00:00:00 2001 From: Fabian Date: Mon, 19 Sep 2022 13:08:03 +0200 Subject: [PATCH 3/3] add_electricity: calculate marginal costs from plant efficiency --- doc/release_notes.rst | 2 +- scripts/add_electricity.py | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/doc/release_notes.rst b/doc/release_notes.rst index ce7be5c7..32071d6a 100644 --- a/doc/release_notes.rst +++ b/doc/release_notes.rst @@ -12,7 +12,7 @@ Upcoming Release * Individual commits are now tested against pre-commit hooks. This includes black style formatting, sorting of package imports, Snakefile formatting and others. Installation instructions can for the pre-commit can be found `here `_. * Pre-commit CI is now part of the repository's CI. - +* Marginal costs of conventional generators are now taking the plant-specific efficiency into account. PyPSA-Eur 0.6.0 (10th September 2022) ===================================== diff --git a/scripts/add_electricity.py b/scripts/add_electricity.py index 64f18d45..3d9babfd 100755 --- a/scripts/add_electricity.py +++ b/scripts/add_electricity.py @@ -369,6 +369,9 @@ def attach_conventional_generators( .rename(index=lambda s: "C" + str(s)) ) ppl["efficiency"] = ppl.efficiency.fillna(ppl.efficiency_r) + ppl["marginal_cost"] = ( + ppl.carrier.map(costs.VOM) + ppl.carrier.map(costs.fuel) / ppl.efficiency + ) logger.info( "Adding {} generators with capacities [GW] \n{}".format(