[pdal] Classify Buildings and Vegetation in PDAL?

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

[pdal] Classify Buildings and Vegetation in PDAL?

Piero Toffanin
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
[hidden email]
https://lists.osgeo.org/mailman/listinfo/pdal
Reply | Threaded
Open this post in threaded view
|

Re: [pdal] Classify Buildings and Vegetation in PDAL?

Bradley Chambers
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 <[hidden email]> 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
[hidden email]
https://lists.osgeo.org/mailman/listinfo/pdal

_______________________________________________
pdal mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/pdal