Skip to main content
Solved

Adding a new label for las file based on clipping of points


I am trying to add an extra label for each point of the point cloud based on whether or not they were located inside or outside the gml building model.

 

When I clipped a model with my point cloud data with "Clipper", it only identified that point cloud was outside and that point cloud data was identified as 1 feature own on its.

 

How do I label/mark each point in the point cloud whether they clipped with the model or not and then save it as an extra information/variable in a new las file.

Best answer by khairilariffin

To update. I was able to split data into its individual parts for clipper comparison using PointCloudToPointCoercer as adviced.

I then turn each of group of points into individual PointCloud feature. From here used PointCloudComponentAdder to add label based on which group, Inside or Outside.

I then combine both group back together before writing/saving them.

 

Remember to set the Inside or Outside under Additional component when setting up the LAS writer. Attached my workspace for reference.

View original
Did this help you find an answer to your question?

5 replies

daveatsafe
Safer
Forum|alt.badge.img+19
  • Safer
  • May 9, 2023

Hi @khairilariffin​,

You can use a pair of PointCloudComponentAdders after the Clipper, one connected to the Inside port, and the other connected to the Outside. Set a comment component name in each transformer, one set to the inside value, and other set to the outside value. Finally, send the outputs of both PointCloudComponentAdders to a PointCloudCombiner to merge back into a single cloud again.

Screen Shot 2023-05-09 at 1.32.20 PM


Hi @daveatsafe, thanks for the reply.

 

FME reads my LAS file as one feature. As such when I used Clipper, it read entire Point cloud as one feature instead of individual points and when compared to the GML model is read as Outside only. I am trying to identify and label each point in the point cloud if they are either inside or outside when compared to the GML 3D Model.

image 


daveatsafe
Safer
Forum|alt.badge.img+19
  • Safer
  • May 10, 2023
khairilariffin wrote:

Hi @daveatsafe, thanks for the reply.

 

FME reads my LAS file as one feature. As such when I used Clipper, it read entire Point cloud as one feature instead of individual points and when compared to the GML model is read as Outside only. I am trying to identify and label each point in the point cloud if they are either inside or outside when compared to the GML 3D Model.

image 

It looks like the GML features you are using as Clippers are being rejected. To clip a point cloud, the Clipper features should be either polygons (for 2D clip), or solids for (3D clip). 3D features from GML are usually a collection of surfaces rather than a solid, so you may need to use a SolidBuilder transformer to convert these to proper solids. A successful solid will require that there be no gaps in the input surfaces.


daveatsafe wrote:

It looks like the GML features you are using as Clippers are being rejected. To clip a point cloud, the Clipper features should be either polygons (for 2D clip), or solids for (3D clip). 3D features from GML are usually a collection of surfaces rather than a solid, so you may need to use a SolidBuilder transformer to convert these to proper solids. A successful solid will require that there be no gaps in the input surfaces.

The 3D GML model is not causing the issue, rather I am still not able to label the individual point cloud from my LAS file. I was able to find a Transformer called PointCloudFilter but it requires an expression input which I do not know what to fill in since I require all the points from the point cloud.


To update. I was able to split data into its individual parts for clipper comparison using PointCloudToPointCoercer as adviced.

I then turn each of group of points into individual PointCloud feature. From here used PointCloudComponentAdder to add label based on which group, Inside or Outside.

I then combine both group back together before writing/saving them.

 

Remember to set the Inside or Outside under Additional component when setting up the LAS writer. Attached my workspace for reference.


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings