# Matching Point Clouds with STL Models by Using the Principle Component Analysis and a Decomposition into Geometric Primitives

^{1}

^{2}

^{3}

^{*}

## Abstract

**:**

## 1. Introduction

## 2. Related Work

## 3. Principal Component Analysis

#### Matching Point Clouds Using PCA

## 4. Decomposition into Geometric Primitives

- Identify geometrical primitives that are sub-clouds of points belonging to the same plane or cylinder.
- Calculate the following four pairwise-feature matrices: distances between the parallel planar primitives, angles between the planar primitives, distances between the parallel axes of the cylindrical primitives, and angles between the axes of the cylindrical primitives.
- Find the STL triangulation of the feature matrices that fits best with the feature matrices of the scanned point cloud.

#### 4.1. Identification of Geometrical Primitives

#### 4.2. Pairwise-Feature Matrices

#### 4.3. Matching Procedure

## 5. Software and Laboratory Equipment

## 6. Experimental Results

## 7. Conclusions

## Author Contributions

## Funding

## Institutional Review Board Statement

## Informed Consent Statement

## Data Availability Statement

## Conflicts of Interest

## References

- Pearson, K. On lines and planes of closest fit to systems of points in spaces. Philos. Mag.
**1901**, 2, 559–572. [Google Scholar] [CrossRef] [Green Version] - Hotelling, H. Analysis of a complex of statistical variables into principal components. J. Educ. Psychol.
**1933**, 24, 417–441. [Google Scholar] [CrossRef] - Jolliffe, I.T. Principal Component Analysis, 2nd ed.; Springer: New York, NY, USA, 2002. [Google Scholar]
- Rjasanow, S.; Steinbach, O. The Fast Solution of Boundary Integral Equations; Springer: Berlin/Heidelberg, Germany, 2007. [Google Scholar]
- Lukáš, D.; Kovář, P.; Kovářová, T.; Merta, M. A parallel fast boundary element method using cyclic graph decompositions. Numer. Algorithms
**2015**, 70, 807–824. [Google Scholar] [CrossRef] - Schnabel, R.; Wahl, R.; Klein, R. Efficient RANSAC for point-cloud shape detection. Comput. Graph. Forum
**2007**, 26, 214–226. [Google Scholar] [CrossRef] - Zhang, J.; Cao, J.; Liu, X.; Wang, J.; Liu, J.; Shi, X. Point cloud normal estimation via low-rank subspace clustering. Comput. Graph.
**2013**, 37, 697–706. [Google Scholar] [CrossRef] - Zhao, J.; Zong, C.; Cao, L.; Chen, S.; Liu, G.; Xu, J.; Xin, S. Automatically modeling piecewise planar furniture shapes from unorganized point cloud. Comput. Graph.
**2020**, 90, 116–125. [Google Scholar] [CrossRef] - Tran, T.T.; Cao, V.T.; Laurendeau, D. Extraction of cylinders and estimation of their parameters from point clouds. Comput. Graph.
**2015**, 46, 345–357. [Google Scholar] [CrossRef] - Schnabel, R.; Wessel, R.; Wahl, R.; Klein, R. Shape Recognition in 3D Point-Clouds. In Proceedings of the 16-th International Conference in Central Europe on Computer Graphics, Visualization and Computer Vision’2008, Plzen, Czech Rebuplic, 4–7 February 2008; pp. 65–72. [Google Scholar]
- Schnabel, R.; Degener, P.; Klein, R. Completion and reconstruction with primitive shapes. Comput. Graph. Forum
**2009**, 28, 503–512. [Google Scholar] [CrossRef] - Ochmann, S.; Vock, R.; Wessel, R.; Klein, R. Automatic reconstruction of parametric building models from indoor point clouds. Comput. Graph.
**2016**, 54, 94–103. [Google Scholar] [CrossRef] [Green Version] - Vock, R.; Dieckmann, A.; Ochmann, S.; Klein, R. Fast template matching and pose estimation in 3D point clouds. Comput. Graph.
**2019**, 79, 34–45. [Google Scholar] [CrossRef] - Zhang, Z.; Zhang, L.; Tong, X.; Zhen, W.; Guo, B.; Huang, X.; Yuebin, W. A multilevel point-cloud-based discriminative feature for ALS point cloud classification. IEEE Trans. Geosci. Remote Sens.
**2016**, 54, 3309–3321. [Google Scholar] [CrossRef] - Yu, Y.; Li, J.; Guan, H.; Jia, F.; Wang, C. Three-dimensional object matching in mobile laser scanning point clouds. IEEE Geosci. Remote Sens. Lett.
**2014**, 12, 492–496. [Google Scholar] - Yang, B.; Wei, Z.; Li, Q.; Li, J. Semiautomated building facade footprint extraction from mobile LiDAR point clouds. IEEE Geosci. Remote Sens. Lett.
**2013**, 10, 766–770. [Google Scholar] [CrossRef] - Rente, P.; Brites, C.; Ascenso, J.; Pereira, F. Graph-based static 3d point clouds geometry coding. IEEE Trans. Multimed.
**2018**, 21, 284–299. [Google Scholar] [CrossRef] - Somani, N.; Cai, C.; Perzylo, A.; Rickert, M.; Knoll, A. Object recognition using constraints from primitive shape matching. In Proceedings of the International Symposium on Visual Computing, Rethymnon, Crete, Greece, 29–31 July 2013; pp. 783–792. [Google Scholar]
- Besl, P.; McKay, H.D. A method for registration of 3-d shapes. IEEE Trans. Pattern Anal. Mach. Intell.
**1992**, 14, 239–256. [Google Scholar] [CrossRef] - Roth, G.; Levine, M.D. Extracting geometric primitives. Image Underst.
**1993**, 58, 1–22. [Google Scholar] [CrossRef] - Jiang, H.; Drew, M.; Li, Z.N. Matching by linear programming and successive convexification. IEEE Trans. Pattern Anal. Mach. Intell.
**2007**, 29, 959–975. [Google Scholar] [CrossRef] [PubMed] [Green Version] - Rusu, R.B. Semantic 3D Object Maps for Everyday Robot Manipulation; Springer: Berlin/Heidelberg, Germany, 2013. [Google Scholar]
- Mahmoudi, M.; Sapiro, G. Three-dimensional point cloud recognition via distributions of gemetric distances. Graph. Model.
**2009**, 71, 22–31. [Google Scholar] [CrossRef] [Green Version] - Zia, Z.; Stark, M.; Schiele, B.; Schindler, K. Detailed 3d representations for object recognition and modeling. IEEE Trans. Softw. Eng.
**2013**, 35, 2608–2623. [Google Scholar] [CrossRef] [PubMed] - Hilaga, M.; Shinagawa, Y.; Komura, T.; Kunii, T.L. Topology matching for fully automatic similarity estimation of 3d shapes. In Proceedings of the 28th Annual Conference on Computer Graphics and Interactive Techniques, Los Angeles, CA, USA, 12–17 August 2001; pp. 203–212. [Google Scholar]
- Gonzalez, J.P.; Luna-Madrigal, F.; Pina-Ramirez, O. Deep learning point cloud registration based on distance features. IEEE Lat. Am. Trans.
**2019**, 17, 2053–2060. [Google Scholar] [CrossRef] - Rusu, R.B.; Cousins, S. 3D is here: Point Cloud Library (PCL). In Proceedings of the IEEE International Conference on Robotics and Automation (ICRA), Shangai, China, 9–13 May 2011; pp. 65–72. [Google Scholar]
- The Point Cloud Library. Available online: http://pointclouds.org (accessed on 19 March 2020).
- Photoneo, PhoXi 3D Meshing. Available online: https://www.photoneo.com/3d-model-creation/ (accessed on 12 February 2020).

**Figure 3.**Principal Component Analysis (PCA) decomposition of the point cloud from Figure 2.

**Figure 4.**(

**a**) Hierarchical PCA decomposition of the point cloud from Figure 2 and (

**b**) the related tree, the vertices of which are labeled with the triples of eigenvalues.

**Figure 5.**Decomposition of the model from Figure 2 into (

**a**) planar primitives and (

**b**) cylindrical primitives.

**Figure 7.**Standard Triangle Language (STL) model of a mechanical part and the corresponding virtual scan.

**Figure 10.**Scans of the mechanical components from Figure 9.

**Figure 11.**Collection of 6 models successfuly preselected by the hierarchical PCA at the second level, while the correct model was the very first one.

**Figure 12.**Collection of models among which the PCA cannot distinguish, but it includes the correct model, which is the second one.

**Table 1.**Matching results of the method of decomposition into geometric primitives. The first column comprises the identification numbers (IDs) of the 29 scans. Notice that object 8 was scanned twice; see also Figure 10. The next 5 columns display the IDs of the 5 best matched candidates from the collection of 389 models. The percentual score is the amount of primitives in the model that match the primitives of the scan. This amount is divided by the total amount of primitives in the scan (and multiplied by 100%).

Scan ID | Top-5 Models | ||||
---|---|---|---|---|---|

Model ID: Matching-Score | |||||

1 | 1: 38% | 68: 25% | 87: 25% | 271: 25% | 292: 25% |

2 | 2: 50% | 164: 36% | 165: 36% | 13: 29% | 15: 29% |

3 | 3: 42% | 22: 33% | 45: 33% | 135: 33% | 158: 33% |

7 | 7: 63% | 3: 21% | 8: 21% | 38: 21% | 43: 21% |

8a | 8: 56% | 194: 40% | 91: 24% | 6: 16% | 7: 16% |

8b | 8: 66% | 13: 28% | 15: 28% | 7: 21% | 6: 14% |

9 | 9: 38% | 6: 25% | 135: 25% | 159: 25% | 1: 13% |

11 | 11: 88% | 4: 47% | 215: 47% | 5: 35% | 47: 35% |

12 | 12: 87% | 4: 27% | 5: 27% | 6: 27% | 17: 27% |

13 | 13: 83% | 15: 33% | 26: 33% | 64: 33% | 127: 33% |

15 | 15: 50% | 13: 35% | 26: 30% | 37: 30% | 120: 30% |

17 | 17: 53% | 43: 27% | 205: 27% | 210: 27% | 215: 27% |

20 | 20: 88% | 186: 59% | 321: 41% | 135: 35% | 153: 35% |

21 | 21: 80% | 27: 40% | 50: 40% | 70: 40% | 79: 40% |

22 | 22: 83% | 37: 31% | 189: 31% | 370: 31% | 74: 29% |

24 | 24: 85% | 22: 46% | 196: 46% | 321: 38% | 31: 31% |

26 | 26: 84% | 43: 54% | 153: 54% | 169: 54% | 176: 54% |

28 | 28: 86% | 47: 64% | 152: 64% | 27: 57% | 304: 57% |

29 | 29: 50% | 224: 22% | 272: 22% | 319: 22% | 22: 17% |

30 | 30: 38% | 91: 31% | 174: 31% | 319: 31% | 191: 23% |

32 | 32: 88% | 28: 38% | 139: 31% | 142: 31% | 54: 25% |

36 | 36: 71% | 89: 71% | 63: 57% | 69: 57% | 155: 57% |

38 | 38: 92% | 212: 42% | 129: 33% | 167: 33% | 218: 33% |

39 | 39: 75% | 370: 42% | 318: 38% | 74: 33% | 29: 29% |

41 | 41: 62% | 5: 29% | 29: 29% | 332: 29% | 190: 24% |

43 | 43: 93% | 93: 31% | 159: 31% | 240: 31% | 4: 28% |

45 | 45: 73% | 205: 29% | 66: 24% | 11: 18% | 27: 18% |

47 | 47: 78% | 350: 39% | 130: 35% | 294: 35% | 22: 30% |

50 | 50: 71% | 221: 71% | 160: 57% | 34: 43% | 35: 43% |

Publisher’s Note: MDPI stays neutral with regard to jurisdictional claims in published maps and institutional affiliations. |

© 2021 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (http://creativecommons.org/licenses/by/4.0/).

## Share and Cite

**MDPI and ACS Style**

Straková, E.; Lukáš, D.; Bobovský, Z.; Kot, T.; Mihola, M.; Novák, P.
Matching Point Clouds with STL Models by Using the Principle Component Analysis and a Decomposition into Geometric Primitives. *Appl. Sci.* **2021**, *11*, 2268.
https://doi.org/10.3390/app11052268

**AMA Style**

Straková E, Lukáš D, Bobovský Z, Kot T, Mihola M, Novák P.
Matching Point Clouds with STL Models by Using the Principle Component Analysis and a Decomposition into Geometric Primitives. *Applied Sciences*. 2021; 11(5):2268.
https://doi.org/10.3390/app11052268

**Chicago/Turabian Style**

Straková, Erika, Dalibor Lukáš, Zdenko Bobovský, Tomáš Kot, Milan Mihola, and Petr Novák.
2021. "Matching Point Clouds with STL Models by Using the Principle Component Analysis and a Decomposition into Geometric Primitives" *Applied Sciences* 11, no. 5: 2268.
https://doi.org/10.3390/app11052268