Export classified point clouds

Feel free to ask any question here
Marcus
Posts: 4
Joined: Thu Jun 09, 2016 12:36 pm

Export classified point clouds

Post by Marcus »

Hi Daniel,

I just startet working with CC to process TLS data and I'm quite impressed by the functionality of CC. It helps a lot to process the data.

I have data which include a lot of vegetation as well as measurement infrastructure like eddy covariance towers and lysimeters, which I want to remove since I only need vegetation and ground points. So far, I build up my own classifier to separate the points according to these two classes mentioned above. I also found in this forum how one class can be removed from the other one (http://cloudcompare.org/forum/viewtopic ... ilit=class). Thanks for this simple tool.

Now my question - how can I export the classified point cloud in a way that the defined classes will be exported as well, so that I can use other tools, for instance lasstools, to remove certain classes or work on these classes?

Thanks in advance.

Regards,

Marcus
daniel
Site Admin
Posts: 7717
Joined: Wed Oct 13, 2010 7:34 am
Location: Grenoble, France
Contact:

Re: Export classified point clouds

Post by daniel »

To export such a classification result, you should use the exact same values as the LAS standard:

(see http://www.asprs.org/wp-content/uploads ... _3_r11.pdf)

Here are the main values:
0 Created, never classified
1 Unclassified (equivalent to 0 in fact)
2 Ground
3 Low Vegetation
4 Medium Vegetation
5 High Vegetation
6 Building
7 Low Point (noise)
8 Model Key-point (mass point)
9 Water

And if you rename your scalar field as 'Classification' (mind the case) then it will be saved at the right place in the LAS file. And I bet lastools should be able to use it.
Daniel, CloudCompare admin
Marcus
Posts: 4
Joined: Thu Jun 09, 2016 12:36 pm

Re: Export classified point clouds

Post by Marcus »

Hi Daniel,

thank you for your quick reply.

This workflow works quite well.

Regards,

Marcus
Ohlaris
Posts: 9
Joined: Tue Aug 06, 2019 11:11 am

Re: Export classified point clouds

Post by Ohlaris »

Hello, I am a marine geologist and in my project, I aim to find different classification techniques for 3D models of coral reefs derived from SfM.
So I have been looking into different classification methods to analyze which application can be applied to marine environments.

I have seen really good results with Canupo and I decided to use it as one of my testing methods on my dataset. As it is a binary classifier, I have segmented the same point cloud into the seabed (plain seabed, low vegetation coverage) and coral samples (corals branches), as the dataset is small, not many samples were used in the segmentation process. So I have created and tested 7 training classifiers so far (changing the max core points value and the scales and running them). My first question is if is there a way to export the training classifier results in the same way we see in the pop-up? Also, after I classify my point cloud, how can I export the results of it? I want to export the point cloud with the same classes results (red and blue- see image attached) and also the values for it. I have tried to export the point cloud csv but the files look corrupted( see image attached). So I wonder if is there a way to do it?
Another question is if can I create more classes for it? How would it work?


Also, can you shed some light on the classification process? i think that there is something I am missing there and there is a way to improve the whole process. Any suggestions would be greatly welcomed
Sorry for the probably too primary questions
Attachments
Imagem5.png
Imagem5.png (282.04 KiB) Viewed 26041 times
Imagem1.png
Imagem1.png (285.65 KiB) Viewed 26041 times
Imagem2.png
Imagem2.png (369.16 KiB) Viewed 26041 times
daniel
Site Admin
Posts: 7717
Joined: Wed Oct 13, 2010 7:34 am
Location: Grenoble, France
Contact:

Re: Export classified point clouds

Post by daniel »

Hi,

That's an interesting application.

Have you already read the wiki and the article? (https://www.cloudcompare.org/doc/wiki/i ... O_(plugin)).

The trick is of course to find the right scales... and use good training samples.

To answer your questions:
- when you see 'export the results', what are you thinking about exactly?
- to export the classified cloud, you can simply export it to an ASCII/text file. You'll get each point along with its scalar fields - among which the 'class' one. You may have to change the delimiter to the comma also.
- if you want to create more classes, you actually have to create other classifiers that will split an existing class in two (for instance if you have 'seabed / non-seabed', then you can classify further the 'non-seabed' class into two new classes). In effect you have to apply the first classifier. Then extract the points of the second class (with 'Edit > Scalar fields > Filter by value'), and then apply the second classifier to these points. The original CANUPO tool had the option to create a 'tree of classifiers' that would do this automatically, but this is not supported by the GUI version integrated in CloudCompare.

Don't hesitate to send me some data so that I can try on my side and see how far I manage to go (admin [at] cloudcompare.org).
Daniel, CloudCompare admin
Ohlaris
Posts: 9
Joined: Tue Aug 06, 2019 11:11 am

Re: Export classified point clouds

Post by Ohlaris »

Hi Daniel,

Thank you for sending a reply so fast. I have been testing other classification methods and so far, CC outperformed the other ones.
Can I still send you some data to test? Would files would you need?

Thank you
Kind regards
Larissa
daniel
Site Admin
Posts: 7717
Joined: Wed Oct 13, 2010 7:34 am
Location: Grenoble, France
Contact:

Re: Export classified point clouds

Post by daniel »

Well, yes, you can always send me the data. I'll try to look at them ASAP (but it might not be super fast ;): admin [at] cloudcompare.org
Daniel, CloudCompare admin
JoeKan
Posts: 25
Joined: Fri Nov 29, 2019 11:58 pm

Re: Export classified point clouds

Post by JoeKan »

daniel wrote: Thu Jun 09, 2016 7:55 pm To export such a classification result, you should use the exact same values as the LAS standard:

(see http://www.asprs.org/wp-content/uploads ... _3_r11.pdf)

Here are the main values:
0 Created, never classified
1 Unclassified (equivalent to 0 in fact)
2 Ground
3 Low Vegetation
4 Medium Vegetation
5 High Vegetation
6 Building
7 Low Point (noise)
8 Model Key-point (mass point)
9 Water

And if you rename your scalar field as 'Classification' (mind the case) then it will be saved at the right place in the LAS file. And I bet lastools should be able to use it.
Hi Daniel or Anyone,

A while back - When I imported a LAS file, I seem to remember I was asked which classification, or combination of, I wanted to import into CloudCompare. Been a while since then. Now when I import a LAS, it does not ask me which classification I want to import or see. I know it's possible... I remember doing it and can't find it in the Forum.

Can you refresh my mind on how to 'fish out' the LAS classifications in the LAS files for display? I tried the Scalar options but could not locate the LAS classifications in there.
Thanks.
daniel
Site Admin
Posts: 7717
Joined: Wed Oct 13, 2010 7:34 am
Location: Grenoble, France
Contact:

Re: Export classified point clouds

Post by daniel »

Well, not all LAS files have classification values. But I believe the functionality is still there?
Daniel, CloudCompare admin
JoeKan
Posts: 25
Joined: Fri Nov 29, 2019 11:58 pm

Re: Export classified point clouds

Post by JoeKan »

Hi Daniel,

The LAS Point Clouds I'm looking at are Classified - I can see the classifications as different colours. What I'm trying to figure out, is how to limit my import of the LAS to a specific classification, or how to segregate it to a single classification after the whole cloud is imported.

If I figure it out, I'll post it here just so I have a reminder for next time.
Thanks.
Post Reply