Skip to content

Add crs to config to make code less error prone #393

Open
@pz-max

Description

@pz-max

Describe the feature you'd like to see

In PyPSA-Africa/Earth we define the crs system (coordinate reference system) in the config.

# definition of the Coordinate Reference Systems
crs:
  geo_crs: EPSG:4326  # general geographic projection, not used for metric measures. "EPSG:4326" is the standard used by OSM and google maps
  distance_crs: EPSG:3857  # projection for distance measurements only. Possible recommended values are "EPSG:3857" (used by OSM and Google Maps)
  area_crs: ESRI:54009  # projection for area measurements only. Possible recommended values are Global Mollweide "ESRI:54009"

These values are then important by scripts & functions as shown here:
https://github.com/pypsa-meets-africa/pypsa-africa/blob/4d7174ae5e75ba62fb2a9981c27b45a45873be52/scripts/clean_osm_data.py#L782-L836

This could be also adapted in PyPSA-Eur making the code less error-prone.
Maybe someone wants to implement this?

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions