Abstract
Automatic visual inspection allows for the identification of surface defects in manufactured parts. Nevertheless, when defects are on a sub-millimeter scale, detection and recognition are a challenge. This is particularly true when the defect generates topological deformations that are not shown with strong contrast in the 2D image. In this paper, we present a method for recognizing surface defects in 3D point clouds. Firstly, we propose a novel 3D local descriptor called the Model Point Feature Histogram (MPFH) for defect detection. Our descriptor is inspired from earlier descriptors such as the Point Feature Histogram (PFH). To construct the MPFH descriptor, the models that best fit the local surface and their normal vectors are estimated. For each surface model, its contribution weight to the formation of the surface region is calculated and from the relative difference between models of the same region a histogram is generated representing the underlying surface changes. Secondly, through a classification stage, the points on the surface are labeled according to five types of primitives and the defect is detected. Thirdly, the connected components of primitives are projected to a plane, forming a 2D image. Finally, 2D geometrical features are extracted and by a support vector machine, the defects are recognized. The database used is composed of 3D simulated surfaces and 3D reconstructions of defects in welding, artificial teeth, indentations in materials, ceramics and 3D models of defects. The quantitative and qualitative results showed that the proposed method of description is robust to noise and the scale factor, and it is sufficiently discriminative for detecting some surface defects. The performance evaluation of the proposed method was performed for a classification task of the 3D point cloud in primitives, reporting an accuracy of 95%, which is higher than for other state-of-art descriptors. The rate of recognition of defects was close to 94%.
Keywords: 3D point cloud, 3D inspection, surface quality inspection, defects detection
1. Introduction
Industrial inspection has to date been an exclusively human task. However, maintaining a group of people detecting surface defects accelerates visual fatigue and misinterpretations. Automatic visual inspection allows for detection of defects by image analysis. This process improves product quality, increases the production rate, avoids errors caused by subjectivity, integrates other systems into the production line, and reduces costs [1,2,3]. Industrial machine vision applications are classified into four quality categories according to the characteristics of the inspected product. These categories refer to dimensional, structural or proper assembly, superficial, and operational features [4]. An estimated 10% of failures in the manufactured parts are caused by superficial defects [5]. The surface quality inspection searches for holes, scratches, cracks, wear, finish, roughness, texture, joints, folds, discontinuities, etc. [6].
Approaches to surface defect detection are summarized in two main research directions. The first approach uses complex lighting systems to generate contrast changes in the surface defect [7]. These methods detect and recognize the defect from the measurement and characterization of pattern deformation on the surface of the object. Zhi and Johansson [8] presented a method for interpreting the deformation of the fringes based on 14 shape features without measuring the depth. Caulier et al. [9] proposed a set of eight features suited to the problem of surface inspection, combined with six characteristics that were developed for the classification of defects in interferometry images. Osten et al. [10] carried out a study of the behavior of the fringes in different defects with the aim of developing inspection systems based on knowledge. Li et al. [11] proposed an automatic inspection scheme for fabric defect detection using smart visual sensors. The system consisted of multiple smart visual sensors working independently. Martínez et al. [12] presented a machine vision system, with an easily configurable hardware-software structure, for surface quality inspection of transparent parts. Neogi et al. [6] presented a detailed review of vision-based steel surface inspection systems. Also, a comparison was made by typology of the defect, extracted features, and detection accuracy between different defect detection systems. In [13] a machine vision system able to achieve fused image acquirement and defect inspection for the textured surface with a suitable efficiency and accuracy was presented. The second direction of investigation focuses on the 3D surface reconstruction of the object, and from the 3D point cloud features are extracted to detect and classify the defect. Pernkof [14] proposed an approach for the 3D reconstruction of raw steel blocks in industrial environments using light sectioning. Ogun et al. [15] proposed a method for identifying conical defects on simple surfaces and measuring its volume automatically from the 3D reconstruction of the part. Chu and Wang [16] presented a automated vision-based system for measure the weld bead size and detect defects. Song et al. [17] proposed a method for fabric defect identification in the textile industry using three-dimensional color phase shift profilometry. A procedure to extract fundamental quality parameters to assess the quality of welds was proposed in [18]. They used a structured light system to obtain 3D reconstruction.
The works that interpret the deformation of the illumination on the defects in the 2D image present some limitations. The 2D image does not provide enough information to enable recognition between different typologies of defects. When there are variations in the scale and geometry of defects, determining the appropriate lighting system is a challenge. The geometry and texture of the object generate brightness and shadows that may be confused with a defect. From the 2D image, it is not possible to perform precise metrology of the defect. In the literature some approaches have been reported to detect and recognize defects from the 3D reconstruction of the piece. However, this is in specific domains of an application where the geometries of surfaces have few variations and only one type of defect is recognized. Because of the above, the methods of describing the defect are simple, which limits them to recognition of a set of larger defects.
The problem of recognizing defects in a 3D surface is similar to the task of recognizing objects in 3D images from partial views. This is not a simple problem, taking into account different variations that the object/surface may suffer, such as translation, rotation, scaling, noise addition, lack of information, and in some cases, non-rigid deformations. For this reason it is necessary to create robust descriptors for different variations suffered by the defect and the surface. In [19] a method for the extraction of characteristics is proposed, called Point Signature, which creates a signature of each point using the intersection with the surface of a sphere centered at the point. A disadvantage of this method lies in the calculation of what the author called signature point, as the intersection of the sphere with the surface is not easy to calculate and in some cases it is necessary to interpolate points, which leads to a reduced accuracy of the signature point and increases the computational cost. In addition, the calculation of the reference vector is sensitive to noise.
Johnson and Hebert [20] proposed Spin Image, which is a point descriptor based on the projection of the adjacent 3D points on a tangential 2D plane. It obtains a 2D image for that point, which becomes the characteristic. A disadvantage of Spin Image is its high dependence on the resolution of the method. Some modifications have been proposed for interpolation, increasing the computational cost. In Reference [21] a method called the Point Feature Histogram (PFH) is proposed to describe the surface of the neighborhood of a point by the difference between the normals. Although an advantage of the method is the simplicity of its calculation, a greater disadvantage lies in the construction of the histogram for each point from the calculation of the differences between normals of an entire region. Full connectivity is created, which generates a smoothing effect for small changes in the region. This also affects the processing times. In Reference [22] a modification to the PFH method improving the processing time was presented, called the Fast Point Feature Histogram (FPFH). It does not create full connectivity for the construction of the histogram, at the cost of reducing the discriminant ability of the method. In Reference [23] the Viewpoint Feature Histogram (VFH) is presented, which is a modification to the FPFH method to describe an object globally by coding its geometry and point of view.
In the recognition of surface defects of objects on a submillimeter scale, the acquisition conditions strongly affect the recognition process. Moreover, it is considered that defects are composed of abrupt changes in the surface, which generate glare and shadows in the 3D reconstruction process and cause low point density in these defective regions. Therefore, the descriptors used to represent the underlying surface must be sufficiently stable to conditions of low point density and noise in the data. The PFH, FPFH and Spin Image, by including the normals in the calculation of the descriptor, are representation methods that highly depend on the correct estimation of the normals and their support radius, which is difficult to ensure in the presence of a defect. The PFH uses the difference between all the normals in the vicinity of a keypoint. As such, in regions with small changes the normals of these points are averaged with the normals of regions with few changes, hence causing a loss of information when describing the defect region.
This paper proposes a descriptor that allows discrimination of different regions within a 3D surface. Our descriptor is based on the estimation of local models on the surface and the difference between the model’s normals in a local region.
The contributions to this paper can be summarized as follows:
The new local 3D surface descriptor the Model Point Feature Histogram (MPFH) is presented, improving robustness and discriminant capabilities of the PFH method.The MPFH descriptor is constructed from the estimation of models and their weighting to the formation of the underlying region.
Furthermore, a methodology for the automatic surface defects inspection is presented. For the detection of the defect, the local 3D descriptor MPFH is used in 3D reconstructed objects. From the projection 2D of the detected 3D primitives are extracted 2D features that allow to classification of the defect.
This paper is organized as follows: Section 2 provides an overview of the methodology. It emphasizes the calculation of structures, estimation of the normals, and the proposed descriptor. Section 3 describes the experimental results and, finally, the conclusions are drawn in Section 4.
2. System Overview
Figure 1 illustrates the scheme of the methodology proposed to recognize surface defects. Our methodology begins with surface 3D reconstruction by projecting structured light patterns (Figure 1a). As a result, a 3D point cloud is obtained which represents the sampled 3D surface (Figure 1b), followed by the calculation of the models or planes that fit each region best using the multiple structures estimation method J-linkage [24] (Figure 1c), and then the normals of the surface models are estimated (Figure 1d). For each surface model, the model contribution weight to the formation of the surface region (Figure 1e) is calculated and from the relative difference between two models of the same region a histogram is generated representing the underlying surface changes (Figure 1f). Each point on the 3D surface is classified into one of five types of primitives, points belonging to hollow, hollow edge, crest, base crest, or flat surfaces (Figure 1g). In this work, it is considered that with this set of primitives it is possible to describe any typology of the defect. For instance, a bump defect will be composed of the base crest, crest, and possibly flat primitives; therefore regions with local geometric changes are detected on the surface. Finally, these regions are extracted 2D features to recognize the defect in a classification stage (Figure 1h).
2.1. Image Acquisition
The 3D point cloud is acquired from a 3D reconstruction system. The technique of projecting structured light patterns was used. Specifically, sinusoidal phase shift patterns were projected. A complementary metal-oxide semiconductor (CMOS) camera (Point Grey FL3-U3-88S2C-C, Richmond, BC, Canada) was used to capture the images and a digital light projector (DLP) was used to synchronously project the sinusoidal patterns on the object [25]. The acquisition scheme is shown in Figure 2. The specifications of the camera and the projector are shown in Table 1. Our 3D reconstruction system had an RMS measurement error of 0.053 mm in x, 0.039 mm in y and 0.10 mm in z, for a measurement area of 60 mm × 60 mm.
Table 1.
Device | Specifications |
---|---|
Camera | Point Grey FL3-U3-88S2C-C |
Sensor size | 1.55 m × 1.55 m |
Image resolution | pixels |
Lenses | Edmund Optics f8.5 mm |
Digital light projector (DLP) | DLP LightCrafter 4500 |
DLP resolution | pixels |
Synchronization circuit | freescale FRDM-K20D50M |
Software | Visual C++ + OpenCV3.0 + PCL1.8 |
2.2. Calculation of Structures
Superficial defects generate deformations on the object’s surface; this causes the normals and curvature in a defective region to change with respect to the neighborhood region. Therefore, if the representation method includes the normal or curvature in the construction of the descriptor, its adequate estimation influences the description of the region. Given a point cloud of the sample 3D surface called S, let be point on the surface; the k closest adjacent points around are denoted by . The problem of choosing k is known as the correct scale factor and it affects the estimation of the normal vectors. The parameter k is also related to the minimum defect size that our system is capable of detecting. To estimate the normal to a point on the surface, a least squares local plane is fitted to and its normal vector becomes normal to the point [26]. However, the normals of the planes that are adjusted to points , with very big k or belonging to edges or corners, undergo a smoothing effect leading to misdirection, which influences the description of that region. The normals shown in red in Figure 3a present these effects.
A structure is defined as a set of points that adjusts to a plane. We call these structures “models” as they represent the surface changes in a simple manner. The region around the corner is composed of three structures or models with different normal vectors (Figure 3a). Thus, our methodology proposes using a method to estimate the multiple structures in a region and then calculate their normal vectors. A model is denoted by . Moreover, it associates the normal vector of the model to each point , which makes it not strictly necessary to calculate the normals for each point of the surface, but rather ensures that the joining of the points that belong to the generated models is equal to the surface S. This is shown in Equation (1), where n represents the total number of models found on the surface. Figure 3b shows the normal vectors on the surface using the proposed methodology, where is possible observe the correct directing of the normals for points belonging to edges and corners. The number of models in a region depends on its topology, so that if the region has few variations, the number of found models is low compared to a region presenting many topological changes. Figure 3c represents this concept, where the red dots indicate the center of each estimated model on a defective surface.
(1) |
The nature of the problem described above is comprised of a set of data that belongs to multiple structures and outliers. The challenge is to estimate the different structures in the presence of noise and geometric changes in the point cloud.
We use the approach proposed in [24], the J-linkage method, to estimate the multiple structures on a local region of points , which is composed of the k-nearest neighbors of a point . As in Random Sample Consensus (RANSAC) [27], J-linkage generates a random set of M hypothesis models called a minimum sampling set. Then the consensus set (CS) of each model is determined as the set of points that is at a smaller distance than a threshold for this particular model. From the CS of the M hypothesis models, a vector is built, representing the set of models to which belongs, where 1 in the column j of the vector represents the belonging of that point to the model and 0 represents that the point does not belonging to the model. This vector is called the preference set (PS) of a point , which becomes a conceptual representation of this point, so that points within the same structure will have similar representations. They will be grouped together as in [24], in a conceptual space . To measure this similarity, the Jaccard distance is used (Equation (2)). A and B are two PSs different to ⊘ and takes on values between 0 and 1, for identical and different sets, consecutively.
(2) |
J-linkage has been used to determine the multiple flat structures in a scene for segmentation purposes from point clouds [28,29], where the difference between the functions of the flat structures is high and the amount of structures is low compared to the density of points. This difference does not arise with point clouds belonging to 3D reconstructions of surface defects, where noise can easily be an inlier of structures and generate a very large number of structures. Therefore, we first generated local regions throughout the point cloud, and then the models of each region were determined using J-linkage. As a result, the estimated models represent local changes in the surface.
A model of a plane can be represented from up to three points. However, we found experimentally that accepting models with fewer than five points increases false models due the noisy data. Increasing the number of points results in that in defective regions, where the point density is low, the models are rejected.
2.3. Normal Estimation
After obtaining the M models belonging to a neighborhood of , the normal vector to the model is determined from the analysis of the eigenvalues and eigenvectors of the covariance matrix C, as described in Equation (3).
(3) |
The eigenvector of the smallest eigenvalue corresponds to the approximation of the normal , if the condition is fulfilled [30].
Using models to determine the normal vectors to a surface of a region solves to a large extent the problem of the right scale factor when calculating the normals (see Section 3.2). The problem of the scale factor is associated with the selected support radii to estimate the normals. If the scale factor (k or r search) is big, the region will undergo a smoothing effect and the normal vector will not capture its details. Algorithm 1 shows the pseudo-code for determining the models and their associated normal vectors and Figure 4 shows the result of the estimation of the normal vectors on a surface sampled containing a hole defect.
Algorithm 1: Normals estimation |
2.4. Model Points Feature Histogram (MPFH)
After obtaining the models and its normal vectors, it is necessary to calculate a representation for each point of the surface sampled S. For this, we propose calculating a histogram of characteristics similar to that proposed in [31].
The calculated feature is the relative difference between the normal vectors of each two models belonging to the region in a Darboux coordinate system. This coordinate system generates a 4D feature that is invariant to the translation and rotation, which has the advantage of reducing the number of parameters from 12 to 4 parameters. This reduction is composed of the coordinates and normal vectors of the two points.
The pair is known as surflet. The origin will be , if Equation (4) is met, otherwise it will be and the indexes 1 y 2 in the equations must be exchanged. This is to achieve homogeneity in the choice of the origin of the coordinate system.
Let · denote the scalar product between two vectors and × the cross product of the two vectors.
(4) |
The axes of the coordinate system are expressed in Equations (5)–(7), and the features indicating the differences between two surflets are described in Equations (8)–(11), [31]. Figure 5 shows the relationship between the coordinate systems and the features obtained.
(5) |
(6) |
(7) |
(8) |
(9) |
(10) |
(11) |
To calculate the descriptor of a point , the closest points are searched in a neighborhood which we call region . Then, the models and their centroids to which belong to the region are determined. Hence, a vector with the set of models and another with the level of participation of the model in the representation of the region are computed. represents the ratio between the number of points that form a model and the totality of the points , described in Equation (12). ranges from ; is not present, because . Figure 5 illustrates the models belonging to the region and the difference between them.
(12) |
The PFH method [21] uses the histogram of characteristics proposed in [31], where the features are found between each pair of surflets belonging to the region . It generates a set of quadruplets of features with complete connectivity without weighting. As a result, it averages the differences between surflets and smoothes local details of the region. On the other hand, our method is based on the relationship between the normal vectors of the models belonging to the region . In addition, our proposal adds the parameter , which represents the participation of each model to the formation of the region. This speeds up the calculation of the representation and leads to a better capture of the geometric information of the underlying 3D surface. This also reduces the computational complexity.
To calculate the MPFH representation of each point , a histogram is generated from the quadruplets of the region using the first three Darboux features and adding the weighting of the model to the formation of the region . Therefore, a histogram H with 4 × b bins is generated, where the first b bins corresponds to the quantization of the feature , the following to , then to , and finally the last corresponds to . Figure 6a shows the MPFH representation for a point belonging to a flat region and Figure 6b for a point belonging to a hole-like defect, given b equals 11 as in the FPFH method.
2.5. Primitives 2D Projection
The identification of primitives allows for detection of defects on surface but not their classification. Our proposal is to project each connected component of primitives on a plane forming a 2D image. Then, 2D geometrical features are extracted for recognition of the defect. Figure 7 shows the methodological scheme proposed.
First, the primitives are clustered in connected components, using Euclidean distance. The threshold distance is selected according to resolution of the point cloud. Then, for each connected component , the centroid is calculated, and with the flat primitive nearest to this, the projection plane is set. All primitives are projected orthogonally to the plane as described in Equations (13)–(15). Figure 8a,b illustrates the procedure.
(13) |
(14) |
(15) |
is the normal vector associated to .
A affine transformation is applied to the plane , so that it is parallel to the plane with normal vector (). Equations (16)–(18) show the calculate of axis and angle rotation, and Equation (19) obtains the matrix Euler-Rodriguez formula.
(16) |
(17) |
(18) |
(19) |
denotes the cross-product matrix of , ⊗ is the tensor product, and is the identity matrix. Figure 6b illustrates the result of this procedure.
The 2D image is formed by the conversion of the plane in mm to pixels. For that, we calculate the factor , where is the closest distance between projected at and other point. Then, the bounding box of is calculated with the goal of translating it the coordinate origin. Figure 8c shows the 2D image result and Figure 8d,e shows 2D projections of different typologies of defects on the objects of experimentation.
According to [32], the characteristics of a surface imperfection are represented in the length, width, depth, height, and area of imperfection. Hence, it is possible to combine 3D and 2D descriptors to recognize an imperfection. As explained in Section 2.4, the 3D information of the curvature of the surface is embedded in the local 3D descriptor MPFH. However, it is necessary to obtain 2D geometric information that allows recognition of the defect. We proposed to group each set of primitives from its 2D projection and then extract a set of characteristics from each region of primitives belonging to the defect. Finally, in a classification stage the defect region is recognized.
The set of characteristics was chosen from a process of selection of characteristics using a Fisher discriminant [33] through the Balu toolbox Matlab [34]. The most relevant features for each type of primitives were the Hu [H1, H2, H7] moments, the Fourier descriptors [F3, F4, F5, F7 and F11], the eccentricity [Exc], and the number Euler [En].
3. Results
In this section, we developed two types of evaluation. First, we proved the discriminative power of the proposed 3D local descriptor compared with five methods of description commonly used. Also, invariance of descriptors to noise and support radius was addressed. Second, we tested the performance of the proposed defects recognition methodology in a database with different objects and defect typology.
3.1. Database
According to our review, to date there have not been any public databases of 3D images with surface defects. Therefore, the database used in these experiments was constructed from 3D reconstructions of defects in welding, artificial teeth; indentations in materials, ceramics, models of artificial defects, and simulations. Figure 9 shows an example of the objects used in the database. Our database contains 480 three-dimensional images with more than 2000 regions with surface defects. There are four types labeled in the database: holes, bumps, cracks and without defect.
In order to understand how difficult it is to detect and recognize a micro-metric defect on an object, Figure 10a–c shows an indentation with a test of Vickers hardness on a sample of aluminum. In Figure 10d–f a material detachment defect in an artificial tooth can be observed.
3.2. Evaluation of the Estimation of the Normals from Multiple Structures
In this section, we evaluate how the computation of the normal vector on a surface is affected when simple or multiple structure estimation methodologies are used. In Figure 11, the result of evaluating the change of a normal at a critical point, where abrupt geometrical changes take place, is shown. The number of k-neighbors, which supports the parameter to estimate the models, was varied between 15 and 250 points. As Figure 11 shows, the scaling factor does not significantly influence the normal vectors calculated by estimating multiple structures. In contrast to using a unique structure, the normal vector in that region changes with the variation of support radius. This means that through the proposed methodology, better-oriented normal vectors at critical points such as edges and corners are obtained. Consequently, this will increase the discriminating capabilities of our descriptor.
3.3. Robustness to Noise in the Estimation of the Normal Vectors
In order to evaluate the robustness to noise in the estimation of models for calculating the normal vectors, in Table 2 we show a comparison of the results of calculating the normal vectors using the adjustment of multiple- structure J-linkage versus the adjustment of a single structure on a cube. In a simple structure like a cube that has three types of regions (planes, edges, and corners), normal estimation methods based on a single structure fail at edges and corners. The defects, being more complex structures, require greater precision in the estimation of the normal, which can be achieved if the estimation of normal multiples is used. The regions chosen for the evaluation were: points in planes, near edges, and on corners. Gaussian noise with a standard deviation of 5% is also added. The calculation of the normal vectors is compared with the theoretical normal vector. The spaces in the “One Structure” column are due to the fact that, regardless of the topological complexity of a region, the methods based on the estimation of unique structures will always find only one normal vector. However, for example for a cube-type region, there are three theoretical normal vectors which match the results using multiple structures. The mean square error between the calculation of the normal vectors using the estimation of multiple structures with respect to the normal theoretical vector was 0.00854, whereas with a single structure this value was 0.01117. In summary, these results show that is more stable to calculate the normal vectors using the estimation of multiple structures versus single structure, even with the presence of noise.
Table 2.
Region | Theoretical Normal Vector | One-Structure Theoretical | Multiple-Structure J-linkage |
---|---|---|---|
// | (Standard Methods) // | Theoretical (Method Used) // | |
Corner | 0.0/−1.0/0.0 | −0.5350/−0.5350/0.6538 | 0.0/−1.0/0.0 |
−1.0/0.0/0.0 | — | −1.0/0.0/0.0 | |
0.0/0.0/1.0 | — | 0.0/0.0/1.0 | |
Corner 5% noise | 0.0/−1.0/0.0 | −0.5438/−0.5888/0.5979 | −0.0010/−0.9997/0.0215 |
−1.0/0.0/0.0 | — | −0.9993/0.0234/0.02866 | |
0.0/0.0/1.0 | — | 0.0711/0.0478/0.9963 | |
Edge | 0.0/0.0/1.0 | 0.0/−0.7071/0.7071 | 0.0/0.0/1.0 |
0.0/−1.0/0.0 | — | 0.0/−1.0/0.0 | |
Edge 5% noise | 0.0/0.0/1.0 | 0.0027/−0.5286/0.8488 | 0.0765/−0.0416/0.9962 |
0.0/−1.0/0.0 | — | 0.0159/−0.9953/−0.0952 | |
Plane | |||
Plane 5% noise | 0.0/0.0/1.0 | 0.0191/−0.0116/0.9998 | 0.01271/−0.0114/0.9998 |
3.4. Evaluation of the Discriminating Properties
In order to evaluate the discriminating capabilities of the MPFH method, it is compared with the PFH and FPFH descriptor with different k neighborhood support. The measure of similarity used for the histogram was the intersection between the descriptors for seven different regions: the point in a plane, cylinder, sphere, a point on the vertices of a triangular pyramid, square pyramid, pentagonal pyramid, and hexagonal pyramid. When the number of sides of the polygon of the base of the pyramid increases, the curvature of the vertex is close to the curvature of a sphere. These regions were chosen because they present a small change between them in the curvature.
Figure 12 presents a similarity matrix. The intensity level represents the quantification of similarity between objects row and column. The rows correspond to the similarity measure for the PFH, FPFH, and MPFH descriptors consecutively, and the columns represent the similarity with different and neighborhood support. An ideal similarity matrix for a classification process would have a diagonal with black and the rest white.
It can be seen in the gray levels from Figure 12g–i that there is a lower probability of confusion of the MPFH method between different classes with respect to the PFH (Figure 12a–c) and FPFH (Figure 12d–f). These results suggest that the description made by the MPFH method facilitates a correct classification of the underlying region.
3.5. Comparison with Some 3D Local Descriptors
In this section, the descriptor MPFH proposed is compared with some of the descriptors more often used in the literature like PFH, FPFH, spin image, radius-based surface (RSD), and signature of histograms of orientations (SHOT). From the database we carefully selected 2800 points belonging to different 3D surfaces regions. These points were categorized into five classes: hollow, crest, edge hollow, base crest and planar surfaces. Descriptors were evaluated in a classification task varying Gaussian noise, adding 0%, 5% and 10%.
Figure 13a compares the accuracy obtained between the descriptors. It can be seen that the accuracy of the descriptor MPFH is higher, even with the addition of noise, and although accuracy decreases with increasing the percentage of noise, it provides less of a slope than the PFH, FPFH, spin image and the radius-based surface descriptor (RSD).
In Figure 13b, the classification results varying the support radius for the calculation of the descriptors are displayed. We can also observe that while decreasing the classification accuracy with the variation in radius support, our method still has the greatest accuracy between descriptors. In Figure 13b, the qualitative results taking the 3D sampled surface of the artificial tooth, welding defect, and simulated defects models with added noise as test data are shown.
3.6. Performance Evaluation for Defects Recognition
This section evaluates the full methodology of surface defect recognition proposed in this paper. The set of training and test images consisted of 2160 regions labeled as holes, bumps, cracks and without defect.
In the detection stage, the points of the surface are classified into five primitives, the points belonging to a hollow (red), hollow edge (yellow), crest (magenta), base crest (blue), and flat (green) surfaces. The capacity of the local descriptor to represent and classify the regions of the surface can be seen in Figure 14, . However, it is also observed that misclassified primitives appear, which will affect the classification process.
The recognition stage was evaluated with the classification techniques: k-nearest neighbors (knn), linear discriminant analysis (LDA), quadratic discriminant analysis (QDA), multilayer perceptron, support vector machine (SVM) with radial basis function kernel (rbf), SVM with polynomial kernel function (poly), and SVM with a quadratic kernel (quad). In the evaluation process, we used 10-fold cross-validation. Table 3 shows the performance of each classifier. The performance was measured using the accuracy factor (Equation (20)).
(20) |
Table 3.
Classifier | knn (k = 10) | LDA | QDA | Multilayer Perceptron | SVM (rbf) | SVM (poly) | SVM (quad) |
---|---|---|---|---|---|---|---|
Accuracy | 90.09% | 86.22% | 66.89% | 93.95% | 94.17% | 87.72% | 93.05% |
The parameters () are the true positive for class , the elements () are false positives, () are false negatives, and finally, the the parameters () are the true negatives. The factor l is the class number.
Figure 15 shows the result of the classification for different images in the database. It can be seen from images that the recognition stage is able to correctly classify the defect. However, can be seen that in defective regions close to the edges of the object, our method erroneously classifies the region as without defect (Figure 15d). The misclassification could be attributed to the very low density of points in this regions, which causes a misclassification in primitives, affecting the recognition.
The average processing time of the automated inspection system is composed of the acquisition step, which is delayed 0.3 s, the processing and description step with 1.1 s for a region with 1817 points and three defects, and the classification step with 0.2 s. According to the above, the automated inspection system could detect defects on a surface in 1.6 s.
4. Conclusions
In this paper, we have presented a new local 3D surface descriptor that improves the robustness and discriminating capabilities of the PFH method. We have demonstrated its applicability for surface quality inspection in the detection of defects on different objects. The proposed MPFH method was evaluated and compared to some of the most used state-of-the-art descriptors under a classification task. The obtained results show that our method has higher discriminating capabilities, because we tried to capture the geometric information of the underlying 3D surface more precisely by estimating the normals from the models that are adjusted to the surface and including these in the construction of the descriptor. From the identification of primitives, we propose a method of description that projects each connected component of primitives on a plane forming the 2D image. Then, 2D geometric features are extracted to recognize the defect. With this method, three types of defects (holes, bumps, and cracks), with an accuracy of 94.17%, are recognized using an SVM. In the MPFH descriptor calculation, the models that best fit the surface are estimated through an estimation technique of multiple structures or models. In this paper the models are flat surfaces, however, we believe that if models can be fitted to polynomial surfaces or splines, this would help to estimate the normal vectors more correctly and the local region would be more accurately represented.
Acknowledgments
We give particular thanks to the research groups Automatic, Electronic, and Computer Sciences at ITM, GIDIA at the Universidad Nacional de Colombia at Medellin, and GRIMA at the Pontificia Universidad Católica de Chile.
Author Contributions
Carlos A. Madrigal contributed extensively to the entire work, in particular to the concept and implementation of the MPFH descriptor and the writing of the paper. John W. Branch and Alejandro Restrepo contributed to the work as scientific directors, designing the methodology of recognition, analyzing the results, and preparing the paper. The contribution of Domingo Mery focused on the concept of the descriptor MPFH, the analysis of results and feedback on the manuscript.
Conflicts of Interest
The authors declare no conflict of interest.
References
- 1.Jaramillo A., Prieto F., Boulanger P. Fast dimensional inspection of deformable parts from partial views. Comput. Ind. 2013;64:1076–1081. doi: 10.1016/j.compind.2013.03.016. [DOI] [Google Scholar]
- 2.Aubreton O., Bajard A., Verney B., Truchetet F. Infrared system for 3D scanning of metallic surfaces. Mach. Vis. Appl. 2013;24:1513–1524. doi: 10.1007/s00138-013-0487-z. [DOI] [Google Scholar]
- 3.Bokhabrine Y., Seulin R., Voon L.F.L.Y., Gorria P., Girardin G., Gomez M., Jobard D. 3D characterization of hot metallic shells during industrial forging. Mach. Vis. Appl. 2012;23:417–425. doi: 10.1007/s00138-010-0297-5. [DOI] [Google Scholar]
- 4.Malamas E.N., Petrakis E.G., Zervakis M., Petit L., Legat J.D. A survey on industrial vision systems, applications and tools. Image Vis. Comput. 2003;21:171–188. doi: 10.1016/S0262-8856(02)00152-X. [DOI] [Google Scholar]
- 5.Leach R.K. Optical Measurement of Surface Topography. Springer; Berlin, Germany: 2011. pp. 71–106. [Google Scholar]
- 6.Neogi N., Mohanta D.K., Dutta P.K. Review of vision-based steel surface inspection systems. EURASIP J. Image Video Process. 2014;50 doi: 10.1186/1687-5281-2014-50. [DOI] [Google Scholar]
- 7.Shen H., Li S., Gu D., Chang H. Bearing defect inspection based on machine vision. Measurement. 2012;45:719–733. doi: 10.1016/j.measurement.2011.12.018. [DOI] [Google Scholar]
- 8.Zhi H., Johansson R.B. Interpretation and classification of fringe patterns. Opt. Lasers Eng. 1992;17:9–25. doi: 10.1016/0143-8166(92)90023-Z. [DOI] [Google Scholar]
- 9.Caulier Y., Spinnler K., Wittenberg T., Bourennane S. Specific features for the analysis of fringe images. Opt. Eng. 2008;47:057201. doi: 10.1117/1.2927463. [DOI] [Google Scholar]
- 10.Osten W., Jueptner W.P., Mieth U. Knowledge-assisted evaluation of fringe patterns for automatic fault detection; Proceedings of the SPIE’s 1993 International Symposium on Optics, Imaging, and Instrumentation; San Diego, CA, USA. 11–16 July 1994; pp. 256–268. [Google Scholar]
- 11.Li Y., Ai J., Sun C. Online fabric defect inspection using smart visual sensors. Sensors. 2013;13:4659–4673. doi: 10.3390/s130404659. [DOI] [PMC free article] [PubMed] [Google Scholar]
- 12.Martínez S.S., Ortega J.G., García J.G., García A.S., Estévez E.E. An industrial vision system for surface quality inspection of transparent parts. Int. J. Adv. Manuf. Technol. 2013;68:1123–1136. doi: 10.1007/s00170-013-4904-2. [DOI] [Google Scholar]
- 13.Martínez S.S., Vázquez C.O., García J.G., Ortega J.G. Quality inspection of machined metal parts using an image fusion technique. Measurement. 2017;111:374–383. doi: 10.1016/j.measurement.2017.08.002. [DOI] [Google Scholar]
- 14.Pernkopf F. 3D surface acquisition and reconstruction for inspection of raw steel products. Comput. Ind. 2005;56:876–885. doi: 10.1016/j.compind.2005.05.025. [DOI] [Google Scholar]
- 15.Ogun P.S., Chamberlain M.R., Phairatt P.L., Tailor M.J., Jackson M.R. An active three-dimensional vision system for automated detection and measurement of surface defects. Proc. Inst. Mech. Eng. Part B J. Eng. Manuf. 2014;228:1543–1549. doi: 10.1177/0954405414522604. [DOI] [Google Scholar]
- 16.Chu H.H., Wang Z.Y. A vision-based system for post-welding quality measurement and defect detection. Int. J. Adv. Manuf. Technol. 2016;86:3007–3014. doi: 10.1007/s00170-015-8334-1. [DOI] [Google Scholar]
- 17.Song L.M., Li Z.Y., Chang Y.L., Xing G.X., Wang P.Q., Xi J.T., Zhu T.D. A color phase shift profilometry for the fabric defect detection. Optoelectron. Lett. 2014;10:308–312. doi: 10.1007/s11801-014-4065-z. [DOI] [Google Scholar]
- 18.Rodriguez-Martin M., Rodriguez-Gonzalvez P., Gonzalez-Aguilera D., Fernandez-Hernandez J. Feasibility study of a structured light system applied to welding inspection based on articulated coordinate measure machine data. IEEE Sens. J. 2017;17:4217–4224. doi: 10.1109/JSEN.2017.2700954. [DOI] [Google Scholar]
- 19.Chua C.S., Jarvis R. Point signatures: A new representation for 3D object recognition. Int. J. Comput. Vis. 1997;25:63–85. doi: 10.1023/A:1007981719186. [DOI] [Google Scholar]
- 20.Johnson A.E., Hebert M. Using spin images for efficient object recognition in cluttered 3D scenes. IEEE Trans. Pattern Anal. Mach. Intell. 1999;21:433–449. doi: 10.1109/34.765655. [DOI] [Google Scholar]
- 21.Rusu R.B., Blodow N., Marton Z.C., Beetz M. Aligning point cloud views using persistent feature histograms; Proceedings of the 2008 IEEE/RSJ International Conference on Intelligent Robots and Systems (IROS); Nice, France. 22–26 September 2008; pp. 3384–3391. [Google Scholar]
- 22.Rusu R.B., Blodow N., Beetz M. Fast point feature histograms (FPFH) for 3D registration; Proceedings of the IEEE International Conference on Robotics and Automation (ICRA); Kobe, Japan. 12–17 May 2009; pp. 3212–3217. [Google Scholar]
- 23.Rusu R.B., Bradski G., Thibaux R., Hsu J. Fast 3D recognition and pose using the viewpoint feature histogram; Proceedings of the 2010 IEEE/RSJ International Conference on the Intelligent Robots and Systems (IROS); Taipei, Taiwan. 18–22 October 2010; pp. 2155–2162. [Google Scholar]
- 24.Toldo R., Fusiello A. Robust multiple structures estimation with J-linkage; Proceedings of the European Conference on Computer Vision; Marseille, France. 12–18 October 2008; pp. 537–547. [Google Scholar]
- 25.Madrigal C.A., Restrepo A., Branch J.W. Identification of superficial defects in reconstructed 3D objects using phase-shifting fringe projection; Proceedings of the SPIE Optical Engineering + Applications; San Diego, CA, USA. 28 September–1 October 2016. [Google Scholar]
- 26.Hoppe H., DeRose T., Duchamp T., McDonald J., Stuetzle W. Surface Reconstruction from Unorganized Points. ACM; New York, NY, USA: 1992. [Google Scholar]
- 27.Fischler M.A., Bolles R.C. Random sample consensus: A paradigm for model fitting with applications to image analysis and automated cartography. Commun. ACM. 1981;24:381–395. doi: 10.1145/358669.358692. [DOI] [Google Scholar]
- 28.Fouhey D.F., Scharstein D., Briggs A.J. Multiple plane detection in image pairs using J-linkage; Proceedings of the 20th International Conference on Pattern Recognition (ICPR); Istanbul, Turkey. 23–26 August 2010; pp. 336–339. [Google Scholar]
- 29.Tardif J.P. Non-iterative approach for fast and accurate vanishing point detection; Proceedings of the IEEE 12th International Conference on Computer Vision; Kyoto, Japan. 29 September–2 October 2009; pp. 1250–1257. [Google Scholar]
- 30.Berkmann J., Caelli T. Computation of surface geometry and segmentation using covariance techniques. IEEE Trans. Pattern Anal. Mach. Intell. 1994;16:1114–1116. doi: 10.1109/34.334391. [DOI] [Google Scholar]
- 31.Wahl E., Hillenbrand U., Hirzinger G. Surflet-pair-relation histograms: A statistical 3D-shape representation for rapid classification; Proceedings of the Fourth International Conference on 3-D Digital Imaging and Modeling (3DIM); Banff, AB, Canada. 6–10 October 2003; pp. 474–481. [Google Scholar]
- 32.Zhao Y., Kramer T., Brown R., Xu X. Information Modeling for Interoperable Dimensional Metrology. Springer Science & Business Media; New York, NY, USA: 2011. [Google Scholar]
- 33.Mika S., Ratsch G., Weston J., Scholkopf B., Mullers K.R. Fisher discriminant analysis with kernels; Proceedings of the 1999 IEEE Signal Processing Society Workshop Neural Networks for Signal Processing; Madison, WI, USA. 25 August 1999; pp. 41–48. [Google Scholar]
- 34.Mery D. BALU: A Toolbox Matlab for Computer Vision, Pattern Recognition and Image Processing. [(accessed on 15 November 2016)];2011 Available online: http://bibbase.org/network/publication/mery-baluamatlabtoolboxforcomputervisionpatternrecognitionandimageprocessing-2011.