Laminated slab quality detection method and system based on image processing

By analyzing the pixel eigenvalues ​​and autocorrelation coefficients in the grayscale image of the composite board, a fusion function is constructed to adjust the diffusion tensor, which solves the problem of distinguishing cracks and wood grain in wooden composite boards and improves the accuracy of quality inspection and the precision of edge detection.

CN120598967AActive Publication Date: 2025-09-05SHAANXI ZHUBIDA TECH CO LTD

Patent Information

Application Number
CN202511114862.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-08-11
Publication Date
2025-09-05
Estimated Expiration
2045-08-11

AI Technical Summary

Technical Problem

Existing technologies make it difficult to accurately distinguish between cracks and wood grain on wooden composite panels, resulting in errors in quality inspection results.

Method used

An image processing-based method is used to analyze the pixel structure tensor in the grayscale image of the laminated board to obtain the main eigenvalue, secondary eigenvalue and autocorrelation coefficient. A pixel fusion function is constructed to adjust the adaptive diffusion tensor in the Perona-Malik equation to enhance image edge detection and distinguish wood grain and cracks.

Benefits of technology

The accuracy of composite board quality inspection is improved, the effective distinction between cracks and wood grain is ensured, and the detection accuracy of the edge detection algorithm is enhanced.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120598967A_ABST
    Figure CN120598967A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of image data processing, in particular to a laminated slab quality detection method and system based on image processing. The method comprises the following steps: determining direction coherence of pixel points according to primary characteristic values and secondary characteristic values of the pixel points in a laminated slab grayscale image; constructing a rectangular region of the pixel point by taking the pixel point as a center to obtain an autocorrelation coefficient sequence in the rectangular region of the pixel point so as to obtain the periodic intensity of the pixel point; constructing a fusion function of the pixel points, wherein the fusion function of the pixel points is positively correlated with the direction coherence and the periodic intensity of the pixel points; according to the fusion function of the pixel points, adjusting a self-adaptive diffusion tensor in a Perorona-Malik equation so as to realize enhancement of each pixel point in the gray level image of the laminated slab; and carrying out edge detection on the enhanced laminated slab grayscale image to obtain a crack edge, so that the accuracy of a laminated slab quality detection result is effectively 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 image data processing, and in particular to a method and system for detecting the quality of laminated plates based on image processing. Background Art

[0002] Wood composite panels can be used in construction and renovation as the base material for floor and wall panels, leveraging their high compressive and flexural strength to share building loads. Compared to traditional solid wood panels, composite panels are more stable and less susceptible to deformation due to temperature and humidity fluctuations, effectively reducing the risk of cracking in building structures. However, cracks may occur in wood composite panels, so to ensure their effectiveness in these applications, they must be quality-tested before use.

[0003] Currently, crack defects on wooden composite panels are mostly identified through machine vision and deep learning technologies. On the one hand, through two-dimensional image acquisition and combined with convolutional neural networks, multi-target recognition and detection of composite panel bottom plate dimensions and surface defects are achieved; on the other hand, by integrating three-dimensional point cloud scanning and close-range photogrammetry technology, a high-precision digital twin model is constructed to achieve quantitative analysis of composite panel thickness and flatness.

[0004] The above-mentioned existing technologies can realize the identification of crack defects on wooden composite panels through machine vision and deep learning technology. However, there are similarities in the visual features of cracks and wood grain. Extracting edges through conventional edge recognition algorithms may mistakenly identify fine cracks consistent with the direction of wood grain as wood grain. In addition, the performance of deep learning models depends on a large amount of labeled data. If the types of crack sample data are not comprehensive, it may lead to errors in the quality inspection results of composite panels.

[0005] Therefore, how to accurately distinguish cracks and wood grain on wooden composite panels, so as to accurately obtain the quality inspection results of the composite panels, is a problem that needs to be solved urgently. Summary of the Invention

[0006] In order to solve the technical problem of how to accurately distinguish cracks and wood grains on wooden composite boards, thereby accurately obtaining composite board quality inspection results, the present invention provides a composite board quality inspection method and system based on image processing.

[0007] In a first aspect, the present invention provides a method for detecting the quality of laminated boards based on image processing, which adopts the following technical solutions: The method for detecting the quality of laminated boards based on image processing comprises the following steps: Based on the structural tensor of the pixel points in the grayscale image of the composite plate, the main eigenvalue, secondary eigenvalue and main direction angle of the pixel points are obtained; the directional coherence of the pixel points is determined according to the main eigenvalue and secondary eigenvalue of the pixel points; a rectangular area of ​​the pixel point is constructed with the pixel point as the center, and the position of the pixel point in the rectangular area is used as the starting point to obtain the autocorrelation coefficient between the pixel point and other pixels of the main direction angle in the rectangular area to obtain the autocorrelation coefficient sequence of the pixel point; the periodicity intensity of the pixel point is obtained according to the maximum value, median and standard deviation of the grayscale value of the pixel point in the autocorrelation coefficient sequence; a fusion function of the pixel point is constructed, and the fusion function of the pixel point is positively correlated with the directional coherence and periodicity intensity of the pixel point; the adaptive diffusion tensor in the Perona-Malik equation is adjusted according to the fusion function of the pixel point to achieve enhancement of each pixel point in the grayscale image of the composite plate; edge detection is performed on the enhanced grayscale image of the composite plate to obtain the crack edge.

[0008] The present invention can effectively increase the difference between the wood grain and cracks in the grayscale image of the composite board by processing them separately, thereby improving the accuracy of quality detection. During the enhancement process, the present invention obtains the possibility of the pixel being a wood grain pixel by analyzing the directional coherence of the pixel point, and further obtains the periodic characteristics of the pixel point. By combining the two, the pixel points that meet the wood grain characteristics in the grayscale image of the composite board can be accurately captured, thereby accurately constructing a fusion function of the pixel point to evaluate the possibility of it being a wood grain pixel point. On this basis, the present invention also adjusts the adaptive diffusion tensor in the Perona-Malik equation through the fusion function value of the pixel point, and iteratively processes the grayscale image of the composite board, so that the wood grain is more continuous and the gradient is smoother, while the edge of the crack is sharper, which helps to improve the detection accuracy of the edge detection algorithm, thereby effectively improving the accuracy of the quality detection results of the composite board.

[0009] According to the image processing-based quality detection method for laminated boards provided by the present invention, determining the directional coherence of pixels based on the primary eigenvalues ​​and secondary eigenvalues ​​of the pixels includes: ; is the directional coherence of the i-th pixel, 、 are the main eigenvalue and secondary eigenvalue of the i-th pixel, respectively. To prevent division by zero coefficients.

[0010] The present invention takes into account that the primary eigenvalue and secondary eigenvalue of a pixel point can respectively represent the direction in which the gradient changes most dramatically and the direction in which it changes most gently. Therefore, by obtaining the difference between the two, the difference in the changing speed of the pixel point along the direction with the largest gradient changing speed and the direction with the smallest gradient changing speed is evaluated, thereby accurately evaluating the possibility that the gradient direction of the pixel point conforms to the wood grain area.

[0011] According to the image processing-based composite board quality detection method provided by the present invention, the periodic intensity of the pixel point is obtained, including: obtaining the difference between the maximum value and the median in the pixel point autocorrelation coefficient sequence as a first indicator, obtaining the product of the normalized value of the grayscale value standard deviation of the pixel point in the rectangular area of ​​the pixel point and the preset sensitivity coefficient as a second indicator; and obtaining the periodic intensity of the pixel point according to the ratio of the first indicator to the second indicator of the pixel point.

[0012] According to the image processing-based quality detection method for laminated boards provided by the present invention, the adaptive diffusion tensor in the Perona-Malik equation is adjusted according to the fusion function of the pixel points, including: , is the pixel fusion function, 、 are the directional coherence and periodicity intensity of the pixel, is the periodic sensitivity coefficient, and e is a natural constant. The adaptive diffusion tensor of the pixel point in the Perona-Malik equation is decomposed into the sum of the main direction component and the vertical direction component. The fusion function of the pixel point is decomposed into the main direction diffusion coefficient and the vertical direction diffusion coefficient. The main direction component is obtained by multiplying the main direction angle component of the pixel point by the main direction diffusion coefficient, and the vertical direction component is obtained by multiplying the vertical main direction angle component of the pixel point by the vertical direction diffusion coefficient.

[0013] The present invention adjusts the adaptive diffusion tensor in the Perona-Malik equation through a fusion function, which can make the wood grain pixels more continuous and the gradient smoother, while the edges of the cracks are sharper, effectively increasing the difference between the two so that different edges can be accurately identified later.

[0014] According to the image processing-based quality detection method for laminated boards provided by the present invention, a method for obtaining the main direction diffusion coefficient of a pixel point includes: ; is the main direction diffusion coefficient of the i-th pixel, is the fusion function value of the i-th pixel, is the sensitivity coefficient of the fusion function in the main direction, is an exponential function with base e.

[0015] According to the image processing-based quality inspection method for laminated boards provided by the present invention, a method for obtaining the vertical diffusion coefficient of a pixel point includes: ; is the vertical diffusion coefficient of the i-th pixel, is the minimum diffusion constant, is the fusion function value of the i-th pixel, is the sensitivity coefficient of the fusion function in the vertical direction, is an exponential function with base e.

[0016] According to the image processing-based quality detection method for superimposed plates provided by the present invention, the edge detection of the enhanced grayscale image of the superimposed plates also includes: constructing an overlapping coefficient of the pixel points by presetting the directional coherence of the pixel points in the local area; marking the pixel points whose overlapping coefficient is greater than the overlapping threshold as overlapping area pixel points; and enhancing the vertical main direction of the gradient of the pixel points in the overlapping area.

[0017] The present invention takes into account that wood grain and cracks in some areas may overlap, resulting in them being mixed together and unable to be distinguished. Therefore, the present invention further obtains the overlapping coefficient of pixel points and performs secondary enhancement on the pixel points in the overlapping area, thereby further increasing the distinction between wood grain and cracks and improving the accuracy of edge recognition.

[0018] According to the image processing-based quality inspection method for laminated boards provided by the present invention, the method of constructing the overlap coefficient of the pixel points by using the directional coherence of the pixel points in the preset local area includes: sorting the directional coherence of the pixel points in the preset local area to obtain a coherence sequence; ; 、 are the overlap coefficient and directional coherence of the i-th pixel, is the upper quartile of the coherence sequence of the i-th pixel, is the projection of the gradient of the i-th pixel in the vertical main direction, Preset the grayscale standard deviation normalized value in the local area for the i-th pixel, is the adjustment factor.

[0019] According to the image processing-based quality detection method for superimposed plates provided by the present invention, the enhancement of the vertical main direction of the gradient of the pixel points in the overlapping area includes: taking the product of the vertical main direction of the gradient of the pixel points in the overlapping area and a preset enhancement coefficient as the gradient value after the enhancement of the vertical main direction of the pixel points in the overlapping area.

[0020] The present invention enhances the gradient value of the pixel point perpendicular to the main direction, and can further enhance the gradient on the basis of continuous and smooth wood grain, thereby improving the accuracy of the edge detection algorithm in distinguishing wood grain areas and crack defects in overlapping areas.

[0021] In a second aspect, the present invention provides a laminated plate quality detection system based on image processing, which adopts the following technical solutions: The composite board quality detection system based on image processing includes: a processor and a memory, wherein the memory stores computer program instructions, and when the computer program instructions are executed by the processor, the composite board quality detection method based on image processing is implemented.

[0022] By adopting the above technical solution, the above-mentioned composite board quality detection method based on image processing is generated into a computer program and stored in the memory to be loaded and executed by the processor, so that a terminal device is made according to the memory and the processor for easy use.

[0023] The present invention has the following technical effects: Based on the above technical solution, the present invention provides a method and system for detecting the quality of composite boards based on image processing. By processing the wood grain and cracks in the grayscale image of the composite board separately, the difference between the two can be effectively increased, thereby improving the accuracy of quality detection. During the enhancement process, the present invention obtains the possibility of the pixel being a wood grain pixel by analyzing the directional coherence of the pixel point, and further obtains the periodic characteristics of the pixel point. By combining the two, the pixel points that meet the wood grain characteristics in the grayscale image of the composite board can be accurately captured, thereby accurately constructing a fusion function of the pixel point to evaluate the possibility of it being a wood grain pixel point. On this basis, the present invention also adjusts the adaptive diffusion tensor in the Perona-Malik equation through the fusion function value of the pixel point, and iteratively processes the grayscale image of the composite board, so that the wood grain is more continuous and the gradient is smoother, while the edge of the crack is sharper, which helps the detection accuracy of the edge detection algorithm, thereby effectively improving the accuracy of the quality detection results of the composite board. BRIEF DESCRIPTION OF THE DRAWINGS

[0024] Figure 1 A schematic diagram of the process of the composite plate quality detection method based on image processing provided in an embodiment of the present invention. DETAILED DESCRIPTION

[0025] The technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, but not all of the embodiments.

[0026] The present invention discloses a method for detecting the quality of laminated boards based on image processing. Figure 1 As shown, Figure 1This is a flow chart of a laminated board quality inspection method based on image processing provided by an embodiment of the present invention. The method analyzes the difference between cracks and wood grain and enhances different gradient directions of pixels to varying degrees to increase the difference between wood grain and cracks, thereby effectively improving the accuracy of crack identification on laminated boards. The method specifically includes the following steps: S1: Obtain each pixel in the grayscale image of the superimposed plate.

[0027] For example, when obtaining the grayscale image of the laminated plate, the laminated plate image can be photographed by a high-definition industrial camera, and the photographed laminated plate image is grayscaled to obtain the laminated plate grayscale image.

[0028] The camera resolution can be set to at least 5 megapixels. When shooting in a uniformly illuminated environment, the laminate can be placed on a horizontal workbench, a fixed-focus lens can be used to reduce distortion, and the focal length can be adjusted based on the shooting distance to ensure that the laminate surface fills the lens frame. The shooting parameters can be set specifically based on the shooting environment and are not limited in this embodiment of the present invention.

[0029] For example, after obtaining the grayscale image of the superimposed plate based on the above steps, the gradient of each pixel point can be obtained by using the Sobel operator.

[0030] It's important to note that wood grain patterns reflect the orientation of cells during wood growth. Therefore, the orientation of pixels within the wood grain region is highly consistent, stable, and continuous. Cracks, on the other hand, typically appear as irregular gaps, so the orientation of pixels within the crack region is typically more random.

[0031] Based on this, an embodiment of the present invention can construct a direction measurement function for pixel points to evaluate the degree of directional consistency of the pixel points, thereby distinguishing wood grain pixels and crack pixels in the grayscale image of the composite board. The structural tensor can be decomposed into primary eigenvalues ​​and secondary eigenvalues ​​to describe the local pattern in the pixel neighborhood by calculating the statistical characteristics of the grayscale gradient of the pixel points in the image, where the primary eigenvalue reflects the intensity of the strongest grayscale change direction in the pixel neighborhood, that is, the main direction of the edge or texture, and the secondary eigenvalue reflects the intensity of the secondary change direction perpendicular to the main direction. Therefore, the degree of directional consistency of the pixel points can be analyzed by obtaining the primary eigenvalue and secondary eigenvalue of the pixel points, that is, performing the following steps: S2: Based on the structure tensor of the pixel points in the grayscale image of the superimposed plate, the main eigenvalue and the secondary eigenvalue of the pixel points are obtained; and the directional coherence of the pixel points is determined according to the main eigenvalue and the secondary eigenvalue of the pixel points.

[0032] The specific steps of obtaining the main eigenvalue and the secondary eigenvalue of a pixel based on the structure tensor of the pixel in the grayscale image of the composite plate can be achieved by existing technologies and will not be described in detail in this embodiment of the present invention.

[0033] For example, in an embodiment of the present invention, the directional coherence of a pixel point is determined based on the primary eigenvalue and the secondary eigenvalue of the pixel point. For details, see the relationship: ; is the directional coherence of the i-th pixel, is the main eigenvalue of the i-th pixel, is the secondary eigenvalue of the i-th pixel, To prevent the coefficient from being divided by zero, it can be set to 0.001.

[0034] In the above formula, Approaching 1, Close to , Approaching 0, that is, the gradient change of the pixel point is mainly concentrated in the main direction corresponding to the main eigenvalue, and the gradient perpendicular to the main direction approaches 0, so the pixel point is more likely to correspond to an area with obvious directionality such as wood grain. Approaching 0, Approaching , that is, the speed of change of the pixel gradient in the main direction corresponding to the main eigenvalue and the vertical direction corresponding to the secondary eigenvalue is relatively consistent. Therefore, the pixel point is more likely to correspond to an area without obvious directionality, such as a crack or smooth area of ​​the composite plate.

[0035] Based on the above steps, we can obtain the directional coherence of each pixel. This directional coherence can be used to measure the general direction of the pixel texture. However, the direction of cracks may be similar to that of wood grain, extending in the same direction, so further differentiation is required.

[0036] It should be noted that there is a clear difference between wood grain and cracks. Wood grain has periodic growth characteristics, while cracks are usually generated randomly, so their periodicity is usually poor.

[0037] Based on this, the embodiment of the present invention can further obtain the periodicity of the pixel point, and evaluate the possibility that the pixel point is a crack pixel point by combining the directional coherence and periodicity of the pixel point, that is, continue to perform the following steps.

[0038] S3: Obtain the main direction angle of the pixel point, construct a rectangular area of ​​the pixel point with the pixel point as the center, and use the position of the pixel point in the rectangular area as the starting point to obtain the autocorrelation coefficient between the pixel point and other pixel points with the main direction angle in the rectangular area, obtain the autocorrelation coefficient sequence of the pixel point, and calculate the periodic intensity of the pixel point.

[0039] The principal direction angle of a pixel can be obtained based on the structure tensor of the pixel in the grayscale image of the composite plate. The specific steps for obtaining the principal direction angle of the pixel based on the structure tensor of the pixel can be implemented using existing technologies and are not described in detail in the embodiments of the present invention. The principal direction angle of a pixel is the direction in which the grayscale gradient of the pixel changes most rapidly, and can reflect the general direction of the texture.

[0040] It should be noted that the wood grain has a repetitive texture pattern with similar spacing along the main direction, which is manifested in the grayscale image of the laminated board as high grayscale similarity between pixels after being translated a specific periodic distance in the main direction.

[0041] Based on this, the embodiment of the present invention can specifically analyze the texture characteristics of the pixel points in the dominant direction within a certain range, eliminate non-periodic interference in the vertical direction, and quantify the similarity between the pixel points and the center pixel points after angular translation along the main direction for a certain distance, so as to accurately obtain their periodicity.

[0042] It should be further explained that the maximum similarity in the autocorrelation coefficient sequence obtained after pixel shifting corresponds to the most likely period length, while the sequence median represents the overall baseline level of the sequence. The grayscale standard deviation measures the fluctuation of the autocorrelation coefficient and can be used for normalization.

[0043] For example, the size of the rectangular area of ​​pixels may be set to 50×50; the size of the rectangular area may be specifically set according to actual needs.

[0044] It is understandable that if the camera resolution is 5 million pixels, the common wood grain period in the obtained grayscale image is usually 25 pixels, so the size of the rectangular area can also be set to 25 pixels.

[0045] For example, in an embodiment of the present invention, the periodic intensity of the pixel point is obtained based on the maximum value, median and grayscale value standard deviation of the pixel point in the pixel point autocorrelation coefficient sequence, including: obtaining the difference between the maximum value and the median in the pixel point autocorrelation coefficient sequence as a first indicator, obtaining the product of the normalized value of the grayscale value standard deviation of the pixel point in the rectangular area of ​​the pixel point and a preset sensitivity coefficient as a second indicator; and obtaining the periodic intensity of the pixel point based on the ratio of the first indicator to the second indicator of the pixel point.

[0046] The normalized value of the grayscale standard deviation of the pixel point can be obtained by the ratio of the grayscale standard deviation of the pixel point to the grayscale maximum value. The preset sensitivity coefficient can be set to 1.

[0047] In this calculation method, the first indicator can highlight the difference between significant periodic peaks and background fluctuations. If there is strong periodicity, the first indicator will be larger; if the texture is random, the difference between the two is smaller, and the first indicator will also be smaller.

[0048] The grayscale standard deviation reflects the overall grayscale fluctuation in the region. The grayscale value of the crack region varies greatly, so the standard deviation is also large. The grayscale value of the wood grain region varies less, so the standard deviation is also small. Using it for normalization can eliminate the differences between different regions.

[0049] According to the above steps, the periodic intensity of each pixel can be obtained. By fusing the directional coherence and periodic intensity of each pixel, even when the periodic intensity is too high due to noise interference, it can be reduced by lowering the directional coherence. Ultimately, the possibility of the pixel being a crack or wood grain can be accurately assessed.

[0050] S4: Construct a pixel fusion function; adjust the adaptive diffusion tensor in the Perona-Malik equation according to the pixel fusion function to enhance each pixel in the grayscale image of the laminated plate; perform edge detection on the enhanced grayscale image of the laminated plate to obtain the crack edge.

[0051] For example, in an embodiment of the present invention, a pixel fusion function is constructed, which can be seen from the formula: ; is the pixel fusion function, is the directional coherence of the pixel, is the periodic intensity of the pixel, is the period sensitivity coefficient, and e is a natural constant.

[0052] in, Can be set to 0.05.

[0053] In this fusion function, the period sensitivity coefficient determines the sensitivity of the fusion function to periodicity.

[0054] Because wood grain varies greatly in all directions and exhibits periodicity, higher directional coherence and periodicity strength correspond to larger fusion function values. If periodicity is high but directional coherence is low, the pixel is likely a crack with a spacing of less than 25 pixels, so the fusion function is also small.

[0055] In summary, only when the directional coherence and periodicity of a pixel are both large can the pixel be a wood grain pixel; otherwise, it is a crack pixel.

[0056] It's important to note that the fusion function constructed in the above steps can characterize the likelihood of a pixel being a wood grain or crack. Grayscale images of laminated boards may contain noise interference, and the wood grain may appear broken. In these cases, the Canny algorithm can easily misclassify them as cracks. Crack edges need to be sharp to be more easily detected, so filtering the image is necessary to suppress noise and enhance the distinction between cracks and wood grain.

[0057] Based on this, the embodiment of the present invention can adjust the gradient of the pixel points according to the fusion function value of the pixel points to highlight the difference between the wood grain and the cracks.

[0058] For example, the embodiment of the present invention may filter the grayscale image of the superimposed plate using an anisotropic algorithm.

[0059] Anisotropic algorithms can use the Perona-Malik equation, the Catte model, and the variable exponential anisotropic diffusion algorithm. The Perona-Malik equation has a high computational speed, meeting the real-time requirements of detection and is suitable for composite panels with smooth surfaces and pronounced cracks.

[0060] Therefore, the embodiment of the present invention is described by taking the fusion function adjusting the Perona-Malik equation to implement image filtering processing as an example.

[0061] It should be further explained that the adaptive diffusion tensor in the Perona-Malik equation can control the degree of denoising and edge preservation during the noise smoothing process. Therefore, embodiments of the present invention can achieve denoising by adjusting the adaptive diffusion tensor in the Perona-Malik equation through a fusion function. However, the original form of this equation uses the same diffusion strength in all directions, while edges in composite grayscale images are typically directional. Directly applying this formula will result in poor image denoising results.

[0062] Based on this, the embodiment of the present invention can diffuse along the edge direction through the fusion function to smooth the noise, and suppress diffusion in the direction perpendicular to the edge to retain edge details.

[0063] For example, in an embodiment of the present invention, the adaptive diffusion tensor in the Perona-Malik equation is adjusted according to the fusion function of the pixel point, including: decomposing the adaptive diffusion tensor of the pixel point in the Perona-Malik equation into the sum of the main direction component and the vertical direction component; wherein, the main direction component is obtained by multiplying the main direction angle component of the pixel point by the main direction diffusion coefficient, and the vertical direction component is obtained by multiplying the vertical main direction angle component of the pixel point by the vertical direction diffusion coefficient, and the fusion function of the pixel point is decomposed into the main direction diffusion coefficient and the vertical direction diffusion coefficient.

[0064] For example, the pixel point main direction angle component and the pixel point vertical main direction angle component can be obtained by the main direction angle of the pixel point. The specific steps can be implemented by existing technologies and will not be described in detail in the embodiment of the present invention.

[0065] Among them, the main direction angle component reflects the direction in which the pixel gradient changes most dramatically, usually corresponding to the normal direction, and the vertical main direction angle component reflects the direction in which the pixel gradient changes most slowly, usually corresponding to the tangent direction.

[0066] When constructing the main direction diffusion coefficient and the vertical direction diffusion coefficient, it is necessary to ensure that the adaptive diffusion tensor obtained based on this can diffuse along the main direction of the wood grain, making the wood grain more continuous and with a smaller gradient amplitude, while diffusing less in the direction perpendicular to the wood grain, so that the edges of the wood grain are effectively protected. The details are as follows: For example, in an embodiment of the present invention, a method for obtaining the diffusion coefficient of a pixel in a main direction includes: ; is the main direction diffusion coefficient of the i-th pixel, is the fusion function value of the i-th pixel, is the sensitivity coefficient of the fusion function in the main direction, is an exponential function with base e.

[0067] in, It can be set to 0.2; it can be set according to actual needs.

[0068] In the above formula, The closer it is to 1, the greater the possibility that the i-th pixel is a pixel in the wood grain area. The closer the exponential part of The closer the value of is to 1. On the contrary, The closer it is to 0, the greater the possibility that the i-th pixel is a pixel in the crack area. The closer the exponential part is to , The closer it is to 0.

[0069] For example, in an embodiment of the present invention, a method for obtaining the vertical diffusion coefficient of a pixel includes: ; is the vertical diffusion coefficient of the i-th pixel, is the minimum diffusion constant, is the fusion function value of the i-th pixel, is the sensitivity coefficient of the fusion function in the vertical direction, is an exponential function with base e.

[0070] Among them, the minimum diffusion constant can be set to 0.001; It can be set to 5.0; it can be set according to actual needs. Can be less than , to avoid wood grain breaks being misjudged as cracks.

[0071] In the above formula, the minimum diffusion constant is used to avoid the vertical diffusion coefficient Too big, The closer it is to 1, The closer it is to 0.

[0072] In summary, the closer the diffusion coefficient of pixels in the wood grain area is to 1 in the main direction and the closer the diffusion coefficient is to 0 in the vertical direction, the more the equation will diffuse along the wood grain area and protect the edges. Conversely, the closer the diffusion coefficient of pixels in the non-wood grain area is to 0 in the main direction and the closer the diffusion coefficient is to 0 in the vertical direction, the less the equation will diffuse in either the main or vertical direction.

[0073] The adaptive diffusion tensor of the pixel can be obtained based on the main direction diffusion coefficient and the vertical direction diffusion coefficient of the pixel obtained in the above steps. Using the adaptive diffusion tensor of the pixel to discretize and iteratively solve the Perona-Malik equation can make the wood grain continuous while protecting the edges of the wood grain, thereby obtaining an enhanced image.

[0074] For example, edge detection is performed on the enhanced grayscale image of the laminated plate to obtain crack defects in the enhanced grayscale image of the laminated plate.

[0075] It can be seen that in an embodiment of the present invention, when obtaining the quality inspection result of the superimposed plate, the main eigenvalue, secondary eigenvalue and main direction angle of the pixel point can be obtained based on the structural tensor of the pixel point in the grayscale image of the superimposed plate; the directional coherence of the pixel point is determined according to the main eigenvalue and secondary eigenvalue of the pixel point; a rectangular area of ​​the pixel point is constructed with the pixel point as the center, and the position of the pixel point in the rectangular area is used as the starting point to obtain the autocorrelation coefficient between the pixel point and other pixel points of the main direction angle in the rectangular area to obtain the autocorrelation coefficient sequence of the pixel point; the periodic intensity of the pixel point is obtained according to the maximum value, median and grayscale value standard deviation of the pixel point in the autocorrelation coefficient sequence; a fusion function of the pixel point is constructed, and the fusion function of the pixel point is positively correlated with the directional coherence and periodic intensity of the pixel point; the adaptive diffusion tensor in the Perona-Malik equation is adjusted according to the fusion function of the pixel point to realize the enhancement of each pixel point in the grayscale image of the superimposed plate; edge detection is performed on the enhanced grayscale image of the superimposed plate to obtain the crack edge, which effectively improves the accuracy of the quality inspection result of the superimposed plate.

[0076] In the above step S4, after image enhancement is achieved by adjusting the adaptive diffusion tensor in the Perona-Malik equation through the pixel fusion function, the embodiment of the present invention can also perform targeted enhancement on the overlapping parts of the image.

[0077] It's important to note that in grayscale images of laminated boards, wood grain and cracks may overlap. In these overlapping areas, the wood grain and cracks are intertwined, and the enhancement steps described above may not accurately distinguish them. However, there are also substantial differences between wood grain and cracks. Wood has a weaker resistance to deformation in the transverse direction of its grain. When cracks form in wooden laminated boards due to external forces or environmental factors, these cracks tend to develop in the transverse direction, ultimately forming cracks perpendicular to the grain.

[0078] Based on this, the embodiment of the present invention can construct an overlap coefficient through the directional coherence of pixel points, determine the overlap of wood grain and cracks, and enhance the wood grain gradient along the vertical direction of the wood grain in the overlapping area.

[0079] It should be further explained that when wood grain and cracks overlap, the directional coherence of each pixel in the overlapping area will be significantly weakened, while the cracks and wood grain are perpendicular, and the projection of the gradient in the perpendicular main direction will be significantly increased. Based on this, the overlapping area can be identified.

[0080] For example, in an embodiment of the present invention, edge detection is performed on the enhanced grayscale image of the superimposed plate, further comprising: constructing an overlap coefficient of the pixel points by determining the directional coherence of the pixel points in a preset local area.

[0081] The size of the preset local area of ​​pixels may be set to a rectangular area of ​​7×7, which may be specifically set according to actual needs.

[0082] For example, in an embodiment of the present invention, the overlap coefficient of the pixel points is constructed based on the directional coherence of the pixel points in the preset local area, including: sorting the directional coherence of the pixel points in the preset local area to obtain a coherence sequence; calculating the overlap coefficient of the pixel points, which can be seen in the formula: ; is the overlap coefficient of the i-th pixel, is the directional coherence of the i-th pixel, is the upper quartile of the coherence sequence of the i-th pixel, is the projection of the gradient of the i-th pixel in the vertical main direction, Preset the grayscale standard deviation normalized value in the local area for the i-th pixel, is the adjustment factor.

[0083] Among them, it can be set to 20; it can be set according to actual needs.

[0084] In the above formula, the directional coherence of the wood grain area will be larger, and the directional coherence of the local area of ​​the pixels in this area is close to the directional coherence of the central pixel in the local area. The difference will be smaller, and the projection of the pixel gradient in the vertical main direction will be smaller. At this time, the overlap coefficient of the corresponding pixel points will be smaller.

[0085] The purpose is to reduce noise interference, but since the standard deviation of the wood grain area is small, the entire score will increase. In order to suppress the influence of the standard deviation, the square root of the standard deviation is used to suppress it, and a constant K is added to prevent excessive influence of the square root of the standard deviation.

[0086] In the overlapping area, the directional coherence of the pixels in the crack area will be lower, and the directional coherence of the pixels in the wood grain area will be greater. The difference will be larger, and the crack is perpendicular to the wood grain, which leads to the projection of the gradient in the vertical main direction. It will increase significantly, and the corresponding pixel overlap coefficient will be higher, and the possibility of the pixel being in the overlapping area will also be greater.

[0087] For crack-only regions, the directional coherence will be low, but The overlap coefficient is in the middle of the overlap area and the wood grain area.

[0088] Based on the above steps, the overlap coefficients of each area are obtained from large to small as follows: overlap area, crack area, and wood grain area.

[0089] Therefore, if the value of the overlap coefficient of a pixel point is greater than the overlap coefficients of the crack area and the wood grain area, the pixel point can be determined as an overlap area.

[0090] For example, in an embodiment of the present invention, pixels with an overlap coefficient greater than an overlap threshold may be marked as pixels in the overlap area; and the vertical main direction of the gradient of the pixels in the overlap area may be enhanced.

[0091] The overlap threshold may be set to 0.5, and may be specifically set according to the overlap coefficient between the crack area and the wood grain area. The embodiment of the present invention does not impose any additional limitations on this.

[0092] For example, in an embodiment of the present invention, the vertical main direction of the gradient of the pixel points in the overlapping area is enhanced, including: taking the product of the vertical main direction of the gradient of the pixel points in the overlapping area and a preset enhancement coefficient as the gradient value after the vertical main direction of the pixel points in the overlapping area is enhanced.

[0093] According to the above steps, the gradient enhancement of the wood grain pixels in the overlapping area of ​​the grayscale image of the laminated board can be achieved.

[0094] An embodiment of the present invention also discloses a composite board quality detection system based on image processing, including a processor and a memory, wherein the memory stores computer program instructions. When the computer program instructions are executed by the processor, the composite board quality detection method based on image processing provided by the present invention is implemented.

[0095] The above system also includes other components well known to those skilled in the art, such as a communication bus and a communication interface. The configuration and functions of these components are known in the art and will not be described in detail here.

[0096] In the present invention, the aforementioned memory may be any tangible medium that contains or stores a program, which may be used by or in combination with an instruction execution system, apparatus, or device.

[0097] The above are all preferred embodiments of the present invention, and are not intended to limit the scope of protection of the present invention. Therefore, any equivalent changes made based on the structure, shape, and principle of the present invention should be included in the scope of protection of the present invention.

Claims

1. A method for detecting the quality of laminated boards based on image processing, characterized in that: include: Based on the structure tensor of the pixel points in the grayscale image of the superimposed plate, the main eigenvalue, secondary eigenvalue and main direction angle of the pixel points are obtained; Determine the directional coherence of the pixel points based on the primary eigenvalue and secondary eigenvalue of the pixel points; A rectangular region is constructed with the pixel point as the center, and the position of the pixel point in the rectangular region is used as the starting point to obtain the autocorrelation coefficient between the pixel point and other pixels in the rectangular region with the main direction angle, thereby obtaining the autocorrelation coefficient sequence of the pixel point; The periodic intensity of the pixel is obtained based on the maximum value, median and standard deviation of the pixel's gray value in the pixel's autocorrelation coefficient sequence; A pixel fusion function is constructed, which is positively correlated with the directional coherence and periodicity strength of the pixel. The adaptive diffusion tensor in the Perona-Malik equation is adjusted according to the pixel fusion function to enhance each pixel in the grayscale image of the composite plate. Edge detection is performed on the enhanced grayscale image of the laminated plate to obtain the crack edge.

2. The method for detecting the quality of laminated boards based on image processing according to claim 1, characterized in that: The determining of the directional coherence of the pixel points according to the primary eigenvalue and the secondary eigenvalue of the pixel points includes: ; is the directional coherence of the i-th pixel, 、 are the main eigenvalue and secondary eigenvalue of the i-th pixel, respectively. To prevent division by zero coefficients.

3. The method for detecting the quality of laminated boards based on image processing according to claim 1, characterized in that: The obtaining of the periodic intensity of the pixel point includes: The difference between the maximum value and the median in the pixel autocorrelation coefficient sequence is obtained and recorded as the first indicator, and the product of the normalized value of the grayscale value standard deviation of the pixel point in the rectangular area of ​​the pixel point and the preset sensitivity coefficient is obtained and recorded as the second indicator; according to the ratio of the first indicator to the second indicator of the pixel point, the periodic intensity of the pixel point is obtained.

4. The method for detecting the quality of laminated boards based on image processing according to claim 1, characterized in that: The step of adjusting the adaptive diffusion tensor in the Perona-Malik equation according to the pixel fusion function includes: , is the pixel fusion function, 、 are the directional coherence and periodicity intensity of the pixel, is the periodic sensitivity coefficient, and e is a natural constant. The adaptive diffusion tensor of the pixel point in the Perona-Malik equation is decomposed into the sum of the principal direction component and the vertical direction component. The fusion function of the pixel point is decomposed into the principal direction diffusion coefficient and the vertical direction diffusion coefficient. The principal direction component is obtained by multiplying the principal direction angle component of the pixel point by the principal direction diffusion coefficient, and the vertical direction component is obtained by multiplying the perpendicular principal direction angle component of the pixel point by the vertical direction diffusion coefficient.

5. The method for detecting the quality of laminated boards based on image processing according to claim 4, characterized in that: Methods for obtaining the diffusion coefficient of the main direction of a pixel include: ; is the main direction diffusion coefficient of the i-th pixel, is the fusion function value of the i-th pixel, is the sensitivity coefficient of the fusion function in the main direction, is an exponential function with base e.

6. The method for detecting the quality of laminated boards based on image processing according to claim 4, characterized in that: The vertical diffusion coefficient of a pixel is obtained by: ; is the vertical diffusion coefficient of the i-th pixel, is the minimum diffusion constant, is the fusion function value of the i-th pixel, is the sensitivity coefficient of the fusion function in the vertical direction, is an exponential function with base e.

7. The method for detecting the quality of laminated boards based on image processing according to claim 1, characterized in that: The edge detection of the enhanced grayscale image of the laminated plate further includes: The overlapping coefficient of the pixel points is constructed by presetting the directional coherence of the pixel points in the local area; the pixel points with an overlapping coefficient greater than the overlapping threshold are marked as overlapping area pixels; and the vertical main direction of the gradient of the pixel points in the overlapping area is enhanced.

8. The method for detecting the quality of laminated boards based on image processing according to claim 7, characterized in that: The method of constructing the overlap coefficient of the pixel points by presetting the directional coherence of the pixel points in the local area includes: Sort the directional coherence of the pixels in a preset local area to obtain a coherence sequence; ; 、 are the overlap coefficient and directional coherence of the i-th pixel, is the upper quartile of the coherence sequence of the i-th pixel, is the projection of the gradient of the i-th pixel in the vertical main direction, Preset the grayscale standard deviation normalized value in the local area for the i-th pixel, is the adjustment factor.

9. The method for inspecting the quality of laminated boards based on image processing according to claim 7, characterized in that: The step of enhancing the vertical main direction of the gradient of the pixel points in the overlapping area includes: The product of the vertical main direction of the gradient of the pixel point in the overlapping area and the preset enhancement coefficient is used as the gradient value of the pixel point in the overlapping area after the vertical main direction is enhanced.

10. The laminated board quality detection system based on image processing is characterized by: include: A processor and a memory, wherein the memory stores computer program instructions, and when the computer program instructions are executed by the processor, the image processing-based composite plate quality detection method according to any one of claims 1 to 9 is implemented.

Citation Information

Patent Citations

  • Carbonate rock fracture-cavity enhanced recognition method based on gradient structure tensor spectrum decomposition

    CN111290021A

  • Smart home production board quality detection method and system

    CN119006446A

  • Grinding wheel defect detection method based on machine vision

    CN119831990A

  • Pin shaft forging forming quality detection method and system

    CN120339278A

  • Method of iris image recogntion and storing withcharacteristic syndrome pattern

    KR1020050044073A

Cited By

  • Aluminum bar quality detection method and system based on machine vision

    CN121414747A

  • Impression roller pressure uniformity analysis method based on indentation image features

    CN121544617A

  • Wafer bonding interface micro-crack identification method based on machine vision

    CN122434932A