Filter löschen
Filter löschen

I need to classify ellipsoids consisting of set of points.

1 Ansicht (letzte 30 Tage)
I have a matrix includes the surface points of elllipsoids. and I want to classifiy each ellipsoid seperatly and store the ellipsoid points into a vector. I have used "rangesearch" function with a range distance equals the meshing distance of the ellipsoids. but it catchs also the points of the nearby ellispoids as the distance between the ellispoids may be less than the range distance.

Akzeptierte Antwort

Shubham
Shubham am 20 Okt. 2023
Hi Bassem,
If you want to classify each ellipsoid separately and store the points belonging to each ellipsoid in a vector, you can use the following approach:
  1. Perform a clustering algorithm on the surface points of the ellipsoids. One popular algorithm for this task is the DBSCAN (Density-Based Spatial Clustering of Applications with Noise) algorithm.
  2. Set the parameters for the DBSCAN algorithm. The key parameter is the epsilon value, which represents the maximum distance between two points to be considered as part of the same cluster. Choose an epsilon value that is slightly larger than the meshing distance of the ellipsoids.
  3. Apply the DBSCAN algorithm to the surface points of the ellipsoids. This will cluster the points into different groups based on their proximity.
  4. Iterate over the clusters obtained from the DBSCAN algorithm and store the points of each cluster in a separate vector. These vectors will represent the points belonging to each individual ellipsoid.
By using a clustering algorithm like DBSCAN, you can separate the points belonging to each ellipsoid while avoiding the issue of nearby ellipsoids being considered as part of the same cluster.
You can refer to the documentation link: https://in.mathworks.com/help/stats/dbscan.html
  3 Kommentare
Shubham
Shubham am 30 Okt. 2023
If DBSCAN is not working properly for your 3D data points, you can try an alternative approach using a distance-based method to classify the ellipsoids. Here's a suggestion:
  1. Calculate the pairwise distances between all surface points of the ellipsoids. You can use the Euclidean distance or any other suitable distance metric for your data.
  2. Set a threshold distance equal to or slightly larger than the meshing distance of the ellipsoids. This threshold will be used to determine whether two points belong to the same ellipsoid.
  3. Initialize an empty vector to store the points belonging to each ellipsoid.
  4. Iterate over the surface points of the ellipsoids. For each point, find all other points within the threshold distance. If the number of nearby points is above a certain threshold (e.g., MinPts), consider the point as part of an ellipsoid.
  5. Add the point to the vector corresponding to the ellipsoid it belongs to.
  6. Repeat this process for all surface points, assigning each point to the appropriate ellipsoid vector.
By using this distance-based approach, you can classify the ellipsoids separately based on their surface points while avoiding the issue of nearby ellipsoids being included. Adjusting the threshold distance and the MinPts value will help you control the classification sensitivity and the minimum number of points required to define an ellipsoid.
Bassem Mokhtar
Bassem Mokhtar am 9 Nov. 2023
Thank you for your reply. It really helped me to find the solution. I did not use dbscan function, but I have read about the way it works. The main idea of dbscan is to cluster each group of points using "core points" that is the main idea. Therefore, I have followed the same procedure but with using rangesearch. I have used the inner points "core points" inside each ellipsoid to distinguse the surface points, as same as dbscane and it worked fine.

Melden Sie sich an, um zu kommentieren.

Weitere Antworten (0)

Kategorien

Mehr zu Geodesy and Mapping finden Sie in Help Center und File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by