Skip to content

Commit dcc3891

Browse files
Fix: Invalid aquifer shapes in build_ates_potentials (PyPSA#1724)
* fix: ensure aquifer geometries are valid in build_ates_potentials.py * fix: add release note for fixing invalid aquifer shape geometries in build_ates_potentials.py
1 parent f72ebe2 commit dcc3891

2 files changed

Lines changed: 4 additions & 0 deletions

File tree

doc/release_notes.rst

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,8 @@ Release Notes
1111
.. Upcoming Release
1212
.. ================
1313
14+
* Fix: Invalid aquifer shape geometries are now fixed in `build_ates_potentials.py` (fixing https://github.com/PyPSA/pypsa-eur/issues/1696)
15+
1416
* Fix: Sanitize columns in `add_brownfield` as it's done for `add_exisiting_baseyear` (https://github.com/PyPSA/pypsa-eur/pull/1676).
1517

1618
* (Breaking) Consolidate gap-filling strategies options under a new configuration section `load:fill_gaps` and add a switch (https://github.com/PyPSA/pypsa-eur/pull/1677). The options `load:interpolate_limit` and `load:time_shift_for_large_gaps` are now located under `load:fill_gaps` as `load:fill_gaps:interpolate_limit` and `load:fill_gaps:time_shift_for_large_gaps`.

scripts/build_ates_potentials.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -391,6 +391,8 @@ def check_aquifer_coverage(
391391
aquifer_shapes = gpd.read_file(snakemake.input.aquifer_shapes_shp).to_crs(
392392
regions_onshore.crs
393393
)
394+
# fix any invalid geometries
395+
aquifer_shapes.geometry = aquifer_shapes.geometry.make_valid()
394396

395397
dh_areas = gpd.read_file(snakemake.input.dh_areas).to_crs(regions_onshore.crs)
396398

0 commit comments

Comments
 (0)