A surface quality detection method and system for automobile exterior products

Through automated and intelligent detection methods, defect characteristics in the surface images of automotive exterior products are extracted, solving the problem of time-consuming and labor-intensive manual inspection and high error rate, and achieving more efficient and accurate surface quality detection.

CN119338825BActive Publication Date: 2025-04-11NANCHANG HUAXIANG AUTOMOBILE INTERIOR & EXTERIOR PARTS CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202411886513.7
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-12-20
Publication Date
2025-04-11
Estimated Expiration
2044-12-20

AI Technical Summary

Technical Problem

In the prior art, manual detection of surface quality defects of automotive exterior products is time-consuming and labor-intensive and has a high error rate, making it difficult to meet the needs of modern industrial production.

Method used

It provides a surface quality detection method for automotive exterior products, including acquiring surface images and performing grayscale processing and image enhancement, filtering background information and extracting feature images, edge detection and defect type determination, and replacing manual detection through automated and intelligent detection methods.

Benefits of technology

By extracting defect features in surface images, avoiding errors and omissions, improving the comprehensiveness and accuracy of detection, reducing the detection error rate, and improving detection efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119338825B_ABST
    Figure CN119338825B_ABST
Patent Text Reader

Abstract

The present invention provides a surface quality detection method and system for automobile exterior products, the method comprising: obtaining a surface image corresponding to the exterior product, and then obtaining a standby image; filtering the background information of the standby image to obtain a first feature image, and extracting features of the standby image based on the pixel grayscale value of the standby image to obtain a second feature image; extracting a first redundant image and a first feature image from the first feature image, and extracting a second redundant image and a second feature image from the second feature image, and then obtaining a final feature image; obtaining edge detection parameters and detection thresholds of the final feature image to extract several contour areas; selecting and eliminating exterior contours and exterior logo contours from several contour areas to obtain several defect contours, and determining the defect type based on the defect contours. By replacing manual detection with an automated and intelligent detection method, the detection error rate is reduced and the detection efficiency is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of automobile component detection, and in particular to a surface quality detection method and system for automobile exterior products. Background Art

[0002] After more than ten years of rapid development, the automobile market has seen an increasing number of motor vehicles nationwide. As one of the means of transportation, automobiles have become popular in human society.

[0003] Different cars will use different exterior decoration products to improve the beauty and safety of the car. As an important carrier of the intuitive expression of the car, the beauty and quality of the exterior decoration products will directly determine the customer's first impression.

[0004] During the production process of automotive exterior products, there may be surface quality defects such as scratches, which not only affect the aesthetics of the exterior products, but also pose certain safety hazards. Currently, the surface quality inspection of automotive exterior products mainly relies on manual inspection, which not only has the possibility of mis-inspection and missed inspection, but is also time-consuming and labor-intensive, and cannot meet the needs of modern industrial production. Summary of the invention

[0005] In view of the shortcomings of the prior art, the purpose of the present invention is to provide a surface quality inspection method and system for automobile exterior products, aiming to solve the technical problem that manual inspection of surface quality defects of automobile exterior products in the prior art is not only time-consuming and labor-intensive, but also has a large inspection error rate.

[0006] In order to achieve the above objectives, in a first aspect, an embodiment of the present application provides a surface quality detection method for an automobile exterior product, comprising the following steps:

[0007] Acquire a surface image corresponding to the exterior product, and perform grayscale processing and image enhancement processing on the surface image in sequence to obtain a standby image;

[0008] Performing filtering processing on the background information of the image to be used to obtain a first feature image, and performing feature extraction on the image to be used based on the pixel grayscale value of the image to be used to obtain a second feature image;

[0009] Extracting a first redundant map and a first characteristic map from the first characteristic image, and extracting a second redundant map and a second characteristic map from the second characteristic image, and acquiring a final characteristic image based on the first redundant map, the first characteristic map, the second redundant map, and the second characteristic map;

[0010] Acquire edge detection parameters and a detection threshold of the final feature image, and acquire a plurality of contour regions from the final feature image based on the edge detection parameters and the detection threshold;

[0011] Select and eliminate the exterior contours from the plurality of contour areas to obtain a plurality of contours to be selected, compare the contours to be selected with preset identification contours to eliminate the exterior identification contours, and obtain a plurality of defect contours, and determine the defect type based on the defect contours.

[0012] Compared with the prior art, the beneficial effects of the present invention are as follows: by filtering the background information, the first characteristic image is obtained, and a larger range of defect features in the surface image are extracted; by obtaining the second characteristic image based on the pixel grayscale value, more detailed defect features in the surface image are extracted; and then by combining the first characteristic image with the second characteristic image, it is ensured that all defect features of the surface image are obtained, and the omission of defects is avoided, thereby improving the comprehensiveness of surface quality detection; by eliminating the exterior contour and the exterior logo area, the edges of the exterior products and the logos on the exterior are avoided from being mixed with the defects, thereby improving the accuracy of quality detection; by replacing manual detection with automated and intelligent detection methods, the probability of false detection and missed detection is reduced, that is, the detection error rate is effectively reduced, and the detection efficiency is improved.

[0013] Furthermore, the step of filtering the background information of the image to be used to obtain the first feature image includes:

[0014] Convert the image to be used from the spatial domain to the frequency domain to obtain a phase spectrum and an amplitude spectrum of the image to be used, and obtain a logarithmic spectrum corresponding to the image to be used through the amplitude spectrum;

[0015] The logarithmic spectrum is filtered to obtain residual information, and a first characteristic image is constructed based on the phase spectrum and the residual information.

[0016] Furthermore, the formula for obtaining the residual information is:

[0017] ,

[0018] in, Represents the residual information, represents the log spectrum, represents a filter;

[0019] The formula for obtaining the first characteristic image is:

[0020] ,

[0021] in, represents the first feature image, represents Gaussian smoothing, represents the inverse Fourier transform, represents the phase spectrum, Represents an exponential function.

[0022] Furthermore, the step of extracting features from the stand-by image based on the pixel grayscale values ​​of the stand-by image to obtain a second feature image includes:

[0023] Comparatively adjusting each pixel of the standby image based on the pixel grayscale values ​​of different pixels in the standby image to obtain an adjusted grayscale value;

[0024] The spatial feature of the pixel point is obtained by adjusting the grayscale value, and the pixel feature is obtained by adjusting the grayscale value and the spatial feature, thereby forming a second feature map.

[0025] Furthermore, the formula for obtaining the adjusted gray value is:

[0026] ,

[0027] in, represents the adjusted gray value of the i-th pixel, represents the frequency weight, Represents the pixel gray value weight, Represents the pixel gray value of the i-th pixel, represents the grayscale value of the jth pixel, and j≠i, represents the frequency corresponding to the pixel gray value of the jth pixel;

[0028] The formula for obtaining the spatial features is:

[0029] ,

[0030] in, represents the spatial feature of the i-th pixel, Represents the horizontal coordinate of the i-th pixel in the spatial coordinate system, Represents the ordinate of the i-th pixel in the spatial coordinate system, Indicates the height of the image to be used, Indicates the width of the image to be used, Indicates the total number of pixels in the image to be used.

[0031] Furthermore, the step of acquiring a final feature image based on the first redundant map, the first feature map, the second redundant map and the second feature map includes:

[0032] Respectively obtain a first similarity value and a second similarity value between the second redundant image, the second feature image and the first feature image, and obtain a first image to be fused through the first similarity value and the second similarity value;

[0033] Respectively obtaining a third similarity value and a fourth similarity value between the first redundant image, the first feature image, and the second feature image, and obtaining a second image to be fused through the third similarity value and the fourth similarity value;

[0034] The first image to be fused and the second image to be fused are combined into a final feature image.

[0035] Furthermore, the calculation formula of the first similarity value is:

[0036] ,

[0037] in, represents the first similarity value, represents the total number of pixels in the second redundant image, represents the number of pixels in the second redundant image corresponding to the mth color value in the first feature image;

[0038] The calculation formula of the second similarity value is:

[0039] ,

[0040] in, represents the second similarity value, Represents the total number of pixels in the second feature map, Represents the number of pixels in the second feature image that correspond to the mth color value in the first feature image.

[0041] Furthermore, the step of obtaining edge detection parameters and detection thresholds of the final feature image includes:

[0042] Constructing a configuration table, the configuration table including a plurality of preset noise intensity ranges and backup parameters and backup thresholds corresponding to the preset noise intensity ranges;

[0043] The signal-to-noise ratio of the final feature image is obtained, and the signal-to-noise ratio is compared with a plurality of preset noise intensity ranges to determine an edge detection parameter from a plurality of the spare parameters, and to determine a detection threshold from a plurality of the spare thresholds.

[0044] Furthermore, the step of selecting and removing the external contours from the plurality of contour areas includes:

[0045] Determine whether two opposite ends of the contour area abut against two opposite edges of the final feature image, and if both opposite ends of the contour area abut against two opposite edges of the final feature image, select the contour area as a candidate area;

[0046] It is determined whether the angle between the selected area and the top or bottom of the final feature image is less than a preset angle range. If the angle is less than the preset angle range, the contour area is selected as the exterior contour and the exterior contour is removed.

[0047] In a second aspect, an embodiment of the present application provides a surface quality detection system for an automobile exterior product, which is applied to the surface quality detection method for an automobile exterior product as described in the first aspect above, and the system comprises:

[0048] An acquisition module, used to acquire a surface image corresponding to the exterior product, and to perform grayscale processing and image enhancement processing on the surface image in sequence to acquire a standby image;

[0049] A first extraction module is used to filter the background information of the standby image to obtain a first feature image, and extract features of the standby image based on the pixel gray value of the standby image to obtain a second feature image;

[0050] A second extraction module, configured to extract a first redundant map and a first characteristic map from the first characteristic image, and to extract a second redundant map and a second characteristic map from the second characteristic image, and to obtain a final characteristic image based on the first redundant map, the first characteristic map, the second redundant map, and the second characteristic map;

[0051] An analysis module, used for obtaining edge detection parameters and a detection threshold of the final feature image, and obtaining a plurality of contour regions from the final feature image based on the edge detection parameters and the detection threshold;

[0052] The detection module is used to select and eliminate the exterior contours from the plurality of contour areas to obtain a plurality of contours to be selected, compare the contours to be selected with preset identification contours to eliminate the exterior identification contours, and obtain a plurality of defect contours, and determine the defect type based on the defect contours.

[0053] In a third aspect, an embodiment of the present application provides a computer, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the computer program, the surface quality detection method for automotive exterior products as described in the first aspect above is implemented.

[0054] In a fourth aspect, an embodiment of the present application provides a storage medium having a computer program stored thereon, which, when executed by a processor, implements the surface quality detection method for automobile exterior products as described in the first aspect above. BRIEF DESCRIPTION OF THE DRAWINGS

[0055] Figure 1It is a flow chart of the surface quality detection method of the automobile exterior product in the first embodiment of the present invention;

[0056] Figure 2 It is a structural block diagram of a surface quality detection system for automobile exterior products in a second embodiment of the present invention;

[0057] The following specific implementation manner will further illustrate the present invention in conjunction with the above-mentioned drawings. DETAILED DESCRIPTION

[0058] In order to facilitate the understanding of the present invention, the present invention will be described more fully below with reference to the relevant drawings. Several embodiments of the present invention are given in the drawings. However, the present invention can be implemented in many different forms and is not limited to the embodiments described herein. On the contrary, the purpose of providing these embodiments is to make the disclosure of the present invention more thorough and comprehensive.

[0059] It should be noted that when an element is referred to as being "fixed to" another element, it may be directly on the other element or there may be a central element. When an element is considered to be "connected to" another element, it may be directly connected to the other element or there may be a central element at the same time. The terms "vertical", "horizontal", "left", "right" and similar expressions used herein are for illustrative purposes only.

[0060] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as those commonly understood by those skilled in the art to which the present invention belongs. The terms used herein in the specification of the present invention are only for the purpose of describing specific embodiments and are not intended to limit the present invention. The term "and / or" used herein includes any and all combinations of one or more of the related listed items.

[0061] See also Figure 1 The surface quality detection method of the automobile exterior product provided by the first embodiment of the present invention comprises the following steps:

[0062] S10: Acquire a surface image corresponding to the exterior product, and perform grayscale processing and image enhancement processing on the surface image in sequence to obtain a standby image;

[0063] In this embodiment, a CMOS camera is selected, and a lens with 5 million pixels and a focal length range of 6 mm is selected to obtain the surface image. The grayscale processing and the image enhancement processing have been widely used in image processing, and will not be described in detail here.

[0064] S20: filtering the background information of the image to be used to obtain a first feature image, and extracting features of the image to be used based on the pixel grayscale value of the image to be used to obtain a second feature image;

[0065] The step S20 comprises:

[0066] S210: converting the image to be used from the spatial domain to the frequency domain to obtain a phase spectrum and an amplitude spectrum of the image to be used, and obtaining a logarithmic spectrum corresponding to the image to be used through the amplitude spectrum;

[0067] The calculation formula of the log spectrum is:

[0068] ,

[0069] in, represents the log spectrum, represents the amplitude spectrum, Represents a logarithmic function.

[0070] S220: Filter the log spectrum to obtain residual information, and construct a first feature image based on the phase spectrum and the residual information.

[0071] The formula for obtaining the residual information is:

[0072] ,

[0073] in, Represents the residual information, represents the log spectrum, represents a filter;

[0074] The formula for obtaining the first characteristic image is:

[0075] ,

[0076] in, represents the first feature image, represents Gaussian smoothing, represents the inverse Fourier transform, represents the phase spectrum, Represents an exponential function.

[0077] S230: performing comparative adjustment on each pixel of the standby image based on the pixel grayscale values ​​of different pixels in the standby image to obtain an adjusted grayscale value;

[0078] The formula for obtaining the grayscale value is:

[0079] ,

[0080] in, represents the adjusted gray value of the i-th pixel, represents the frequency weight, Represents the pixel gray value weight, Represents the pixel gray value of the i-th pixel, represents the grayscale value of the jth pixel, and j≠i, Represents the frequency corresponding to the pixel grayscale value of the jth pixel.

[0081] Specifically, when the ratio between the frequency corresponding to the adjusted grayscale value of the i-th pixel and the maximum frequency corresponding to the adjusted grayscale values ​​of all the pixels in the stand-by image is between 0.05 and 1, the value of α is 1, otherwise the value of α is 0.6; when the difference between the adjusted grayscale value of the i-th pixel and the most frequent adjusted grayscale value in the stand-by image is between 100 and 255, the value of β is 0.8, otherwise the value of β is 1.

[0082] S240: obtaining spatial features of the pixel points by adjusting the grayscale values, and obtaining pixel features by adjusting the grayscale values ​​and the spatial features, thereby forming a second feature map;

[0083] The formula for obtaining the grayscale value is:

[0084] ,

[0085] in, represents the adjusted gray value of the i-th pixel, represents the frequency weight, Represents the pixel gray value weight, Represents the pixel gray value of the i-th pixel, represents the grayscale value of the jth pixel, and j≠i, represents the frequency corresponding to the pixel gray value of the jth pixel;

[0086] The formula for obtaining the spatial features is:

[0087] ,

[0088] in, represents the spatial feature of the i-th pixel, Represents the horizontal coordinate of the i-th pixel in the spatial coordinate system, Represents the ordinate of the i-th pixel in the spatial coordinate system, Indicates the height of the image to be used, Indicates the width of the image to be used, Indicates the total number of pixels in the image to be used.

[0089] The formula for obtaining the pixel features is:

[0090] ,

[0091] in, Represents the pixel features of the i-th pixel.

[0092] S30: extracting a first redundant map and a first characteristic map from the first characteristic image, and extracting a second redundant map and a second characteristic map from the second characteristic image, and acquiring a final characteristic image based on the first redundant map, the first characteristic map, the second redundant map, and the second characteristic map;

[0093] It can be understood that the first redundant map is the background area in the first feature image, and the second redundant map is the background area in the second feature image. In this embodiment, the first redundant map and the first feature map are obtained from the first feature image by binary segmentation, and the second redundant map and the second feature map are obtained from the second feature image.

[0094] Specifically, the step S30 includes:

[0095] S310: respectively obtaining a first similarity value and a second similarity value between the second redundant image, the second feature image and the first feature image, and obtaining a first image to be fused through the first similarity value and the second similarity value;

[0096] The calculation formula of the first similarity value is:

[0097] ,

[0098] in, represents the first similarity value, represents the total number of pixels in the second redundant image, represents the number of pixels in the second redundant image corresponding to the mth color value in the first feature image;

[0099] The calculation formula of the second similarity value is:

[0100] ,

[0101] in, represents the second similarity value, Represents the total number of pixels in the second feature map, Represents the number of pixels in the second feature image that correspond to the mth color value in the first feature image.

[0102] The formula for obtaining the first image to be fused is:

[0103] ,

[0104] in, represents the first graph to be fused, Represents the mth color value in the first feature image.

[0105] S320: respectively obtaining a third similarity value and a fourth similarity value between the first redundant image, the first feature image, and the second feature image, and obtaining a second image to be fused through the third similarity value and the fourth similarity value;

[0106] The third similarity value and the fourth similarity value are obtained in the same manner as the first similarity value and the second similarity value, and the second image to be fused is obtained in the same manner as the first image to be fused, which will not be described in detail here.

[0107] S330: combining the first image to be fused and the second image to be fused into a final feature image;

[0108] In this embodiment, the first image to be fused and the second image to be fused are superimposed as the final feature image. It can be understood that by obtaining the similarity values ​​between the second redundant image, the second feature image and the first feature image, and by obtaining the similarity values ​​between the first redundant image, the first feature image and the second feature image, the dependency relationship between the first feature image and the second feature image can be fully described, thereby ensuring that the final feature image obtained can fully describe the defect area.

[0109] S40: Acquire edge detection parameters and a detection threshold of the final feature image, and acquire a plurality of contour regions from the final feature image based on the edge detection parameters and the detection threshold;

[0110] Edge detection algorithms that use parameters and thresholds for edge detection have been used frequently and will not be described in detail here. The surface images corresponding to the same type of exterior products are not very different, so there is no need to use a more complex adaptive threshold and parameter determination method to reduce the detection efficiency due to a larger amount of calculation. However, there are still differences between different surface images due to environmental factors such as shooting. If fixed thresholds and parameters are used, it is easy to cause errors such as incomplete extraction of the contour area, resulting in reduced detection accuracy and comprehensiveness. Therefore, step S40 includes:

[0111] S410: constructing a configuration table, wherein the configuration table includes a plurality of preset noise intensity ranges and backup parameters and backup thresholds corresponding to the preset noise intensity ranges;

[0112] It should be noted that the configuration table can be constructed based on the working experience of experts.

[0113] S420: Acquire a signal-to-noise ratio of the final feature image, compare the signal-to-noise ratio with a plurality of preset noise intensity ranges, determine an edge detection parameter from a plurality of the spare parameters, and determine a detection threshold from a plurality of the spare thresholds;

[0114] It can be understood that the preset noise intensity range is the same as the concept of the signal-to-noise ratio, only the numerical value is different. By constructing the configuration table, the determination of the adaptive threshold and parameters in a small range can be quickly completed, and the calculation amount is reduced and the detection efficiency is improved while ensuring the comprehensive extraction of the contour area.

[0115] S50: selecting and eliminating exterior contours from the plurality of contour areas to obtain a plurality of contours to be selected, comparing the contours to be selected with preset identification contours to eliminate the exterior identification contours, and obtaining a plurality of defect contours, and determining defect types based on the defect contours;

[0116] When shooting the surface image, since the shooting area is not limited to the exterior decoration products but also includes the background area, the exterior decoration contour formed by the edge of the exterior decoration product will also be extracted, and its contour similarity with defects such as cracks is high. Therefore, the exterior decoration contour needs to be eliminated, and for each exterior decoration product, a corresponding exterior decoration logo will be set on it, such as a product number, etc., which will also be mixed in the contour of the defect, affecting the accuracy of surface quality detection.

[0117] The step S50 comprises:

[0118] S510: Determine whether two opposite ends of the contour area abut against two opposite edges of the final feature image; if both opposite ends of the contour area abut against two opposite edges of the final feature image, select the contour area as a candidate area;

[0119] For the photographed exterior decoration products, due to their horizontal extensibility, in the surface image obtained by shooting, the exterior decoration products will extend from one end of the surface image to the other end of the surface image. Therefore, by judging whether the endpoint of the contour area is at the side edge of the final feature image, the edge contour of the exterior decoration product itself can be preliminarily screened.

[0120] S520: determining whether the angle between the to-be-selected area and the top or bottom of the final feature image is smaller than a preset angle range; if the angle is smaller than the preset angle range, selecting the contour area as an exterior contour, and removing the exterior contour;

[0121] It is understandable that the preset angle range can be adjusted accordingly according to the different setting angles of the camera device. Taking the camera device shooting parallel to the exterior product as an example, the actual judgment principle of this step is whether the selected area is parallel or close to parallel with the top or bottom of the final feature image, thereby completing the judgment of the exterior contour. It should be noted that when the contour of the exterior product itself is not parallel to the camera device, the preset angle range can be adaptively adjusted to complete the corresponding judgment.

[0122] Furthermore, the contour similarity between the selected contour and the exterior logo contour is obtained. If the contour similarity is greater than a similarity threshold, the selected contour is determined to be the exterior logo contour. If the contour similarity is less than the similarity threshold, the selected contour is determined to be the defective contour.

[0123] After obtaining the defect contour, the defect type can be determined by identifying the length, width and contour shape of the defect contour. In this embodiment, the defect contour is input into a trained neural network model, and the defect type is output through the neural network model.

[0124] By filtering the background information and obtaining the first feature image, a larger range of defect features in the surface image are extracted. By obtaining the second feature image based on the pixel grayscale value, more detailed defect features in the surface image are extracted. Then, by combining the first feature image with the second feature image, it is ensured that all defect features of the surface image are obtained, and the omission of defects is avoided, thereby improving the comprehensiveness of surface quality detection. By eliminating the exterior contour and the exterior logo area, the edges of the exterior products and the logos on the exterior are avoided from being mixed with the defects, thereby improving the accuracy of quality detection. By replacing manual detection with automated and intelligent detection methods, the probability of false detection and missed detection is reduced, that is, the detection error rate is effectively reduced, and the detection efficiency is improved.

[0125] See also Figure 2 The second embodiment of the present invention provides a surface quality detection system for automobile exterior products. The system is applied to the surface quality detection method for automobile exterior products in the above-mentioned embodiment. The description has been made and will not be repeated here. As used below, the terms "module", "unit", "subunit", etc. can be a combination of software and / or hardware that implements a predetermined function. Although the device described in the following embodiments is preferably implemented in software, the implementation of hardware, or a combination of software and hardware, is also possible and conceivable.

[0126] The system comprises:

[0127] An acquisition module 10 is used to acquire a surface image corresponding to the exterior product, and to perform grayscale processing and image enhancement processing on the surface image in sequence to acquire a standby image;

[0128] A first extraction module 20 is used to filter the background information of the standby image to obtain a first feature image, and extract features of the standby image based on the pixel grayscale value of the standby image to obtain a second feature image;

[0129] The first extraction module 20 comprises:

[0130] The first unit is used to convert the standby image from the spatial domain to the frequency domain to obtain a phase spectrum and an amplitude spectrum of the standby image, and obtain a logarithmic spectrum corresponding to the standby image through the amplitude spectrum;

[0131] A second unit is used to filter the log spectrum to obtain residual information, and construct a first feature image based on the phase spectrum and the residual information;

[0132] The third unit is used to compare and adjust each pixel of the standby image based on the pixel grayscale values ​​of different pixels in the standby image to obtain an adjusted grayscale value;

[0133] A fourth unit is used to obtain the spatial feature of the pixel point through the adjusted gray value, and obtain the pixel feature through the adjusted gray value and the spatial feature, so as to form a second feature map;

[0134] A second extraction module 30 is used to extract a first redundant map and a first characteristic map from the first characteristic image, and to extract a second redundant map and a second characteristic map from the second characteristic image, and to obtain a final characteristic image based on the first redundant map, the first characteristic map, the second redundant map, and the second characteristic map;

[0135] The second extraction module 30 includes:

[0136] A fifth unit is used to respectively obtain a first similarity value and a second similarity value between the second redundant image, the second feature image and the first feature image, and obtain a first image to be fused through the first similarity value and the second similarity value;

[0137] A sixth unit is used to respectively obtain a third similarity value and a fourth similarity value between the first redundant image, the first feature image and the second feature image, and obtain a second image to be fused through the third similarity value and the fourth similarity value;

[0138] A seventh unit, configured to combine the first image to be fused and the second image to be fused into a final feature image;

[0139] An analysis module 40, configured to obtain edge detection parameters and a detection threshold of the final feature image, and to obtain a plurality of contour regions from the final feature image based on the edge detection parameters and the detection threshold;

[0140] The analysis module 40 includes:

[0141] An eighth unit is used to construct a configuration table, wherein the configuration table includes a plurality of preset noise intensity ranges and backup parameters and backup thresholds corresponding to the preset noise intensity ranges;

[0142] A ninth unit, configured to obtain a signal-to-noise ratio of the final feature image, compare the signal-to-noise ratio with a plurality of preset noise intensity ranges to determine an edge detection parameter from the plurality of spare parameters, and determine a detection threshold from the plurality of spare thresholds;

[0143] The detection module 50 is used to select and remove the exterior contours from the plurality of contour areas to obtain a plurality of to-be-selected contours, compare the to-be-selected contours with preset identification contours to remove the exterior identification contours, and obtain a plurality of defect contours, and determine the defect type based on the defect contours;

[0144] The detection module 50 includes:

[0145] A tenth unit is used to determine whether two opposite ends of the contour area abut against two opposite side edges of the final feature image, and if both opposite ends of the contour area abut against two opposite side edges of the final feature image, the contour area is selected as a candidate area;

[0146] The eleventh unit is used to determine whether the angle between the selected area and the top or bottom of the final feature image is less than a preset angle range. If the angle is less than the preset angle range, the contour area is selected as the exterior contour and the exterior contour is removed.

[0147] The present invention also provides a computer, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the computer program, the surface quality detection method for automobile exterior products as described in the above technical solution is implemented.

[0148] The present invention also provides a storage medium on which a computer program is stored. When the computer program is executed by a processor, the surface quality detection method of the automobile exterior product as described in the above technical solution is implemented.

[0149] In the description of this specification, the description with reference to the terms "one embodiment", "some embodiments", "examples", "specific examples", or "some examples" means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present invention. In this specification, the schematic representation of the above terms does not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials or characteristics described may be combined in any one or more embodiments or examples in a suitable manner.

[0150] The above-mentioned embodiments only express several implementation methods of the present invention, and the description thereof is relatively specific and detailed, but it cannot be understood as limiting the scope of the patent of the present invention. It should be pointed out that, for ordinary technicians in this field, several variations and improvements can be made without departing from the concept of the present invention, which all belong to the protection scope of the present invention. Therefore, the protection scope of the patent of the present invention shall be subject to the attached claims.

Claims

1. A surface quality detection method for automobile exterior products, characterized in that: The following steps are involved: Acquire a surface image corresponding to the exterior product, and perform grayscale processing and image enhancement processing on the surface image in sequence to obtain a standby image; Performing filtering processing on the background information of the image to be used to obtain a first feature image, and performing feature extraction on the image to be used based on the pixel grayscale value of the image to be used to obtain a second feature image; Extracting a first redundant map and a first characteristic map from the first characteristic image, and extracting a second redundant map and a second characteristic map from the second characteristic image, and acquiring a final characteristic image based on the first redundant map, the first characteristic map, the second redundant map, and the second characteristic map; The step of acquiring a final feature image based on the first redundant map, the first feature map, the second redundant map, and the second feature map comprises: Respectively obtain a first similarity value and a second similarity value between the second redundant image, the second feature image and the first feature image, and obtain a first image to be fused through the first similarity value and the second similarity value; Respectively obtaining a third similarity value and a fourth similarity value between the first redundant image, the first feature image, and the second feature image, and obtaining a second image to be fused through the third similarity value and the fourth similarity value; Combining the first image to be fused and the second image to be fused into a final feature image; Acquire edge detection parameters and a detection threshold of the final feature image, and acquire a plurality of contour regions from the final feature image based on the edge detection parameters and the detection threshold; Select and eliminate the exterior contours from the plurality of contour areas to obtain a plurality of contours to be selected, compare the contours to be selected with preset identification contours to eliminate the exterior identification contours, and obtain a plurality of defect contours, and determine the defect type based on the defect contours.

2. The surface quality detection method of automobile exterior products according to claim 1, characterized in that: The step of filtering the background information of the to-be-used image to obtain the first feature image comprises: Convert the image to be used from the spatial domain to the frequency domain to obtain a phase spectrum and an amplitude spectrum of the image to be used, and obtain a logarithmic spectrum corresponding to the image to be used through the amplitude spectrum; The logarithmic spectrum is filtered to obtain residual information, and a first characteristic image is constructed based on the phase spectrum and the residual information.

3. The surface quality detection method of automobile exterior products according to claim 2, characterized in that: The formula for obtaining the residual information is: , in, Represents the residual information, represents the logarithmic spectrum, represents a filter; The formula for obtaining the first characteristic image is: , in, represents the first feature image, represents Gaussian smoothing, represents the inverse Fourier transform, represents the phase spectrum, Represents an exponential function.

4. The surface quality inspection method for automobile exterior products according to claim 1, characterized in that: The step of extracting features from the standby image based on the pixel grayscale values ​​of the standby image to obtain a second feature image comprises: Comparing and adjusting each pixel of the standby image based on the pixel grayscale values ​​of different pixels in the standby image to obtain an adjusted grayscale value; The spatial feature of the pixel point is obtained by adjusting the grayscale value, and the pixel feature is obtained by adjusting the grayscale value and the spatial feature, thereby forming a second feature map.

5. The surface quality inspection method for automobile exterior products according to claim 4, characterized in that: The formula for obtaining the grayscale value is: , in, represents the adjusted gray value of the i-th pixel, represents the frequency weight, Represents the pixel gray value weight, Represents the pixel gray value of the i-th pixel, represents the grayscale value of the jth pixel, and j≠i, represents the frequency corresponding to the pixel gray value of the jth pixel; The formula for obtaining the spatial features is: , in, represents the spatial feature of the i-th pixel, Represents the horizontal coordinate of the i-th pixel in the spatial coordinate system, Represents the ordinate of the i-th pixel in the spatial coordinate system, Indicates the height of the image to be used, Indicates the width of the image to be used, Indicates the total number of pixels in the image to be used.

6. The surface quality inspection method for automobile exterior products according to claim 1, characterized in that: The calculation formula of the first similarity value is: , in, represents the first similarity value, represents the total number of pixels in the second redundant image, represents the number of pixels in the second redundant image corresponding to the mth color value in the first feature image; The calculation formula of the second similarity value is: , in, represents the second similarity value, Represents the total number of pixels in the second feature map, Represents the number of pixels in the second feature image that correspond to the mth color value in the first feature image.

7. The surface quality inspection method for automobile exterior products according to claim 1, characterized in that: The step of obtaining edge detection parameters and detection thresholds of the final feature image comprises: Constructing a configuration table, the configuration table including a plurality of preset noise intensity ranges and backup parameters and backup thresholds corresponding to the preset noise intensity ranges; The signal-to-noise ratio of the final feature image is obtained, and the signal-to-noise ratio is compared with a plurality of preset noise intensity ranges to determine an edge detection parameter from a plurality of the spare parameters, and to determine a detection threshold from a plurality of the spare thresholds.

8. The surface quality inspection method for automobile exterior products according to claim 1, characterized in that: The step of selecting and removing the external contours from the plurality of contour areas comprises: Determine whether two opposite ends of the contour area abut against two opposite side edges of the final feature image, and if both opposite ends of the contour area abut against two opposite side edges of the final feature image, select the contour area as a candidate area; It is determined whether the angle between the selected area and the top or bottom of the final feature image is less than a preset angle range. If the angle is less than the preset angle range, the contour area is selected as the exterior contour and the exterior contour is removed.

9. A surface quality detection system for automobile exterior products, applied to the surface quality detection method for automobile exterior products as claimed in any one of claims 1 to 8, characterized in that: The system comprises: An acquisition module, used to acquire a surface image corresponding to the exterior product, and to perform grayscale processing and image enhancement processing on the surface image in sequence to acquire a standby image; A first extraction module is used to filter the background information of the standby image to obtain a first feature image, and extract features of the standby image based on the pixel grayscale value of the standby image to obtain a second feature image; A second extraction module, configured to extract a first redundant map and a first characteristic map from the first characteristic image, and to extract a second redundant map and a second characteristic map from the second characteristic image, and to obtain a final characteristic image based on the first redundant map, the first characteristic map, the second redundant map, and the second characteristic map; The second extraction module comprises: A fifth unit is used to respectively obtain a first similarity value and a second similarity value between the second redundant image, the second feature image and the first feature image, and obtain a first image to be fused through the first similarity value and the second similarity value; A sixth unit is used to respectively obtain a third similarity value and a fourth similarity value between the first redundant image, the first feature image and the second feature image, and obtain a second image to be fused through the third similarity value and the fourth similarity value; A seventh unit, configured to combine the first image to be fused and the second image to be fused into a final feature image; An analysis module, used for obtaining edge detection parameters and a detection threshold of the final feature image, and obtaining a plurality of contour regions from the final feature image based on the edge detection parameters and the detection threshold; The detection module is used to select and eliminate the exterior contours from the plurality of contour areas to obtain a plurality of contours to be selected, compare the contours to be selected with preset identification contours to eliminate the exterior identification contours, and obtain a plurality of defect contours, and determine the defect type based on the defect contours.

Citation Information

Patent Citations

  • Automatic detection method and device for surface defects of brake pad

    CN110473201A

  • Printed matter defect detection method and device based on artifact elimination

    CN111986190A