Automatic identification method for borehole fracture based on multi-scale filtering and geometric prior
By employing multi-scale filtering and geometric prior methods, the problems of data dependency and noise interference in borehole fracture identification are solved, achieving high-precision automatic fracture identification, which is suitable for small-sample unsupervised scenarios and complex backgrounds.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- LIUPANSHUI NORMAL UNIV
- Filing Date
- 2026-01-21
- Publication Date
- 2026-06-05
Smart Images

Figure CN122156714A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the fields of digital image processing and geological exploration technology, specifically to an automatic borehole fracture identification method based on multi-scale filtering and geometric prior. Background Technology
[0002] Borehole camera technology generates panoramic unfolded images of the borehole wall to visually reflect the underground rock mass structure. Accurate extraction and parameter calculation of fractures are crucial for rock mass stability assessment and engineering geological exploration. Existing technologies typically employ manual visual interpretation or automated segmentation models based on fully supervised deep learning for fracture identification.
[0003] However, the existing technology has the following significant drawbacks: (1) Manual interpretation is labor-intensive, inefficient, and the results are greatly affected by the subjective experience of the operators. (2) The performance of mainstream deep learning segmentation models (such as the U-Net series) heavily depends on massive and high-quality pixel-level labeled datasets. In actual engineering scenarios, there is often a "small sample, unsupervised" constraint due to scarce data samples and lack of manual labeling. (3) Deep learning models usually require the input image to be a square of a fixed size (such as 256×256 or 512×512 pixels), while the borehole unfolded image is usually a thin strip image with a very high aspect ratio. If scaling is used, it will cause severe deformation of the geometric features of the crack; if cropping and segmenting are used, it will easily destroy the continuity of the crack and introduce edge artifacts at the splicing. (4) Existing traditional image processing algorithms based on gradient edge detection or global thresholding are ineffective in suppressing background noise when processing borehole unfolding images containing complex interference factors such as natural rock texture, mechanical drilling marks, mud covering and image stitching lines. This is because they lack the ability to specifically extract the tubular or linear geometric features of the fractures, resulting in insufficient fracture segmentation accuracy in low contrast or strong interference areas.
[0004] Therefore, there is an urgent need for a high-precision automatic fracture identification method that does not require training samples, can directly process slender images, and can effectively resist interference from complex geological and technological noise. Summary of the Invention
[0005] The purpose of this invention is to provide an automatic borehole fracture identification method based on multi-scale filtering and geometric prior, in order to solve the problems of existing borehole fracture identification methods mentioned in the background art, which rely on a large amount of labeled data, cannot adapt to small sample unsupervised scenarios, have weak processing capabilities for slender images with large aspect ratios, and have low segmentation accuracy in complex geological noise backgrounds.
[0006] To address the aforementioned technical problems, this invention provides the following technical solution: an automatic borehole fracture identification method based on multi-scale filtering and geometric prior. S1, Image grayscale preprocessing The original color borehole imaging unfolded image was converted into a single-channel grayscale image using a weighted average method according to the ITU-R BT.601 standard to reduce data dimensionality and preserve original texture features. The calculation formula is as follows: ,in, Grayscale value , , These are the red, green, and blue channel components of the original color image, respectively. S2, Multi-scale Frangi Feature Enhancement To establish a multi-scale Frangi feature enhancement model based on the Hessian matrix, the Hessian matrix of each pixel in the image is first calculated. : ; The second-order partial derivatives are calculated using Gaussian kernel convolution to solve for the eigenvalues of the matrix. (and satisfy) ); The linear dark structure features exhibited by the cracks (i.e. Construct the Frangi response function :
[0007] in, For spot measurement factor, For structural strength factor, and These are the threshold parameters that control spot sensitivity and structural contrast, respectively. A multi-scale discrete sampling ensemble strategy is adopted, and the scale range is set. and sampling step size At every discrete scale The response is calculated, and the maximum value is taken as the final feature enhancement map: ; This strategy can adapt to crack features of different widths, ensuring that micro-cracks and main cracks are preserved in a single feature map at the same time.
[0008] Extract the tubular structure features of the cracks in the image and obtain the maximum Frangi response map; S3, Initial Segmentation and Noise Reduction An adaptive thresholding algorithm is used to initially segment the maximum Frangi response map to obtain an initial binary image, and area filtering is used to remove small noise regions; specifically, this includes: Calculate the inter-class variance of foreground and background using the Otsu algorithm. : ; in, and These represent the threshold values respectively. The probability of pixels being classified as background and foreground. and These represent the average grayscale values of the background and foreground pixels, respectively. Select to make Maximize As the optimal threshold The Frangi response map is converted into an initial binary image, and area filtering is applied to the initial binary image. The area of each connected component is calculated through connected component analysis. Set area threshold Remove The small noise region; S4. Mask Correction Based on Geometric Priors Based on the geological morphology of fractures and drilling technology characteristics, artifact regions in the initial binary image are identified and an error mask is constructed. The maximum Fragi response map is then corrected using the error mask to obtain a corrected response map. The corrected response map undergoes secondary segmentation and morphological optimization to output the final fracture identification result. This process is carried out in the following steps: Identify all connected components in the initial binary image and calculate the elongation and principal axis direction angle of each connected component; Based on the geometric features of drilling marks and image stitching lines, which respectively exhibit vertical and horizontal long straight lines, a correction function is constructed. Connected components with principal axis orientation angles close to 0° or 90° and high linearity are marked as artifact regions, and corresponding error masks are generated. ; The error mask obtained in step S2 is used to... The response map is corrected by setting the response values within the masked region to zero or suppressing them: ; The corrected response diagram Perform secondary Otsu binarization and morphological closing operation (dilation followed by erosion) to connect the broken crack segments. Then, smooth the contour through opening operation to output the final crack segmentation result.
[0009] Compared with the prior art, the beneficial effects achieved by the present invention are: (1) Adaptable to small sample unsupervised scenarios: This invention does not rely on training with a large amount of labeled data. It can complete high-precision segmentation with just a single image, effectively solving the problems of scarce data and high labeling costs in engineering sites.
[0010] (2) Overcoming image size limitations: This algorithm directly processes the original resolution long image without cropping or scaling, avoiding the geometric distortion of cracks caused by changing the aspect ratio and the edge effect caused by block processing. It is particularly suitable for the slender shape of the borehole panoramic unfolded image.
[0011] (3) Strong anti-interference and high robustness: This invention abandons the traditional enhancement methods (such as CLAHE and normalization) that easily amplify noise, and instead uses the geometric sensitivity of the Frangi filter combined with geological prior mask correction, which can accurately remove complex interference such as mud edges, mechanical drill marks and splicing lines, which is significantly better than traditional gradient operators.
[0012] (4) High segmentation accuracy: Through the closed-loop strategy of “initial segmentation to locate artifacts -> response map correction -> secondary segmentation”, interference is eliminated at the feature level rather than only at the result level. While preserving the integrity of the crack topology, pixel-level artifact removal is achieved. Attached Figure Description
[0013] The accompanying drawings are provided to further illustrate the invention and form part of the specification. They are used in conjunction with embodiments of the invention to explain the invention and do not constitute a limitation thereof. In the drawings: Figure 1 This is a schematic diagram of the overall process of the method of the present invention; Figure 2 This is the original borehole imaging unfolded image selected in the embodiment of the present invention, which includes mud cover and splicing line interference; Figure 3 This is an embodiment of the present invention. Figure 2 The image shown is a schematic diagram of the intermediate process after grayscale preprocessing. Wherein: (a) is the multi-scale Frangi filter response map, (b) is the initial Otsu binarized mask map, (c) is the result map of the first morphological post-processing, (d) is the horizontal / vertical artifact error mask map generated based on geometric prior, (e) is the Frangi response map after mask correction, and (f) is the final binarized segmentation map. Figure 4 This is a schematic diagram comparing the final crack identification result of an embodiment of the present invention with the artificial true value; Wherein: (a) is the final morphologically optimized crack extraction image, and (b) is the original image identification reference. Detailed Implementation
[0014] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0015] In this embodiment, a borehole imaging unfolded image with typical complex background interference is selected as the input data, such as... Figure 2 The image on the left is characterized by the presence of real rock fissures, significant mud-covered areas, and horizontal and vertical stitching lines generated during the image acquisition and stitching process. These disturbances, morphologically similar to fissures, pose a significant challenge to the robustness of the algorithm.
[0016] This embodiment uses, as follows: Figure 1 The technical process shown below includes the following specific steps: S1: Image grayscale preprocessing The original color borehole unfolded image is converted into a single-channel grayscale image. To preserve the original fracture features while avoiding the introduction of background noise due to over-enhancement, this embodiment uses a weighted average method for grayscale processing. The calculation formula is as follows: This step effectively reduces the dimensionality of the data, providing standard input for subsequent morphological analysis, such as... Figure 2 As shown in the diagram on the right.
[0017] S2: Multi-scale Frangi feature enhancement. The preprocessed image is subjected to multi-scale Frangi filtering based on the Hessian matrix.
[0018] 1. Parameter settings: Set the dimensional parameters according to the common width range of borehole fractures. The step size is 1 pixel.
[0019] 2. Matrix Calculation: Calculate the Hessian matrix for each pixel in the image and solve for its eigenvalues. .
[0020] 3. Response Construction: Utilizing the characteristic of fissures to present tubular dark structures ( ), construct a multi-scale response function. For example Figure 3 As shown in (a), the cracked area exhibits a bright response after filtering. It is worth noting that, due to geometric similarity, the mud edges and splicing lines in the image also show a strong tubular structure response at this time, which will be removed in subsequent steps.
[0021] S3: Initial Segmentation and Noise Reduction 1. Adaptive global thresholding segmentation of the Frangi response map is performed using Otsu's method (maximum inter-class variance method) to obtain an initial binary image (e.g., Figure 3 (b) is shown.
[0022] 2. Subsequently, a first morphological post-processing step is performed, using area filtering to remove areas smaller than a threshold. Tiny isolated noise points (e.g., 50 pixels) result in... Figure 3 As shown in (c).
[0023] S4: Mask correction based on geometric priors.
[0024] For the non-crack high-response regions remaining in the results of step S3 (mainly mud edges and splicing lines), the mask correction mechanism proposed in this invention is applied: S4-1, Geometric Feature Extraction: Recognition Figure 3 For all connected components in (c), calculate the elongation and principal axis direction angle of each connected component; S4-2, Artifact Mask Generation: Introducing prior geological and engineering knowledge. Since image stitching lines and mechanical drilling marks typically appear as highly linear horizontal (0°) or vertical (90°) lines, an angle threshold (e.g., ...) is set. or ( ) and a high linearity threshold are used as discrimination conditions; connected components that meet the above conditions are marked as "error masks" (e.g. Figure 3 As shown in (d), the non-geological disturbances in the figure were accurately located.
[0025] S4-3, Response Map Correction: Perform a logical difference operation between the initial Frangi response map and the error mask to remove artifact regions, obtaining the corrected response map (e.g., ...). Figure 3 (e) is shown.
[0026] S4-4, Secondary Fine Segmentation: The corrected response map is binarized again (e.g., ...). Figure 3 (as shown in (f)), and then perform a second morphological operation. Closing operations are used to connect the fractured crack segments, and opening operations are used to smooth the edge contours. The final crack identification result is shown in (f). Figure 4 As shown in (a).
[0027] and Figure 4 As can be seen from the comparison of the original image ground truth in (b), the method of the present invention successfully eliminates the mud and splicing line interference that are difficult to handle by general algorithms without the need for a large number of sample training, accurately extracts the topological structure of the crack, and achieves high-precision recognition at the pixel level.
[0028] Finally, it should be noted that the above descriptions are merely preferred embodiments of the present invention and are not intended to limit the present invention. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art can still modify the technical solutions described in the foregoing embodiments or make equivalent substitutions for some of the technical features. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the protection scope of the present invention.
Claims
1. An automatic borehole fracture identification method based on multi-scale filtering and geometric prior, characterized in that: S1. Perform grayscale preprocessing on the original color borehole unfolded image to convert it into a single-channel grayscale image; S2. Establish a multi-scale Frangi feature enhancement model based on the Hessian matrix, extract the tubular structure features of the cracks in the image, and obtain the maximum Frangi response map. S3. The maximum Frangi response map is initially segmented using an adaptive threshold algorithm to obtain an initial binary image, and small noise regions are removed by area filtering. S4. Based on the geological morphology of fractures and the characteristics of drilling technology, identify artifact regions in the initial binary image and construct an error mask; The maximum Frangi response map is corrected using the error mask to obtain a corrected response map; the corrected response map is then subjected to secondary segmentation and morphological optimization to output the final crack identification result.
2. The automatic borehole fracture identification method based on multi-scale filtering and geometric prior as described in claim 1, characterized in that, In step S1, a weighted average method is used to perform grayscale conversion according to the ITU-R BT.601 standard. The calculation formula is as follows: ; in, Grayscale value , , These are the red, green, and blue channel components of the original color image, respectively.
3. The automatic borehole fracture identification method based on multi-scale filtering and geometric prior as described in claim 1, characterized in that, Step S2 specifically includes: Calculate the Hessian matrix for each pixel in the image. : ; Solving for eigenvalues of a matrix and And satisfy ; Constructing the Frangi response function : ; in, For spot measurement factor, For structural strength factor, and These are the threshold parameters that control spot sensitivity and structural contrast, respectively. A multi-scale discrete sampling ensemble strategy is adopted to calculate the response under a set discrete scale sequence, and the maximum value of the response at each scale is taken as the maximum Frangi response map.
4. The automatic borehole fracture identification method based on multi-scale filtering and geometric prior as described in claim 3, characterized in that, The specific steps of the multi-scale discrete sampling ensemble strategy are as follows: Set scale range and sampling step size Construct discrete-scale sequences ; At each discrete scale The response value is calculated, and the maximum value is taken as the final feature enhancement map. : .
5. The automatic borehole fracture identification method based on multi-scale filtering and geometric prior as described in claim 1, characterized in that, Step S3 specifically includes: Calculate the inter-class variance of foreground and background using the Otsu algorithm. : ; in, and These represent the threshold values respectively. The probability of pixels being classified as background and foreground. and These represent the average grayscale values of the background and foreground pixels, respectively. Select to make Maximize As the optimal threshold The Frangi response graph is binarized; the area of each connected component in the initial binary image is calculated through connected component analysis. Remove The area, in which This is a preset area threshold.
6. The automatic borehole fracture identification method based on multi-scale filtering and geometric prior as described in claim 1, characterized in that, In step S4, the specific steps for constructing the error mask are as follows: identifying all connected components in the initial binary image, calculating the elongation and principal axis direction angle of each connected component; and constructing a correction function. Connected components with principal axis orientation angles close to 0° or 90° and high linearity are marked as artifact regions, and corresponding error masks are generated. .
7. The automatic borehole fracture identification method based on multi-scale filtering and geometric prior as described in claim 1, characterized in that, In step S4, the correction of the maximum Frangi response map using the error mask is achieved by the following formula: .
8. The automatic borehole fracture identification method based on multi-scale filtering and geometric prior as described in claim 1, characterized in that, In step S4, the morphological optimization includes performing closing and opening operations on the secondary segmentation results sequentially.