Stamping part surface defect intelligent detection method and device

Through a camera array with full viewing angle and the SSD object detection network of PeleeNet backbone, combined with the point cloud matching algorithm, intelligent detection of stamped parts surface defects is realized, solving the problems of low manual detection efficiency and low accuracy in the existing technology, and improving The detection stability and accuracy are suitable for a wide range of product sizes.

CN119198737APending Publication Date: 2024-12-27SUZHOU ZHENCHANG INTELLIGENT TECH CO LTD
View PDF 0 Cites 2 Cited by

Patent Information

Application Number
CN202411315617.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-09-20
Publication Date
2024-12-27

AI Technical Summary

Technical Problem

The existing stamping parts inspection methods rely on manual inspection, which are low in efficiency and low in detection accuracy, and cannot effectively identify diverse surface defects, and traditional inspection systems cannot comprehensively evaluate product quality.

Method used

Image acquisition and splicing are used for camera arrays with full viewing angles, combined with the SSD target detection network and point cloud matching algorithm of PeleeNet backbone, intelligent detection of surface defects of the stamped parts is realized, and the detection results are screened through the non-maximum suppression method, and the detection results are judged and Output defect information.

Benefits of technology

Improve the stability and accuracy of stamping parts inspection, realize the rapid identification of surface defects, reduce the labor intensity and cost of quality inspection workers, and can detect a single piece in 5 seconds, with an accuracy of 99.9%. It is suitable for a variety of product sizes. And reduce the number of camera layouts.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119198737A_ABST
    Figure CN119198737A_ABST
Patent Text Reader

Abstract

The invention discloses an intelligent detection method and device for surface defects of a stamping part, and the method comprises the steps: laying a camera array with full view angle coverage, and obtaining all angle images of the surface of the stamping part; splicing the angle images of the surface of the stamping part to obtain a complete image of the surface of the stamping part; inputting the complete surface image of the stamping part into the defect detection model to obtain defect detection information; and judging whether the stamping part has a defect type needing to be detected or not, and if yes, outputting defect information and giving an alarm. On the basis of machine vision and existing conditions of a production line, an image acquisition system is designed, and whether the stamping part has surface defects or not is quickly recognized through real-time image acquisition and intelligent analysis. By rapidly and intelligently detecting the surface defects of the stamping part, the stability and reliability of production line detection are improved (12 pcs can be detected per minute, the precision can reach + / -0.1 mm, and the accuracy rate is as high as 99.9%), and the problems of high labor intensity and labor cost of manual quality inspection are solved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention belongs to the field of defect detection, and in particular relates to a method and a device for intelligently detecting surface defects of stamping parts. Background Art

[0002] Automobile stamping parts are one of the important production parts in the field of automobile manufacturing. The measurement and inspection of automobile stamping parts is also the quality requirement of major automobile factories and parts factories. Due to the complexity and diversity of stamping parts manufacturing process, the types of manufacturing defects are complex and diverse.

[0003] The existing inspection method at the end of the stamping production line is manual inspection, which requires the rapid sorting of stamping parts with surface defects such as cracks, scratches, slip lines, bumps and bumps within the limited production cycle. The inspection standards are not unified, the stability is not high, and the quality inspection data is difficult to effectively quantify and store, which is not conducive to the collection of enterprise data resources, quality problem analysis and traceability. The limitations of the detection principles of eddy current, infrared and magnetic leakage detection technologies have led to very limited types of detectable defects and parameters for quantitative description of defects, and it is impossible to comprehensively evaluate the surface quality of the product. Therefore, the corresponding inspection system is only suitable for certain occasions with low application requirements.

[0004] Compared with the traditional manual stamping defect detection method, the CCD-based computer vision detection method has become the main method for stamping surface defect detection due to the characteristics of CCD devices themselves, such as lightness, high precision and easy configuration. However, due to the limitations of technical level and detection environment, the detection accuracy of the CCD-based computer vision surface defect detection system needs to be further improved. Summary of the invention

[0005] In order to solve the above technical problems, namely, the common problems in the existing automotive industry such as multiple and complex product specifications, low efficiency of manual inspection, and reliance on foreign technology for intelligent inspection, the present invention provides a method and device for intelligent inspection of surface defects of stamping parts.

[0006] The technical solution provided by the present invention is as follows:

[0007] A method for intelligently detecting surface defects of stamping parts, comprising the steps of:

[0008] S1. Arrange a camera array with full coverage of viewing angle to obtain images of the stamping part surface at various angles;

[0009] S2. stitching the images of the stamping part surface at various angles to obtain a complete image of the stamping part surface;

[0010] S3, inputting the complete image of the stamping part surface into the defect detection model to obtain defect detection information;

[0011] S4. Determine whether the stamping part has the defect type that needs to be detected. If so, output the defect information and issue an alarm.

[0012] Furthermore, in step S1, for a horizontal camera array composed of multiple cameras arranged horizontally, the steps for obtaining the horizontal viewing angle are:

[0013] Place the camera array on a horizontal table and keep its photosensitive plane parallel to the vertical wall;

[0014] Measure the distance from the optical center of each camera to the wall, and calculate the average distance as oc;

[0015] Use a laser pen to illuminate the wall and observe the image of the leftmost camera in the camera array, and move the laser pen to find the position point a on the wall of the left boundary of the left field of view of the leftmost camera; observe the image of the rightmost camera in the camera array, and move the laser pen to find the position point b on the wall of the right boundary of the right field of view of the rightmost camera; record the distance between the position point a and the position point b as ab;

[0016] Horizontal viewing angle

[0017] Preferably, the horizontal field of view angle of the camera array is greater than 50°, the vertical field of view angle is greater than 35°, and the fields of view of adjacent cameras must overlap to a certain extent; the camera array includes horizontal, divergent, convergent, and stereoscopic types.

[0018] Furthermore, in step S2, after acquiring the image information at each angle, it is converted into point cloud information, and then the point cloud information at multiple angles is aligned through a point cloud matching algorithm to obtain complete point cloud information of the stamping surface.

[0019] Preferably, the point cloud matching algorithm adopts an ICP-based color point cloud registration algorithm, and performs a preliminary registration of the point cloud by feature point matching before point cloud matching to ensure that the point cloud to be registered is initially aligned.

[0020] Furthermore, in step S3, the defect detection model adopts an SSD target detection network with PeleeNet as the backbone.

[0021] Furthermore, the target bounding box generated by the SSD target detection network is screened using the non-maximum suppression method, including the following steps:

[0022] Sort the bounding boxes in the bounding box set B from large to small according to their confidence;

[0023] Select the bounding box b with the highest confidence in the bounding box set B, and put b into the detection result A;

[0024] Calculate the intersection and union ratio of the remaining bounding boxes in bounding box set B with b, and delete the bounding boxes whose calculation results are greater than the threshold from bounding box B;

[0025] Repeat the above steps until the bounding box set B is empty.

[0026] Furthermore, in step S4, the defect types to be detected include indentations, cracks, missing edges, multiple edges, necking, and scratches; when the defects detected by the defect detection model belong to the defect types to be detected and reach the set defect index, it is determined that the corresponding stamping part has defects.

[0027] An intelligent detection device for stamping part surface defects based on the above method comprises a detection frame constructed of a plurality of profiles and a conveying module arranged at the lower part of the detection frame for conveying stamping parts, the detection frame is also provided with a plurality of detection cameras for photographing stamping parts, and a light source for illuminating stamping parts; and also comprises a central processing module connected to each camera;

[0028] The central processing module is equipped with an image stitching module and a defect detection model. The image stitching module is used to register and stitch the stamping part images taken by each camera to obtain a complete image of the stamping part surface. The defect detection model is used to perform defect detection on the stamping part image input therein and output defect detection information.

[0029] The central processing module is also used to set the stamping part defect type and corresponding defect index to be detected, and when the defect detected by the defect detection model meets the set defect type and corresponding defect index, output the defect information and corresponding stamping part information and alarm information;

[0030] The central processing module is also used to send the defect detection result to a remote server or a mobile terminal.

[0031] Furthermore, a plurality of detection cameras are arranged horizontally to form a flat scanning module, and the flat scanning module is also provided with a flipping mechanism for adjusting the shooting angle.

[0032] Compared with the prior art, the present invention has at least the following beneficial effects:

[0033] The present invention is based on the intelligent recognition and detection of stamping part defects by machine vision. Based on the existing conditions of the production line, the image acquisition system is designed. Through real-time image acquisition and intelligent analysis, it can quickly identify whether the stamping part has surface defects, and automatically store all detection images and process processing data to the big data platform. Through the association between quality inspection data, production process parameters, and product design parameters, with the help of big data analysis technology, a closed-loop connection for the analysis and management of stamping product quality problems is formed, and the precise control and optimization of stamping product quality are achieved. By quickly and intelligently detecting the surface defects of stamping parts, the stability and reliability of production line detection are improved, and the labor intensity and labor cost of quality inspection workers are reduced. The present invention shortens the full inspection time of a single stamping part to 5 seconds, and can detect 12 pieces per minute; it can detect a variety of product sizes with an accuracy of up to ±0.1mm and an accuracy rate of up to 99.9%; the number of camera layouts is reduced by 50% to 60%, and incremental camera layout can be performed. BRIEF DESCRIPTION OF THE DRAWINGS

[0034] The accompanying drawings are used to provide further understanding of the present invention and constitute a part of the specification. They are used to explain the present invention together with the embodiments of the present invention and do not constitute a limitation of the present invention.

[0035] Figure 1 is a schematic diagram of the camera field of view provided by an embodiment of the present invention;

[0036] Figure 2 is a schematic diagram of a divergent camera array provided by an embodiment of the present invention;

[0037] Figure 3 is a schematic diagram of a polymerized camera array provided by an embodiment of the present invention;

[0038] Figure 4 is a schematic diagram of a stereo camera array provided by an embodiment of the present invention;

[0039] Figure 5 is a schematic diagram of the PeleeNet-SSD network structure provided by an embodiment of the present invention;

[0040] Figure 6 is a schematic diagram of a lightweight residual network module provided by an embodiment of the present invention;

[0041] Figure 7 It is a schematic diagram of Default Boxes at multiple scales provided by an embodiment of the present invention;

[0042] Figure 8 It is a schematic diagram of the process of an intelligent detection method for surface defects of stamping parts provided by an embodiment of the present invention;

[0043] Fig. 9 It is a schematic diagram of the appearance of an intelligent detection device for surface defects of stamping parts provided by one embodiment of the present invention;

[0044] Fig.10 It is a structural schematic diagram of an intelligent detection device for surface defects of stamping parts provided by an embodiment of the present invention;

[0045] Fig.11 It is a structural front view of an intelligent detection device for surface defects of stamping parts provided by one embodiment of the present invention;

[0046] Fig.12 It is a structural side view of a stamping part surface defect intelligent detection device provided by an embodiment of the present invention;

[0047] Fig.13 A pan-scan camera array module is provided in one embodiment of the present invention. DETAILED DESCRIPTION

[0048] In order to make the purpose, technical solution and advantages of the embodiments of the present invention clearer, the technical solution in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, other embodiments obtained by ordinary technicians in this field without making creative work are all within the scope of protection of the present invention.

[0049] Embodiment 1

[0050] This embodiment provides an intelligent detection method for surface defects of stamping parts. Based on the existing conditions of the production line, an image acquisition system is designed. Through real-time image acquisition and intelligent analysis, it is possible to quickly identify whether there are surface defects on the stamping parts, and automatically store all detection images and process processing data on the big data platform. Through the correlation between quality inspection data, production process parameters, and product design parameters, with the help of big data analysis technology, a closed-loop connection for stamping product quality problem analysis and management is formed, thereby achieving precise control and optimization of stamping product quality.

[0051] 1. Distributed multi-camera array design based on field of view optimization

[0052] In view of the fact that a single camera or a single angle cannot penetrate the obstructed part of the irregular stamping part for inspection, this embodiment uses a distributed multi-camera array to optimize the camera position, alleviate the obstruction problem, and improve the comprehensiveness of the inspection. In this process, in order to reduce the redundancy of the system's collected information and reduce the computing burden of the central processor for defect detection, this embodiment focuses on data collection and function allocation: optimizing the distribution of camera positions based on the field of view angle as an indicator and local image stitching technology based on point cloud segmentation technology. Finally, a distributed multi-camera array acquisition system with the optimal field of view angle is formed.

[0053] (1) Camera arrangement design based on field of view optimization

[0054] In optical engineering, the field of view angle refers to the angle between the vertex of the optical instrument lens and the two boundary lines of the maximum range of the observed object that can be displayed in the lens. For optical devices such as cameras with rectangular photosensitive surfaces, the field of view angle is divided into horizontal field of view angle and vertical field of view angle according to the direction. Figure 1 As shown, o is the optical center of the camera, the angle between oa and ob is the horizontal field of view, and the angle between od and of is the vertical field of view. The size of the field of view angle determines the size of the camera's field of view. The larger the field of view angle, the larger the camera's field of view. The size of the field of view angle is a parameter of the camera itself, which has nothing to do with external conditions and is determined by the size of the photosensitive element and the focal length of the camera. Under ideal imaging conditions, the field of view of the camera can be theoretically calculated based on the size and focal length of the image sensor. In this embodiment, the camera uses a fixed-focus lens, so the field of view of a single camera is unchanged. In order to ensure that the camera monitors irregular stamping parts in all directions, multiple cameras are arranged in combination in this embodiment, resulting in the concept of a multi-camera field of view angle. For example, when multiple cameras are arranged horizontally, the angle formed by the left field of view boundary line of the leftmost camera and the right field of view boundary line of the rightmost camera is the horizontal multi-camera field of view angle, and the same applies to the vertical direction.

[0055] This embodiment uses a measurement method to calculate the camera field of view angle. For a single camera, place it on a horizontal table with its photosensitive plane parallel to the vertical wall, and measure the distance from the camera's optical center to the wall, that is, Figure 1 Observe the camera image, use the laser pen to illuminate the wall, move the laser pen to find the position points a and b on the wall where the camera's left and right field of view boundaries are located. Note that the vertical heights of a and b should be consistent with the camera's optical center. Make a mark on the wall and measure the distance between a and b. The camera's field of view angle can be calculated by the following formula:

[0056]

[0057] For multiple horizontally arranged cameras, the calculation method is similar, except that oc in formula (1) should be the average distance between the optical center of all cameras and the wall. In addition, point a is found using the image of the leftmost camera, and point b is found using the image of the rightmost camera. The position of the camera and the distance from the wall can be changed, and the average value can be taken after multiple measurements.

[0058] In order to ensure comprehensive monitoring of irregular stamping parts with different shielding and sizes, the production line has the following requirements for the layout of multiple cameras: ① There is a certain overlap in the field of view of adjacent cameras; ② The horizontal field of view angle is greater than 50° and the vertical field of view angle is greater than 35°. Figures 2 to 4 As shown, in addition to the horizontal arrangement, this embodiment designs divergent, convergent and stereoscopic camera arrays to meet different needs.

[0059] (2) Local image stitching technology based on point cloud segmentation technology

[0060] After acquiring the image information of multiple adjacent cameras, it is converted into point cloud information. After obtaining the point cloud information of multiple angles, this embodiment aligns the point cloud information of multiple angles through an iterative closest point (ICP) algorithm to obtain complete stamping part point cloud information.

[0061] Assume P is a colored point cloud and C(p) is a discrete point cloud function that sequentially retrieves the intensity of each point p. In order to use color information in optimization, it is necessary to generalize C(p) to a continuous function so that its gradient can be calculated.

[0062] Conceptually, we introduce a virtual orthographic camera that, for each point p∈P, is configured to observe the normal η along p p , the image plane of this virtual camera is the tangent plane at point p, which parameterizes a continuous color function C that can be expressed as p (u), where u is the vector along the tangent plane from p: uη p = 0. Function C p (u) can be approximated as the first-order approximation of the discrete point cloud function:

[0063]

[0064] where d p It is C p The gradient of (u). The least squares fitting method is used to estimate the gradient {C(p′)|p′∈N p}, where N p is the local neighborhood of p.

[0065] Specifically, let f(s) be the function that projects a 3D point s onto the tangent plane of p:

[0066] f(s)=sn p (sp) T n p (3)

[0067] Calculate d p The least squares fitting objective of is:

[0068]

[0069] There are additional constraints This is a linear least squares problem that can be solved efficiently during preprocessing.

[0070] Similarly, we can assume that the virtual camera has a depth channel and define a continuous depth function G p (u). Since G p The gradient of (u) at the origin is 0, so G p The first-order approximation of (u) is a constant function:

[0071] G p (u)≈(ο p -p) T n p (5)

[0072] Among them p is the origin of the virtual camera.

[0073] Assume P and Q are two color point clouds, and the goal is to find the optimal transformation T that aligns Q and P. This embodiment formulates a joint optimization goal:

[0074] E(T)=(1-σ)E C (T)+σE G (T) (6)

[0075] Where E C and E G are the photometric term and the geometric term respectively. σ∈[0,1] is the weight to balance the two terms.

[0076] Compared with the traditional ICP algorithm, one change made in this embodiment is to define the residual according to the correspondence set K = {(p, q)} instead of the pixel set {x}. Here, K is created according to the ICP algorithm: In each optimization iteration, K is recalculated as the distance between P and T k The set of corresponding pairs between Q, where T k is the current transformation. Using a virtual camera, project q onto point q′ on the tangent plane of p:

[0077] q′=f(s(q,T)) (7)

[0078] Where s is the rigid body transformation, and f is the projection function in equation (3). Using the local color function C in equation (2) p and the projection point q′ in equation (7), C Defined as:

[0079]

[0080] Similarly, extending to E G :

[0081]

[0082] G pSubstitute (q′) into equation (9) and eliminate the variable ο p :

[0083]

[0084] This function is equivalent to the point-to-plane objective in the ICP algorithm. When only the geometric term σ=1 is used, the algorithm is simplified to the point-to-plane ICP. In summary, the joint optimization objective can be written as:

[0085]

[0086] in and They are the photometric residual and the geometric residual, respectively:

[0087]

[0088] The Gauss-Newton method is used to minimize the nonlinear least squares objective E(T). In each iteration, we locally linearize T into a six-dimensional vector ξ = (α, β, γ, a, b, c), which can be organized into a rotation component ω and a translation component T. T can be approximated by a linear function ξ:

[0089]

[0090] Where T k is the transformation estimated in the last iteration. After the Gauss-Newton method, we solve the linear system by computing ξ:

[0091]

[0092] Where r is the residual vector, J r Its Jacobian matrix, in T k The value is:

[0093]

[0094] To find the partial derivatives of (20) and (21), we use (22) and apply the chain rule:

[0095]

[0096] in is the gradient pre-calculated for each point p∈P, J f (s) The Jacobian matrix of f obtained according to formula (3), J s (ξ) is the Jacobian matrix of s corresponding to ξ obtained according to formula (23).

[0097] In each iteration, we calculatek The residual r and Jacobian matrix J at r , using equation (14) to solve the linear system of equation (15), by applying the incremental transformation ξ to T k Update T. In the next iteration, we update T k+1 Reparameterize T and repeat.

[0098] Due to the non-convex nature of the objective function, the optimization may get stuck in a local minimum. To improve this problem, we use a coarse-to-fine scheme. We build a point cloud pyramid by downsampling the input point cloud using a voxel grid and increasing the size of the voxel. The downsampling algorithm approximates the points in each voxel with the centroid. Therefore, with respect to the optimization objective, the residual at a coarser level is the combination of several residuals at a finer level. At a coarser level, the objective function is smoother and can guide the Gauss-Newton method to find a deeper minimum. The optimization is performed at each level of the pyramid, from coarse to fine. The results at the coarse level will initialize the optimization at the next level.

[0099] After completing the multi-angle observation of the stamping parts, the point cloud information of the stamping parts at multiple angles is obtained. In order to obtain the complete point cloud of the stamping parts, the point cloud information at multiple angles needs to be spliced ​​together through the point cloud registration method. Due to the existence of factors such as the color, background, and lighting of the stamping parts themselves, in order to be able to more accurately splice the point cloud information from multiple angles, the above-mentioned ICP-based color point cloud registration algorithm uses the point cloud coordinate information to achieve point pair registration while integrating the color information of the point cloud, and downsamples the source point cloud and the target point cloud multiple times to continuously optimize the registration accuracy.

[0100] In some embodiments, in order to further improve the efficiency and accuracy of point cloud registration, before performing the above-mentioned ICP-based color point cloud registration algorithm, the point cloud to be registered needs to be preliminarily registered through feature point matching (corner point registration, contour matching) or other coarse registration methods to ensure that the two point clouds are roughly aligned.

[0101] (3) Defect detection model based on artificial intelligence

[0102] In the SSD target detection network with PeleeNet (Pelee: A Real-Time Object Detection System on Mobile Devices) as the backbone, Figure 5As shown in the figure, the Feature Maps of 5 scales (19×19, 10×10, 5×5, 3×3, 1×1) are connected to the detection branch. PeleeNet is used for feature extraction in the first half of the network. In the second half of the detection, the Feature Maps of 5 different scales are classified and regressed to generate multiple bounding boxes. The bounding boxes obtained from different Feature Maps are combined, and a part of the overlapping or incorrect bounding boxes are suppressed by the non-maximum suppression method to generate the final detection result. In order to ensure the feature expression ability, a lightweight residual block is added for feature extraction before prediction. Its structure is as follows: Figure 6 shown.

[0103] The multi-scale feature map proposed in SSD object detection is used for detection. The multi-scale here refers to multiple feature maps of different sizes. In SSD, default boxes with different scales or aspect ratios are set for each unit, and the predicted bounding boxes are based on these default boxes, such as Figure 7 As shown in the figure, the dotted box represents the Default Boxes. Five feature maps of different sizes are extracted from the first five feature layers. The number, size and aspect ratio of the prior boxes required for these five feature maps are also different. The calculation formula for the size calculation ratio of the prior box anchor is:

[0104]

[0105] Where S min is 0.2, S max is 0.9, m is the number of feature maps 5, S k The size of the anchor can be obtained by multiplying it by the size of the input image. k is the coefficient of the aspect ratio of the anchor box, which is generally set to 1, 2, 3, 1 / 2, and 1 / 3. The sum of the sizes of the five feature maps multiplied by the number of prior boxes is the number of Default Boxes that can be predicted by the image.

[0106] A large number of bounding boxes will be generated under multi-scale feature operations, which contain many erroneous and redundant samples. These samples need to be deleted from the bounding box set B. Non-maximum suppression is used here, and its operation process is divided into the following steps:

[0107] Sort the bounding boxes in the bounding box set B from large to small according to their confidence;

[0108] Select the bounding box b with the highest confidence in the bounding box set, and put b into the final detection result A;

[0109] The bounding boxes in the remaining bounding box set B are calculated with the intersection over union (IOU) ratio of b, and the bounding boxes whose corresponding calculation results are greater than the threshold are deleted from the bounding box set B;

[0110] Repeat the above steps until the bounding box set B is empty.

[0111] In deep learning, the choice of loss function is crucial. Choosing a reasonable loss function can greatly improve the accuracy of the algorithm. There are many kinds of loss functions, such as 0-1 loss function, cross entropy loss function, sorting loss function and triplet loss. This embodiment uses Cross Entropy Loss and triplet loss. Cross Entropy Loss is mainly used to determine the closeness between the output value and the expected value, and use this difference to update the network parameters through back propagation.

[0112] H(x i )=-[p(x i )log(p(x i ))+(1-p(x i ))log(1-p(x i ))] (25)

[0113] H(p,q)=-∑ x (p(x))log(q(x))+(1-p(x))log(1-q(x)) (26)

[0114] The amount of information is used to measure the uncertainty of an event; the greater the probability of an event, the smaller the uncertainty, and the smaller the amount of information it carries. Assume that X is a discrete random variable, its value set is X, and the probability distribution function is p(x) = P(X = x). Define the amount of information of event X = x0 as: I(x0) = -log(p(x0)). When p(x0) = 1, the entropy will be equal to 0, which means that the occurrence of this event will not lead to any increase in the amount of information. Entropy is a measure of the degree of disorder of a system. The greater the uncertainty of an event, the greater the total amount of information. p(x i ) represents the probability of the i-th type of event occurring.

[0115] Cross entropy is used to calculate the distance between the actual probability and the expected probability. The smaller the cross entropy value, the closer the two probability distributions are. Assume that probability distribution p is the expected output, probability distribution q is the actual output, and H(p,q) is the cross entropy.

[0116] In summary, the intelligent detection method for stamping surface defects provided in this embodiment mainly includes five steps: camera layout, image acquisition, image stitching, intelligent detection and judgment and decision making. Figure 8 As shown, specifically:

[0117] Arrange a camera array with full coverage of viewing angle to obtain complete images of stamping parts from all angles;

[0118] Each camera takes images of the stamping parts at different angles;

[0119] The images of stamping parts taken by the camera at different angles are stitched together to obtain a complete image of the stamping parts surface;

[0120] The stitched images are input into the AI ​​detection model for defect detection to obtain information such as defect type, width, height, area, and perimeter;

[0121] Determine whether the detected defect type belongs to the defect type that needs to be detected for stamping parts; if so, further determine whether it meets the defect standard based on the width, height, area, perimeter and other information of the defect. If so, output the defect information and issue an alarm.

[0122] Embodiment 2

[0123] Based on the above method, this embodiment provides an intelligent detection device for surface defects of stamping parts, such as Figures 9 to 12 As shown, it mainly includes: a detection frame built by several profiles and a conveying module arranged at the lower part of the detection frame for conveying stamping parts. The detection frame is also provided with several detection cameras for photographing stamping parts, and a light source for illuminating stamping parts; it also includes a central processing module (computer) connected to each camera, and the central processing module is deployed with an image stitching module and a pre-trained defect detection model. The image stitching module is used to align and stitch the stamping part images taken by each camera through the above-mentioned image stitching technology to obtain a complete surface image of the stamping part. The defect detection model is used to perform defect detection on the stamping part image input therein, and output the detected defect type, width, height, area, perimeter and other information; the central processing module is also used to set the stamping part defect type (indentation, cracking, few edges, multiple edges, necking, scratches, etc.) and the corresponding defect standards (such as width, height, area, perimeter thresholds, etc.) of the stamping parts to be detected. When the defect detected by the defect detection model meets the set defect type and the corresponding defect standard, the defect information, the corresponding stamping part information and the alarm information are output.

[0124] like Fig.13 As shown, the detection cameras are arranged in a horizontal array at a certain interval according to their respective field of view angles to form a flat scanning module, and multiple groups of flat scanning modules can be set at different positions of the detection frame. In some embodiments, the flat scanning module is also provided with a flip mechanism for adjusting the shooting angle of the flat scanning module.

[0125] In some embodiments, the central processing module is also used to send the defect detection results to a remote server or mobile terminal, so that relevant personnel can obtain the detection information in a timely manner.

[0126] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit them. Under the concept of the present invention, the technical features in the above embodiments or different embodiments may also be combined, the steps may be implemented in any order, and there are many other changes in different aspects of the present invention as described above, which are not provided in detail for the sake of simplicity. Although the present invention has been described in detail with reference to the aforementioned embodiments, a person of ordinary skill in the art should understand that the technical solutions described in the aforementioned embodiments may still be modified, or some of the technical features may be replaced by equivalents. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the scope of the technical solutions of the embodiments of the present application.

Claims

1. An intelligent detection method for surface defects of stamping parts, characterized in that: Includes steps: S1. Arrange a camera array with full coverage of viewing angle to obtain images of the stamping part surface at various angles; S2. stitching the images of the stamping part surface at various angles to obtain a complete image of the stamping part surface; S3, inputting the complete image of the stamping part surface into the defect detection model to obtain defect detection information; S4. Determine whether the stamping part has the defect type that needs to be detected. If so, output the defect information and issue an alarm.

2. The intelligent detection method for stamping part surface defects according to claim 1, characterized in that: In step S1, for a horizontal camera array consisting of multiple cameras arranged horizontally, the steps for obtaining the horizontal viewing angle are as follows: Place the camera array on a horizontal table and keep its photosensitive plane parallel to the vertical wall; Measure the distance from the optical center of each camera to the wall, and calculate the average distance as oc; Use a laser pen to illuminate the wall and observe the image of the leftmost camera in the camera array. Move the laser pen to find the position point a of the left field boundary of the leftmost camera on the wall. Observe the image of the rightmost camera in the camera array, and move the laser pointer to find the position point b of the right field boundary of the rightmost camera on the wall; The distance between position point a and position point b is recorded as ab; Horizontal viewing angle 3. The intelligent detection method for stamping part surface defects according to claim 1, characterized in that: The horizontal field of view angle of the camera array is greater than 50°, the vertical field of view angle is greater than 35°, and the fields of view of adjacent cameras must overlap to a certain extent; the camera array includes horizontal, divergent, convergent, and stereoscopic types.

4. The intelligent detection method for stamping part surface defects according to claim 1, characterized in that: In step S2, after acquiring the image information at each angle, it is converted into point cloud information, and then the point cloud information at multiple angles is registered through a point cloud matching algorithm to obtain complete point cloud information of the stamping surface.

5. The intelligent detection method for stamping part surface defects according to claim 4, characterized in that: The point cloud matching algorithm adopts an ICP-based color point cloud registration algorithm, and performs a preliminary registration of the point cloud by feature point matching before point cloud matching to ensure that the point cloud to be registered is initially aligned.

6. The intelligent detection method for stamping part surface defects according to claim 1, characterized in that: In step S3, the defect detection model uses the SSD target detection network with PeleeNet as the backbone.

7. The intelligent detection method for stamping part surface defects according to claim 6, characterized in that: The target bounding box generated by the SSD target detection network is screened using the non-maximum suppression method, including the following steps: Sort the bounding boxes in the bounding box set B from large to small according to their confidence; Select the bounding box b with the highest confidence in the bounding box set B, and put b into the detection result A; Calculate the intersection and union ratio of the remaining bounding boxes in bounding box set B with b, and delete the bounding boxes whose calculation results are greater than the threshold from bounding box B; Repeat the above steps until the bounding box set B is empty.

8. The intelligent detection method for stamping part surface defects according to claim 1, characterized in that: In step S4, the defect types to be detected include indentation, cracking, missing edges, multiple edges, necking, and scratches; When the defect detected by the defect detection model belongs to the defect type that needs to be detected and reaches the set defect index, it is determined that the corresponding stamping part has a defect.

9. An intelligent detection device for stamping surface defects based on the method according to any one of claims 1 to 8, characterized in that: It includes a detection frame constructed of several profiles and a conveying module arranged at the lower part of the detection frame for conveying stamping parts. The detection frame is also provided with several detection cameras for photographing stamping parts and a light source for illuminating stamping parts; it also includes a central processing module connected to each camera; The central processing module is equipped with an image stitching module and a defect detection model. The image stitching module is used to register and stitch the stamping part images taken by each camera to obtain a complete image of the stamping part surface. The defect detection model is used to perform defect detection on the stamping part image input therein and output defect detection information. The central processing module is also used to set the stamping part defect type and corresponding defect index to be detected, and when the defect detected by the defect detection model meets the set defect type and corresponding defect index, output the defect information and corresponding stamping part information and alarm information; The central processing module is also used to send the defect detection result to a remote server or a mobile terminal.

10. The intelligent detection device for surface defects of stamping parts according to claim 9, characterized in that: A plurality of detection cameras are arranged horizontally to form a flat scanning module, and the flat scanning module is also provided with a flipping mechanism for adjusting the shooting angle.

Citation Information

Cited By

  • Motor appearance defect identification method based on machine vision

    CN120912575A

  • Code nail stamping defect detection method and system based on machine vision

    CN121258954A