[pdal] PDAL v2 spatial reference difference

Howard Butler howard at hobu.co
Mon Aug 24 11:04:52 PDT 2020



> On Aug 24, 2020, at 9:34 AM, Evert Etienne <evert.etienne at gmail.com> wrote:
> 
> Dear all,
> 
> I have a question about some behaviour I don’t understand when using PDAL.
> We are in the middle up updating PDAL from 1.8.0 to 2.1.0. We have some unit tests checking the spatial reference system reading in our code.
> In 1.8.0, the spatial reference read (using info—metadata `spatialreference`) from a test pointcloud (https://pdal.io/tutorial/reading.html#a-basic-inquiry-example <https://pdal.io/tutorial/reading.html#a-basic-inquiry-example> interesting.las) was the following
> 
> 'PROJCS["NAD_1983_Oregon_Statewide_Lambert_Feet_Intl",GEOGCS["GCS_North_American_1983",DATUM["D_North_American_1983",SPHEROID["GRS_1980",6378137,298.257222101]],PRIMEM["Greenwich",0],UNIT["degree",0.0174532925199433]],PROJECTION["Lambert_Conformal_Conic_2SP"],PARAMETER["standard_parallel_1",43],PARAMETER["standard_parallel_2",45.5],PARAMETER["latitude_of_origin",41.75],PARAMETER["central_meridian",-120.5],PARAMETER["false_easting",400000],PARAMETER["false_northing",0],UNIT["foot",0.3048,AUTHORITY["EPSG","9002"]]]’
> 
> But using 2.1.0, this becomes the following
> 
> 'PROJCS["NAD_1983_Oregon_Statewide_Lambert_Feet_Intl",GEOGCS["GCS_North_American_1983",DATUM["North_American_Datum_1983",SPHEROID["GRS_1980",6378137,298.257222101]],PRIMEM["Greenwich",0],UNIT["degree",0.0174532925199433,AUTHORITY["EPSG","9122"]]],PROJECTION["Lambert_Conformal_Conic_2SP"],PARAMETER["latitude_of_origin",41.75],PARAMETER["central_meridian",-120.5],PARAMETER["standard_parallel_1",43],PARAMETER["standard_parallel_2",45.5],PARAMETER["false_easting",400000],PARAMETER["false_northing",0],UNIT["foot",0.3048,AUTHORITY["EPSG","9002"]],AXIS["Easting",EAST],AXIS["Northing",NORTH]]’
> 
> I am lost on 2 topics
> - How can a read operation change the data returned, is there some lookup being done (proj version causing this?)

Yes. First confirm that the same version of PROJ and GDAL are being used between these two different WKT.

> - Are these 2 equivalent or what causes this to change and be different?

It looks to me by a quick glance at the parameters that these are equivalent, but it is totally possible that PROJ produces "equivalent" WKT that do not string-compare as equal.

> Very possibly i am missing some crucial background information on these spatial references, so feel free to point me to relevant documentation or changelogs.

Dealing with WKT is akin to enduring the cruciatus curse...

Howard
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/pdal/attachments/20200824/f25b934e/attachment.html>


More information about the pdal mailing list