A method, device, equipment and storage medium for detecting a circular metal edge defect

By extracting features and processing grayscale images of circular metal objects, edge defects are automatically identified, solving the problems of low efficiency and low accuracy of manual inspection and achieving efficient and accurate automatic inspection.

CN115731231BActive Publication Date: 2025-11-21HANGZHOU ANMAISHENG INTELLIGENT TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202211557675.7
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-12-06
Publication Date
2025-11-21
Estimated Expiration
2042-12-06

AI Technical Summary

Technical Problem

In existing technologies, the detection of edge defects in circular metal workpieces relies on manual inspection, which results in low efficiency and low accuracy, and is easily affected by subjective factors.

Method used

By extracting features from the circular metal image to be inspected, unfolding it, calculating the target's average grayscale image, and combining image denoising, cropping, and Cartesian coordinate transformation, edge defects are automatically identified.

Benefits of technology

It enables rapid and accurate detection of circular metal edge defects, improving detection efficiency and accuracy while reducing human error.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115731231B_ABST
    Figure CN115731231B_ABST
Patent Text Reader

Abstract

The application discloses a kind of circular metal edge defect detection methods, applied to the field of industrial internet, the method comprises: the feature extraction of the image of the circular metal to be detected is carried out, and the target area to be detected is obtained;The target area to be detected is unfolded, and the initialization target area is obtained;The target average gray diagram corresponding to initialization target area is calculated;According to the target average gray diagram, the edge defect corresponding to the image of the circular metal to be detected is obtained.The initialization target area is obtained by unfolding the image of the circular metal to be detected, and then the target average gray diagram corresponding to initialization target area is calculated, and the edge defect of the edge of the circular metal to be detected is directly determined according to the target average gray diagram.In addition, the application also provides a kind of circular metal edge defect detection device, equipment and storage medium, also have the beneficial effects above.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the field of industrial internet, and in particular to a circular metal edge defect detection method, device, equipment and storage medium. BACKGROUND

[0002] Circular metal workpieces are involved in various fields and have become indispensable basic components, such as in military weapons, aerospace, automotive and other industrial manufacturing fields. However, the scratch of the metal circular edge is one of the most common defects, which has a certain influence on use and appearance. At present, for metal circular workpieces, most domestic manufacturers still use manual detection to detect the defects of the circular metal edge. The manual detection method has the technical problems of low detection efficiency and low detection accuracy. SUMMARY

[0003] Therefore, the purpose of the present application is to provide a circular metal edge defect detection method, device, equipment and storage medium, which solves the technical problems of low detection efficiency and low detection accuracy of the existing manual detection method for detecting the defects of the circular metal edge.

[0004] To solve the above technical problems, the present application provides a circular metal edge defect detection method, comprising:

[0005] feature extraction is performed on the to-be-detected circular metal image to obtain a to-be-detected target region;

[0006] The to-be-detected target region is processed to obtain an initialized target region;

[0007] The target average gray image corresponding to the initialized target region is calculated;

[0008] According to the target average gray image, the edge defect corresponding to the to-be-detected circular metal image is obtained.

[0009] Optionally, the feature extraction on the to-be-detected circular metal image to obtain the to-be-detected target region comprises:

[0010] The to-be-detected circular metal image is binarized to obtain a to-be-detected circular region;

[0011] The to-be-detected circular region is converted into a contour graph;

[0012] The contour graph is fitted into the to-be-detected target region.

[0013] Optionally, the expansion processing on the to-be-detected target region is to obtain an initialized target region, and the expansion processing on the to-be-detected target region in the polar coordinate manner is to obtain the initialized target region.

[0014] Optionally, the expansion processing on the to-be-detected target region is to obtain an initialized target region, and the expansion processing on the to-be-detected target region in the polar coordinate manner is to obtain the initialized target region.

[0015] Optionally, after the expansion processing on the to-be-detected target region is to obtain an initialized target region, the method further comprises:

[0016] processing the initialized target region according to an image denoising method to obtain an edge interference removed region;

[0017] Optionally, the calculation of the target average gray image corresponding to the initialized target region comprises:

[0018] Optionally, the calculation of the target average gray image corresponding to the initialized target region comprises:

[0019] Optionally, the calculation of the target average gray image corresponding to the initialized target region comprises:

[0020] Optionally, the processing of the initialized target region according to the image denoising method to obtain an edge interference removed region comprises:

[0021] Optionally, the processing of the initialized target region according to the image denoising method to obtain an edge interference removed region comprises:

[0022] Optionally, the processing of the initialized target region according to the image denoising method to obtain an edge interference removed region comprises:

[0023] Optionally, the calculation of the target average gray image corresponding to the initialized target region comprises:

[0024] Optionally, the calculation of the target average gray image corresponding to the initialized target region comprises:

[0025] Optionally, the calculation of the target average gray image corresponding to the initialized target region comprises:

[0026] Optionally, the calculation of the target average gray image corresponding to the initialized target region comprises:

[0027] Optionally, the calculation of the target average gray image corresponding to the initialized target region comprises:

[0028] Optionally, the calculation of the target average gray image corresponding to the initialized target region comprises:

[0029] Optionally, the calculation of the target average gray image corresponding to the initialized target region comprises:

[0030] The defect area corresponding to the pre-detection image is calculated according to a morphological processing method and a feature screening method, and the defect area is subjected to Cartesian coordinate transformation to obtain the edge defect.

[0031] The application further provides a circular metal edge defect detection device, comprising:

[0032] A to-be-detected target area acquisition module is configured to extract features from the to-be-detected circular metal image to obtain a to-be-detected target area.

[0033] An initialization target area acquisition module is configured to perform unfolding processing on the to-be-detected target area to obtain an initialization target area.

[0034] An average gray scale image acquisition module is configured to calculate a target average gray scale image corresponding to the initialization target area.

[0035] A circular metal edge defect determination module is configured to obtain an edge defect corresponding to the to-be-detected circular metal image according to the target average gray scale image.

[0036] The application further provides a circular metal edge defect detection device, comprising:

[0037] A memory is configured to store a computer program.

[0038] A processor is configured to execute the computer program to implement the steps of the circular metal edge defect detection method.

[0039] The application further provides a storage medium, wherein the computer readable storage medium stores a computer program, and the computer program is executed by a processor to implement the steps of the circular metal edge defect detection method.

[0040] It can be seen that the application extracts features from a to-be-detected circular metal image to obtain a to-be-detected target area, performs unfolding processing on the to-be-detected target area to obtain an initialization target area, calculates a target average gray scale image corresponding to the initialization target area, and obtains an edge defect corresponding to the to-be-detected circular metal image according to the target average gray scale image. The application performs unfolding processing on the obtained to-be-detected circular metal image to obtain an initialization target area, further calculates a target average gray scale image corresponding to the initialization target area, and finally directly determines an edge defect of a to-be-detected circular metal edge according to the target average gray scale image. It can be seen that, compared with the method of detecting a circular metal edge defect manually in the prior art, the application can quickly and accurately obtain an edge defect of a circular metal edge in combination with an average gray scale image.

[0041] In addition, the application further provides a circular metal edge defect detection device, a device and a storage medium, which also have the above beneficial effects. BRIEF DESCRIPTION OF DRAWINGS

[0042] In order to more clearly illustrate the technical solutions in the embodiments of the present application or the prior art, the following will briefly introduce the drawings needed to be used in the embodiments or prior art description. Obviously, the drawings described below are only a part of the embodiments of the present application, and for those skilled in the art, other drawings can be obtained without creative labor on the basis of the provided drawings.

[0043] Figure 1 A flow chart of a circular metal edge defect detection method provided by the embodiment of the present application is shown in the figure.

[0044] Figure 2 A schematic diagram of an initialization target area obtained by polar coordinate expansion processing provided by the embodiment of the present application is shown in the figure.

[0045] Figure 3 A flow chart of a circular metal edge defect detection method provided by the embodiment of the present application is shown in the figure.

[0046] Figure 4 A schematic diagram of a target area to be detected provided by the embodiment of the present application is shown in the figure.

[0047] Figure 5 A schematic diagram of an initialization target area provided by the embodiment of the present application is shown in the figure.

[0048] Figure 6 A schematic diagram of a target average gray scale map provided by the embodiment of the present application is shown in the figure.

[0049] Figure 7 A schematic diagram of an edge defect corresponding to a circular metal image to be detected provided by the embodiment of the present application is shown in the figure.

[0050] Figure 8 A structural schematic diagram of a circular metal edge defect detection device provided by the embodiment of the present application is shown in the figure.

[0051] Figure 9 A structural schematic diagram of a circular metal edge defect detection device provided by the embodiment of the present application is shown in the figure. DETAILED DESCRIPTION

[0052] In order to make the purpose, technical solutions and advantages of the embodiments of the present application more clear, the following will combine the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are only a part of the embodiments of the present application, but not all the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those skilled in the art without creative labor are within the protection scope of the present application.

[0053] Please refer to Figure 1, Figure 1 A flowchart of a circular metal edge defect detection method is provided for an embodiment of the present application. The method can include:

[0054] S100, feature extraction is performed on a to-be-detected circular metal image to obtain a to-be-detected target region.

[0055] The embodiment is not limited to a specific method of feature extraction on the to-be-detected circular metal image to obtain the to-be-detected target region. For example, the to-be-detected circular metal image can be subjected to feature extraction through binarization processing to obtain the to-be-detected target region; or the to-be-detected circular metal image can be subjected to feature extraction through Blob Analysis (connected domain analysis) to obtain the to-be-detected target region; or the to-be-detected circular metal image can be subjected to feature extraction through edge segmentation to obtain the to-be-detected target region. The embodiment is not limited to the frequency of feature extraction on the to-be-detected circular metal image. For example, the to-be-detected circular metal image can be subjected to feature extraction at a preset period; or the to-be-detected circular metal image can be subjected to feature extraction when detection is needed; or the to-be-detected circular metal image can be subjected to feature extraction in real time.

[0056] S101, the to-be-detected target region is subjected to unwrapping processing to obtain an initialized target region.

[0057] The embodiment is not limited to a specific method of unwrapping processing on the to-be-detected target region to obtain the initialized target region. For example, the to-be-detected target region can be subjected to unwrapping processing through a polar coordinate method to obtain the initialized target region; or the to-be-detected target region can be subjected to unwrapping processing through morphological processing to obtain the initialized target region.

[0058] S102, a target average gray image corresponding to the initialized target region is calculated.

[0059] The embodiment calculates a target average gray image corresponding to the initialized target region through average gray image calculation, so as to obtain an edge defect corresponding to the to-be-detected circular metal image according to the target average gray image. The embodiment is not limited to a specific process of calculating the target average gray image corresponding to the initialized target region. For example, the target average gray image corresponding to the initialized target region can be directly calculated; or the target average gray image corresponding to the initialized target region can be calculated after edge processing is performed on the initialized target region; or the target average gray image corresponding to the initialized target region can be calculated after edge processing and cropping are performed on the initialized target region.

[0060] S103, an edge defect corresponding to the to-be-detected circular metal image is obtained according to the target average gray image.

[0061] The embodiment obtains the edge defect corresponding to the to-be-detected circular metal image according to the target average gray image.

[0062] Further, in order to improve the efficiency and accuracy of extracting the to-be-detected target region, the feature extraction on the to-be-detected circular metal image to obtain the to-be-detected target region can include:

[0063] The to-be-detected circular metal image is binarized to obtain a to-be-detected circular region.

[0064] The to-be-detected circular region is converted into a contour map.

[0065] The contour map is fitted into the to-be-detected target region.

[0066] The embodiment obtains the to-be-detected circular region by binarizing the to-be-detected circular metal image, that is, by determining the region through the upper and lower limits of the gray threshold value of the binarization, and then obtaining the to-be-detected circular region. The embodiment does not limit the specific process of binarizing the to-be-detected circular metal image to obtain the to-be-detected circular region. For example, the to-be-detected circular region can be directly obtained according to the binarization, or the to-be-detected circular region can be obtained by determining the region through the upper and lower limits of the gray threshold value of the binarization, and then through morphological erosion processing; or the to-be-detected circular region can be obtained by determining the region through the upper and lower limits of the gray threshold value of the binarization, and then through morphological erosion processing, and finally through area feature screening to obtain the initial circular region. The to-be-detected circular region is finally converted into a contour map, and the contour map is fitted into the to-be-detected target region. Since the to-be-detected circular region is further processed by the contour processing in the embodiment, the to-be-detected target region obtained is more accurate, thereby improving the efficiency and accuracy of extracting the to-be-detected target region. It can be understood that the contour processing on the to-be-detected circular region can remove part of the noise in the to-be-detected target region, such as low contrast, gray abnormality, and the like, so that the to-be-detected circular region is more accurate, thereby improving the accuracy of the edge defect detection.

[0067] Further, in order to improve the speed of unfolding, the unfolding processing on the to-be-detected target region to obtain the initialization target region can include:

[0068] The to-be-detected target region is unfolded in a polar coordinate manner to obtain the initialization target region.

[0069] The embodiment expands the target region to be detected in a polar coordinate manner to obtain an initialized target region. The image is transformed between the rectangular coordinate system and the polar coordinate system, which can transform a circular image into a rectangular image and is commonly used for processing clock, disc and other images. The text on the edge of the circular pattern can be arranged vertically on the edge of the new image after the coordinate transformation, which facilitates the recognition and detection of the text. The embodiment can extract the target region to be detected to obtain a target image to be detected, and then expand the target image to be detected in a polar coordinate manner to obtain an initialized target region. For ease of understanding, please refer to Figure 2 , Figure 2 The embodiment of the application provides a schematic diagram of an initialized target region obtained by polar coordinate expansion processing, and it can be clearly seen from the diagram that the target region to be detected has edge defects.

[0070] Further, in order to improve the accuracy of defect detection, after the above expansion processing of the target region to be detected to obtain an initialized target region, the method can further include:

[0071] processing the initialized target region according to an image denoising method to obtain an edge interference removed region;

[0072] Correspondingly, the target average gray image corresponding to the initialized target region is calculated, including:

[0073] calculating the target average gray image corresponding to the edge interference removed region.

[0074] The embodiment does not limit the specific method of the image denoising method, as long as the edge of the initialized target region can be denoised. For example, the initialized target region is processed by a Lee filter (image denoising filter) to obtain an edge interference removed region; or the initialized target region can be processed by a variable window filter to obtain an edge interference removed region; or the initialized target region can be processed by a gray value method to obtain an edge interference removed region. According to the image denoising method, the initialized target region is processed to obtain an edge interference removed region, and the target average gray image corresponding to the edge interference removed region is calculated. Since the edge of the initialized target region has been denoised when the target average gray image is calculated, the accuracy of defect detection is higher.

[0075] Further, in order to improve the accuracy of circular metal edge defect detection, the above processing of the initialized target region according to the image denoising method to obtain an edge interference removed region can include:

[0076] obtaining an initialized average gray value corresponding to the initialized target region, and filling the initialized target region with a gray value of 0;

[0077] According to the target region to be detected, the initialized target region filled with the gray value 0, and the initialized average gray value, image filling processing is performed to obtain a region with edge interference removed.

[0078] The embodiment obtains the initialized average gray value corresponding to the initialized target region, and fills the initialized target region with the gray value 0; the target region to be detected and the initialized target region filled with the gray value 0 are subtracted, and image filling processing is performed using the initialized average gray value to obtain a region with edge interference removed. Since the initialized target region is denoised using the gray value in this embodiment, the image is more clear and accurate, and the accuracy of the circular metal edge defect detection is improved.

[0079] Further, in order to make the target average gray image clearer, the above-mentioned calculation of the target average gray image corresponding to the region with edge interference removed can include:

[0080] The region with edge interference removed is cropped, and image type conversion is performed to obtain a cropped target region;

[0081] The cropped target region is filled according to the initialized average gray value to obtain a target average gray image.

[0082] The embodiment can crop the region with edge interference removed, and perform image type conversion to obtain a cropped target region; the cropped target region is filled according to the initialized average gray value to obtain a target average gray image. Since the region with edge interference removed is further cropped in this embodiment, the target average gray image obtained is further clearer.

[0083] Further, in order to improve the accuracy of the circular metal edge detection, the above-mentioned obtaining of the edge defect corresponding to the circular metal image to be detected according to the target average gray image can include:

[0084] A target image to be detected corresponding to the target region to be detected is obtained.

[0085] The target image to be detected and the target average gray image are subjected to dynamic threshold segmentation to obtain a pre-detection image.

[0086] The pre-detection image is calculated according to a morphological processing method and a feature screening method, and the defect region is subjected to Cartesian coordinate conversion to obtain an edge defect.

[0087] In this embodiment, when the defect region corresponding to the circular metal image to be detected is obtained according to the target average gray image, the determined region is subjected to Cartesian coordinate conversion to obtain an edge defect, so that the edge defect corresponds to the position of the target region to be detected, and the edge defect corresponds to the position in the circular metal image to be detected, and the specific position of the edge defect of the circular metal image to be detected is more easily found.

[0088] The method for detecting the edge defect of the circular metal provided by the embodiment of the application comprises: extracting features of a to-be-detected circular metal image to obtain a to-be-detected target region; performing unfolding processing on the to-be-detected target region to obtain an initialized target region; calculating a target average gray image corresponding to the initialized target region; and obtaining an edge defect corresponding to the to-be-detected circular metal image according to the target average gray image. The embodiment of the application performs unfolding processing on the obtained to-be-detected circular metal image to obtain an initialized target region, and then calculates a target average gray image corresponding to the initialized target region, and directly determines the edge defect of the edge of the to-be-detected circular metal according to the target average gray image. It can be seen that, compared with the method for detecting the edge defect of the circular metal by manual operation in the prior art, the embodiment of the application can quickly and accurately obtain the edge defect of the edge of the circular metal in combination with the average gray image. In addition, the to-be-detected target region obtained by using the binarization combined with the contour processing method is accurate to a circle, which is more conducive to the detection of the edge defect. In addition, the embodiment of the application performs unfolding processing on the to-be-detected target region in the polar coordinate mode, so that the unfolding mode is simpler and the initialized target region obtained is more accurate. In addition, the image denoising method is used to eliminate the edge interference of the initialized target region, so that the accuracy of the detection of the edge defect of the circular metal is higher. In addition, the initialized target region subjected to the image denoising is further cropped, so that the target average gray image obtained is more in line with the requirements. In addition, the Cartesian coordinate conversion is performed to obtain the edge defect, so that the obtained edge defect is more easily observed and compared.

[0089] In order to make the application more convenient to understand, please refer to the specific description Figure 3 , Figure 3 A flowchart of the method for detecting the edge defect of the circular metal provided by the embodiment of the application can specifically comprise:

[0090] A to-be-detected target region corresponding to a to-be-detected circular metal image is obtained, and a to-be-detected target image corresponding to the to-be-detected target region is extracted, as shown in Figure 4 , Figure 4 A to-be-detected target region provided by the embodiment of the application is a to-be-detected target region provided by the embodiment of the application; Figure 5 A to-be-detected target image provided by the embodiment of the application is a to-be-detected target image provided by the embodiment of the application; the to-be-detected target region is unfolded in the polar coordinate mode to obtain an initialized target region, as shown in Figure 2 , Figure 2An initialization target region schematic diagram obtained by using polar coordinate expansion processing is provided for the embodiment of the present application; an initialization average gray value corresponding to the initialization target region is obtained, and the initialization target region is filled with a gray value of 0; the to-be-detected target image is subtracted from the initialization target region filled with the gray value of 0, a region with a gray value of 0-1 is obtained, and the initialization average gray value is used to fill the region, to obtain a region with edge interference removed; the region with edge interference removed is cropped, and image type conversion is performed to obtain a cropped target region; the cropped target region is filled according to the initialization average gray value, to obtain a target average gray diagram, Figure 6 A target average gray diagram schematic diagram is provided for the embodiment of the present application; the to-be-detected target image and the target average gray diagram are subjected to dynamic threshold segmentation, to obtain a pre-detection image; a defect region corresponding to the pre-detection image is calculated according to a morphological processing method and a feature screening method, and the defect region is subjected to Cartesian coordinate conversion, to obtain an edge defect, as shown in Figure 7 Figure 7 A to-be-detected circular metal image corresponding edge defect schematic diagram is provided for the embodiment of the present application.

[0091] The circular metal edge defect detection device provided by the embodiment of the present application is described below, and the circular metal edge defect detection device described below can be correspondingly referred to the circular metal edge defect detection method described above.

[0092] For details, please refer to Figure 8 , Figure 8 A structure schematic diagram of a circular metal edge defect detection device is provided for the embodiment of the present application, which can include:

[0093] A to-be-detected target region acquisition module 100 is configured to perform feature extraction on a to-be-detected circular metal image, to obtain a to-be-detected target region.

[0094] An initialization target region acquisition module 200 is configured to perform expansion processing on the to-be-detected target region, to obtain an initialization target region.

[0095] An average gray diagram acquisition module 300 is configured to calculate a target average gray diagram corresponding to the initialization target region.

[0096] A circular metal edge defect determination module 400 is configured to obtain an edge defect corresponding to the to-be-detected circular metal image according to the target average gray diagram.

[0097] Further, based on the above embodiment, the to-be-detected target region acquisition module 100 can include:

[0098] A to-be-detected circular region calculation unit is configured to perform binaryzation processing on the to-be-detected circular metal image, to obtain a to-be-detected circular region.​

[0099] a contour map calculation unit, configured to convert the to-be-detected circular region into a contour map;

[0100] a to-be-detected target region calculation unit, configured to fit the contour map into the to-be-detected target region.

[0101] Further, based on any of the above embodiments, the initialization target region acquisition module 200 can include:

[0102] a polar coordinate processing unit, configured to perform polar coordinate expansion processing on the to-be-detected target region to obtain the initialization target region.

[0103] Further, based on any of the above embodiments, the circular metal edge defect detection device can further include:

[0104] an edge interference region removal calculation module, configured to process the initialization target region according to an image denoising method to obtain an edge interference region removal region;

[0105] Correspondingly, the average gray map acquisition module 300 can include:

[0106] a target average gray map calculation unit, configured to calculate the target average gray map corresponding to the edge interference region removal region.

[0107] Further, based on any of the above embodiments, the edge interference region removal calculation module can include:

[0108] a gray value filling unit, configured to obtain an initialization average gray value corresponding to the initialization target region, and fill the initialization target region with a gray value 0;

[0109] an edge interference region removal calculation unit, configured to perform image filling processing on the to-be-detected target region, the initialization target region filled with the gray value 0, and the initialization average gray value, to obtain the edge interference region removal region.

[0110] Further, based on any of the above embodiments, the target average gray map calculation unit can include:

[0111] a clipping subunit, configured to clip the edge interference region removal region, and perform image type conversion to obtain a clipped target region;

[0112] a target average gray map calculation subunit, configured to fill the clipped target region according to the initialization average gray value to obtain the target average gray map.

[0113] Further, the circular metal edge defect determination module 400 can include:

[0114] a to-be-detected target image calculation unit configured to obtain a to-be-detected target image corresponding to the to-be-detected target region;

[0115] a pre-detection image acquisition unit configured to perform dynamic threshold segmentation on the to-be-detected target image and the target average gray image to obtain a pre-detection image;

[0116] an edge defect calculation unit configured to calculate a defect region corresponding to the pre-detection image according to a morphological processing method and a feature screening method, and perform Cartesian coordinate conversion on the defect region to obtain the edge defect.

[0117] It should be noted that the sequence of the modules and units in the circular metal edge defect detection device described above can be changed without affecting the logic.

[0118] The circular metal edge defect detection device provided by the embodiment of the present application comprises a to-be-detected target region acquisition module 100 configured to perform feature extraction on a to-be-detected circular metal image to obtain a to-be-detected target region; an initialization target region acquisition module 200 configured to perform unfolding processing on the to-be-detected target region to obtain an initialization target region; an average gray image acquisition module 300 configured to calculate a target average gray image corresponding to the initialization target region; and a circular metal edge defect determination module 400 configured to obtain an edge defect corresponding to the to-be-detected circular metal image according to the target average gray image. The circular metal edge defect detection device provided by the embodiment of the present application performs unfolding processing on the obtained to-be-detected circular metal image to obtain an initialization target region, and then calculates a target average gray image corresponding to the initialization target region, and directly determines the edge defect of the edge of the to-be-detected circular metal according to the target average gray image. It can be seen that, compared with the method of detecting the edge defect of the circular metal by manual operation in the prior art, the present application can quickly and accurately obtain the edge defect of the edge of the circular metal in combination with the average gray image. Moreover, the to-be-detected target region obtained by using binarization combined with a contour processing method is accurate to a circle, which is more conducive to the detection of the edge defect. Furthermore, the to-be-detected target region is unfolded by the polar coordinate method, so that the unfolding method is simpler and the obtained initialization target region is more accurate. In addition, the edge interference of the initialization target region is eliminated by an image denoising method, so that the accuracy of the circular metal edge defect detection is higher. Furthermore, the initialization target region after image denoising is cropped, so that the obtained target average gray image is more in line with the requirements. Furthermore, Cartesian coordinate conversion is performed to obtain the edge defect, so that the obtained edge defect is easier to observe and compare.

[0119] The circular metal edge defect detection device provided by the embodiment of the present application is introduced as follows, and the circular metal edge defect detection device described below can be correspondingly referred to the circular metal edge defect detection method described above.

[0120] Please refer to Figure 9 , Figure 9 The structural schematic diagram of the circular metal edge defect detection device provided by the embodiment of the present application can include:

[0121] The memory 10 is used for storing a computer program;

[0122] The processor 20 is used for executing the computer program to realize the steps of the circular metal edge defect detection method described above.

[0123] The memory 10, the processor 20 and the communication interface 31 can complete the communication among each other through the communication bus 32.

[0124] In the embodiment of the present application, the memory 10 is used for storing one or more programs, and the program can include program codes, and the program codes include computer operation instructions. In the embodiment of the present application, the memory 10 can store programs for realizing the following functions:

[0125] The feature extraction is performed on the circular metal image to be detected to obtain a target region to be detected;

[0126] The expansion processing is performed on the target region to be detected to obtain an initialized target region;

[0127] The target average gray image corresponding to the initialized target region is calculated;

[0128] The edge defect corresponding to the circular metal image to be detected is obtained according to the target average gray image.

[0129] In a possible implementation manner, the memory 10 can include a storage program area and a storage data area. The storage program area can store an operating system and at least one application program required by a function, etc. The storage data area can store data created in the use process.

[0130] In addition, the memory 10 can include a read-only memory and a random access memory, and provide instructions and data for the processor. A part of the memory can also include an NVRAM. The memory stores an operating system and operation instructions, executable modules or data structures, or subsets of them, or an extended set of them, wherein the operation instructions can include various operation instructions for realizing various operations. The operating system can include various system programs for realizing various basic tasks and processing hardware-based tasks.

[0131] The processor 20 can be a central processing unit (CPU), an application specific integrated circuit, a digital signal processor, a field programmable gate array or other programmable logic device. The processor 20 can be a microprocessor or any conventional processor, etc. The processor 20 can invoke a program stored in the memory 10.

[0132] The communication interface 31 can be an interface of a communication module, used for connecting with other devices or systems.

[0133] Of course, it needs to be explained that, Figure 9 The structure shown does not constitute a limitation on the circular metal edge defect detection device in the embodiments of the present application. In actual applications, the circular metal edge defect detection device can include more or fewer components than Figure 9 those shown, or some components can be combined.

[0134] The storage medium provided by the embodiments of the present application is described below. The storage medium described below can be referred to in conjunction with the circular metal edge defect detection method described above.

[0135] The present application also provides a storage medium having a computer program stored thereon, and the computer program is executed by a processor to implement the steps of the circular metal edge defect detection method described above.

[0136] The storage medium can include a U disk, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk, and various media that can store program codes.

[0137] The embodiments in the present specification are described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same or similar parts of each embodiment can be referred to each other. For the device disclosed by the embodiments, since it corresponds to the method disclosed by the embodiments, the description is relatively simple, and the related parts can be referred to the method part.

[0138] The skilled person can further realize that the units and algorithm steps of the examples described in conjunction with the embodiments disclosed herein can be realized in electronic hardware, computer software or a combination of the two. In order to clearly show the interchangeability of hardware and software, the components and steps of each example have been described in the above description. Whether the functions are executed in hardware or software depends on the specific application and design constraints of the technical solution. The skilled person can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of the present application.

[0139] Finally, it is to be understood that, wherever used herein, relational terms such as first and second and the like can be used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Also, the terms "comprises," "comprising," or any other variation thereof are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but can include other elements not expressly listed or inherent to such process, method, article, or apparatus.

[0140] The above describes the circular metal edge defect detection method, device, equipment and storage medium provided by the present application in detail. The principles and implementation manners of the present application are described by applying specific examples in the present article. The above example is only used to help understand the method of the present application and its core idea. Meanwhile, for the general technical personnel in the field, the specific implementation manners and application ranges will be changed according to the idea of the present application. In summary, the content of the present article should not be understood as a limitation of the present application.

Claims

1. A method for detecting circular metal edge defects, characterized in that, include: Feature extraction is performed on the circular metal image to be detected to obtain the target region to be detected; The target region to be detected is expanded to obtain an initialized target region; Obtain the initial average grayscale value corresponding to the initialization target area, and fill the initialization target area with the grayscale value 0; Extract the target image corresponding to the target region to be detected, subtract the target image to be detected from the initial target region filled with gray value 0 to obtain the region with gray value 0-1, and fill the region with the initial average gray value to obtain the edge-free interference region. Calculate the average grayscale image of the target corresponding to the edge-disturbed region; The edge defects corresponding to the circular metal image to be detected are obtained based on the target average grayscale image.

2. The method for detecting circular metal edge defects according to claim 1, characterized in that, The process of extracting features from the circular metal image to be detected to obtain the target region includes: The circular metal image to be detected is binarized to obtain the circular region to be detected; The circular region to be detected is converted into a contour map; The contour map is fitted to the target region to be detected.

3. The method for detecting circular metal edge defects according to claim 1, characterized in that, The step of expanding the target region to obtain the initialized target region includes: The target region to be detected is expanded in polar coordinates to obtain the initialized target region.

4. The method for detecting circular metal edge defects according to claim 1, characterized in that, The calculation of the target average grayscale image corresponding to the edge-disturbed region includes: The edge-disturbed region is cropped, and the image type is converted to obtain the cropped target region; The cropped target area is filled with the initial average gray value to obtain the target average gray map.

5. The method for detecting circular metal edge defects according to claim 1, characterized in that, The step of obtaining the edge defect corresponding to the circular metal image to be detected based on the target average grayscale image includes: Obtain the image of the target to be detected corresponding to the target region to be detected; Dynamic threshold segmentation is performed on the target image to be detected and the target average grayscale image to obtain a pre-detection image; The defect region corresponding to the pre-detection image is calculated based on morphological processing and feature selection methods, and the defect region is transformed into Cartesian coordinates to obtain the edge defect.

6. A device for detecting edge defects in circular metal, characterized in that, include: The target region acquisition module is used to extract features from the circular metal image to be detected, thereby obtaining the target region to be detected. An initial target region acquisition module is used to expand the target region to be detected to obtain an initial target region; The average grayscale image acquisition module is used to acquire the initial average grayscale value corresponding to the initialization target area, and fill the initialization target area with the grayscale value 0; Extract the target image corresponding to the target region to be detected, subtract the target image to be detected from the initial target region filled with gray value 0 to obtain the region with gray value 0-1, and fill the region with the initial average gray value to obtain the edge-free interference region. Calculate the average grayscale image of the target corresponding to the edge-disturbed region; A circular metal edge defect determination module is used to obtain the edge defects corresponding to the circular metal image to be detected based on the target average grayscale image.

7. A circular metal edge defect detection device, characterized in that, include: Memory, used to store computer programs; A processor, configured to execute the computer program to implement the steps of the circular metal edge defect detection method as described in any one of claims 1 to 5.

8. A storage medium, characterized in that, The storage medium stores a computer program, which, when executed by a processor, implements the steps of the circular metal edge defect detection method as described in any one of claims 1 to 5.

Citation Information

Patent Citations

  • Microcrack detection method, device and system and storage medium

    CN113822890A

  • Defect inspection method and defect inspection system

    GB201818898D0