<div dir="ltr"><div>I have a GeoTIFF file that contains a projected CRS defined as EPSG:3857 via GeoTIFF keys. When I open it using GDAL, the spatial reference is interpreted as a <code>LOCAL_CS</code>, while QGIS displays it as the EPSG:3857 Web Mercator projection.</div><div><br></div><div>I'm trying to understand the reason behind this discrepancy.</div><div><br></div><div>Here is the code I'm using with GDAL:</div><div><br></div><div><font face="monospace">>>> from osgeo import gdal<br>>>> ds = gdal.OpenEx("test.tif")<br>>>> dsproj = ds.GetProjection()<br>Warning 1: The definition of projected CRS EPSG:3857 got from GeoTIFF keys is not the same as the one from the EPSG registry, which may cause issues during reprojection operations. Set GTIFF_SRS_SOURCE configuration option to EPSG to use official parameters (overriding the ones from GeoTIFF keys), or to GEOKEYS to use custom values from GeoTIFF keys and drop the EPSG code.<br>>>> dsproj<br>'LOCAL_CS["WGS 84 / Pseudo-Mercator",UNIT["metre",1,AUTHORITY["EPSG","9001"]],AXIS["Easting",EAST],AXIS["Northing",NORTH],AUTHORITY["EPSG","3857"]]'</font></div><div><br></div><div>Why does QGIS appear to resolve this as EPSG:3857, while GDAL gives a <code>LOCAL_CS</code> definition?</div></div>