An automatic identification method for concealed karst voids based on borehole downhole television camera
By combining borehole downhole television cameras with image processing and PCA analysis, the problem of low accuracy in identifying concealed karst voids has been solved, achieving higher accuracy in karst void identification and data support, which is suitable for geological and engineering applications.
Patent Information
- Application Number
- CN202411108345.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-13
- Publication Date
- 2025-11-25
- Estimated Expiration
- 2044-08-13
AI Technical Summary
Existing technologies have low accuracy in identifying hidden karst voids, making it difficult to meet the needs of groundwater pollution prevention and control and infrastructure construction.
A method based on borehole downhole television cameras was adopted. Through image preprocessing, clustering, edge detection, skeleton extraction and vectorization, combined with PCA principal component analysis, the geometric parameters and spatial distribution of concealed karst voids were identified and calculated.
It improves the accuracy of identifying concealed karst voids, provides more accurate geological analysis data, reduces errors, and supports further spatial analysis and engineering applications.
Smart Images

Figure CN119021675B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The application belongs to the technical field of karst geological exploration, and particularly relates to a method for automatically identifying covered karst voids based on downhole television imaging of boreholes. BACKGROUND
[0002] Covered karst is a special karst geological phenomenon, which refers to karst landforms and structures formed by soluble rocks (such as limestone, dolomite, etc.) buried under the ground and covered by non-soluble rocks or sediments. Due to the existence of the cover layer on the top, this type of karst usually does not form typical karst landforms such as caves, stone forests, and sinkholes on the ground surface, making it difficult to directly observe and identify. The accurate identification of the development rules of covered karst voids (caves, fractures, pipes, and cavities, etc.) and regional karst development characteristics is extremely important for regional groundwater pollution prevention and control, as well as the identification and tracking of groundwater pollution pathways. At the same time, it also poses potential risks to human activities, especially infrastructure construction such as buildings, roads, and bridges, as they may cause ground subsidence, building stability, and other issues.
[0003] Currently, there are various methods for identifying covered karst voids, including Ground Penetrating Radar (GPR), high-density resistivity method, shallow seismic method, transient electromagnetic method, borehole image analysis method, inter-hole tomography, and ground nuclear magnetic resonance method. Among them, the borehole image analysis method uses downhole television to take pictures of the rock core inside the borehole, obtains rock layer images, and then analyzes the rock core images to identify rock types, structural planes, and fractures, etc., to assist in geological analysis and interpretation. The specific operation is as follows: first, the rock layer images are preprocessed (grayscale, noise reduction preprocessing), then the structural plane is located using the structural plane positioning signal eigenvalue, and the image of the region where the structural plane is located is obtained; edge detection, threshold segmentation, and morphological processing are then performed, and the structural plane features (occurrence, gap width, and other geometric parameters) are intelligently identified by fitting the edge curve and combining mathematical representation methods. However, the structural plane in the rock layer image is not always a sinusoidal curve, or a large part of the digital borehole image is a broken, discontinuous, and uneven structural plane, i.e., the randomness of the void, which leads to an unclear fitting effect and ultimately low recognition accuracy. SUMMARY
[0004] The present application aims to provide a method for automatically identifying covered karst voids based on downhole television imaging of boreholes to improve the recognition accuracy of covered karst voids.
[0005] The method for automatically identifying covered karst voids based on downhole television imaging of boreholes in the present application includes the following steps:
[0006] Step one, pre-processing of rock stratum image
[0007] (1) Read the rock stratum image and display it as a grayscale image;
[0008] (2) Convert the rock stratum image to a binary image according to the threshold value. During binary conversion, non-white pixels in the image are changed to white, and white pixels are changed to black;
[0009] (3) Remove small noise points in the rock stratum image through morphological opening operation;
[0010] Step two, image stitching
[0011] (4) Use the DBSCAN algorithm to cluster the pixels in the rock stratum image after removing small noise points;
[0012] (5) Use a mask to extract the image area corresponding to each cluster in the rock stratum image;
[0013] (6) Stitch multiple image areas into a complete image;
[0014] Step three, edge detection processing of the image
[0015] (7) Convert the stitched image to an array form and perform normalization processing;
[0016] (8) Use the BDCN model to perform edge detection on the normalized image to obtain an edge probability map;
[0017] Step four, pre-processing of the edge probability map
[0018] (9) Read the edge probability map and add a border, then perform binaryzation processing. During binaryzation processing, set the part of the image with a pixel value less than 110 to 1 and the part with a pixel value greater than 110 to 0 to form a binary image;
[0019] (10) Use the copy.deepcopy function to perform deep copy of the binary image;
[0020] (11) Set the part of the deep-copied binary image cmg with a pixel value of 1 to 255 to form a black and white image;
[0021] (12) Use the cv2.imwrite function to save the black and white image;
[0022] Step five, skeleton extraction
[0023] (13) Copy the saved black and white image and use the skeletonize function in the skimage library to extract the skeleton of the binary image;
[0024] (14) Convert the skeleton to a distance matrix and save it as a TIFF format file, i.e. a skeleton raster image.
[0025] Further, the skeleton raster image is converted to a vector polyline map using the RasterToPolyline_conversion function in the ArcPy module. The skeleton lines in the raster image are converted to vector polylines using ArcPy. The shange_to_zhexian.shp file is the result of vectorizing the crack skeleton extracted from the raster image, stored as a vector polyline data. This step converts the image data to vector data that can be processed by geographic information systems (GIS). This format is suitable for spatial analysis, overlay analysis, and visualization in GIS, facilitating further spatial analysis and processing, and providing basic data support for further geological research and engineering applications. The generated shange_to_zhexian.shp is a vector data file that stores the crack skeleton information extracted from the raster image (i.e. julei_gujia.tif). These skeleton information is represented as a polyline in vector format, which is convenient for further spatial analysis and processing in geographic information systems (GIS).
[0026] Further, in step one, the rock layer image is read using OpenCV to read and display the image.
[0027] Further, in step one, the rock layer image is converted to a binary image. During binary conversion, the threshold value is 255.
[0028] Further, in step one, the cv2.morphologyEx function of OpenCV is used for morphological opening operation.
[0029] Further, in step two, the np.where function of NumPy is used to extract the coordinates of non-zero pixels in the image, and DBSCAN algorithm is used for clustering analysis of these pixels.
[0030] Further, in step four, the cv2.imread function is used to read the image file from the file system.
[0031] Further, in step five, the copy.deepcopy function is used to deep copy the saved black and white image.
[0032] Further, the calculation process of the concealed karst void is as follows:
[0033] (1) Select any identified structural plane, and extract the two-dimensional plane coordinates of all points of the selected polyline;
[0034] (2) Calculate the radius: First, output the starting coordinates (X0, Y0) and ending coordinates (X...) of the selected crack curve. e ,Y e ), calculate the difference A between the x-coordinates of the starting and ending points of the curve. i As the circumference, the radius r can be calculated by using the formula for the circumference of a circle. i ;
[0035] ,
[0036] ;
[0037] (3) Calculate the central angle: Output the coordinates of each point on the crack curve. Their x-coordinates Subtract the x-coordinate of the starting point That is, the arc length The central angle corresponding to each point can be calculated by using the arc length formula. ;
[0038] ;
[0039] (4) Calculate the three-dimensional planar coordinates of all points on the selected polyline in the three-dimensional coordinate system:
[0040] ,
[0041] ,
[0042] ;
[0043] Therefore, the coordinates of each point on the crack curve in the three-dimensional coordinate system are obtained. Coordinates It can be restored to a curved surface;
[0044] (5) Perform PCA principal component analysis to obtain three eigenvalues and their corresponding eigenvectors, and select the smallest one. The steps are as follows:
[0045] Data centralization: subtracting the mean of each dimension;
[0046] Step 1: Standardize the data
[0047] Each point in the above crack curve in the three-dimensional coordinate system Coordinates, store them as a matrix type, and construct Data matrix ,in It is the number of samples. It is the number of features. First, the data is centered, that is, each feature is subtracted from its mean, so that the mean of each feature is 0.
[0048] ;
[0049] where, is the mean vector of each feature:
[0050] ;
[0051] Covariance matrix: compute the covariance matrix H of the data
[0052] Step 2: Compute the covariance matrix
[0053] The centered data matrix is , compute its covariance matrix:
[0054] ;
[0055] Eigen decomposition: solve the eigenvalues and eigenvectors of the covariance matrix by singular value decomposition;
[0056] Step 3: Eigenvalue decomposition
[0057] Eigenvalue decomposition of the covariance matrix , get the eigenvalues and eigenvectors:
[0058] ;
[0059] where, is the eigenvalue, is the corresponding eigenvector, the eigenvalues are sorted in descending order, and the data direction corresponding to the largest eigenvalue is the direction with the largest data change;
[0060] Sorting: sort the eigenvalues and corresponding eigenvectors in descending order;
[0061] Step 4: Select principal components
[0062] Select the eigenvectors corresponding to the first largest eigenvalues as principal components, and project the data onto these eigenvectors:
[0063] ;
[0064] where, is the matrix composed of the first eigenvectors, is the representation of the data in the new coordinate system;
[0065] (6) Calculate the inclination:
[0066] If and , the inclination is 0 degrees; otherwise, calculate the sine and cosine values as follows:
[0067] ,
[0068] ;
[0069] Based on the signs of the sine and cosine values, the tendency is... The calculation is as follows:
[0070] if and ,but
[0071] ;
[0072] In the first quadrant, and All are positive. The result directly represents the angle;
[0073] if and ,but
[0074] ;
[0075] In the second quadrant, For positive, If it is negative, it needs to be used minus The result is used to obtain the correct angle;
[0076] if and ,but
[0077] ;
[0078] In the third quadrant, and Both are negative, so they also need to be used. minus The result;
[0079] if and ,but
[0080] ;
[0081] In the fourth quadrant, Negative, To be positive, it needs to be Add to the result To obtain the correct angle;
[0082] (7) Calculate the inclination angle:
[0083] ;
[0084] wherein, 、 and represent the first three components of the feature vector respectively, is a very small value (for example 0.000001) to avoid the case of division by zero;
[0085] (8) Line and surface karst rates:
[0086] Line karst rate: the percentage of the length of karst space form in the length of the drilling hole; that is, "line karst rate = length of karst cave and karst fissure encountered by drilling hole / length of drilling hole passing through soluble rock x 100%"
[0087] ;
[0088] wherein, is the fracture depth range pixel value, which refers to the maximum Y coordinate minus the minimum Y coordinate (since they are all non-positive numbers) of the pixel occupied by a fracture, is the vertical pixel value of the drilling hole image, which refers to the total number of pixels in the vertical direction of the entire drilling hole image;
[0089] Surface karst rate: the percentage of the area of karst space form in the unit area;
[0090] ;
[0091] wherein, is the area of each karst surface, is the cross-sectional area of the cylinder "enclosed" by the drilling hole image;
[0092] Line karst rate of any hole section interval:
[0093] The sum of all karst heights of the interval hole section / the height of the interval hole section = the line karst rate of the interval hole section.
[0094] The application also provides a downhole television which integrates the automatic identification method of concealed karst gap based on drilling downhole television camera shooting. The automatic identification method of concealed karst gap based on drilling downhole television camera shooting is integrated into the downhole television, so that the downhole television can analyze while shooting the drilling hole. BRIEF DESCRIPTION OF DRAWINGS
[0095] Figure 1 is a flowchart of the automatic identification method of concealed karst gap based on drilling downhole television camera shooting of the application;
[0096] Figure 2 is a three-dimensional space graph of concealed karst gap;
[0097] Figure 3Thermal map for hidden karst void. DETAILED DESCRIPTION
[0098] Further details are described below through a specific embodiment:
[0099] A hidden karst void automatic identification method based on borehole downhole television camera shooting, comprising the following steps:
[0100] Step one, rock stratum image preprocessing
[0101] 1. Image reading and display:
[0102] Technology: Use OpenCV to read and display images. The image is an image XX.jpg taken by a downhole television camera after drilling a borehole for hidden karst.
[0103] Read image: Use the cv2.imread function of OpenCV to read the input image.
[0104] Display image: Use the cv2.imshow function of OpenCV to display the image, and control the display time through cv2.waitKey.
[0105] 2. Binary transformation:
[0106] Change non-white pixels (values less than 255) in the image to white (255), and change white pixels to black (0).
[0107] Principle: Convert the grayscale image to a binary image according to the threshold value, which is used for subsequent morphological operations and clustering analysis.
[0108] 3. Morphological opening operation:
[0109] Use the cv2.morphologyEx function of OpenCV to perform morphological opening operation to remove noise in the image. The convolution kernel used here is a 30x30 all-1 matrix.
[0110] Step two, image stitching
[0111] 1. Clustering analysis:
[0112] Extract non-zero pixels: Use the np.where function of NumPy to extract the coordinates of non-zero pixels in the image.
[0113] DBSCAN clustering: Use the DBSCAN algorithm to perform clustering analysis on these pixels.
[0114] 2. Mask extraction image:
[0115] Label assignment: Assign the clustering result labels to the corresponding pixel positions to generate a clustering result image.
[0116] Extraction region: Extract the image region corresponding to each cluster based on the labels in the clustering result image.
[0117] 3. Image stitching:
[0118] Create a blank image: Create a blank image based on the size of the extracted region.
[0119] Stitch the image: Stitch the extracted image region onto the blank image.
[0120] Display and save the image: Display the stitched image and save it to a file, generating XX_tiqu.jpg.
[0121] Step three, edge detection processing of the image
[0122] The edge detection task based on Bi-Directional Cascade Network (BDCN) is implemented, and the process is introduced in detail as follows:
[0123] 1. Loading and configuring the BDCN model:
[0124] Model loading: Load the pre-trained BDCN model using PyTorch.
[0125] Model parameters: Load the model parameters from the specified path and apply them to the BDCN model.
[0126] 2. Data loading and preprocessing
[0127] Custom dataset: Create a class that inherits from torch.utils.data.Dataset to load and preprocess the dataset.
[0128] Data transformation: Convert the image from RGB to BGR, normalize it by subtracting the mean, perform scale transformation and cropping, etc.
[0129] Data loader: Use torch.utils.data.DataLoader to create a data loader for batch processing and iteration.
[0130] 3. Model inference and result saving
[0131] Model inference: Pass the data into the model to get the output result. Use torch.sigmoid to convert the output result to a probability map.
[0132] Result Saving: Save the processed edge detection result as an image file using OpenCV, i.e., generate XX_result.tif. Specifically, this XX_result.tif file contains the results of edge detection, where each pixel value represents the probability that the pixel belongs to the edge.
[0133] Step Four: Preprocessing of Edge Probability Map
[0134] Some basic image processing and computer vision techniques are used, and the process is detailed as follows:
[0135] 1. Read Image
[0136] Tool: OpenCV
[0137] Use the cv2.imread function to read the image file from the file system, and the cv2.IMREAD_UNCHANGED parameter ensures that the image is read in the original format without any color conversion.
[0138] 2. Add Border
[0139] Tool: OpenCV
[0140] Add a border to the four edges of the image by directly manipulating the image array. Specifically, set the specified value a at the four edge positions of the image array.
[0141] 3. Image Binarization Processing
[0142] Tool: Numpy
[0143] Set the part of the image with pixel value less than 110 to 1 and the part with pixel value greater than 110 to 0 to form a binary image. Binarization processing helps simplify image processing tasks such as edge detection, shape analysis, etc.
[0144] 4. Deep Copy Image
[0145] Tool: Python built-in copy module
[0146] Use the copy.deepcopy function to make a deep copy of the image array to ensure that modifying cmg will not affect the original image ymg.
[0147] 5. Modify Copied Image
[0148] Tool: Numpy
[0149] Set the part of the binary image cmg with pixel value 1 to 255 to form a black and white image. The processed image is more suitable for display and further analysis.
[0150] 6. Save the processed image
[0151] Use the cv2.imwrite function to save the processed image to the specified path, generating threshold_extraction.tif.
[0152] Step five, skeleton extraction
[0153] 1. Copy the image
[0154] Use the cv2.imread function of OpenCV to read the threshold_extraction.tif image file, add a border to the image through the custom function add_border, then perform binaryzation processing, set the pixel value below 110 to 1 and above 110 to 0, finally convert to 8-bit unsigned integer type and save the processed image, that is, take the binary image; then use the copy.deepcopy function to deep copy the cmg image to ensure that subsequent operations do not affect the original image data.
[0155] 2. Get the crack skeleton
[0156] Use the skeletonize function in the skimage library to extract the skeleton of the binary image. Skeleton extraction is to simplify the object to one-dimensional lines and preserve its basic shape structure. The purpose is to simplify the line with multiple pixels in the image to a single-pixel line to represent the main structure of the crack.
[0157] 3. Convert the skeleton to a distance matrix
[0158] Use the np.where function to find the position of the skeleton pixels and convert the result to a two-dimensional array to represent the coordinates of each skeleton point.
[0159] 4. Save the crack skeleton picture
[0160] Use the cv2.imwrite function to save the skeleton image as a TIFF format file, generating julei_gujia.tif. The generated julei_gujia.tif is the crack skeleton image extracted from the cmg image. Specifically, this file contains the refined structure (skeleton) extracted from the original binary image XX_result.tif, where white pixels represent the skeleton structure of the crack and black pixels represent the background.
[0161] The skeleton image can be used for further crack analysis, feature extraction, shape analysis, etc. For example, the length, direction, distribution, etc. of the cracks can be calculated. In summary, the generated julei_gujia.tif file is a skeleton image that simplifies the representation of the crack structure in the image, providing simplified and meaningful image information for subsequent analysis and processing.
[0162] Six, grid turning line
[0163] The process of generating a vector polyline from the crack skeleton image is implemented.
[0164] The RasterToPolyline_conversion function in the ArcPy module is used to convert the skeleton raster image into a vector polyline image, i.e. generate shange_to_zhexian.shp.
[0165] Parameter interpretation:
[0166] “ZERO” means converting pixels with a value of 0 to the background and non-0 pixels to the polyline. 50 represents the tolerance value set to simplify the generated polyline. “SIMPLIFY” means that simplification processing is performed during the conversion process to remove unnecessary details.
[0167] The raster-to-vector conversion uses ArcPy to convert the skeleton lines in the raster image into a vector polyline. The shange_to_zhexian.shp file is the result of vectorizing the crack skeleton extracted from the raster image, stored as a vector polyline data. This step converts the image data into vector data that can be processed by a geographic information system (GIS), which is suitable for various applications such as spatial analysis, overlay analysis, and visualization in GIS, facilitating further spatial analysis and processing, and providing basic data support for further geological research and engineering applications.
[0168] The generated shange_to_zhexian.shp is a vector data file that stores the crack skeleton information extracted from the raster image (i.e. julei_gujia.tif). These skeleton information is represented as a polyline in vector format, which is convenient for further spatial analysis and processing in a geographic information system (GIS).
[0169] Hidden karst void void calculation
[0170] (1) Select any identified structural plane (already vectorized as a polyline), and extract the two-dimensional plane coordinates of all points of the selected polyline (referring to the two-dimensional plane coordinates of the digital borehole image after a series of processing and splicing into a complete borehole image).
[0171] (2) Calculate the radius: first output the start point coordinates of the selected crack curve and the end point coordinates , as shown in the complete borehole image, the complete borehole image is "surrounded" in the vertical direction, which is a complete "cylinder" without top and bottom, so the projection of one crack in the complete borehole image onto the top and bottom surface is a "circle", therefore the difference between the start point horizontal coordinate and the end point horizontal coordinate of the curve is calculated as the circumference of the circle (the projection of the crack on the rock column to the horizontal coordinate system is a circle) ;
[0172] ,
[0173] ;
[0174] (3) Calculate the central angle: output the coordinates of each point on the crack curve , their horizontal coordinates minus the start point horizontal coordinate is the arc length , and the central angle corresponding to each point is calculated by the arc length formula .
[0175]
[0176] (4) Calculate the three-dimensional coordinates of all points of the selected polyline in the three-dimensional coordinate system:
[0177] ,
[0178] ,
[0179] ;
[0180] Therefore, the coordinates of each point on the crack curve in the three-dimensional coordinate system are obtained, that is , which can be restored to a curved surface.
[0181] (5) Perform PCA principal component analysis to obtain three eigenvalues and their corresponding eigenvectors, and select the smallest one.
[0182] PCA (Principal Component Analysis) is used to map high-dimensional data to low-dimensional space while preserving as much of the original data variability as possible. The steps are as follows:
[0183] Data centralization: subtract the mean value of each dimension.
[0184] Step 1: Standardize the data
[0185] Suppose we have Data matrix (That is, each point in the above crack curve in the three-dimensional coordinate system) Coordinates (stored as a matrix type), where It is the number of samples. It refers to the number of features. We first center the data, that is, we subtract the mean from each feature so that the mean of each feature is 0.
[0186] ;
[0187] in, It is the mean vector of each feature:
[0188] ;
[0189] Covariance matrix: Calculate the covariance matrix H of the data.
[0190] Step 2: Calculate the covariance matrix
[0191] The centralized data matrix is We calculate its covariance matrix:
[0192] ;
[0193] Eigenvalue decomposition: Solving for the eigenvalues and eigenvectors of the covariance matrix using singular value decomposition (SVD).
[0194] Step 3: Eigenvalue decomposition
[0195] For covariance matrix Eigenvalue decomposition yields eigenvalues and eigenvectors:
[0196] ;
[0197] in, It is an eigenvalue. These are the corresponding eigenvectors. The eigenvalues are arranged in descending order, and the direction of data change corresponding to the largest eigenvalue is the direction of the greatest data variation.
[0198] Sorting: Arrange the eigenvalues and their corresponding eigenvectors in descending order.
[0199] Step 4: Select principal components
[0200] Before choosing The eigenvectors corresponding to the largest eigenvalues are used as principal components, and the data is projected onto these eigenvectors:
[0201] ;
[0202] in, It is from the front A matrix composed of eigenvectors It is the representation of data in the new coordinate system.
[0203] Typically, the dip and tilt angle of a surface can be determined using the smallest eigenvalue and its corresponding eigenvector. This is because the eigenvector corresponding to the smallest eigenvalue indicates the direction of the slowest change in the surface, and the dip and tilt angle precisely describe the slope and direction of the surface.
[0204] (6) Calculation tendency:
[0205] if and If the sine and cosine values are positive, the tendency is 0 degrees. Otherwise, calculate the sine and cosine values as follows:
[0206] ;
[0207] ;
[0208] Based on the signs of the sine and cosine values, the tendency is... The calculation is as follows:
[0209] if and ,but
[0210] ;
[0211] In the first quadrant, and All are positive. The result directly represents the angle.
[0212] if and ,but
[0213] ;
[0214] In the second quadrant, For positive, If it is negative, it needs to be used minus The result is used to obtain the correct angle.
[0215] if and ,but
[0216] ;
[0217] In the third quadrant, and Both are negative, so they also need to be used. Subtract the result.
[0218] If and , then
[0219] ;
[0220] In the fourth quadrant, is negative, is positive, and the result to get the correct angle.
[0221] (7) Calculate the inclination angle:
[0222] ;
[0223] where, , and represent the first three components of the eigenvector, is a very small value (e.g. 0.000001) to avoid division by zero.
[0224] (8) Line and surface karst rate:
[0225] Line karst rate: the percentage of the length of karst space form per unit length exposed by drilling. That is, "Line karst rate = the length of the karst cave and fissure encountered by the drilling / the length of the drilling through soluble rock × 100%"
[0226] ;
[0227] where, is the fracture depth range pixel value, which refers to the maximum Y coordinate minus the minimum Y coordinate of the pixel occupied by a certain fracture (since they are all non-positive numbers), is the vertical pixel value of the drilling image, which refers to the total number of vertical pixels in the entire drilling image.
[0228] Surface karst rate: the percentage of the area of karst space form per unit area.
[0229] ;
[0230] where, is the area of each karst surface, is the cross-sectional area of the cylinder "enclosed" by the drilling image.
[0231] Arbitrary hole section interval line karst rate:
[0232] The interval hole section (in the vertical direction) can be selected, such as 0-10 meters, 40-50 meters, and the total height of all karst in the 10-meter hole section (or 20.4-31.6 meters, in general, the interval hole section can be selected at will) / the height of the interval hole section = the interval hole section line karst rate.
[0233] The calculation idea is: read the depth interval of each karst, that is, ymin and ymax, because ymin and ymax are arranged according to the pixel size and are negative numbers, so first take the absolute value of ymin and ymax to become positive numbers, and then multiply by a pixel actual distance, that is, pixel_distance = a, to obtain the actual depth interval of each karst underground. For example, the interval of a certain karst is 9.3m-10.6m, and another karst is 19.7m-20.5m, and so on. In this way, the depth interval of all karsts is obtained.
[0234] For example, 10m-20m is selected, and then the depth of all karsts in this interval hole section is found, such as 9.3m-10.6m before can only be 10.0m-10.6m, and 19.7m-20.5m can only be 19.7m-20.0m, and then there are only two karsts in this interval hole section, so (20.0-19.7=0.3m, 10.6-10.0=0.6m) is recorded, and then 0.3m+0.6m=0.9m is recorded as the total height of all karsts in the selected 10m-20m interval hole section, and the interval hole section height is obtained by subtracting the input range and taking the positive, and then the karst height total / interval hole section height = interval hole section line karst rate.
[0235] (9) Three-dimensional plane display:
[0236] The three-dimensional plane coordinates of all points of the selected polyline in the three-dimensional coordinate system obtained in (4) are imported, a visualization window, coordinate axes and labels are created, a curved surface is drawn and all points are marked, and finally the visualization window is displayed, as shown in the accompanying Figure 2 .
[0237] In addition, the extracted three-dimensional space feature data can be further used to draw a heat map, as shown in the accompanying Figure 3 .
[0238] The above only describes the embodiments of the present application, and the specific structure and characteristics of the scheme are not described in detail. It should be noted that for those skilled in the art, without departing from the structure of the present application, a number of modifications and improvements can be made, which should also be considered as the protection scope of the present application, which will not affect the effect and practicality of the patent. The protection scope claimed in this application should be subject to the content of its claims, and the specific implementation mode and the like recorded in the specification can be used to explain the content of the claims.
Claims
1. A method for automatically identifying concealed karst voids based on borehole downhole television camera, characterized in that: Includes the following steps: Step 1: Preprocessing of rock strata images (1) Read the rock strata image and display it as a grayscale image; (2) Convert the rock layer image into a binary image according to the threshold. During the binary transformation, non-white pixels in the image are changed to white, and white pixels are changed to black. (3) Remove small noise points in rock strata images by morphological opening operations; Step 2: Image stitching (4) Use the DBSCAN algorithm to cluster the pixels in the rock layer image after removing small noise points; (5) Use a mask to extract the image region corresponding to each cluster in the rock layer image; (6) Stitch together multiple image regions into a complete image; Step 3: Edge detection processing of the image (7) Convert the stitched image into an array and normalize it; (8) Use the BDCN model to perform edge detection on the normalized image to obtain the edge probability map; Step 4: Preprocessing of the marginal probability map (9) Read the edge probability map and add a border, and then perform binarization. During binarization, set the part of the image with a pixel value less than 110 to 1 and the part with a pixel value greater than 110 to 0 to form a binary image. (10) Use the copy.deepcopy function to perform a deep copy of the binary image; (11) Set the pixel value of 1 in the binary image cmg after deep copying to 255 to form a black and white image; (12) Use the cv2.imwrite function to save the black and white image; Step 5: Skeleton Extraction (13) Copy the saved black and white image and use the skeletonize function in the skimage library to extract the skeleton of the binary image; (14) Convert the skeleton into a distance matrix and save it as a TIFF file, i.e., a skeleton raster image; The calculation process for concealed karst voids is as follows: (1) Select any identified structural surface and extract the two-dimensional plane coordinates of all points of the selected polyline; (2) Calculate the radius: first output the selected crack curve starting point coordinates (X0, Y0) and end point coordinates (X e ,Y e ), calculate the difference A i of the starting point and end point horizontal coordinates as the circumference, and calculate the radius r i from the circumference formula of the circle; , ; (3) Calculate the central angle: the x-coordinate of each point on the output crack curve is subtracted from the x-coordinate of the starting point, i.e. the arc length, and the corresponding central angle of each point is calculated from the arc length formula. ; ; (4) Calculate the three-dimensional planar coordinates of all points on the selected polyline in the three-dimensional coordinate system: , , ; Therefore, the coordinates of each point on the crack curve in the three-dimensional coordinate system are obtained. Coordinates It can be restored to a curved surface; (5) Perform PCA principal component analysis to obtain three eigenvalues and their corresponding eigenvectors, and select the smallest one. The steps are as follows: Data centralization: subtracting the mean of each dimension; Step 1: Standardize the data Each point in the above crack curve in the three-dimensional coordinate system Coordinates, store them as a matrix type, and construct Data matrix ,in It is the number of samples. It is the number of features. First, the data is centered, that is, each feature is subtracted from its mean, so that the mean of each feature is 0. ; wherein, is the mean vector of each feature: ; Covariance matrix: Calculate the covariance matrix H of the data. Step 2: Calculate the covariance matrix The centralized data matrix is , and its covariance matrix is calculated: ; Eigenvalue decomposition: Solving for the eigenvalues and eigenvectors of the covariance matrix through singular value decomposition; Step 3: Eigenvalue decomposition For covariance matrix Eigenvalue decomposition yields eigenvalues and eigenvectors: ; in, It is an eigenvalue. These are the corresponding feature vectors, with the feature values arranged in descending order. The direction of the data corresponding to the largest feature value is the direction of the greatest data change. Sorting: Arrange the eigenvalues and their corresponding eigenvectors in descending order; Step 4: Select principal components Before choosing The eigenvectors corresponding to the largest eigenvalues are used as principal components, and the data is projected onto these eigenvectors: ; in, It is from the front A matrix composed of eigenvectors It is the representation of data in the new coordinate system; (6) Calculation tendency: if and If the sine and cosine values are positive, the tendency is 0 degrees; otherwise, the sine and cosine values are calculated as follows: , ; Based on the signs of the sine and cosine values, the tendency is... The calculation is as follows: if and ,but ; In the first quadrant, and All are positive. The result directly represents the angle; if and ,but ; In the second quadrant, For positive, If it is negative, it needs to be used minus The result is used to obtain the correct angle; if and ,but ; In the third quadrant, and Both are negative, so they also need to be used. minus The result; if and ,but ; In the fourth quadrant, Negative, To be positive, it needs to be Add to the result To obtain the correct angle; (7) Calculate the inclination angle: ; in, , and These represent the first three components of the eigenvector, 0 < ≤0.000001; (8) Linear and surface karst ratio: Linear karst ratio: The percentage of karst spatial morphology per unit length revealed by the borehole; that is, "Linear karst ratio = Length of caves and fissures encountered by the borehole / Length of soluble rock traversed by the borehole × 100%" ; in, This refers to the pixel value representing the crack depth range, specifically the difference between the maximum and minimum Y-coordinates of the pixels occupied by a crack. Both the maximum and minimum Y-coordinates of the pixels occupied by the crack are non-positive numbers. It refers to the vertical pixel value of the borehole image, which is the total number of pixels in the vertical direction of the entire borehole image; Surface karst ratio: the percentage of karst spatial morphology area per unit area; ; in, It represents the area of each karst surface. It is the cross-sectional area of the cylinder "enclosed" by the borehole image; Karst ratio of any borehole section: The sum of all karst heights in the borehole section / the height of the borehole section = the karst ratio of the borehole section line.
2. The method for automatic identification of concealed karst voids based on downhole video cameras according to claim 1, characterized in that: Use the RasterToPolyline_conversion function in the ArcPy module to convert a skeleton raster image into a vector polyline graph.
3. The method for automatic identification of concealed karst voids based on downhole video cameras according to claim 2, characterized in that: In step one, when reading the rock strata image, OpenCV is used to read and display the image.
4. The method for automatic identification of concealed karst voids based on downhole video cameras according to claim 3, characterized in that: Step 1 converts the rock strata image into a binary image. The threshold for the binary transformation is 255.
5. The method for automatic identification of concealed karst voids based on downhole video cameras according to claim 4, characterized in that: In step one, the cv2.morphologyEx function of OpenCV is used to perform morphological opening operations.
6. The method for automatic identification of concealed karst voids based on downhole video cameras according to claim 5, characterized in that: In step two, the coordinates of non-zero pixels in the image are extracted using the np.where function of NumPy, and the DBSCAN algorithm is used to perform cluster analysis on these pixels.
7. The method for automatic identification of concealed karst voids based on downhole video cameras according to claim 6, characterized in that: In step four, the cv2.imread function is used to read the image file from the file system.
8. The method for automatic identification of concealed karst voids based on downhole video cameras according to claim 7, characterized in that: In step five, when copying the saved black and white image, the copy.deepcopy function is used to perform a deep copy of the black and white image.
9. A type of underground television, characterized in that: The method for automatic identification of concealed karst voids based on downhole television cameras according to any one of claims 1 to 8 shall be implemented.
Citation Information
Patent Citations
Apparatus for measuring crack using image processing technology and method thereof
KR101932214B1
Method for landslide crack detection based deep learning and Method for landslide monitoring therewith and Apparatus thereof
KR102550707B1