marcomusy / vedo

A python module for scientific analysis of 3D data based on VTK and Numpy
https://vedo.embl.es
MIT License
1.98k stars 257 forks source link

How does compute_clustering work? #1075

Closed JeffreyWardman closed 3 months ago

JeffreyWardman commented 3 months ago

Does compute_clustering use normals and other pointdata information? It seems to be ignoring the x axis for the example I'm investigating and I believe this is a possible reason.

If it's just points being used, the radius doesn't seem to work regardless if set to 1 for an object with a bounding box of e.g. [-20, 20, -20, 20, -20, 20]. Is it a fraction?

My ideal clustering approach:

marcomusy commented 3 months ago

I don´t understand what you mean.. it uses no pointdata information nor normals, the way it works is this https://vedo.embl.es/autodocs/content/vedo/vedo/pointcloud.html#Points.compute_clustering

JeffreyWardman commented 3 months ago

Ah thanks. So it uses just positional coordinates as inputs. Not sure why I was getting clusters on my U-shaped object where both ends of the U had the same labels (as though the x-axis wasn't considered).