bugfix to avoid duplicated offshore regions (closes #396)

This commit is contained in:
Fabian Neumann 2024-05-13 17:56:28 +02:00
parent ef395cadf9
commit 788e07a0d1
2 changed files with 3 additions and 1 deletions

View File

@ -10,6 +10,8 @@ Release Notes
Upcoming Release Upcoming Release
================ ================
* Bugfix to avoid duplicated offshore regions.
* Added option ``industry: HVC_environment_sequestration_fraction:`` to specify * Added option ``industry: HVC_environment_sequestration_fraction:`` to specify
the fraction of carbon contained plastics that is permanently sequestered in the fraction of carbon contained plastics that is permanently sequestered in
landfill. The default assumption is that all carbon contained in plastics is landfill. The default assumption is that all carbon contained in plastics is

View File

@ -569,7 +569,7 @@ def _set_countries_and_substations(n, config, country_shapes, offshore_shapes):
buses["substation_lv"] = ( buses["substation_lv"] = (
lv_b & onshore_b & (~buses["under_construction"]) & has_connections_b lv_b & onshore_b & (~buses["under_construction"]) & has_connections_b
) )
buses["substation_off"] = (offshore_b | (hv_b & onshore_b)) & ( buses["substation_off"] = ((hv_b & offshore_b) | (hv_b & onshore_b)) & (
~buses["under_construction"] ~buses["under_construction"]
) )