diff --git a/doc/release_notes.rst b/doc/release_notes.rst index 918bb6dd..35e56660 100644 --- a/doc/release_notes.rst +++ b/doc/release_notes.rst @@ -14,6 +14,8 @@ Upcoming Release * PyPSA-EUR now supports the simultaneous execution of multiple scenarios. For this purpose, a scenarios.yaml file has been introduced which contains customizable scenario names with corresponding configuration overrides. To enable it, set the ``run: scenarios:`` key to ``True`` and define the scenario names to run under ``run: name:`` in the configuration file. The latter must be a subset of toplevel keys in the scenario file. +* For industry distribution, use EPRTR as fallback if ETS data is not available. + PyPSA-Eur 0.8.1 (27th July 2023) ================================ diff --git a/scripts/build_industrial_distribution_key.py b/scripts/build_industrial_distribution_key.py index e93e43c2..979a1493 100644 --- a/scripts/build_industrial_distribution_key.py +++ b/scripts/build_industrial_distribution_key.py @@ -115,7 +115,9 @@ def build_nodal_distribution_key(hotmaps, regions, countries): facilities = hotmaps.query("country == @country and Subsector == @sector") if not facilities.empty: - emissions = facilities["Emissions_ETS_2014"] + emissions = facilities["Emissions_ETS_2014"].fillna( + hotmaps["Emissions_EPRTR_2014"] + ) if emissions.sum() == 0: key = pd.Series(1 / len(facilities), facilities.index) else: diff --git a/scripts/build_sequestration_potentials.py b/scripts/build_sequestration_potentials.py index e19a96da..f6ad3526 100644 --- a/scripts/build_sequestration_potentials.py +++ b/scripts/build_sequestration_potentials.py @@ -28,9 +28,7 @@ def allocate_sequestration_potential( overlay["share"] = area(overlay) / overlay["area_sqkm"] adjust_cols = overlay.columns.difference({"name", "area_sqkm", "geometry", "share"}) overlay[adjust_cols] = overlay[adjust_cols].multiply(overlay["share"], axis=0) - gdf_regions = overlay.groupby("name").sum() - gdf_regions.drop(["area_sqkm", "share"], axis=1, inplace=True) - return gdf_regions.squeeze() + return overlay.dissolve("name", aggfunc="sum")[attr] if __name__ == "__main__":