From 38cd777fb2fdbee28477fb3b4ff2b9472bf5bd59 Mon Sep 17 00:00:00 2001 From: Sebastian Maierhofer Date: Thu, 28 Dec 2023 16:35:00 +0100 Subject: [PATCH] update osm projection --- crdesigner/common/config/osm_config.py | 3 --- .../osm2cr/converter_modules/osm_operations/osm_parser.py | 3 ++- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/crdesigner/common/config/osm_config.py b/crdesigner/common/config/osm_config.py index 0dd0f57d..118e68ed 100644 --- a/crdesigner/common/config/osm_config.py +++ b/crdesigner/common/config/osm_config.py @@ -19,9 +19,6 @@ class OsmConfig(BaseConfig): "Projection string", "String describing the projection of the OSM map", ) - PROJ_STRING_TO = Attribute( - gui_config.pseudo_mercator, "Projection string", "String used for the initialization of projection" - ) # Lanelet type each lanelet should have LANELETTYPE = Attribute("urban", "Lanelet Type") diff --git a/crdesigner/map_conversion/osm2cr/converter_modules/osm_operations/osm_parser.py b/crdesigner/map_conversion/osm2cr/converter_modules/osm_operations/osm_parser.py index 541997e4..d6e4e8d4 100644 --- a/crdesigner/map_conversion/osm2cr/converter_modules/osm_operations/osm_parser.py +++ b/crdesigner/map_conversion/osm2cr/converter_modules/osm_operations/osm_parser.py @@ -15,6 +15,7 @@ from ordered_set import OrderedSet from pyproj import CRS, Transformer +from crdesigner.common.config.general_config import general_config from crdesigner.common.config.osm_config import osm_config from crdesigner.common.config.osm_config import osm_config as config from crdesigner.map_conversion.common.geometry import ( @@ -365,7 +366,7 @@ def parse_file( # create transformer for projecting lat/lon crs_from = CRS(osm_config.PROJ_STRING_FROM) - crs_to = CRS(osm_config.PROJ_STRING_TO) + crs_to = CRS(general_config.proj_string_cr) transformer = Transformer.from_proj(crs_from, crs_to) road_points = transform_lat_lon(road_ids, road_lats, road_lons, transformer)