New answers tagged


The +init= syntax is deprecated. So all you need is the ESRI:102001 part. See: = 'esri:102001'


The issue you are having is due to axis order changes in PROJ 6+: One solution is to use always_xy: from shapely.geometry import LineString from shapely.ops import transform from functools import partial import pyproj roadsegment = LineString([(5.318945751388698, 50....


Could you try something like this for python file? C:\PROGRA~1\QGIS3~1.4\apps\Python37\python.exe c:/Users/user/Desktop/xx/


You need to set the environment variables to run the QGIS python outside. In this case my QGIS installation is in D:\QGIS, so you should only change OSGEO4W_ROOT. @ECHO OFF set OSGEO4W_ROOT=D:\QGIS call "%OSGEO4W_ROOT%\bin\o4w_env.bat" call "%OSGEO4W_ROOT%\bin\qt5_env.bat" call "%OSGEO4W_ROOT%\bin\py3_env.bat" path %OSGEO4W_ROOT%\apps\qgis\bin;%PATH% ...


@jelleve, your answer is correct and in line with Additionally, you may be interested in geopandas. It will enable you to read/write these geometries and reproject them using the same method you showed above using one line of code: gdf = geopandas.read_file("input....


After some experimenting, it seems that I was just plain wrong. My initial code looked as follows: def convertCoordinates(polygon): transformer = pyproj.Transformer.from_proj(pyproj.Proj(init='epsg:27563'), pyproj.Proj(init='epsg:4326')) projected = shapely.ops.transform(transformer.transform, polygon) return projected for polygon in polygons: ...

Top 50 recent answers are included