[pdal] Classify Buildings and Vegetation in PDAL?

Bradley Chambers brad.chambers at gmail.com
Sat Jul 29 04:48:02 PDT 2017


Piero,

This isn't going to be any kind of silver bullet, but you could start
playing around with a pipeline similar to:

{
  "pipeline": [
    {
      "type": "filters.assign",
      "assignment": "Classification[:]=0"
    },
    {
      "type": "filters.smrf"
    },
    {
      "type": "filters.hag"
    },
    {
      "type": "filters.range",
      "limits": "HeightAboveGround[2:)"
    },
    {
      "type": "filters.approximatecoplanar",
      "knn": 10
    },
    {
      "type": "filters.range",
      "limits": "Coplanar[1:1]"
    }
  ]
}

If you already have ground returns labeled, you could skip the first two
steps altogether. You could also plugin PMF in place of SMRF in you prefer.

The first range filter is used to cut out not only ground, but also near
ground points using the height above ground value computed in the previous
HAG step.

The ApproximateCoplanar filter is borrowed from [1] and compares
eigenvalues computed from 10 nearest neighbors to estimate planarity.

The final range filter cuts out the non-planar points, returning only the
(roughly) planar ones. If you are writing to a format that accommodates the
Coplanar dimension then you don't need to use the range filter, just write
out the Coplanar dimension and analyze the results using your tool of
choice.

It's been a while since I ran this pipeline, but IIRC the truly planar
objects tended to be marked planar pretty reliably, whereas the non-planar
objects tended to have some noise mixed in. That is, it wasn't uncommon to
find points within the vegetation whose ten neighbors just happened to look
approximately planar. Anyway, it may be a starting point. There is clearly
more work that could be done in this area!

Brad

[1] F. A. Limberger and M. M. Oliveira, “Real-time detection of planar
regions in unorganized point clouds,” Pattern Recognit., vol. 48, no. 6,
pp. 2043–2053, 2015.

On Fri, Jul 28, 2017 at 11:46 PM Piero Toffanin <pt at masseranolabs.com>
wrote:

> Hello!
>
> I was wondering if somebody could point me in the right direction; I'm
> trying to classify (roughly) a set of non-ground points into buildings
> and vegetation for the purpose of filtering out vegetation and retaining
> only the buildings. I was thinking of using an approach similar to
> lasclassify (check for planarity or roughness)
> https://rapidlasso.com/lastools/lasclassify/, but I'm not sure which
> would be the best way to approach this.
>
> Suggestions?
>
> Thank you!
>
> -Piero
>
> _______________________________________________
> 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/20170729/a6b8f8d8/attachment.html>


More information about the pdal mailing list