Defect recognition method based on optimization of industrial image quality

By employing image quality enhancement methods for different ROI regions and multi-scale detail enhancement, the problem of poor industrial image quality has been solved, resulting in more accurate workpiece quality assessment and improved efficiency of manual inspection.

CN115272184BActive Publication Date: 2026-05-01SHENYANG ZHIGU TECH CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
SHENYANG ZHIGU TECH CO LTD
Filing Date
2022-06-24
Publication Date
2026-05-01

AI Technical Summary

Technical Problem

In existing technologies, the poor quality of industrial images leads to a lack of objectivity, consistency, and accuracy in manual inspections. Furthermore, the reliance on extensive professional knowledge makes it difficult to accurately assess workpiece quality, especially defects in pipe welds.

Method used

The image quality of non-linear ROI regions is improved by using a grayscale balancing function and an adaptive histogram equalization method, while the image quality of linear ROI regions is improved by an adaptive contrast enhancement algorithm with background attenuation. In addition, multi-scale detail enhancement and threshold adaptive binarization are combined to mark potential abnormal regions.

Benefits of technology

It improves the contrast and detail of industrial images, helps improve the efficiency of manual inspection, and enables more accurate workpiece quality assessment.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115272184B_ABST
    Figure CN115272184B_ABST
Patent Text Reader

Abstract

The application provides a defect identification method based on optimization of industrial image quality, and relates to the technical field of industrial image quality optimization; the application respectively performs contrast enhancement processing on whether the ROI region type on the industrial image is linear, then applies a multi-scale detail enhancement method to make the ROI region details of the ray image after contrast enhancement more obvious, finally combines a threshold adaptive binarization method to perform background subtraction to obtain potential abnormal regions on the measured workpiece image, and performs labeling, so as to assist in improving the artificial inspection efficiency.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of industrial image quality optimization technology, specifically relating to a defect identification method based on optimizing industrial image quality. Background Technology

[0002] After industrial images are digitized, due to the influence of many factors such as photosensitive materials, radiation energy, and radiation dose, the digitized images suffer from drawbacks such as low contrast and high noise.

[0003] Currently, workpiece quality assessment in industrial imaging is primarily conducted manually. However, manual inspection can lack objectivity, consistency, accuracy, and efficiency. Assessment results can vary depending on the operator's skill level, and the assessment process relies heavily on specialized knowledge, often being subjective and time-consuming. Furthermore, novice operators typically lack the experience needed to accurately assess defects in pipe welds, making them highly susceptible to human error. Since the evaluation process relies mainly on visual observation, operators cannot obtain precise geometric parameters such as length, area, and density. These factors constitute major obstacles to accurately assessing the quality of the workpiece being tested.

[0004] With the development of industrial imaging technology, quality enhancement techniques based on industrial images have been widely applied. The challenges faced in industrial images can be summarized as: poor image quality, uneven brightness, dirt spots, and low contrast between the ROI and the background. Generally, each quality enhancement technique can effectively address one of these problems, but may not be as effective for others. Furthermore, most recent methods require manual setting of parameters or influencing factors, rather than adaptively calculating the relevant factors of industrial X-ray images. This also makes the application of X-ray image quality enhancement techniques to assist manual inspection less effective. Summary of the Invention

[0005] To address the aforementioned problems, this invention provides a defect identification method based on optimizing industrial image quality, comprising:

[0006] Step 1: Convert the workpiece information into digital signals using photoelectric technology and digital processing technology to obtain the original workpiece image;

[0007] Step 2: Classify the workpiece image according to the ROI region type: non-linear region and linear region;

[0008] Step 3: For nonlinear ROI regions, a combination of gray-level balancing function and contrast-limited adaptive histogram equalization method is used to improve image quality; including:

[0009] Step 3-1: Calculate the histogram of the image of the workpiece being measured, and then calculate the mean and variance of the histogram;

[0010]

[0011] In the formula, E(X) and V(X) represent the mean and variance of the image grayscale histogram, g(X) represents the number of pixels with a grayscale value of X, and n represents the total number of pixels.

[0012] Step 3-2: Use the mean and variance to derive the relationship with the balancing coefficient, as shown in the following formula:

[0013]

[0014] In the formula, p represents the balancing coefficient, and p determines the boundary values ​​(minimum and maximum values) of the histogram to be balanced. The larger the value, the greater the color distortion; the smaller the value, the less the contrast enhancement. In formula (2), s is the scaling factor that adjusts the ratio of mean to variance.

[0015] Step 3-3: Calculate the expected minimum and maximum values ​​using the ratio of the balancing coefficient to the total number of pixels, as shown in formula (3). In the cumulative histogram of the image, when the cumulative pixel value of the histogram is less than n×p, the gray value corresponding to this histogram is set as the expected minimum value. When the cumulative pixel value of the histogram is greater than n×(1-p), the gray value corresponding to this histogram is set as the expected maximum value.

[0016]

[0017] In the formula, H j This represents the cumulative number of pixels in the image histogram. min and v max These represent the expected minimum and maximum values, respectively.

[0018] Steps 3-4: Use the grayscale balancing formula (4) to map the values ​​of the original histogram to the range of 0 to 255. This can map the grayscale range of most pixel distributions to the entire pixel range.

[0019]

[0020] In formula (4), x is the gray value of a pixel, and v min v max These represent the minimum and maximum grayscale values, respectively.

[0021] Steps 3-5: Divide the grayscale balanced image into multiple non-overlapping regions;

[0022] Steps 3-6: Calculate the histogram for each region separately;

[0023] Steps 3-7: Calculate the shear limit β of a shear histogram, using the following formula:

[0024]

[0025] Where β is the cropping constraint, M×N is the number of pixels in each region, L is the gray level, α is the cropping factor from 0 to 100, and S... max The maximum allowable slope;

[0026] Steps 3-8: Reassign each histogram so that its height does not exceed the shear limit. From formula (5), it can be deduced that if α = 0, then the shear limit...

[0027] Step 4: For linear ROI regions, an adaptive contrast enhancement algorithm with background attenuation is used to improve image quality; specifically:

[0028] Step 4-1: Use formula (6) to normalize the grayscale value of the image of the workpiece under test to obtain a floating-point image with a grayscale range between 0 and 1.

[0029]

[0030] Where I(x,y) and I max These are the maximum values ​​of the entire image and the input workpiece image, respectively. D(x,y) and R(x,y) are the detail component and variable component, respectively. Here, (x,y) is a spatial domain index, and both the detail component and the variable component are between 0 and 1.

[0031] Step 4-2: In order to find the local maximum component G(y) and local minimum component T(y) of the normalized image, the local maximum component is calculated using formula (7), and the background component, i.e. the local minimum component, is calculated using formula (8).

[0032]

[0033]

[0034] Among them, Lo y The T(x,y) component represents the local region surrounding a pixel (x,y), where (x,y) represents the pixel within that local region. The T(x,y) component can be considered as background material and is a component that can be attenuated to enhance image contrast.

[0035] Step 4-3: Use the local maximum and local minimum components to generate an attenuation factor λ(x,y) according to formula (9).

[0036]

[0037] In formula (9), G(x,y) and T(x,y) are the local maximum and local minimum components, and var(T(x,y)) is the variance of the local minimum component.

[0038] Step 4-4: Use formula (10) to generate a movable component R(x,y), which can be adaptively adjusted to find a suitable background component to eliminate in order to better enhance the contrast of the image.

[0039] R(x,y)≡λ·T(x,y) (10)

[0040] The attenuation factor λ adjusts the proportion of the background component in the removed component. Therefore, the movable portion R(x,y) and the removable background component T(x,y) determined by adjusting the attenuation factor λ can effectively enhance the weld defect image.

[0041] Steps 4-5: Use formula (11) to determine another adjustable brightness parameter ψ(x,y) to control the brightness of the enhanced image.

[0042]

[0043] Where R(x,y) and G(x,y) are the variable components and local maxima of the input ray image;

[0044] Steps 4-6: Finally, the enhanced ray image E(x,y) was obtained using formula (12).

[0045]

[0046] Step 5: Further perform multi-scale detail enhancement on the ray image E(x,y) processed in Step 3 or Step 4; specifically:

[0047] Step 5-1: By applying Gaussian convolution kernels of three scales to the ray image E(x,y), three different degrees of blurred images are obtained, as shown in formula (13).

[0048]

[0049] G1(x,y), G2(x,y), and G3(x,y) are Gaussian convolution kernels of different scales.

[0050] Step 5-2: We extract fine details D1(x,y), intermediate details D2(x,y) and coarse details D3(x,y), as shown in formula (14);

[0051]

[0052] Step 5-3: Merge these three layers of details by designing operation rules to generate an overall detail image, as shown in formula (15).

[0053] D * (x,y)=(1-ω1×sgn(D1(x,y)))×D1(x,y)+ω2×D2(x,y)+ω3×D3(x,y) (15)

[0054] Wherein, ω1, ω2, and ω3 are the adjustment factors for fine detail, intermediate detail, and coarse detail, respectively;

[0055] Step 5-4: We will obtain the overall detail D from formula (15) * Adding (x,y) to the contrast-enhanced ray image E(x,y) yields a multi-scale detail-enhanced image.

[0056] Step 6: Threshold adaptive binarization processing, specifically described as follows:

[0057] Step 6-1: Calculate the adaptive standard deviation σ for each window of the enhanced image using a sliding window. A The calculation method is given by formula (16).

[0058]

[0059] In the formula, σ w σ is the standard deviation of the window pixels. min and σ max These are the minimum and maximum standard deviations of all windows in the image to be processed, respectively.

[0060] Step 6-2: Calculate the binarization threshold, as shown in equation (17):

[0061]

[0062] In the formula, T is the threshold, and μ w σ is the average value of the window pixels. w μ is the standard deviation of the window pixels. g σ is the average value of all pixels in the image. A This is the adaptive standard deviation of the window.

[0063] Step 6-3: Based on this threshold T, the binarization process is defined in equation (18).

[0064]

[0065] Where I(x,y) is the binarized image, i(x,y) is the pixel value of the original workpiece image, and T is the threshold of the local window in the image.

[0066] Step 7: Use background subtraction to mark potential abnormal areas in the image of the workpiece being tested.

[0067] Step 7-1: Perform large-scale median filtering on the fine multi-scale segment enhancement image obtained in Step 5 to obtain the background model;

[0068] Step 7-2: Apply background subtraction to obtain the difference image;

[0069] Step 7-3: Perform the threshold adaptive binarization process described in step 6 on the difference image;

[0070] Step 7-4: Obtain potential abnormal regions on the image of the workpiece under test through area filtering and morphological operations;

[0071] Step 7-5: Perform contour tracking on the binary image to draw the minimum bounding rectangle of the potential anomaly region.

[0072] The beneficial effects of this invention are:

[0073] This invention provides a defect identification method based on optimizing industrial image quality. Different contrast enhancement methods are applied depending on whether the region of interest (ROI) of the workpiece image is a linear region. Then, multi-scale detail enhancement is applied to make the detail information of the ROI region more significant. Combined with a threshold-adaptive binarization method, background subtraction is performed to obtain potential abnormal regions on the workpiece image and they are marked, thereby helping to improve the efficiency of manual inspection. Attached Figure Description

[0074] Figure 1 A flowchart of an industrial image quality improvement method provided in an embodiment of the present invention;

[0075] Figure 2 This is a flowchart for improving image quality in nonlinear ROI regions provided in an embodiment of the present invention;

[0076] Figure 3 This is a flowchart for improving the image quality of a linear ROI region, provided as an embodiment of the present invention. Detailed Implementation

[0077] The invention will be further described below with reference to the accompanying drawings and specific embodiments. The following embodiments are used to illustrate the invention, but are not intended to limit the scope of the invention.

[0078] In this embodiment, an industrial image quality improvement method is described, such as... Figure 1 As shown: Includes the following steps:

[0079] Step 1: Based on photoelectric technology and digital processing technology, the workpiece information is converted into digital signals to obtain the original workpiece image; in this embodiment, the image data of the workpiece is directly acquired by an industrial X-ray flaw detector.

[0080] Step 2: Classify the workpiece image according to the ROI region type: non-linear region and linear region;

[0081] Step 3: For nonlinear ROI regions, a combination of gray-level balancing function and contrast-limited adaptive histogram equalization method is used to improve image quality, such as... Figure 2 As shown.

[0082] Step 3-1: Calculate the histogram of the image of the workpiece under test, and then calculate the mean and variance of the histogram:

[0083]

[0084] In the formula, E(X) and V(X) represent the mean and variance of the image grayscale histogram, g(X) represents the number of pixels with a grayscale value of X, and n represents the total number of pixels.

[0085] Step 3-2: We derive the relationship with the balancing coefficient using the mean and variance, as shown in the following formula:

[0086]

[0087] In the formula, p represents the balancing coefficient, and p determines the boundary values ​​(minimum and maximum values) of the histogram to be balanced. The larger the value, the greater the color distortion; the smaller the value, the less the contrast enhancement. In formula (2), s is the scaling factor that adjusts the ratio of mean to variance, which is fixed at 0.4 in this embodiment.

[0088] Step 3-3: Calculate the expected minimum and maximum values ​​using the ratio of the balancing coefficient to the total number of pixels, as shown in formula (3). In the cumulative histogram of the image, when the cumulative pixel value of the histogram is less than n×p, the gray value corresponding to this histogram is set as the expected minimum value. When the cumulative pixel value of the histogram is greater than n×(1-p), the gray value corresponding to this histogram is set as the expected maximum value.

[0089]

[0090] In the formula, H j This represents the cumulative number of pixels in the image histogram. min and v max These represent the expected minimum and maximum values, respectively.

[0091] Steps 3-4: Use the grayscale balancing formula (4) to map the values ​​of the original histogram to the range of 0 to 255. This can map the grayscale range of most pixel distributions to the entire pixel range.

[0092]

[0093] In formula (4), x is the gray value of a pixel, and v min v max These represent the minimum and maximum grayscale values, respectively.

[0094] Steps 3-5: Divide the grayscale balanced image into multiple non-overlapping regions; in this embodiment, the entire image is divided into 8*8 non-overlapping regions;

[0095] Steps 3-6: Calculate the histogram for each region separately;

[0096] Steps 3-7: Calculate the shear limit β of a shear histogram, using the following formula:

[0097]

[0098] Where β is the cropping constraint, M×N is the number of pixels in each region, L is the gray level, α is the cropping factor from 0 to 100, and S... max The maximum allowable slope;

[0099] Steps 3-8: Reassign each histogram so that its height does not exceed the shear limit. From formula (5), it can be deduced that if α = 0, then the shear limit...

[0100] Step 4: For linear ROI regions, an adaptive contrast enhancement algorithm with background attenuation is used to improve image quality, such as... Figure 3 As shown.

[0101] Step 4-1: Use formula (6) to normalize the grayscale value of the image of the workpiece under test to obtain a floating-point image with a grayscale range between 0 and 1.

[0102]

[0103] Where I(x,y) and I max These are the maximum values ​​of the entire image and the input workpiece image, respectively. D(x,y) and R(x,y) are the detail component and variable component, respectively. Here, (x,y) is a spatial domain index, and both the detail component and the variable component are between 0 and 1.

[0104] Step 4-2: In order to find the local maximum component G(y) and local minimum component T(y) of the normalized image, we create a local region around each pixel using a window size of 15x15, calculate the local maximum component using formula (7), and calculate the background component, i.e. the local minimum component, using formula (8).

[0105]

[0106]

[0107] Among them, Lo y The T(x,y) component represents the local region surrounding a pixel (x,y), where (x,y) represents the pixel within that local region. The T(x,y) component can be considered as background material and is a component that can be attenuated to enhance image contrast.

[0108] Step 4-3: Use the local maximum and local minimum components to generate an attenuation factor λ(x,y) according to formula (9).

[0109]

[0110] In formula (9), G(x,y) and T(x,y) are the local maximum and local minimum components, and var(T(x,y)) is the variance of the local minimum component.

[0111] Step 4-4: Use formula (10) to generate a movable component R(x,y), which can be adaptively adjusted to find a suitable background component to eliminate in order to better enhance the contrast of the image.

[0112] R(x,y)≡λ·T(x,y) (10)

[0113] The attenuation factor λ adjusts the proportion of the background component in the removed component. Therefore, the movable portion R(x,y) and the removable background component T(x,y) determined by adjusting the attenuation factor λ can effectively enhance the weld defect image.

[0114] Steps 4-5: Use formula (11) to determine another adjustable brightness parameter ψ(x,y) to control the brightness of the enhanced image.

[0115]

[0116] Where R(x,y) and G(x,y) are the variable components and local maxima of the input ray image;

[0117] Steps 4-6: Finally, use formula (12) to obtain the enhanced ray image E(x,y).

[0118]

[0119] Step 5: Further perform multi-scale detail enhancement on the ray image E(x,y) processed in Step 3 or Step 4; specifically:

[0120] Step 5-1: By applying Gaussian convolution kernels of three scales to the ray image E(x,y), three different degrees of blurred images are obtained, as shown in formula (13).

[0121]

[0122] Wherein, G1(x,y), G2(x,y) and G3(x,y) are Gaussian convolution kernels of different scales, with standard deviations of σ1=1.0, σ2=2.0 and σ3=4.0, respectively.

[0123] Step 5-2: We extract fine details D1(x,y), intermediate details D2(x,y) and coarse details D3(x,y), as shown in formula (14);

[0124]

[0125] Step 5-3: Merge these three layers of details by designing operation rules to generate an overall detail image, as shown in formula (15).

[0126] D * (x,y)=(1-ω1×sgn(D1(x,y)))×D1(x,y)+ω2×D2(x,y)+ω3×D3(x,y) (15)

[0127] Wherein, ω1, ω2 and ω3 are the adjustment factors for fine detail, intermediate detail and coarse detail, respectively, and are fixed at 0.5, 0.5 and 0.25;

[0128] Step 5-4: We will obtain the overall detail D from formula (15) * Adding (x,y) to the contrast-enhanced ray image E(x,y) yields a multi-scale detail-enhanced image.

[0129] Step 6: Threshold adaptive binarization processing, specifically described as follows:

[0130] Step 6-1: Calculate the adaptive standard deviation σ for each window of the enhanced image using a sliding window. A The calculation method is given by formula (16).

[0131]

[0132] In the formula, σ w σ is the standard deviation of the window pixels.min and σ max These are the minimum and maximum standard deviations of all windows in the image to be processed, respectively.

[0133] Step 6-2: Calculate the binarization threshold, as shown in equation (17):

[0134]

[0135] In the formula, T is the threshold, and μ w σ is the average value of the window pixels. w μ is the standard deviation of the window pixels. g σ is the average value of all pixels in the image. A This is the adaptive standard deviation of the window.

[0136] Step 6-3: Based on this threshold T, the binarization process is defined in equation (18).

[0137]

[0138] Where I(x,y) is the binarized image, and i(x,y) is the pixel value of the original workpiece image.

[0139] Step 7: Use background subtraction to mark potential abnormal areas in the image of the workpiece under test. Specifically:

[0140] Step 7-1: Perform large-scale median filtering on the fine multi-scale segment enhancement image obtained in Step 5 to obtain the background model;

[0141] Step 7-2: Apply background subtraction to obtain the difference image;

[0142] Step 7-3: Perform the threshold adaptive binarization process described in step 6 on the difference image;

[0143] Step 7-4: Obtain potential abnormal regions on the image of the workpiece under test through area filtering and morphological operations;

[0144] Step 7-5: Perform contour tracking on the binary image to draw the minimum bounding rectangle of the potential anomaly region.

[0145] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, and are not intended to limit them. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some or all of the technical features therein. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the scope defined by the claims of the present invention.

Claims

1. A defect recognition method based on optimizing industrial image quality, characterized in that, include: Step 1: Convert the workpiece information into digital signals using photoelectric technology and digital processing technology to obtain the original workpiece image; Step 2: Classify the workpiece image into non-linear and linear regions based on the ROI region type; Step 3: For non-linear ROI regions, a combination of gray-level balancing function and contrast-limited adaptive histogram equalization method is used to improve image quality; The method combining the gray-level balancing function and the contrast-limited adaptive histogram equalization method is as follows: calculate the histogram of the image of the workpiece being measured, and then calculate the mean and variance of the histogram. The balancing coefficients are derived using the mean and variance, and the minimum and maximum values ​​are calculated using the ratio of the balancing coefficients to the total number of pixels. Based on the minimum and maximum values, the values ​​of the original histogram are mapped to the range of 0 to 255 using the gray-scale balancing formula. The gray-scale balanced image is divided into multiple non-overlapping regions, and the histogram of each region is calculated. A clipping constraint for the clipping histogram is calculated, and each histogram is redistributed so that its height does not exceed the clipping constraint. Step 4: For linear ROI regions, an adaptive contrast enhancement algorithm with background attenuation is used to improve image quality; The adaptive contrast enhancement algorithm for background attenuation is as follows: perform grayscale value normalization processing on the image of the workpiece under test, and calculate the local maximum and local minimum components of the normalized image. The attenuation factor is generated using local maximum and local minimum components; The movable component is generated using the local minimum component and the attenuation factor; Adjustable brightness parameters are calculated using local maximum components and movable components; then, an enhanced ray image is obtained based on the normalized image, movable components, local maximum components, and adjustable brightness parameters. Step 5: Process the X-ray image from Step 3 or Step 4. Perform multi-scale detail enhancement; Step 6: Perform threshold adaptive binarization; Step 7: Use background subtraction to mark potential abnormal areas in the image of the workpiece being tested.

2. The defect identification method based on optimized industrial image quality according to claim 1, characterized in that, Step 3 includes: Step 3-1: Calculate the histogram of the image of the workpiece being measured, and then calculate the mean and variance of the histogram; (1) In the formula, and The mean and variance of the image grayscale histogram are represented. This represents the number of pixels with a grayscale value of X, where n represents the total number of pixels. Step 3-2: Use the mean and variance to derive the relationship with the balancing coefficient, as shown in the following formula: (2) In the formula, p represents the balancing coefficient, and the boundary value of the histogram to be balanced is determined by p. s is the scaling factor that adjusts the ratio of mean to variance. Step 3-3: Calculate the expected minimum and maximum values ​​using the ratio of the balancing coefficient to the total number of pixels, as shown in formula (3): (3) In the formula, This represents the cumulative number of pixels in the image histogram. and These represent the minimum and maximum expected values, respectively. In the cumulative histogram of an image, when the cumulative pixel value of the histogram is less than... When the cumulative pixel value of the histogram is greater than the minimum expected value, set the gray value corresponding to that moment to the minimum value; when the cumulative pixel value of the histogram is greater than the minimum expected value. If the gray value corresponding to the histogram at that time is set to the expected maximum value; Steps 3-4: Use the grayscale balancing formula (4) to map the values ​​of the original histogram to the range of 0 to 255; (4) In the formula, x is the gray value of a pixel. , These represent the minimum and maximum grayscale values, respectively. Steps 3-5: Divide the grayscale balanced image into multiple non-overlapping regions; Steps 3-6: Calculate the histogram for each region separately; Steps 3-7: Calculate the shearing constraint of a shearing histogram The formula is as follows: (5) in, For shearing restrictions, Where L is the number of pixels in each region, and L is the grayscale level. A shearing factor of 0 to 100 The maximum allowable slope; Steps 3-8: Reassign each histogram so that its height does not exceed the shear limit; from formula (5), it can be concluded that if Then shear restriction .

3. The defect identification method based on optimized industrial image quality according to claim 1, characterized in that, Step 4 includes: Step 4-1: Use formula (6) to normalize the grayscale value of the image of the workpiece under test to obtain a floating-point image with a grayscale range between 0 and 1. (6) in, and These are the maximum values ​​of the entire image and the input workpiece image, respectively; and These are detail components and variable components, respectively. It is a spatial domain index, with detail components and variable components both between 0 and 1; Step 4-2: In order to find the local maximum component G(y) and local minimum component T(y) of the normalized image, the local maximum component is calculated using formula (7), and the background component, i.e. the local minimum component, is calculated using formula (8). (7) (8) in, Represents pixels The surrounding local area Represents pixels within a local area; Step 4-3: Generate an attenuation factor using the local maximum and local minimum components according to formula (9). ; (9) In the formula, and These are local maxima and local minima. The variance of the local minimum component; Step 4-4: Generate movable components using formula (10) : (10) in, This indicates the proportion of background components removed by the attenuation factor. Steps 4-5: Use formula (11) to determine another adjustable brightness parameter. This is used to control and enhance the brightness of the image; (11) Steps 4-6: Obtain enhanced ray images using formula (12) ; (12)。 4. The defect identification method based on optimized industrial image quality according to claim 1, characterized in that, Step 5 includes: Step 5-1: By analyzing the ray image By applying Gaussian convolution kernels of three different scales, three different degrees of blurred images are obtained, as shown in formula (13): (13) in, , and These are Gaussian convolution kernels of different scales; Step 5-2: Extracting fine details Intermediate details and rough details As shown in formula (14); (14) Step 5-3: Merge these three layers of detail by designing operational rules to generate an overall detail image, as shown in formula (15): (15) in, For overall details, , and These are adjustment factors for fine detail, mid-detail detail, and coarse detail, respectively. Step 5-4: Obtain the overall details from formula (15) Added to the contrast-enhanced ray image In this process, multi-scale detail-enhanced images are obtained.

5. The defect identification method based on optimized industrial image quality according to claim 1, characterized in that, Step 6 includes: Step 6-1: Calculate the adaptive standard deviation of each window of the enhanced image using a sliding window. As shown in formula (16): (16) In the formula, The standard deviation of the window pixels, and These are the minimum and maximum standard deviations of all windows in the image to be processed, respectively. Step 6-2: Calculate the binarization threshold, as shown in formula (17): (17) In the formula, T is the threshold. The average value of the window pixels. The standard deviation of the window pixels, This is the average value of all pixels in the image. The adaptive standard deviation of the window; Step 6-3: Design the binarization process to generate the binarized image, as shown in formula (18): (18) in, For binarized images, These are the pixel values ​​of the original workpiece image. This is the threshold for a local window in the image.

6. The defect identification method based on optimized industrial image quality according to claim 1, characterized in that, Step 7 includes: Step 7-1: Perform large-scale median filtering on the fine multi-scale segment enhancement image obtained in Step 5 to obtain the background model; Step 7-2: Apply background subtraction to obtain the difference image; Step 7-3: Perform the threshold adaptive binarization process described in step 6 on the difference image; Step 7-4: Obtain potential abnormal regions on the image of the workpiece under test through area filtering and morphological operations; Step 7-5: Perform contour tracking on the binary image to draw the minimum bounding rectangle of the potential anomaly region.

Citation Information

Patent Citations

  • NSST domain infrared image enhancement method based on beetle antennae optimization algorithm

    CN113870135A