Crack identification method and device, electronic equipment, storage medium and program product

By generating cosine curves of formation fracture characteristics and improving the YOLOv5 network model, the problem of low efficiency of traditional fracture identification methods is solved, efficient and accurate fracture identification is achieved, and manpower and time costs are reduced.

CN116071647BActive Publication Date: 2025-10-10CHINA UNIV OF PETROLEUM (BEIJING)
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202310018665.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-01-05
Publication Date
2025-10-10
Estimated Expiration
2043-01-05

AI Technical Summary

Technical Problem

Traditional methods in crack identification are labor-intensive, inefficient, and have large errors. Manually picking up crack images consumes a lot of manpower and time.

Method used

A cosine curve is generated based on the cosine function of formation fracture characteristics. Sample expansion is performed through operations such as translation, adjustment of random noise and inclination. The residual structure of the yolov5 network model is improved. Combined with the DenseBlock and SE modules, the accuracy of the fracture identification model is improved.

Benefits of technology

It realizes intelligent extraction and precise identification of cracks, saves manpower and time costs, and improves detection accuracy and efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116071647B_ABST
    Figure CN116071647B_ABST
Patent Text Reader

Abstract

The application provides a crack identification method and device, electronic equipment, storage medium and program product, which can obtain a sample image containing a crack based on a cosine function conforming to a formation crack feature, and train a crack identification model, wherein the crack identification model is realized based on a yolov5 network model. The application can intelligently extract and accurately identify cracks, improve the accuracy, save a large amount of manpower cost and time cost, improve the detection accuracy by improving the residual structure of the yolov5 network model to greatly reduce the calculation amount of the model, and achieve the purpose of increasing the feature map receptive field without affecting the model calculation cost, and improve the detection accuracy. The Denseblock full interconnection idea is applied to the yolov5 network model, so that the model can fully extract, propagate and fuse features. The addition of the SE module in the backbone network can learn and combine different channel features to increase the global receptive field of the model, and improve the detection accuracy.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of petroleum exploration and development, and in particular to a fracture identification method, device, electronic equipment, storage medium and program product. Background Art

[0002] Fractured reservoirs have always been the focus and difficulty of exploration. During the oil production process, the identification of fractures and semi-fractures is very important.

[0003] In geological exploration, imaging logging images reflect more fracture information. The traditional method of manually picking fractures has disadvantages such as heavy workload, large errors, and low efficiency. Summary of the Invention

[0004] The present application provides a crack identification method, device, electronic device, storage medium and program product to improve the efficiency and accuracy of crack identification.

[0005] In a first aspect, an embodiment of the present application provides a crack identification method, comprising:

[0006] Based on a cosine function that conforms to formation fracture characteristics, a cosine curve for simulating fractures is generated, and a sample image containing fractures is obtained by performing at least one of the following operations on the cosine curve: translation, adjustment of added random noise, adjustment of inclination, and adjustment of size; wherein the sample image is labeled as a rectangular box within the sample image containing the cosine curve;

[0007] According to the generated sample images, a crack recognition model is trained to recognize cracks in the image to be processed based on the trained model;

[0008] The crack identification model is implemented based on the yolov5 network model.

[0009] Optionally, the crack recognition model is trained based on the generated sample images, including:

[0010] In the residual structure of the yolov5 network model, 1*1 convolution is used for dimensionality increase and dimensionality reduction operations, and the 3*3 convolution in the residual structure adopts the dilation rate 2 dilation technology;

[0011] Use DenseBlock to replace the Resunit module of the yolov5 network model;

[0012] Adding SE module to the backbone network for feature extraction, the improved yolov5 network model is obtained as the crack recognition model;

[0013] The crack recognition model is trained according to the generated sample images.

[0014] Optionally, based on a cosine function that conforms to formation fracture characteristics, a cosine curve for simulating fractures is generated, and a sample image containing fractures is obtained by performing at least one of the following operations on the cosine curve: translation, adjustment of added random noise, adjustment of inclination, and adjustment of size, including:

[0015] Simulate a cosine function based on the cracks: Generate a cosine curve, where θ is the crack inclination and n is random noise. Modify the generated cosine curve by adjusting the function parameters to obtain multiple images.

[0016] The cosine curve in the generated image is translated to obtain multiple images, and the multiple images after the translation operation are randomly shuffled with the multiple images before the translation operation;

[0017] The randomly shuffled images are subjected to data enhancement to obtain multiple sample images containing cracks.

[0018] Optionally, use 1*1 convolution for dimensionality increase and decrease in the residual structure of the Yolov5 network model, and use the dilation rate 2 dilation technique for the 3*3 convolution in the residual structure, including:

[0019] In the residual structure of the yolov5 network model, the convolution operation with a 1*1 convolution kernel is set on the input to achieve dimensionality reduction and obtain an N-channel feature map;

[0020] The feature map is input into a 3*3 convolution operation, which adds a dilation convolution technique with a dilation rate of 2 to obtain an N-channel feature map;

[0021] Add a convolution with a convolution kernel of 1*1 and perform a convolution operation on the N-channel feature map obtained by the 3*3 convolution to achieve dimensionality increase.

[0022] Optionally, use DenseBlock to replace the Resunit module of the yolov5 network model, including:

[0023] The Resunit module replaced by DenseBlock is the Resunit module in the C_1_3 module of the yolov5 network model;

[0024] Among them, each network layer in the DenseBlock structure contains three CBS modules. Each network layer in the DenseBlock structure uses the features extracted by all the layers before itself as the input of this layer, and the features obtained by itself as the input of the subsequent layers, forming a fully interconnected structure as a whole.

[0025] Optionally, add a SE module to the backbone network for feature extraction, including:

[0026] Using the squeezing method, a global average pooling operation is performed on the two-dimensional matrix extracted by the backbone network to obtain a two-dimensional matrix after the spatial dimension is squeezed;

[0027] The activation operation is performed based on the accumulated two-dimensional matrix. The activation operation involves first performing a 1*1 convolution instead of a fully connected layer for dimensionality reduction, then using a ReLU activation function for nonlinear processing, and then using a 1*1 convolution instead of a fully connected layer for dimensionality increase. Finally, a Sigmoid layer is added to obtain a 1*1 feature map and generate attention mechanism weights for different channels.

[0028] The 1*1 feature map is scaled back to its original feature size and weighted with the input feature map to obtain feature maps with different weights for each channel.

[0029] In a second aspect, an embodiment of the present application further provides a crack identification device, comprising:

[0030] A curve generation module is configured to generate a cosine curve for simulating fractures based on a cosine function that conforms to formation fracture characteristics, and to obtain a sample image containing fractures by performing at least one of the following operations on the cosine curve: translation, adjustment of added random noise, adjustment of inclination, and adjustment of size; wherein the sample image is labeled as a rectangular box within the sample image containing the cosine curve;

[0031] An image recognition module is used to train a crack recognition model based on the generated sample images, so as to recognize cracks in the image to be processed based on the trained model;

[0032] The crack identification model is implemented based on the yolov5 network model.

[0033] In a third aspect, an embodiment of the present application further provides an electronic device, including:

[0034] at least one processor; and a memory communicatively coupled to the at least one processor;

[0035] The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor to enable the electronic device to execute the method described in any one of the above aspects.

[0036] In a fourth aspect, an embodiment of the present application further provides a computer-readable storage medium, wherein the computer-readable storage medium stores computer-executable instructions. When a processor executes the computer-executable instructions, the method of any one of the above aspects is implemented.

[0037] In a fifth aspect, an embodiment of the present application further provides a computer program product, comprising a computer program, which implements the method described in any of the above aspects when executed by a processor.

[0038] The crack identification method, device, electronic device, storage medium and program product provided in this application can intelligently extract and accurately identify cracks, improving the accuracy while saving a lot of manpower and time costs; the improvement of the residual structure of the YOLOv5 network model greatly reduces the computational complexity of the model, while achieving the purpose of increasing the receptive field of the feature map without affecting the computational cost of the model, thereby improving detection accuracy; applying the Denseblock full interconnection concept to the YOLOv5 network model enables the model to fully extract, propagate and fuse features; adding the SE module to the backbone network can learn and combine different channel features to increase the global receptive field of the model, thereby improving detection accuracy. BRIEF DESCRIPTION OF THE DRAWINGS

[0039] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present application and, together with the description, serve to explain the principles of the present application.

[0040] Figure 1 An application scenario diagram provided for an embodiment of the present application;

[0041] Figure 2 A schematic flow chart of a crack identification method provided in an embodiment of the present application;

[0042] Figure 3 Schematic diagram of the residual structure of the yolov5 network model;

[0043] Figure 4 A schematic diagram of the residual structure of an improved yolov5 network model provided in an embodiment of the present application;

[0044] Figure 5 This is a schematic diagram of the DenseBlock structure used in the embodiments of this application;

[0045] Figure 6 A schematic diagram of the structure of a CBS module provided in an embodiment of the present application;

[0046] Figure 7 A schematic diagram of the structure after adding an SE module to the backbone network of the yolov5 network model provided in an embodiment of the present application;

[0047] Figure 8 A schematic diagram of the SE module structure provided in an embodiment of the present application;

[0048] Figure 9 A schematic diagram of a global average pooling operation provided in an embodiment of the present application;

[0049] Figure 10A schematic diagram of a crack identification device provided in an embodiment of the present application;

[0050] Figure 11 A schematic diagram of an electronic device provided in an embodiment of the present application.

[0051] The above drawings illustrate specific embodiments of the present application, which will be described in more detail below. These drawings and the textual description are not intended to limit the scope of the present application in any way, but rather to illustrate the concepts of the present application to those skilled in the art by reference to specific embodiments. DETAILED DESCRIPTION

[0052] Exemplary embodiments will be described in detail herein, with examples illustrated in the accompanying drawings. In the following description, when referring to the drawings, identical numerals in different figures represent identical or similar elements, unless otherwise indicated. The embodiments described in the following exemplary embodiments are not intended to represent all embodiments consistent with the present application. Rather, they are merely examples of apparatus and methods consistent with certain aspects of the present application, as detailed in the appended claims.

[0053] Imaging logging is a method of imaging the physical parameters of the wellbore wall and surrounding objects based on observations of the geophysical field in the borehole. In geological exploration, imaging logging images can reflect fracture information.

[0054] In some technologies, fractures in imaging logging images can be manually picked up, but there are disadvantages such as large workload, low efficiency, and large errors.

[0055] In other technologies, crack images can be manually photographed and manually annotated, and then the photographed crack images and annotated data are input into a crack recognition model, and the crack recognition model is trained. Finally, the crack images to be identified are input into the trained model, and the cracks can be automatically identified. However, due to the huge number of samples required for training the model, manually photographing crack images and manually annotating them alone requires a lot of manpower and time costs.

[0056] In view of this, an embodiment of the present application provides a fracture identification method, which can generate a cosine curve based on a cosine function that conforms to the characteristics of formation fractures, and realize sample expansion in the case of small sample size through a series of operations, and input the expanded sample image into a fracture identification model to train the fracture identification model. The trained model can intelligently extract and accurately identify fractures, while saving a lot of manpower and time costs, which is of great significance for guiding the identification of fracture-type reservoirs.

[0057] Figure 1 This is an application scenario diagram provided by the embodiment of this application. Figure 1As shown in the figure, the improved yolov5 network model is first trained using the cosine curve generated by the crack simulation cosine function and the XML format annotation data generated by the annotation tool Labelimg. Then, the crack image to be identified is input into the trained network model, and the cracks in the image can be automatically identified. In the identified crack image, the position of the rectangular box represents the position of the identified crack. Crack 0.82 means that the probability of the crack being at this position is 0.82, crack 0.92 means that the probability of the crack being at this position is 0.92, and crack 0.81 means that the probability of the crack being at this position is 0.81.

[0058] In an embodiment of the present application, a random cosine function that conforms to the characteristics of formation fractures is used to generate a cosine curve that simulates the fractures. A series of operations are used to achieve sample expansion in the case of small sample size, and the residual structure of the yolov5 network model is improved. By adding 1*1 convolution to perform dimensionality increase and dimensionality reduction operations, the amount of parameters that the network needs to calculate is reduced. At the same time, a void technology with an expansion rate of 2 is added to the convolution layer with a convolution kernel of 3*3 to increase the receptive field; at the same time, the full interconnection idea in DenseBlock is applied to the yolov5 network model so that the model can fully extract, propagate and fuse features, where Dense Block is a convolutional neural network with a dense connection property; finally, the SE module is added to the backbone network of the yolov5 network model so that the model considers learning and combining different channel features to increase the global receptive field of the model and improve detection accuracy.

[0059] The following specific embodiments describe in detail the technical solution of the present application and how the technical solution of the present application solves the above-mentioned technical problems. The following specific embodiments can be combined with each other, and the same or similar concepts or processes may not be repeated in some embodiments. The embodiments of the present application will be described below in conjunction with the accompanying drawings.

[0060] Figure 2 This is a flow chart of a crack identification method provided in an embodiment of the present application. The execution subject of this embodiment can be any device with data processing capabilities. As shown in Figure 2, the crack identification method provided in an embodiment of the present application may include:

[0061] Step 201: Based on a cosine function that conforms to formation fracture characteristics, a cosine curve for simulating fractures is generated, and a sample image containing fractures is obtained by performing at least one of the following operations on the cosine curve: translation, adjustment of added random noise, adjustment of inclination, and adjustment of size; wherein the sample image is labeled as a rectangular box containing the cosine curve in the sample image;

[0062] Optionally, you can use the data annotation tool Labelimg to annotate the sample image and generate annotation data in XML format. The annotation data includes the location of the annotation box and the label of the cosine curve within the annotation box. In the embodiment of the present application, the label of the cosine curve within the annotation box is crack, where the annotation box can be the smallest rectangular box that includes the entire cosine curve. You can also automatically annotate the sample image and generate annotation data during the sample image generation process.

[0063] Optionally, based on a cosine function that conforms to formation fracture characteristics, a cosine curve for simulating fractures is generated, and a sample image containing fractures is obtained by performing at least one of the following operations on the cosine curve: translation, adjustment of added random noise, adjustment of inclination, and adjustment of size, including:

[0064] Simulate a cosine function based on the cracks: Generate a cosine curve, where θ is the crack inclination and n is random noise. Modify the generated cosine curve by adjusting the function parameters to obtain multiple images.

[0065] The cosine curve in the generated image is translated to obtain multiple images, and the multiple images after the translation operation are randomly shuffled with the multiple images before the translation operation;

[0066] The randomly shuffled images are subjected to data augmentation to obtain multiple sample images containing cracks.

[0067] Specifically, when the filling material in the fracture is a low-resistance medium, the surrounding rock is a high-resistance surrounding rock layer, and the wellbore wall is extended in the north, east, south, and west directions, the cosine function of the simulated fracture is Among them, θ is the crack inclination, n is random noise, and the cosine function can be used to make a cosine curve. By changing the values ​​of θ and n, the cosine curve can be modified to obtain multiple images;

[0068] Then, the multiple images obtained above are translated. Translation is to add or subtract a certain value based on x in the original cosine function. Adding a positive number m to x can translate the image to the left by m units, and subtracting a positive number f from x can translate the image to the right by f units. For example, the cosine function Shift m units to the left, and it becomes Shift f units to the right, and it becomes Then, the multiple images after the translation operation and the multiple images before the translation operation are put together and randomly shuffled;

[0069] Finally, the randomly shuffled images are subjected to data enhancement to obtain multiple sample images containing cracks. Data enhancement methods may include rotation, scaling, cropping, color jittering, changing light intensity, etc.

[0070] In actual application, the cosine function can be simulated according to the crack A cosine curve is drawn, and the generated cosine curve is modified by adjusting the parameters θ and n to generate 1,000 data images; then the cosine curve is translated left and right according to the principle of left addition and right subtraction to generate 1,000 data images again, and randomly shuffled with the 1,000 data images generated above to obtain 2,000 randomly shuffled data images; thereafter, these 2,000 data images are randomly mirrored, rotated, scaled, cropped, and light intensity and contrast changed using computer vision image processing methods to generate 10,000 diverse data samples.

[0071] In this way, a cosine curve is made according to the cosine function that conforms to the characteristics of the formation fracture, and sample expansion is achieved in the case of small sample size by adjusting the added random noise, adjusting the inclination, translation, data enhancement and other operations.

[0072] Step 202: training a crack recognition model based on the generated sample image, so as to recognize cracks in the image to be processed based on the trained model;

[0073] The crack identification model is implemented based on the yolov5 network model.

[0074] In an optional implementation, the crack identification model may be a Yolov5 network model. In another optional implementation, the crack identification module may be obtained by improving the Yolov5 network model.

[0075] Optionally, the generated sample images can be made into a dataset containing cracks using the VOC2007 standard dataset format. The dataset includes a training set and a validation set. The ratio of the training set to the validation set in all generated sample images can be set to 9:1. Then, the crack recognition model based on the yolov5 network model is trained according to the dataset containing cracks. After the model training is completed, the cracks in the processed image can be identified according to the trained model.

[0076] Optionally, the crack recognition model is trained based on the generated sample images, including:

[0077] In the residual structure of the yolov5 network model, 1*1 convolution is used for dimensionality increase and dimensionality reduction operations, and the 3*3 convolution in the residual structure adopts the dilation rate 2 dilation technology;

[0078] Apply the fully interconnected idea of ​​Denseblock in DenseNet to the yolov5 network model;

[0079] Adding SE module to the backbone network for feature extraction, the improved yolov5 network model is obtained as the crack recognition model;

[0080] The crack recognition model is trained according to the generated sample images.

[0081] Optionally, use 1*1 convolution for dimensionality increase and decrease in the residual structure of the Yolov5 network model, and use the dilation rate 2 dilation technique for the 3*3 convolution in the residual structure, including:

[0082] In the residual structure of the yolov5 network model, the convolution operation with a 1*1 convolution kernel is set on the input to achieve dimensionality reduction and obtain an N-channel feature map;

[0083] The feature map is input into a 3*3 convolution operation, which adds a dilation convolution technique with a dilation rate of 2 to obtain an N-channel feature map;

[0084] Finally, a convolution with a 1*1 kernel is added to perform a convolution operation on the N-channel feature map obtained by the 3*3 convolution to achieve dimensionality increase.

[0085] Specifically, Figure 3 This is a schematic diagram of the residual structure of the yolov5 network model, as shown Figure 3 As shown in the figure, the residual structure is composed of 1*1Conv (convolve, convolution operation), 3*3Conv, BN (Batch-Normal, batch normalization) and SiLU (SigmoidLinear Unit, Sigmoid, weighted linear combination) activation function, where both input and output channels can be set to 32. The residual structure first performs a convolution operation with a convolution kernel of 1*1 on the input 32-channel feature map, outputs a 32-channel feature map, and then performs a batch normalization operation and a SiLU activation function operation on the feature map, still outputting a 32-channel feature map, and then performs a convolution operation with a convolution kernel of 3*3 on the output feature map, and then performs batch normalization and SiLU activation function operations again. The final 32-channel feature map is added to the original 32 feature map that has not undergone the above operation.

[0086] This residual structure can deepen the number of network layers and obtain feature map information at different levels. However, the number of parameters required to calculate the residual structure may reach 1*1*32*32+3*3*32*32=10240, which is relatively large.

[0087] In order to solve the problem of large amount of parameter calculation, this application improves the residual structure. Figure 4 This is a schematic diagram of the residual structure of the improved yolov5 network model, as shown Figure 4 As shown in the figure, the improved residual structure first performs a convolution operation with a convolution kernel of 1*1 on the input 32-channel feature map to achieve a dimensionality reduction effect, and outputs a 16-channel feature map. After that, batch normalization and SiLU activation function operations are performed, and the 16-channel feature map is still output. The output feature map is then subjected to a convolution operation with a convolution kernel of 3*3. The convolution adds a dilation rate of 2 to obtain a 16-channel feature map. After batch normalization and SiLU activation function operations, a convolution operation with a convolution kernel of 1*1 is performed to achieve a dimensionality increase effect and output a 32-channel feature map. Finally, after batch normalization and SiLU activation function operations, the output 32-channel feature map is added to the original 32-feature map that has not undergone the above operations (i.e., the input 32-feature map).

[0088] Calculating the number of parameters in the improved residual structure yields 1*1*32*16 + 3*3*16*16 + 1*1*16*32 = 3328, which is one-third the number of parameters in the original residual structure, significantly reducing the model's computational complexity. Furthermore, the improved residual structure incorporates a dilated convolution technique with a dilation rate of 2 during 3*3 convolution operations. This increases the receptive field of the feature map while maintaining the computational cost of the model, ultimately improving detection accuracy.

[0089] Optionally, DenseBlock can be used to replace the Resunit module in the C_1_3 module of the yolov5 network model;

[0090] Among them, each network layer in the DenseBlock structure contains three CBS modules. Each network layer in the DenseBlock structure uses the features extracted by all the layers before itself as the input of this layer, and the features obtained by itself as the input of all subsequent layers, forming a fully interconnected structure as a whole.

[0091] Specifically, DenseBlock will replace the Resunit module in the C_1_3 module of the yolov5 network model. Figure 5 The DenseBlock structure used in the embodiment of this application is as follows: Figure 5 As shown, the DenseBlock structure contains several network layers, each of which contains 3 CBS modules. Figure 6 The structure of the CBS module is as follows: Figure 6As shown, the CBS module consists of a convolutional layer, a batch normalization layer, and a SiLU activation function layer. This means that each time a feature map passes through a CBS module, it undergoes convolution, batch normalization, and SiLU activation operations. Each time it passes through a network layer, the previous series of operations must be repeated three times. Assuming that the DenseBlock structure contains a total of s network layers, each network layer in the DenseBlock structure, such as the p-th network layer, can use the features extracted by all the layers preceding it, including the 1st network layer, the 2nd network layer, ... the p-1th network layer, as input to this layer. Similarly, the features obtained by the p-th network layer can also be used as input to the subsequent p+1-th network layer, the p+2-th network layer, ... the s-th network layer, forming a fully interconnected structure as a whole.

[0092] For example, you can refer to Figure 5 , the third network layer can use the features extracted from the previous first and second network layers as the input of this layer. Similarly, the features obtained by the third network layer can also be used as the input of the subsequent fourth and fifth network layers.

[0093] In this way, by injecting the fully interconnected idea of ​​DenseBlock into the yolov5 network model, the model can fully extract, propagate and fuse features.

[0094] Optionally, add a SE module to the backbone network for feature extraction, including:

[0095] Using the squeezing method, a global average pooling operation is performed on the two-dimensional matrix extracted by the backbone network to obtain a two-dimensional matrix after the spatial dimension is squeezed;

[0096] The activation operation is performed based on the accumulated two-dimensional matrix. The activation operation involves first performing a 1*1 convolution instead of a fully connected layer for dimensionality reduction, then using a ReLU activation function for nonlinear processing, and then using a 1*1 convolution instead of a fully connected layer for dimensionality increase. Finally, a Sigmoid layer is added to obtain a 1*1 feature map and generate attention mechanism weights for different channels.

[0097] Finally, the 1*1 feature map is scaled back to its original feature size and weighted with the input feature map to obtain feature maps with different weights under each channel.

[0098] Figure 7 This is the structure after adding SE module to the backbone network of yolov5 network model. Figure 7As shown in the figure, the backbone network of the yolov5 network model is mainly composed of three parts. The first part includes the FOCUS (focus) module, CBS module, C3_1_1 module, CBS module and C3_1_3 module from left to right, where the FOCUS module uses a slicing operation to split the high-resolution image / feature map into multiple low-resolution images / feature maps; the second part includes the CBS module and C3_1_3 module from left to right, and an SE module is added before the CBS module in the second part; after the operation of the second part is completed, two branches are generated, and the feature map of one branch is subjected to the operation of the third part, the upsampling operation, and then the Concat (merge) operation is performed with the feature map of the other branch, where the third part includes the CBS module, the SPP module, the C3_2_1 module and the CBS module from left to right, and an SE module is added before the first CBS module in the third part and after the SPP module.

[0099] Figure 8 This is the SE module structure diagram, such as Figure 8 As shown in Figure 1, in the SE module, we first need to perform a global average pooling operation on the two-dimensional matrix of each channel in the input feature map to obtain a two-dimensional matrix after spatial dimension compression.

[0100] For example, the input feature map has c channels, and the two-dimensional matrix of each channel is an h×w matrix. The global average pooling operation is to add the numbers in each row and column of the h×w matrix, and finally divide it by the product of h and w. Its expression can be written as Where u(i, j) is the value corresponding to the i-th row and j-th column of the two-dimensional matrix, h is the total number of rows of the two-dimensional matrix, w is the total number of columns of the two-dimensional matrix, and z is the value obtained after the two-dimensional matrix undergoes global average pooling. The global average pooling operation is performed on the two-dimensional matrix of each channel. After that, the output feature map still has c channels, but the two-dimensional matrix of each channel becomes a 1×1 matrix.

[0101] Figure 9 The schematic diagram of the global average pooling operation when the input feature map has 2 channels and each channel is a 3×3 matrix is ​​as follows Figure 9 As shown, the global average pooling operation is first applied to the 3×3 matrix of the first channel, and the value in the resulting 1×1 matrix is ​​(1+4+6+7+2+8+9+5+3) / (3×3)=5. Then, the global average pooling operation is applied to the 3×3 matrix of the second channel, and the value in the resulting 1×1 matrix is ​​(2+3+6+5+8+1+2+6+3) / (3×3)=4.

[0102] After the global average pooling operation, the activation operation can be performed. The activation operation is divided into 4 steps. First, a convolution operation with a convolution kernel of 1*1 is performed for dimensionality reduction, and then the SiLU activation function is used for nonlinear processing. After that, a convolution operation with a convolution kernel of 1*1 is performed for dimensionality increase. After the first 3 steps, not only the nonlinear performance of the model neural network can be greatly improved, but also the amount of model parameter calculation can be reduced. Finally, the Sigmod activation function is used to generate the attention mechanism weights of different channels.

[0103] At this point, the two-dimensional matrix of each channel is a 1×1 matrix. This matrix is ​​scaled back to its original h×w matrix and then weighted with the initial input feature map to obtain a feature map with different weights for each channel. This feature map can be used as the input feature map for subsequent layers of the backbone network.

[0104] In this way, adding the SE module to the backbone network can learn and combine different channel features to increase the global receptive field of the model and improve detection accuracy.

[0105] In summary, the fracture identification method provided in the embodiments of the present application includes: generating a cosine curve for simulating fractures based on a cosine function that conforms to formation fracture characteristics, and performing at least one of the following operations on the cosine curve: translation, adjustment of added random noise, adjustment of inclination, and adjustment of size to obtain a sample image containing fractures; wherein the sample image is labeled as a rectangular box containing the cosine curve in the sample image; training a fracture identification model based on the generated sample image to identify fractures in the processed image based on the trained model; wherein the fracture identification model is implemented based on the Yolov5 network model. By generating a cosine curve for simulating fractures based on a random cosine function that conforms to formation fracture characteristics, and achieving sample expansion in the case of a small sample size through a series of operations, the sample image is then input into the fracture identification model and the fracture identification model is trained. The trained model can then intelligently extract and accurately identify fractures, improving accuracy while saving a significant amount of labor and time costs, which is of great significance in guiding the identification of fractured reservoirs.

[0106] Corresponding to the above-mentioned crack identification method, an embodiment of the present application further provides a crack identification device. Figure 10 This is a schematic diagram of the structure of a crack identification device provided in an embodiment of the present application. Figure 10 As shown, the device includes:

[0107] The curve generation module 1001 is configured to generate a cosine curve for simulating fractures based on a cosine function that conforms to formation fracture characteristics, and to obtain a sample image containing fractures by performing at least one of the following operations on the cosine curve: translation, adjustment of added random noise, adjustment of inclination, and adjustment of size; wherein the sample image is labeled as a rectangular box within the sample image containing the cosine curve;

[0108] An image recognition module 1002 is configured to train a crack recognition model based on the generated sample image, so as to recognize cracks in the image to be processed based on the trained model;

[0109] The crack identification model is implemented based on the yolov5 network model.

[0110] In one or more embodiments of the present application, optionally, the curve generating module 1001 is specifically configured to:

[0111] Simulate a cosine function based on the cracks: Generate a cosine curve, where θ is the crack inclination and n is random noise. Modify the generated cosine curve by adjusting the function parameters to obtain multiple images.

[0112] The cosine curve in the generated image is translated to obtain multiple images, and the multiple images after the translation operation are randomly shuffled with the multiple images before the translation operation;

[0113] The randomly shuffled images are subjected to data enhancement to obtain multiple sample images containing cracks.

[0114] In one or more embodiments of the present application, optionally, the image recognition module 1002, when used to train the crack recognition model based on the generated sample image, is specifically configured to:

[0115] In the residual structure of the yolov5 network model, 1*1 convolution is used for dimensionality increase and dimensionality reduction operations, and the 3*3 convolution in the residual structure adopts the dilation rate 2 dilation technology;

[0116] Use DenseBlock to replace the Resunit module of the yolov5 network model;

[0117] Adding SE module to the backbone network for feature extraction, the improved yolov5 network model is obtained as the crack recognition model;

[0118] The crack recognition model is trained according to the generated sample images.

[0119] In one or more embodiments of the present application, optionally, the image recognition module 1002, when using 1*1 convolution to perform dimensionality increase and dimensionality reduction operations in the residual structure of the YOLOv5 network model and using a dilation rate of 2 for the 3*3 convolution in the residual structure, is specifically used to:

[0120] In the residual structure of the yolov5 network model, the convolution operation with a 1*1 convolution kernel is set on the input to achieve dimensionality reduction and obtain an N-channel feature map;

[0121] The feature map is input into a 3*3 convolution operation, which adds a dilation convolution technique with a dilation rate of 2 to obtain an N-channel feature map;

[0122] Add a convolution with a convolution kernel of 1*1 and perform a convolution operation on the N-channel feature map obtained by the 3*3 convolution to achieve dimensionality increase.

[0123] In one or more embodiments of the present application, optionally, the image recognition module 1002, when replacing the Resunit module of the yolov5 network model with DenseBlock, is specifically configured to:

[0124] The Resunit module replaced by DenseBlock is the Resunit module in the C_1_3 module of the yolov5 network model;

[0125] Among them, each network layer in the DenseBlock structure contains three CBS modules. Each network layer in the DenseBlock structure uses the features extracted by all the layers before itself as the input of this layer, and the features obtained by itself as the input of the subsequent layers, forming a fully interconnected structure as a whole.

[0126] In one or more embodiments of the present application, optionally, when adding an SE module to the backbone network for extracting features, it is specifically used to:

[0127] Using the squeezing method, a global average pooling operation is performed on the two-dimensional matrix extracted by the backbone network to obtain a two-dimensional matrix after the spatial dimension is squeezed;

[0128] The activation operation is performed based on the accumulated two-dimensional matrix. The activation operation involves first performing a 1*1 convolution instead of a fully connected layer for dimensionality reduction, then using a ReLU activation function for nonlinear processing, and then using a 1*1 convolution instead of a fully connected layer for dimensionality increase. Finally, a Sigmoid layer is added to obtain a 1*1 feature map and generate attention mechanism weights for different channels.

[0129] The 1*1 feature map is scaled back to its original feature size and weighted with the input feature map to obtain feature maps with different weights for each channel.

[0130] The crack identification device provided in the embodiment of the present application can be used to perform the above Figures 1 to 9 The technical solutions of the illustrated embodiment have similar implementation principles and technical effects, and will not be described in detail in this embodiment.

[0131] Figure 11 This is a schematic diagram of the structure of an electronic device provided in an embodiment of the present application. Figure 11 As shown, the electronic device of this embodiment may include:

[0132] at least one processor 1101; and

[0133] a memory 1102 communicatively connected to the at least one processor;

[0134] The memory 1102 stores instructions that can be executed by the at least one processor 1101, and the instructions are executed by the at least one processor 1101 to enable the electronic device to execute the method as described in any of the above embodiments.

[0135] Optionally, the memory 1102 may be independent or integrated with the processor 1101 .

[0136] The implementation principle and technical effects of the electronic device provided in this embodiment can be found in the aforementioned embodiments and will not be described in detail here.

[0137] An embodiment of the present application further provides a computer-readable storage medium, wherein the computer-readable storage medium stores computer-executable instructions. When a processor executes the computer-executable instructions, the method described in any of the above embodiments is implemented.

[0138] An embodiment of the present application further provides a computer program product, including a computer program, which implements the method described in any of the aforementioned embodiments when executed by a processor.

[0139] Those skilled in the art will readily appreciate other embodiments of the present invention after considering the specification and practicing the invention disclosed herein. This application is intended to cover any variations, uses, or adaptations of the present invention that follow the general principles of this application and include common knowledge or customary techniques in the art that are not disclosed herein.

[0140] It will be understood that the present application is not limited to the exact construction that has been described above and shown in the drawings, and that various modifications and changes may be made without departing from the scope thereof.

[0141] In the several embodiments provided in this application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are merely illustrative. For example, the division of modules is merely a logical function division. In actual implementation, other division methods may be used. For example, multiple modules may be combined or integrated into another system, or some features may be ignored or not implemented.

[0142] The above-mentioned integrated module implemented in the form of a software functional module can be stored in a computer-readable storage medium. The above-mentioned software functional module is stored in a storage medium and includes a number of instructions for causing a computer device (which can be a personal computer, server, or network device, etc.) or a processor to perform some steps of the method described in each embodiment of the present application.

[0143] It should be understood that the above-mentioned processor may be a central processing unit (CPU), or other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), etc. The general-purpose processor may be a microprocessor or any conventional processor. The steps of the method disclosed in the application may be directly embodied as being executed by a hardware processor, or may be executed by a combination of hardware and software modules in the processor. The memory may include high-speed RAM memory, and may also include non-volatile storage NVM, such as at least one disk memory, and may also be a USB flash drive, a mobile hard disk, a read-only memory, a magnetic disk or an optical disk, etc.

[0144] The storage medium may be implemented by any type of volatile or non-volatile memory device, or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic storage, flash memory, magnetic disk, or optical disk. The storage medium may be any available medium that can be accessed by a general-purpose or special-purpose computer.

[0145] An exemplary storage medium is coupled to the processor such that the processor can read information from, and can write information to, the storage medium. Of course, the storage medium can be a part of the processor. Consistent with the teachings provided herein, the processor can execute instructions embodied by computer code stored on the storage medium, and the storage medium can store computer code which, when executed by the processor, causes the processor to perform methods as described herein. The processor and the storage medium can be supplemented by, or incorporated in, ASICs (application- specific integrated circuits).

[0146] It should be noted that, as used in this document, the terms "includes" and / or "containing" or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that includes a list of elements is not limited to those elements, but can include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element preceded by "comprises a" does not, without more constraints, foreclose the existence of additional identical elements in the process, method, article, or apparatus that includes the element.

[0147] The above-mentioned sequence numbers of the embodiments of the present application are only for description, and do not represent the advantages and disadvantages of the embodiments.

[0148] From the above description of the embodiments, those skilled in the art can clearly understand that the above-mentioned embodiment methods can be realized by means of software and necessary general hardware platforms, and of course can also be realized by hardware, but in many cases the former is a better embodiment. Based on such understanding, the technical solutions of the present application can be embodied in the form of a software product, which is stored in a storage medium (such as a ROM / RAM, a magnetic disk, or an optical disk), and includes a plurality of instructions for causing a terminal device (which can be a mobile phone, a computer, a server, an air conditioner, or a network device) to execute the methods described in the various embodiments of the present application.

[0149] The above is only the preferred embodiment of the present application, and does not limit the patent scope of the present application, and any equivalent structure or equivalent process transformation, or direct or indirect application in other related technical fields, is also included in the patent protection scope of the present application.

Claims

1. A crack identification method, characterized in that: include: Based on a cosine function that conforms to formation fracture characteristics, a cosine curve for simulating fractures is generated, and a sample image containing fractures is obtained by performing at least one of the following operations on the cosine curve: translation, adjustment of added random noise, adjustment of inclination, and adjustment of size; wherein the sample image is labeled as a rectangular box within the sample image containing the cosine curve; According to the generated sample images, a crack recognition model is trained to recognize cracks in the image to be processed based on the trained model; Wherein, the crack identification model is implemented based on the yolov5 network model; The crack recognition model is trained based on the generated sample images, including: In the residual structure of the yolov5 network model, 1*1 convolution is used for dimensionality increase and dimensionality reduction operations, and the 3*3 convolution in the residual structure adopts the dilation rate 2 dilation technology; Use DenseBlock to replace the Resunit module of the yolov5 network model; Adding SE module to the backbone network for feature extraction, the improved yolov5 network model is obtained as the crack recognition model; Training the crack recognition model according to the generated sample images; The method includes: generating a cosine curve for simulating fractures based on a cosine function that conforms to the characteristics of fractures in the formation; and performing at least one of the following operations on the cosine curve: translation, adjustment of added random noise, adjustment of inclination, and adjustment of size, to obtain a sample image containing fractures, including: Simulate a cosine function based on the cracks: Generate a cosine curve, where θ is the crack inclination and n is random noise. Modify the generated cosine curve by adjusting the function parameters to obtain multiple images. The cosine curve in the generated image is translated to obtain multiple images, and the multiple images after the translation operation are randomly shuffled with the multiple images before the translation operation; The randomly shuffled images are subjected to data enhancement to obtain multiple sample images containing cracks.

2. The method according to claim 1, characterized in that In the residual structure of the yolov5 network model, 1*1 convolution is used for dimensionality increase and dimensionality reduction operations, and the 3*3 convolution in the residual structure adopts the dilation rate 2 hollow technology, including: In the residual structure of the yolov5 network model, the convolution operation with a 1*1 convolution kernel is set on the input to achieve dimensionality reduction and obtain an N-channel feature map; The feature map is input into a 3*3 convolution operation, which adds a dilation convolution technique with a dilation rate of 2 to obtain an N-channel feature map; Add a convolution with a convolution kernel of 1*1 and perform a convolution operation on the N-channel feature map obtained by the 3*3 convolution to achieve dimensionality increase.

3. The method according to claim 1, characterized in that Use DenseBlock to replace the Resunit module of the yolov5 network model, including: The Resunit module replaced by DenseBlock is the Resunit module in the C_1_3 module of the yolov5 network model; Among them, each network layer in the DenseBlock structure contains three CBS modules. Each network layer in the DenseBlock structure uses the features extracted by all the layers before itself as the input of this layer, and the features obtained by itself as the input of the subsequent layers, forming a fully interconnected structure as a whole.

4. The method according to claim 1, wherein Add the SE module to the backbone network for feature extraction, including: Using the squeezing method, a global average pooling operation is performed on the two-dimensional matrix extracted by the backbone network to obtain a two-dimensional matrix after the spatial dimension is squeezed; The activation operation is performed based on the accumulated two-dimensional matrix. The activation operation involves first performing a 1*1 convolution instead of a fully connected layer for dimensionality reduction, then using a ReLU activation function for nonlinear processing, and then using a 1*1 convolution instead of a fully connected layer for dimensionality increase. Finally, a Sigmoid layer is added to obtain a 1*1 feature map and generate attention mechanism weights for different channels. The 1*1 feature map is scaled back to its original feature size and weighted with the input feature map to obtain feature maps with different weights for each channel.

5. A crack identification device, characterized in that: include: A curve generation module is configured to generate a cosine curve for simulating fractures based on a cosine function that conforms to formation fracture characteristics, and to obtain a sample image containing fractures by performing at least one of the following operations on the cosine curve: translation, adjustment of added random noise, adjustment of inclination, and adjustment of size; wherein the sample image is labeled as a rectangular box within the sample image containing the cosine curve; An image recognition module is used to train a crack recognition model based on the generated sample images, so as to recognize cracks in the image to be processed based on the trained model; Wherein, the crack identification model is implemented based on the yolov5 network model; The image recognition module is used to train the crack recognition model based on the generated sample images. In the residual structure of the yolov5 network model, 1*1 convolution is used for dimensionality increase and dimensionality reduction operations, and the 3*3 convolution in the residual structure adopts the dilation rate 2 dilation technology; Use DenseBlock to replace the Resunit module of the yolov5 network model; Adding SE module to the backbone network for feature extraction, the improved yolov5 network model is obtained as the crack recognition model; Training the crack recognition model according to the generated sample images; The curve generation module is specifically used for: Simulate a cosine function based on the cracks: Generate a cosine curve, where θ is the crack inclination and n is random noise. Modify the generated cosine curve by adjusting the function parameters to obtain multiple images. The cosine curve in the generated image is translated to obtain multiple images, and the multiple images after the translation operation are randomly shuffled with the multiple images before the translation operation; The randomly shuffled images are subjected to data enhancement to obtain multiple sample images containing cracks.

6. An electronic device, characterized in that: include: at least one processor; and a memory communicatively coupled to the at least one processor; The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor to enable the electronic device to perform the method according to any one of claims 1 to 4.

7. A computer-readable storage medium, characterized in that The computer-readable storage medium stores computer-executable instructions, and when a processor executes the computer-executable instructions, the method according to any one of claims 1 to 4 is implemented.

8. A computer program product comprising a computer program, characterized in that When the computer program is executed by a processor, the method according to any one of claims 1 to 4 is implemented.

Citation Information

Patent Citations

  • Crack detection method and device, computer equipment and storage medium

    CN112926584A

  • Dynamic target detection and tracking method

    CN114359689A