[pdal] DSM and DTM mismatch.

Howard Butler howard at hobu.co
Mon Aug 20 06:18:14 PDT 2018


I see "writers.p2g". Which version of PDAL are you using? We have refactored writers.p2g to something now called writers.gdal [1], which has many more features and probably some bug fixes. writers.gdal supports setting of an explicit bounds.

[1] https://pdal.io/stages/writers.gdal.html <https://pdal.io/stages/writers.gdal.html>

> On Aug 20, 2018, at 8:09 AM, Murray, Jon <j.murray3 at lancaster.ac.uk> wrote:
> 
> Ah – apologies. My first post as I explained. As below:
> 
> DSM:
> 
> {
>     "pipeline":[
>         "input1.las",
> 
>         {
>             "type":"filters.reprojection",
>             "in_srs":"EPSG:27700",
>             "out_srs":"EPSG:27700"
>         },
>                 {
>             "type":"filters.range",
>             "limits":"returnnumber[1:1]"
>         },
>         {
>             "type":"writers.p2g",
>             "filename":"dsm1",
>             "output_type":"idw",
>             "output_format":"tif",
>             "grid_dist_x":0.5,
>             "grid_dist_y":0.5,
>             "radius":5
>         }
> 
>     ]
> }
> 
> DTM
> {
>     "pipeline":[
>          "input1.las",
>         {
>             "type":"filters.reprojection",
>             "in_srs":"EPSG:27700",
>             "out_srs":"EPSG:27700"
>         },
>                 {
>             "type":"filters.ground",
>             "approximate":true,
>             "max_window_size":10,
>             "slope":1.0,
>             "max_distance":1,
>             "initial_distance":0.15,
>             "cell_size":1.0,
>             "extract":true,
>             "classify":false
>         },
>         {
>             "type":"writers.p2g",
>             "filename":"dtm1",
>             "output_type":"idw",
>             "output_format":"tif",
>             "grid_dist_x":0.5,
>             "grid_dist_y":0.5
>         }
>     ]
> }
> 
> And the CHM:
> 
> gdal_calc.py -A dtm1.idw.tif -B dsm1.idw.tif --calc="B-A" --outfile chm1.tif –overwrite
> 
> Regards,
> 
> Jon.
> 
> From: Andrew Bell <andrew.bell.ia at gmail.com>
> Sent: 20 August 2018 13:58
> To: Murray, Jon <j.murray3 at lancaster.ac.uk>
> Cc: pdal at lists.osgeo.org
> Subject: Re: [pdal] DSM and DTM mismatch.
> 
> You should post pipelines to show how exactly you're creating the files.
> 
> On Mon, Aug 20, 2018 at 8:49 AM, Murray, Jon <j.murray3 at lancaster.ac.uk <mailto:j.murray3 at lancaster.ac.uk>> wrote:
> Hello PDAL users,
> 
> This is my first post to you all, having just joined the mailing list, so I hope this post is appropriate. I have a problem that I hope there is a PDAL (or possibly GDAL) based solution for. I have created both DSM and DTM from LiDAR (.las) data, using the appropriate PDAL filters/writers etc. It all works well, however there is a slight mismatch in output file sizes.
> 
> The DSM comes out at (3069,1094) and the DTM at (3069,1092), from the same input.las file. This prevents the CHM from being created (GDAL side now) as of course, the dimensions must match. I have tried reprocessing the DSM/DTM and changing grid sizes x/y, but no success.
> 
> Can anyone recommend a solution to this problem please? In short what can I do to make the DTM/DSM sizes match?
> 
> Many thanks,
> 
> Jon.
> 
> _______________________________________________
> pdal mailing list
> pdal at lists.osgeo.org <mailto:pdal at lists.osgeo.org>
> https://lists.osgeo.org/mailman/listinfo/pdal <https://lists.osgeo.org/mailman/listinfo/pdal>
> 
> 
> 
> --
> Andrew Bell
> andrew.bell.ia at gmail.com <mailto:andrew.bell.ia at gmail.com>_______________________________________________
> pdal mailing list
> pdal at lists.osgeo.org
> https://lists.osgeo.org/mailman/listinfo/pdal

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/pdal/attachments/20180820/6e8ae2b6/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 528 bytes
Desc: Message signed with OpenPGP
URL: <http://lists.osgeo.org/pipermail/pdal/attachments/20180820/6e8ae2b6/attachment-0001.sig>


More information about the pdal mailing list