Crack image extraction method, device and equipment

By pre-processing the digital images and specific algorithm processing, the crack images of rock mass and concrete materials are extracted, which solves the problems of low crack extraction accuracy and noise interference in the prior art, and achieves higher extraction accuracy and integrity.

CN120088257AActive Publication Date: 2025-06-03QINGDAO UNIV OF TECH +1
View PDF 6 Cites 0 Cited by

Patent Information

Application Number
CN202510570536.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-05-06
Publication Date
2025-06-03
Estimated Expiration
2045-05-06

AI Technical Summary

Technical Problem

The prior art has problems such as low accuracy, unsatisfactory connection effect, and incomplete removal of pseudo-cracks and noise in the crack extraction of rock mass and concrete materials.

Method used

The crack images of rock mass and concrete materials are extracted by performing grayscale processing, non-local mean filtering, homomorphic filtering, expansion calculation and noise removal.

Benefits of technology

It improves the accuracy and integrity of crack extraction, reduces pseudo-fire and noise interference, enhances the distinction between cracks and textures, and adapts to extraction in complex environments.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120088257A_ABST
    Figure CN120088257A_ABST
Patent Text Reader

Abstract

The invention discloses a crack image extraction method, device and equipment, and relates to the field of crack detection of engineering structure materials, and the method comprises the steps: carrying out the graying processing of a first digital image, and determining a digital image after the graying processing; processing the grayed digital image according to non-local mean filtering to obtain a filtered digital image; performing homomorphic filtering processing on the filtered digital image by using a homomorphic filtering algorithm to obtain a second digital image, performing dilation operation, connecting discontinuous cracks of the second digital image, and determining a continuous second digital image; performing segmentation operation and denoising on the continuous second digital image, and determining the denoised second digital image; refining lines or foreground pixel contours in the skeleton into a single-pixel width skeleton; and quantitative analysis is carried out on the crack of the single-pixel width skeleton, and the crack images of the rock mass and the concrete material are extracted, so that the precision of crack extraction of the rock mass and the concrete material is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the technical field of crack detection of engineering structural materials, and particularly to a method, device and equipment for extracting crack images. Background Art

[0002] Cracks directly affect the strength and permeability of engineering structural materials, and their connection and expansion may cause engineering damage. At present, the methods for identifying cracks in rock mass and concrete materials are mainly divided into three categories: traditional manual identification, physical detection identification, and digital image processing identification. Traditional manual identification methods, such as on-site mapping method, core drilling method, etc., rely heavily on the experience and knowledge of professionals. They not only have low investigation efficiency and strong subjectivity, but also have problems such as difficulty in observing the exposed surface of rock mass and concrete materials and dangerous measurement environment. Physical detection identification methods, such as seismic wave detection method, electromagnetic method, three-dimensional laser scanning, etc., although they identify cracks by measuring and analyzing the physical properties or physical field changes of rock mass and concrete materials, have the disadvantages of over-reliance on prior information, detection blind areas, and results being easily affected by geological conditions and external environment. Digital image processing identification methods, including borehole camera, UAV aerial photography, close-range photogrammetry, etc., convert the exposed surface of rock mass and concrete materials into high-quality digital images through high-definition cameras, and then use computer vision technology and image processing algorithms to extract crack feature information, which has the advantages of convenient data collection, intuitive process, and low cost.

[0003] Although the existing crack extraction methods have optimized the extraction results to a certain extent, they still fail to completely solve the problems. For example, the connection effect of crack segments is not ideal, the removal of pseudo-cracks and noise is not thorough, and the traditional Canny algorithm and Frangi filtering are difficult to effectively extract cracks in rock mass and concrete materials. Summary of the Invention

[0004] The purpose of the present application is to provide a method, device and equipment for extracting crack images, which solves the problem of low accuracy in extracting cracks in engineering structural materials.

[0005] To achieve the above purpose, the present application provides the following solutions.

[0006] In a first aspect, the present application provides a method for extracting crack images, including: Performing gray-scale processing on a first digital image including crack feature information to determine the digital image after gray-scale processing.

[0007] Processing the digital image after gray-scale processing according to non-local mean filtering to obtain a filtered digital image.

[0008] Performing homomorphic filtering on the filtered digital image by using a homomorphic filtering algorithm to obtain a second digital image.

[0009] Perform a dilation operation on the second digital image to connect the discontinuous fissures of the second digital image and determine a continuous second digital image.

[0010] Perform a segmentation operation on the continuous second digital image to remove the noise points of the continuous second digital image and determine a denoised second digital image.

[0011] Extract the skeleton of the denoised second digital image and refine the lines or foreground pixel contours in the skeleton into a single-pixel-width skeleton.

[0012] Perform a quantitative analysis on the fissures of the single-pixel-width skeleton and extract a fissure image of engineering structural materials; the engineering structural materials include rock masses and concrete materials.

[0013] In a second aspect, the present application provides a fissure image extraction device, including: A digital image determination module after grayscale processing, configured to perform grayscale processing on a first digital image including fissure feature information to determine a digital image after grayscale processing.

[0014] A digital image determination module after filtering, configured to process the digital image after grayscale processing according to non-local means filtering to obtain a digital image after filtering.

[0015] A second digital image determination module, configured to perform homomorphic filtering on the digital image after filtering by using a homomorphic filtering algorithm to obtain a second digital image.

[0016] A continuous second digital image determination module, configured to perform a dilation operation on the second digital image to connect the discontinuous fissures of the second digital image and determine a continuous second digital image.

[0017] A denoised second digital image determination module, configured to perform a segmentation operation on the continuous second digital image to remove the noise points of the continuous second digital image and determine a denoised second digital image.

[0018] A single-pixel-width skeleton determination module, configured to extract the skeleton of the denoised second digital image and refine the lines or foreground pixel contours in the skeleton into a single-pixel-width skeleton.

[0019] A fissure image extraction module, configured to perform a quantitative analysis on the fissures of the single-pixel-width skeleton and extract a fissure image of engineering structural materials; the engineering structural materials include rock masses and concrete materials.

[0020] In a third aspect, the present application provides a computer device, including: a memory, a processor, and a computer program stored on the memory and executable on the processor, where the processor executes the computer program to implement the steps of the crack image extraction method described in any one of the above.

[0021] According to the specific embodiments provided by the present application, the present application has the following technical effects: The present application provides a crack image extraction method. By preprocessing a first digital image including crack feature information, a second digital image is determined; a dilation operation is performed on the second digital image to connect the discontinuous cracks in the second digital image and determine a continuous second digital image; a segmentation operation is performed on the continuous second digital image to remove the noise points in the continuous second digital image and determine a denoised second digital image. The Laplacian frequency domain variance accurately controls the non-local mean filtering parameters, effectively reducing image noise; the skeleton of the denoised second digital image is extracted, and the lines or foreground pixel contours in the skeleton are refined into a single-pixel-width skeleton; the cracks in the single-pixel-width skeleton are quantitatively analyzed to extract the crack images of rock mass and concrete-like materials. The discontinuous cracks in the processed second digital image are connected, solving the problems of incomplete crack extraction and noise interference, ensuring the integrity and accuracy of crack extraction, and improving the accuracy of crack extraction of rock mass and concrete-like materials and the efficiency of crack extraction parameters. BRIEF DESCRIPTION OF THE DRAWINGS

[0022] 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 required in the embodiments. Obviously, the drawings in the following description are only some embodiments of the present application. For those of ordinary skill in the art, without creative efforts, other drawings can be obtained based on these drawings.

[0023] Figure 1 It is a schematic flowchart of the crack image extraction method provided by an embodiment of the present application.

[0024] Figure 2 It is a schematic diagram of the working process of the crack image extraction method provided by an embodiment of the present application.

[0025] Figure 3 For different h values provided by an embodiment of the present application, it is a schematic diagram of the comparison of Canny edge detection results.

[0026] Figure 4 It is a schematic diagram of the Gaussian regression fitting curve of the Laplacian frequency domain variance ra and h provided by an embodiment of the present application.

[0027] Figure 5The Laplacian frequency domain variance ra provided by an embodiment of the present application and h Schematic diagram of the derivative curve of Gaussian regression fitting.

[0028] Figure 6 Result diagram of homomorphic filtering processing provided by an embodiment of the present application.

[0029] Figure 7(a) is a schematic diagram of the effect of dilation operation.

[0030] Figure 7(b) is a schematic diagram of the effect of filtering operation.

[0031] Figure 8 Schematic diagram of the fracture skeleton extracted by the Zhang-Suen thinning algorithm provided by an embodiment of the present application.

[0032] Figure 9 Schematic diagram of the comparison of the extraction results between the present application and the Canny and Frangi filtering algorithms provided by an embodiment of the present application.

[0033] Figure 10 Schematic diagram of the structure of a computer device provided by an embodiment of the present application. Detailed implementation manners

[0034] Next, the technical solutions in the embodiments of the present application will be clearly and completely described in conjunction with the accompanying drawings in the embodiments of the present application. Obviously, the described embodiments are only a part of the embodiments of the present application, rather than all the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those of ordinary skill in the art without creative efforts shall fall within the protection scope of the present application.

[0035] To make the above objects, features, and advantages of the present application more obvious and understandable, the present application will be further described in detail below in conjunction with the drawings and specific implementation manners.

[0036] As Figure 2 shown, the present application discloses a method for extracting fracture images. The method includes grayscale processing of the rock mass and concrete material images, using Laplacian frequency domain control non-local mean filtering for denoising, and determining the optimal filtering parameters through Gaussian regression h ; enhancing the fracture contrast using homomorphic filtering, setting relevant parameters to optimize the processing effect; connecting discontinuous fractures through dilation operation, using a specific structural element and dilation rate; removing noise points through area and angle threshold filtering operation; and extracting the fracture skeleton using the Zhang-Suen thinning algorithm. The present application can effectively reduce image noise, improve the distinguishability between fractures and textures of rock masses and concrete materials, accurately extract the complete fracture contour in complex environments. Compared with traditional algorithms, it has significant advantages in removing pseudo-fractures, ensuring fracture integrity, and adapting to complex environments, and realizes parameter self-adaptation and full-process automation.

[0037] The purpose of this application is to provide a method and system for automatically extracting fractures in rock mass and concrete-like materials based on Laplace frequency domain image enhancement, so as to solve the problems existing in the existing fracture extraction methods for rock mass and concrete-like materials, such as poor fracture extraction accuracy, large influence of interference factors, and poor universality, and to achieve efficient and accurate extraction of fractures in rock mass and concrete-like materials.

[0038] As Figure 1 shown, the embodiment of this application provides a method for extracting fracture images, which specifically includes the following steps.

[0039] S1: Perform gray-scale processing on the first digital image including fracture feature information to determine the digital image after gray-scale processing.

[0040] S2: Process the digital image after gray-scale processing according to non-local means filtering to obtain the filtered digital image.

[0041] S3: Perform homomorphic filtering on the filtered digital image by using the homomorphic filtering algorithm to obtain the second digital image.

[0042] S4: Perform dilation operation on the second digital image to connect the discontinuous fractures in the second digital image and determine the continuous second digital image.

[0043] S5: Perform segmentation operation on the continuous second digital image to remove the noise points in the continuous second digital image and determine the second digital image after denoising.

[0044] S6: Extract the skeleton of the second digital image after denoising, and refine the lines or foreground pixel contours in the skeleton into a single-pixel-width skeleton.

[0045] S7: Perform quantitative analysis on the fractures of the single-pixel-width skeleton to extract the fracture image of engineering structural materials; the engineering structural materials include rock mass and concrete-like materials.

[0046] Furthermore, in an exemplary embodiment, S1 specifically includes: Convert the first digital image into a first digital image containing only gray-scale information to obtain the digital image after gray-scale processing.

[0047] Convert the exposed surface of rock mass and concrete-like materials or the hole wall of rock mass and concrete-like materials into high-quality digital images through a high-definition camera, and then use computer vision technology and image processing algorithms to extract fracture feature information. Gray-scale the obtained images of rock mass and concrete-like materials to eliminate the interference of image color on subsequent algorithm processing. Because in actual images of rock mass and concrete-like materials, color information may mask the gray-scale difference between fractures and the surrounding rock mass and concrete-like materials, which is not conducive to the identification and extraction of fractures. Through gray-scale processing, the image can be converted into an image containing only gray-scale information, simplifying the subsequent processing process.

[0048] Select image acquisition devices suitable for the fracture detection scenarios of rock mass and concrete-like materials, which can include but are not limited to high-resolution borehole cameras, drones equipped with high-definition cameras, and high-precision close-range photogrammetry devices, etc., and carry out image acquisition work for the exposed surface or hole wall of rock mass and concrete-like materials. Before the acquisition operation, it is necessary to comprehensively evaluate the actual situation of rock mass and concrete-like materials, and flexibly and accurately adjust the device parameters according to various factors such as their location, scale, and lighting conditions.

[0049] If the acquisition environment is an underground area of rock mass and concrete-like materials with relatively dim light, the built-in sensitivity adjustment function of the device can be used to reasonably increase the sensitivity of the camera, and at the same time optimize parameters such as exposure time and aperture size to balance image brightness and noise control, ensuring that the captured images are clear and distinguishable. For large-scale exposed surfaces of rock mass and concrete-like materials, it is preferred to use a drone equipped with a high-definition camera for image acquisition. According to the scope and topography of the exposed surface of rock mass and concrete-like materials, combined with the flight performance and shooting ability of the drone, plan appropriate flight heights and shooting angles to ensure that the captured images can not only completely cover the target detection area but also clearly present the fine features of fractures in rock mass and concrete-like materials, including the width, trend, texture, etc. of the fractures.

[0050] For high-precision close-range photogrammetry devices, when facing rock mass and concrete-like materials with complex shapes, by adjusting the focal length, shooting distance, and angle of the device, and using multi-angle shooting and image stitching technology, complete and high-precision image data of rock mass and concrete-like materials can be obtained. During the image acquisition process, the system automatically records metadata such as the acquisition time, location, and device parameters of the images, providing auxiliary information for subsequent image analysis and processing.

[0051] The collected image data will be stored in common and highly versatile formats such as JPEG and PNG. These formats have good compatibility, facilitating efficient processing using various image processing software and algorithms later, reducing data conversion costs, and improving work efficiency.

[0052] Input the collected images of colored rock mass and concrete materials into the grayscale processing module. The weighted average method is used for grayscale processing, and the formula is: , where , , are the red, green, and blue component values of each pixel in the color image respectively, is the converted grayscale value. Traverse each pixel in the image, calculate and replace its original color value according to the above formula, so as to convert the color image into a grayscale image. After grayscale processing, the amount of information in the image is reduced, the complexity of subsequent processing is reduced, and at the same time, the interference of color on crack extraction is eliminated, highlighting the grayscale difference characteristics.

[0053] Furthermore, in an exemplary embodiment, S2 can be replaced by the following steps.

[0054] S201: Control the non-local means filtering parameters according to the Laplacian frequency domain variance.

[0055] S202: Calculate the relationship between the Laplacian frequency domain variance and the non-local means filtering parameters according to the Gaussian regression algorithm, and determine the optimal non-local means filtering parameters.

[0056] S203: Determine the filtered digital image according to the optimal non-local means filtering parameters.

[0057] Laplacian frequency domain control non-local means filtering denoising: Use non-local means filtering (Non-Local Means Denoising, NLM) to process the grayscale image to enhance the crack image and retain the crack edges to the greatest extent. Non-local means filtering includes parameters such as similar block size, search window size, similarity threshold, and filtering coefficient h etc. Among them, the filtering coefficient h is the key parameter, and different values of it will cause great differences in the processed image. To determine the optimal filtering parameter h , control the filtering parameter h of non-local means through the Laplacian operator.

[0058] Furthermore, in an exemplary embodiment, S3 can be replaced by the following steps.

[0059] S301: As the non-local means filtering parameters increase, the Laplacian frequency domain variance decreases.

[0060] S302: When dra / d h reaches the minimum value and tends to 0, determine the optimal non-local filtering parameters; where ra is the Laplacian frequency domain variance; h is the non-local filtering parameter; dra / d h is the derivative of ra with respect toh The derivative of

[0061] Initialize the non-local means filtering parameters, set the size of the similar block to 7, and the size of the search window to 21. These two parameters determine the range of neighboring blocks involved in the calculation during the filtering process. Similar blocks are searched within this range to calculate the filtered value of the current pixel for the purpose of denoising.

[0062] Calculate the Laplacian frequency domain variance ra of the image according to the Laplacian operator formula. In the discrete form, the Laplacian operator formula is: .

[0063] Where, is the pixel value of the image at the position. After calculating the Laplace transform of the entire image, then calculate the Laplacian frequency domain variance according to the variance formula , is the variance calculation function, is the Laplace transform function, is the image being processed currently.

[0064] As Figure 3 shown, perform non-local means filtering using different filtering coefficients h , and then perform Canny edge extraction on the filtered result to verify the h optimal value. Use the Gaussian regression algorithm to calculate the relationship between and the filtering coefficient , that is . By plotting the relationship curve of versus as Figure 4 shown, and its derivative curve , as Figure 5 shown, observe the change of the derivative curve. When reaches the minimum value and approaches 0, the corresponding value is the optimal filtering parameter. For example, when processing the images of rock mass and concrete materials in Figure 2 , after multiple calculations and analyses, it is determined that when , it can not only effectively remove noise but also better retain the crack edge information. Denote the sum of the variances after taking the Laplace transform of the entire image as the Laplacian frequency domain variance ra, and use the Gaussian regression algorithm to calculate the relationship between ra and h to obtain the h value for the best denoising effect. During this process, as the h value increases, the ra value gradually decreases. When dra / d h reaches the minimum value and approaches 0, the corresponding hThe value at which the crack enhancement effect is optimal. The advantage of doing this is that it can automatically and accurately determine the filtering parameters, improve the stability and adaptability of the algorithm, and reduce the workload of manual parameter adjustment.

[0065] Perform non-local means filtering on the grayscale image according to the determined optimal value. During the filtering process, calculate the filtering value of each pixel based on the similarity between similar blocks. The calculation of similarity is based on the similarity of pixel values and neighborhood structures. This can remove noise while maximizing the retention of the edges and detailed information of the cracks, improve the image quality, and provide a clearer image basis for subsequent crack extraction.

[0066] Furthermore, in an exemplary embodiment, S4 can be replaced by the following steps.

[0067] S401: Use the formula to obtain the original image; where x is the horizontal coordinate of the pixel in the image, y is the vertical coordinate of the pixel in the image, is the original image; is the illumination component; is the reflectance component.

[0068] The image after filtering and denoising enters the homomorphic filtering module. In this module, set the relevant parameters according to the principle of the homomorphic filtering algorithm. The low-frequency gain rl = 0.9, the high-frequency gain rh = 2.5, the cut-off frequency , the sharpening degree control parameter c = 4, the high-frequency adjustment factor hf = 2, and the low-frequency adjustment factor l = 0.5. According to the calculation steps of homomorphic filtering, first represent the image as the product of the illumination component and the reflectance component , that is .

[0069] S402: Use the formula to obtain the logarithmic domain image function; where, is the logarithmic domain image function.

[0070] Take the logarithm of it to get , and then perform Fourier transform to convert it to the frequency domain .

[0071] S403: Perform Fourier transform on the logarithmic domain image function to convert it to the frequency domain, and obtain ; is the frequency domain image function.

[0072] S404: Based on , use the formula to determine the frequency domain filter; where, is a frequency domain filter; rh is the high-frequency gain; rl is the low-frequency gain; is the center point in the frequency domain the distance to the origin, , M is the size of the second digital image in the horizontal direction; N is the size of the second digital image in the vertical direction; u is the abscissa of the center point in the frequency domain; v is the ordinate of the center point in the frequency domain; D 0 is the origin.

[0073] S405: Use the formula to obtain the filtered frequency domain result; where, is the filtered frequency domain result.

[0074] S406: Use the formula to obtain the adjusted frequency domain result; where, is the adjusted frequency domain result; hf is the high-frequency adjustment factor; l is the low-frequency adjustment factor.

[0075] S407: Perform the inverse Fourier transform on to obtain the spatial domain image .

[0076] S408: Use the formula , perform the inverse Fourier transform and exponential transform on the adjusted frequency domain result to obtain the second digital image; where, is the second digital image.

[0077] After homomorphic filtering, the contrast of the crack is significantly enhanced, and the background noise is effectively suppressed. This filter processes the low-frequency and high-frequency parts to different degrees according to the set parameters, realizes the enhancement of the image contrast and the suppression of the background noise, further optimizes the filtered frequency domain image, enhances the detail information of the high-frequency part, reduces the background influence of the low-frequency part, and makes the crack feature of the image more obvious. After homomorphic filtering as Figure 6 shown, the contrast of the crack is significantly enhanced, the background noise is effectively suppressed, and the clarity and recognizability of the image are greatly improved, providing better image conditions for accurately extracting the crack subsequently.

[0078] Further, in an exemplary embodiment, S5 can be replaced by the following steps.

[0079] S501: When the second digital image is the binary image, expand the foreground pixels outward with the foreground pixels as the center according to the dilation algorithm to determine the continuous second digital image.

[0080] S502: When the second digital image is the grayscale image, replace each pixel value with the maximum grayscale value within the neighborhood of the grayscale image according to the dilation algorithm to determine a continuous second digital image.

[0081] After the homomorphic filtering operation, although the main fissure image has been segmented, there are still many discontinuous positions in the fissures. To address this issue, dilation operation is performed on the image to connect the discontinuous fissures and further enhance the continuity of the fissures. The dilation operation is performed on binary images or grayscale images in the image. For binary images, dilation is the process of expanding foreground pixels into surrounding background pixels; for grayscale images, dilation is to replace the value of each pixel with the maximum grayscale value within its neighborhood. The image after homomorphic filtering is binarized. An appropriate binarization method, such as the Otsu threshold method, is used to calculate the optimal threshold of the image. The binarization algorithm adopted in this application is the global fixed threshold binarization algorithm. According to this threshold, pixels with grayscale values greater than the threshold in the image are set as foreground pixels (value 1), and pixels with grayscale values less than the threshold are set as background pixels (value 0), thus converting the grayscale image into a binary image. In this method, after binarizing the image after homomorphic filtering, a dilation operation is performed using a 7×7 elliptical structuring element with a dilation rate of 5 to form a complete fissure. During the dilation process, for binary images, foreground pixels expand into surrounding background pixels. Specifically, with the center of the structuring element traversing each pixel in the image, if the center pixel is a foreground pixel (value 1), then all background pixels (value 0) within the coverage of the structuring element are changed to foreground pixels. Through the dilation operation, the originally discontinuous fissures are connected, and the continuity of the fissures is enhanced, which is beneficial for subsequent analysis and processing of the overall shape of the fissures. The final processing result is shown in Fig. 7(a).

[0082] The dilation operation can effectively fill the discontinuous parts in the fissures, making the contour of the fissures more complete and facilitating subsequent analysis and processing.

[0083] Further, in an exemplary embodiment, S6 can be replaced by the following steps.

[0084] S601: The noise points include first noise points and second noise points.

[0085] S602: Screen the continuous second digital images to determine the screened digital images; the area threshold of the screened digital images is less than 1 times the average area threshold.

[0086] S603: Remove the first noise points in the screened digital images according to the area threshold method and remove the second noise points in the screened digital images according to the angle threshold method to obtain the denoised second digital image.

[0087] After dilation operation, a certain number of noise points will appear in the crack images of rock mass and concrete materials. These noise points belong to non-crack elements. In order to remove these noise points, threshold segmentation operation is implemented through area threshold and angle threshold. The cracks in rock mass and concrete materials have a certain area range, while the area of noise points and some small non-crack interference regions is relatively small. It is calculated that the foreground regions with an area threshold less than 1 times the average area threshold are generally noise points. For a small part of the noise points that cannot be removed by the area threshold, the angle threshold method is considered again. The angle threshold method believes that cracks are usually relatively long and narrow, and the aspect ratio of the rectangle formed by the two end points of the crack as the diagonal is generally large. Those less than the average threshold (close to a square) are generally noise points or pseudo-cracks. Then they are determined as noise points or pseudo-cracks, and their pixel values are also changed from 1 to 0. Through the double filtering operation of area threshold and angle threshold, the noise points and pseudo-cracks existing in the image after dilation operation are effectively removed, and a clear and accurate crack image is obtained, as shown in Fig. 7(b), improving the accuracy of the crack extraction result.

[0088] Through this filtering operation with double thresholds, a clear and accurate crack image can finally be obtained, effectively improving the accuracy of crack extraction.

[0089] Furthermore, in an exemplary embodiment, S7 can be replaced by the following steps.

[0090] S701: If the value of the pixel point in the denoised second digital image is 1, and the number of pixel points with a value of 1 in the neighborhood of the pixel point is between 2 and 6, then the pixel point is a pixel point that may be deleted; the neighborhood is the 8 pixel points above, below, left, right, and diagonally of the pixel point.

[0091] S702: If the pixel points that may be deleted are continuous, then mark the pixel points that may be deleted as pixel points that can be deleted; starting from a pixel point with a value of 1, in the clockwise or counterclockwise direction, if the values of the adjacent pixel points of the pixel point are also 1, then the pixel points that may be deleted are continuous.

[0092] S703: Set the pixel value of the pixel points that can be deleted from 1 to 0, and delete the pixel points that can be deleted until no new pixel points in the second digital image are marked as pixel points that can be deleted, then the lines in the denoised second digital image are thinned into a single-pixel-width skeleton, and the crack image of the engineering structure material is extracted.

[0093] The first step: Mark the pixels to be deleted.

[0094] For each pixel point in the second digital image after denoising, if its value is 1 and the number of pixel points with a value of 1 among its 8 neighbors (i.e., the 8 pixel points around it, up, down, left, right, and the four diagonal ones) is between 2 and 6, then preliminarily mark this pixel point as a pixel point that may be deleted. Check the arrangement of the pixel points with a value of 1 among the 8 neighbors of this pixel point. If these pixel points with a value of 1 are continuous (i.e., starting from a pixel point with a value of 1, in a clockwise or counterclockwise direction, the adjacent pixel points also have a value of 1 without interruption), then do not mark this pixel point as a deletable pixel point. This is to avoid deleting the edge part of the line and ensure the continuity of the line.

[0095] Step 2: Delete the marked pixels.

[0096] After completing the first round of marking, set the values of all pixel points marked as deletable pixels from 1 to 0, that is, delete these pixel points. In this way, without destroying the overall structure of the image, the lines can be made thinner.

[0097] Repeat the above process.

[0098] Continuously repeat the first and second steps until no new pixel points in the second digital image after denoising are marked as deletable pixels. At this time, the lines in the second digital image after denoising have been thinned to single-pixel width, achieving the expected effect of the algorithm.

[0099] Skeleton extraction is to make the fracture images of rock mass and concrete-like materials form single-pixel curve images, which is convenient for fracture quantification. When the research focus is on the number, length, and orientation of fractures, single-pixel curve images are more conducive to identification. This method uses the Zhang-Suen thinning algorithm to perform skeleton extraction on the fracture images, thinning the lines or foreground pixel contours in the binary image to single-pixel width skeletons. During the thinning process, the topological structure and key features of the image are kept unchanged as much as possible, and finally a single-pixel fracture skeleton image is obtained, as Figure 8As shown. This skeleton image facilitates quantitative analysis of the number, length, and direction of cracks, and provides an important data basis for the study and engineering application of cracks in rock and concrete materials. The algorithm cyclically scans the pixels in the image and determines whether to delete the pixel based on the status of the pixels in the pixel neighborhood. Count the number of pixels whose neighborhood is foreground (value is 1), and record the pixels whose number is not 2-6 (this condition ensures that the current pixel is not an endpoint or an isolated point, nor an internal point, but a boundary point); connect the pixel neighborhood in sequence to form a path. If the number of jumps from 1 to 0 in the path is 1 (indicating that one side of the pixel is the foreground and the other side is the background), deleting the pixel will not destroy the connectivity of the image. Delete the pixels that meet the above two conditions, and gradually refine the lines in the image to a single pixel width, keeping the topological structure and key features of the image unchanged as much as possible. After being processed by the Zhang-Suen thinning algorithm, the Y-shaped trunk of the extracted crack images of rock and concrete materials is well maintained, with fewer noise points and pseudo-cracks, and the crack extraction effect is relatively ideal, which provides convenience for the subsequent crack quantitative analysis.

[0100] In order to verify the effectiveness and superiority of the crack image extraction method of the present application, the crack images of rock and concrete materials are extracted by using the method of the present application and the classic Canny edge detection and Frangi filtering methods, such as Figure 9 To ensure consistency, image preprocessing and enhancement were performed, and the calculation parameters of the Canny and Frangi filtering algorithms were all manually selected optimal values.

[0101] Both Canny edge detection and Frangi filtering can extract cracks in rock and concrete materials. However, the cracks processed by Canny edge detection have more image noise points that are not easy to segment, which is inferior to the method of this application in terms of crack integrity. The cracks processed by Frangi filtering have no obvious boundary with the background color, which is a non-binary image, and the cracks contain some textures, which is not conducive to the subsequent quantitative analysis of the cracks.

[0102] like Figure 9 As shown, in picture sample 3, due to the presence of plant occlusion and sun shadow, the Canny and Frangi filter algorithms are difficult to achieve effective crack extraction, and the algorithm fails. In picture sample 6, the Canny and Frangi filter algorithms extract a large number of pseudo-cracks, and the accuracy of crack extraction is poor. In picture samples 2 and 4, there is an obvious lack of connectivity in the cracks extracted by the Canny and Frangi filter algorithms, and the processing effect of crack continuity is poor. The present application can not only remove pseudo-cracks and background noise, effectively purify image information, but also solve the complex situation of uneven image contrast, realize efficient capture and extraction of crack information, and obtain complete cracks.

[0103] In this application, the filtering parameter h of the non-local mean is precisely controlled in the Laplace frequency domain, effectively reducing image noise and enhancing the distinguishability between cracks and textures. At the same time, homomorphic filtering further enhances the crack contrast and suppresses background noise. The combination of dilation operation and filtering operation solves the problems of incomplete crack extraction and noise interference, ensuring the integrity and accuracy of crack extraction. Compared with traditional Canny edge detection and Frangi filtering algorithms, the crack images extracted in this application perform better in removing pseudo-cracks and ensuring crack integrity. For complex environments such as plant occlusion, shadows generated by uneven surfaces of rock masses and concrete materials, and solar shadows, the method of this application can accurately extract the complete crack contour, has strong environmental adaptability, and overcomes the problem of reduced extraction accuracy of existing algorithms in complex environments. This application fully integrates the two stages of image enhancement and crack extraction, realizes the self-adaptation of crack extraction parameters and full-process automation, reduces manual intervention, improves work efficiency, and reduces labor costs.

[0104] An embodiment of this application provides a crack image extraction device, and the specific modules are described as follows.

[0105] A digital image determination module after grayscale processing is used to perform grayscale processing on a first digital image including crack feature information to determine the digital image after grayscale processing.

[0106] A digital image determination module after filtering is used to process the digital image after grayscale processing according to non-local mean filtering to obtain the digital image after filtering.

[0107] A second digital image determination module is used to perform homomorphic filtering on the digital image after filtering by using a homomorphic filtering algorithm to obtain a second digital image.

[0108] A continuous second digital image determination module is used to perform dilation operation on the second digital image to connect the discontinuous cracks in the second digital image to determine the continuous second digital image.

[0109] A second digital image determination module after denoising is used to perform a segmentation operation on the continuous second digital image to remove the noise points in the continuous second digital image to determine the second digital image after denoising.

[0110] A single-pixel width skeleton determination module is used to extract the skeleton of the second digital image after denoising and refine the lines or foreground pixel contours in the skeleton into a single-pixel width skeleton.

[0111] A crack image extraction module is used to perform quantitative analysis on the cracks of the single-pixel width skeleton to extract the crack images of engineering structure materials.

[0112] In an exemplary embodiment, a computer device is provided. The computer device can be a server or a terminal, and its internal structure diagram can be as shown in Figure 10 . The computer device includes a processor, a memory, an input / output interface (Input / Output, abbreviated as I / O), and a communication interface. Among them, the processor, the memory, and the input / output interface are connected through a system bus, and the communication interface is connected to the system bus through the input / output interface. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program, and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The database of the computer device is used for crack image extraction. The input / output interface of the computer device is used to exchange information between the processor and external devices. The communication interface of the computer device is used to communicate with an external terminal through a network connection. When the computer program is executed by the processor, it implements a video tag processing method.

[0113] Those skilled in the art can understand that Figure 10 the structure shown in is only a block diagram of some structures related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine some components, or have different component arrangements. In an exemplary embodiment, a computer device is provided, including a memory and a processor. A computer program is stored in the memory, and when the processor executes the computer program, the steps in the above method embodiments are implemented.

[0114] The technical features of the above embodiments can be combined arbitrarily. For the sake of brevity of description, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, it should be considered to be within the scope described in this specification.

[0115] In this application, specific examples are used to elaborate on the principle and implementation manner of the present application. The description of the above embodiments is only used to help understand the method and its core idea of the present application; at the same time, for those of ordinary skill in the art, according to the idea of the present application, there will be changes in the specific implementation manner and application scope. In summary, the content of this specification should not be construed as a limitation on the present application.

Claims

1. A crack image extraction method, characterized in that: The crack image extraction method comprises: Performing grayscale processing on the first digital image including crack feature information to determine a digital image after grayscale processing; Processing the grayscaled digital image according to non-local mean filtering to obtain a filtered digital image; Performing homomorphic filtering processing on the filtered digital image using a homomorphic filtering algorithm to obtain a second digital image; Performing a dilation operation on the second digital image to connect discontinuous cracks in the second digital image to determine a continuous second digital image; Performing a segmentation operation on the continuous second digital images to remove noise points from the continuous second digital images and determine a denoised second digital image; Extracting the skeleton of the denoised second digital image, and thinning the lines or foreground pixel contours in the skeleton into a single-pixel width skeleton; The cracks of the single-pixel width skeleton are quantitatively analyzed to extract crack images of engineering structural materials; the engineering structural materials include rock and concrete materials.

2. The crack image extraction method according to claim 1, characterized in that: Gray-scaling the first digital image including the crack feature information to determine the digital image after the gray-scaling process specifically includes: The first digital image is converted into a first digital image containing only grayscale information to obtain a digital image after grayscale processing.

3. The crack image extraction method according to claim 1, characterized in that: Processing the grayscale processed digital image according to non-local mean filtering to obtain a filtered digital image specifically includes: Controlling non-local mean filter parameters based on Laplace frequency domain variance; Calculating the relationship between the Laplace frequency domain variance and the non-local mean filter parameters according to the Gaussian regression algorithm, and determining the optimal non-local mean filter parameters; The filtered digital image is determined according to the optimal non-local mean filtering parameters.

4. The crack image extraction method according to claim 3, characterized in that: Calculating the relationship between the Laplace frequency domain variance and the non-local mean filter parameters according to the Gaussian regression algorithm to determine the optimal non-local mean filter parameters specifically includes: As the non-local mean filter parameter increases, the Laplace frequency domain variance decreases; When dra / d h When the minimum value is reached and approaches 0, the optimal non-local filtering parameter is determined; where ra is the Laplace frequency domain variance; h is the non-local filtering parameter; dra / d h For ra h The derivative of .

5. The crack image extraction method according to claim 1, characterized in that: Performing homomorphic filtering processing on the filtered digital image using a homomorphic filtering algorithm to obtain a second digital image specifically includes: Using the formula Get the original image; where x is the horizontal coordinate of the pixel in the image, and y is the vertical coordinate of the pixel in the image. is the original image; is the illumination component; is the reflectivity component; Using the formula Get the logarithmic domain image function; where, is the logarithmic domain image function; The logarithmic domain image function is Fourier transformed to the frequency domain to obtain ; is the frequency domain image function; based on , using the formula Determine the frequency domain filter; where, is the frequency domain filter; rh is the high frequency gain; rl is the low frequency gain; The center point of the frequency domain The distance to the origin, , M is the size of the second digital image in the horizontal direction; N is the size of the second digital image in the vertical direction; u is the horizontal coordinate of the center point of the frequency domain; v is the vertical coordinate of the center point of the frequency domain; D0 is the origin; Using the formula Get the frequency domain result after filtering; among them, is the frequency domain result after filtering; Using the formula Get the adjusted frequency domain result; among them, is the frequency domain result after adjustment; hf is the high frequency adjustment factor; l is the low frequency adjustment factor; right Perform inverse Fourier transform to obtain the spatial domain image ; Using the formula , the frequency domain result after adjustment Perform inverse Fourier transform and exponential transform to obtain a second digital image; wherein, is the second digital image.

6. The crack image extraction method according to claim 1, characterized in that: Performing a dilation operation on the second digital image to connect discontinuous cracks of the second digital image to determine a continuous second digital image, specifically comprising: the second digital image is a binary image or a grayscale image; When the second digital image is the binary image, foreground pixels are expanded toward external pixels with the foreground pixels as the center according to a dilation algorithm to determine a continuous second digital image; When the second digital image is the grayscale image, each pixel value is replaced with the maximum grayscale value in the neighborhood of the grayscale image according to the dilation algorithm to determine a continuous second digital image.

7. The crack image extraction method according to claim 1, characterized in that: Performing a segmentation operation on the continuous second digital images to remove noise points from the continuous second digital images and determining a denoised second digital image specifically includes: The noise points include first noise points and second noise points; Screening the continuous second digital images to determine a screened digital image; an area threshold of the screened digital image is less than 1 times the average area threshold; The first noise points in the screened digital image are removed according to the area threshold method, and the second noise points in the screened digital image are removed according to the angle threshold method to obtain a denoised second digital image.

8. The crack image extraction method according to claim 1, characterized in that: Extracting the skeleton of the denoised second digital image and thinning the lines or foreground pixel contours in the skeleton into a single-pixel width skeleton specifically includes: If the value of a pixel in the denoised second digital image is 1, and the number of pixel values ​​in the neighborhood of the pixel that are 1 is between 2 and 6, then the pixel is a pixel that may be deleted; the neighborhood is 8 pixel points above, below, left, right and diagonally of the pixel; If the pixels that may be deleted are continuous, the pixels that may be deleted are marked as deletable pixels; starting from a pixel with a value of 1, in a clockwise or counterclockwise direction, if the values ​​of the pixels adjacent to the pixel are also 1, then the pixels that may be deleted are continuous; The pixel value of the deletable pixel is set from 1 to 0, and the deletable pixel is deleted until no new pixel is marked as a deletable pixel in the second digital image. The lines in the denoised second digital image are refined into a single-pixel width skeleton, and the crack image of the engineering structure material is extracted.

9. A crack image extraction device, characterized in that: The crack image extraction device comprises: A module for determining a digital image after grayscale processing, used for performing grayscale processing on the first digital image including crack feature information, and determining a digital image after grayscale processing; A filtered digital image determination module is used to process the grayscale digital image according to non-local mean filtering to obtain a filtered digital image; A second digital image determination module, configured to perform homomorphic filtering on the filtered digital image using a homomorphic filtering algorithm to obtain a second digital image; a continuous second digital image determination module, configured to perform a dilation operation on the second digital image, connect discontinuous cracks in the second digital image, and determine a continuous second digital image; A denoised second digital image determination module, used to perform a segmentation operation on the continuous second digital images, remove noise points from the continuous second digital images, and determine a denoised second digital image; A single-pixel width skeleton determination module is used to extract the skeleton of the denoised second digital image and refine the lines or foreground pixel contours in the skeleton into a single-pixel width skeleton; The crack image extraction module is used to perform quantitative analysis on the cracks of the single-pixel width skeleton and extract the crack image of the engineering structure material.

10. A computer device comprising: A memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the crack image extraction method according to any one of claims 1 to 8.

Citation Information

Patent Citations

  • Non-local theory-based image denoising method

    CN103208104A

  • Color brightness recognition method, device, equipment and medium

    CN112712568A

  • High dynamic range infrared image rapid denoising and display algorithm based on non-local mean filtering

    CN117115017A

  • Control method and device for angle adjustment of guide rail at channel entrance

    CN117590766A

  • Surface crack detection method based on image processing

    CN117974627A