Merge branch 'master' into scenario-management
This commit is contained in:
commit
72e6c2fd80
@ -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.
|
* 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)
|
PyPSA-Eur 0.8.1 (27th July 2023)
|
||||||
================================
|
================================
|
||||||
|
|
||||||
|
@ -115,7 +115,9 @@ def build_nodal_distribution_key(hotmaps, regions, countries):
|
|||||||
facilities = hotmaps.query("country == @country and Subsector == @sector")
|
facilities = hotmaps.query("country == @country and Subsector == @sector")
|
||||||
|
|
||||||
if not facilities.empty:
|
if not facilities.empty:
|
||||||
emissions = facilities["Emissions_ETS_2014"]
|
emissions = facilities["Emissions_ETS_2014"].fillna(
|
||||||
|
hotmaps["Emissions_EPRTR_2014"]
|
||||||
|
)
|
||||||
if emissions.sum() == 0:
|
if emissions.sum() == 0:
|
||||||
key = pd.Series(1 / len(facilities), facilities.index)
|
key = pd.Series(1 / len(facilities), facilities.index)
|
||||||
else:
|
else:
|
||||||
|
@ -28,9 +28,7 @@ def allocate_sequestration_potential(
|
|||||||
overlay["share"] = area(overlay) / overlay["area_sqkm"]
|
overlay["share"] = area(overlay) / overlay["area_sqkm"]
|
||||||
adjust_cols = overlay.columns.difference({"name", "area_sqkm", "geometry", "share"})
|
adjust_cols = overlay.columns.difference({"name", "area_sqkm", "geometry", "share"})
|
||||||
overlay[adjust_cols] = overlay[adjust_cols].multiply(overlay["share"], axis=0)
|
overlay[adjust_cols] = overlay[adjust_cols].multiply(overlay["share"], axis=0)
|
||||||
gdf_regions = overlay.groupby("name").sum()
|
return overlay.dissolve("name", aggfunc="sum")[attr]
|
||||||
gdf_regions.drop(["area_sqkm", "share"], axis=1, inplace=True)
|
|
||||||
return gdf_regions.squeeze()
|
|
||||||
|
|
||||||
|
|
||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
|
Loading…
Reference in New Issue
Block a user