Intelligent recognition algorithm for borehole image

By using the sine cosine algorithm in drilling image recognition technology to optimize the hyperparameters and thresholds of the Resnet50 network model, combined with K-fold cross-validation, the problem of relying on manual experience and poor generalization capabilities of hyperparameter adjustment in the existing technology is solved, and a more efficient and accurate drilling image recognition effect is achieved.

CN120070830APending Publication Date: 2025-05-30INST OF ROCK & SOIL MECHANICS CHINESE ACAD OF SCI
View PDF 6 Cites 0 Cited by

Patent Information

Application Number
CN202510427192.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-04-07
Publication Date
2025-05-30

AI Technical Summary

Technical Problem

The existing drilling image recognition technology based on deep learning has problems such as relying on manual experience in hyperparameter adjustment, poor model generalization ability, and time-consuming and unstable parameter adjustment process.

Method used

The hyperparameters and thresholds of the Resnet50 network model are optimized by using sine cosine algorithm (SCA). Combined with K-fold cross-validation, the network structure and parameters are optimized to improve the training efficiency and segmentation accuracy of the model.

Benefits of technology

Through SCA optimization, it is possible to find the appropriate hyperparameter combination of the model more efficiently, improve the training effect and segmentation accuracy of the model, reduce time costs, and avoid the problem of poor generalization capabilities of the model.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120070830A_ABST
    Figure CN120070830A_ABST
Patent Text Reader

Abstract

The invention provides an intelligent recognition algorithm for a borehole image, and belongs to the technical field of crossing of geological engineering and computer vision. The method comprises the following steps: acquiring original data of a drilling structural plane through a digital panoramic drilling camera system, and constructing a multi-scale feature data set through standardized cutting; and processing the drilling image structural surface data set, wherein the processing comprises image annotation, data set division and the like. Determining an input variable and an output variable according to the Resnet50 model, and training the Resnet50 network by using the training set to complete the construction of the Resnet50 network model; sine and cosine algorithm SCA optimization: introducing a sine and cosine algorithm SCA to carry out global optimization on hyper-parameters and threshold values of the Resnet50 network model, and obtaining an optimized Resnet50 network model; and according to samples of the test set, predicting the samples based on the optimized Resnet50 network model, and generating a prediction map to obtain a final result. According to the method, K-fold cross validation is adopted in the optimization process of the sine and cosine algorithm (SCA), the sine and cosine algorithm is prevented from falling into a local extreme value, finally, a high-precision recognition model is generated through iterative training, and automatic detection of the form of the drilled structural plane is achieved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention relates to a drilling image recognition algorithm, in particular to a drilling image intelligent recognition algorithm. Background Art

[0002] In the fields of geotechnical engineering, geological engineering, hydropower engineering, oil development and geological disaster prevention, the study of the stability characteristics of rock mass structure is of vital importance. The structural surfaces such as joints, faults, weak surfaces and layers that are commonly found in rock mass are key factors affecting the stability of the project. Therefore, how to accurately identify and analyze these structural surfaces has become an important issue that needs to be solved in engineering practice.

[0003] As a traditional means of evaluating the structural integrity of rock mass, the borehole core determination method has long played an irreplaceable role and provided valuable basic geological data for engineering design and construction. However, due to the complex and changeable geological conditions (such as weak or broken rock mass, karst caves, faults and broken zones, etc.) and the limitations of drilling technology itself (such as low or even zero coring rate caused by mechanical disturbance), this method is often difficult to guarantee accuracy in practical applications and may even lead to wrong conclusions.

[0004] As an emerging means of engineering geological detection, borehole camera technology can obtain clear images of the borehole wall in the borehole through optical principles and related equipment. This technology has the advantages of accurate and fast information acquisition, and provides new technical support for engineering geological surveys. Typical borehole camera equipment is mainly composed of core components such as borehole camera probes and controllers, in which the probe integrates key components such as light sources and cameras. When the equipment is working, the light source illuminates the borehole wall, and the camera synchronously captures the image information of the borehole wall.

[0005] However, the current methods for processing borehole camera images mainly rely on manual work. There are the following problems when manually processing borehole camera images: 1) When the number of images is large, the workload increases significantly and the processing efficiency is low; since cracks have specific characteristics, a lot of repetitive work is often required in the manual identification process. 2) When manually identifying cracks in images, due to strong subjectivity, crack identification may not be accurate enough or even misjudgment may occur. 3) Due to factors such as on-site drilling conditions, the quality of borehole imaging may be poor, resulting in a limited amount of image data that can actually be used. It takes a lot of time to filter out valid data; it is inefficient and costly.

[0006] In recent years, methods based on deep learning for identifying underground borehole fractures have also emerged. When processing images using deep learning-based methods, the following problems exist: 1) When processing images using deep learning-based methods, it is necessary to adjust the hyperparameters of the network structure. However, the adjustment of hyperparameters requires certain experience from researchers, which will lead to blindness and low efficiency in the process of adjusting network structure parameters. 2) During the process of adjusting the network parameters of the network structure, certain hyperparameter combinations may cause the model to fall into a local optimum and it is difficult to find the global optimum solution. This will result in the fact that even after a large number of parameter adjustments, the model performance may still not be ideal. 3) The training process of neural networks is random (such as weight initialization, data sampling, etc.). Even when using the same hyperparameters, the results of multiple trainings may be different. The parameter adjustment results may not be stable enough, making it difficult to determine the optimal configuration. 4) The parameter adjustment process requires repeated training of the model. Especially for large-scale datasets or complex models, each training may take several hours or even days. The time cost of parameter adjustment is high, which may affect the project progress. Summary of the Invention

[0007] The existing deep learning-based borehole image recognition has the following problems: 1) When training a deep learning model, it is necessary to adjust the hyperparameters according to the output effect of the model. The adjustment process of hyperparameters depends on the proficiency and experience of the staff and is greatly affected by human subjectivity. 2) During the process of adjusting the parameters of the network structure, it may overly rely on the performance of the validation set and the test set, resulting in the model performing well on the parameter adjustment data but having poor generalization ability on new data, and the actual application effect of the model may not meet expectations.

[0008] To avoid the above problems, the present invention proposes a technical solution to overcome the defects of deep learning borehole image recognition. Specifically, a method for optimizing network model parameters based on the sine-cosine algorithm (SCA) is provided, which provides an efficient method for model optimization and improves the efficiency of model development.

[0009] Specifically, an intelligent recognition algorithm for borehole images is characterized by including the following steps:

[0010] (1) Image collection; The imaging part of image collection consists of components such as a CCD camera and a controller. Among them, the CCD camera integrates key components such as a light source and a camera. The CCD camera is held in a pressure-resistant cylinder, and the lens is located in the upper part of the imaging section near the packer. The pressure-resistant cylinder loaded with the CCD camera is under atmospheric pressure, and its temperature is controlled by a suitable control system and / or heat insulation device. The light source is located near the packer, the light source illuminates the borehole wall, and the CCD camera synchronously captures the image information of the borehole wall, collecting clear and distinct pictures of the borehole wall. These pictures contain different response characteristics of the structural plane in the borehole image, including sinusoidal curve shape, straight line shape, open-type structural plane, cracked-type structural plane, etc., to establish a borehole image structural plane dataset;

[0011] (2) Image cropping; Process the borehole image structural plane dataset: Crop the borehole structural plane image into 512×512, and noise reduction processing is required for some images with more noise;

[0012] (3) Image annotation; Mark the pictures of the above dataset in LABELME, use a polygon box to mark the structural plane, and label it with CRACK;

[0013] (4) Image preprocessing; Preprocess the borehole structural plane dataset, including operations such as image scaling, grayscale conversion, normalization, etc., and increase the diversity of training data through data augmentation techniques such as rotation, flipping, or translation.

[0014] (5) Dataset division; Divide the borehole structural plane dataset, and divide the dataset into a training set, a validation set, and a test set according to the ratio of 8:1:1 respectively;

[0015] (6) Resnet50 model; Determine the input variables and output variables, use the training set to train the Resnet50 network, and complete the construction of the Resnet50 network model;

[0016] (7) Sine-cosine algorithm SCA optimization; Use the sine-cosine algorithm SCA to optimize the hyperparameters and thresholds of the Resnet50 network model to obtain the optimized Resnet50 network model;

[0017] (8) Optimize the Resnet model. Based on the samples of the test set, make predictions using the optimized Resnet50 network model to generate a prediction map and obtain the final result.

[0018] Furthermore, in step (6), select the learning rate, convolution kernel size, number of convolutional layers, batch size, and regularization parameter of the Resnet50 network as the hyperparameters to be optimized, and set the value range for each hyperparameter, where the learning rate is set to 10-6 to 10 -1 , the convolution kernel size ranges from 3×3 to 7×7.

[0019] Furthermore, in step (7), initialize the SCA population; the size of the initialized SCA population is 50, and a set of initial solutions is randomly generated in the hyperparameter space, where each solution represents a set of hyperparameter combinations.

[0020] Furthermore, it also includes K-fold cross-validation; select the validation set accuracy of the model as the fitness function to evaluate the performance of hyperparameter combinations, and at the same time use K-fold cross-validation to verify the model.

[0021] Furthermore, it also includes updating the individual positions; according to the periodic oscillation characteristics of the sine and cosine functions, update the positions of each individual; calculate the fitness value of the individual; update the individuals in the population according to the fitness value, and select the individual with the highest fitness value in each iteration and determine it as the current optimal solution.

[0022] Furthermore, in step (7), the SCA-Resnet model designs the convolutional neural network model structure, including an input layer, a convolutional layer, a pooling layer, a fully connected layer, and an output layer; where the convolutional layer and the pooling layer are arranged alternately; initialize the SCA algorithm parameters, where the hyperparameters in the convolutional neural network structure include weights, thresholds, and biases, which are used as the number of particle dimensions in the particle swarm algorithm and are arranged in order; randomly generate m particles, and each particle is used as the initial parameter of the convolutional neural network structure. The training set is input into the convolutional neural network model, and the mean square error between the model-predicted image structure plane data and the model is used as the fitness function of the particle swarm algorithm; set the number of iterations. When the iteration is completed, the globally optimal particle found by the SCA algorithm is the optimal initialization parameter of the model: weights, thresholds, and biases; assign the value of each dimension of the globally optimal particle position to the weights, thresholds, and biases of the convolutional neural network model in order; train the model, set the loss function as the mean root square error function, and determine whether the required accuracy is met; use the test set data to evaluate the performance of the SCA-Resnet50 model.

[0023] Furthermore, according to the periodic oscillation characteristics of the sine and cosine functions, set the initial individual weights:

[0024]

[0025] where Nodein and Nodeout represent the number of input and output nodes of each layer respectively.

[0026] Further, the hyperparameter and threshold optimization in step (7) includes: Step S7.1, determine whether it is the first iteration. If so, directly calculate the fitness fi for each point Mi. Otherwise, first merge the latest population position M with the historical optimal population position F, then calculate its fitness fi, and sort the fitness fi of each point i from largest to smallest, and select the top N population positions as the historical optimal position F; Step S7.2, screen out the points among the N points whose fitness is greater than the fitness of the optimal point and whose fitness is the largest, replace the optimal point Pbest with the currently screened point with the largest fitness, and further assign the current point position to the best population position Best_pos; calculate the accuracy ACC of the support vector machine according to the internal K-fold cross-validation strategy in formula (2);

[0027]

[0028] Among them, acck represents the accuracy obtained by calculation on each fold of data;

[0029] Step S7.3, in order to stably carry out development and exploration, adaptively change the sine and cosine ranges of the individual weights in formula (1) using formula (3):

[0030]

[0031] Among them, t is the current iteration, T is the maximum number of iterations, and a is a constant;

[0032] Step S7.4, determine whether the maximum number of iterations T is exceeded; if not, jump to step S7.2; if so, execute the next step S7.5;

[0033] Step S7.5, output the position Best_pos of the optimal population Pbest and its corresponding fitness;

[0034] Step S7.6, construct the prediction model shown in formula (4) below, and classify and predict the samples to be classified based on the constructed prediction model; among them, K(xi, xj) is shown in formula (5); xj represents the j-th normalized sample data; xi (i = 1...l) represents the training samples; yi (i = 1...l) represents the labels corresponding to the training samples, yi = 1 represents the positive class samples, and yi = -1 represents the negative class samples; b is the threshold; αi is the Lagrange coefficient;

[0035]

[0036] K(xi,xj) = exp(-r||xi - xj|| 2 ).....(5).

[0037] Compared with the prior art, the technical effects that can be achieved through the technical solution conceived by the present invention are as follows: (1) The method for optimizing hyperparameters of a network structure based on the sine-cosine algorithm (SCA) can optimize the hyperparameters of the CNN network structure, such as the learning rate, convolution kernel size, number of convolutional layers, batch size, and regularization parameter, select a suitable combination of hyperparameters, improve the efficiency of model training, and reduce the time cost.

[0038] (2) By optimizing the hyperparameters of Resnet50 with the sine-cosine algorithm (SCA), a better combination of hyperparameters can be found, improving the training effect and segmentation accuracy of the model.

[0039] (3) In the optimization process of the sine-cosine algorithm (SCA) of the present invention, K-fold cross-validation is adopted to prevent the sine-cosine algorithm from falling into local extrema, enabling the acquisition of a more efficient and accurate intelligent model, and preventing the algorithm from falling into a local optimum and being unable to quickly find the global optimum solution, thereby obtaining a more accurate prediction effect and making more effective and reasonable decisions. BRIEF DESCRIPTION OF THE DRAWINGS

[0040] In order to more clearly illustrate the technical solutions in the embodiments of the present application or related technologies, the following will briefly introduce the drawings required for use in the description of the embodiments or the prior art. Obviously, the drawings in the following description are only the embodiments of the present application. For those of ordinary skill in the art, without creative efforts, other drawings can also be obtained based on the provided drawings.

[0041] The structures, proportions, sizes, etc. shown in the drawings of this specification are only used to cooperate with the content disclosed in the specification for those familiar with this technology to understand and read, and are not used to limit the limited conditions under which the present application can be implemented. Therefore, they do not have technical substantive significance. Any modification of the structure, change of the proportional relationship, or adjustment of the size, without affecting the effects that the present application can produce and the purposes that can be achieved, should still fall within the scope that can be covered by the technical content disclosed in the present application.

[0042] Figure 1 It is a schematic diagram of the training process of the network structure of the present invention;

[0043] Figure 2 It is a schematic diagram of the SCA training process of the present invention;

[0044] Figure 3 It is a network structure diagram of Resnet50 of the present invention;

[0045] Figure 4 It is a supplementary diagram of the Resnet50 network structure of the present invention. DETAILED DESCRIPTION OF THE EMBODIMENTS

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

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

[0048] To more clearly understand the technical solution of the present application, the following will be combined with the attached Figure 1-2 The test method of the present invention will be described in detail.

[0049] As Figure 1 shown, it is a schematic diagram of the training process of the network structure of a network model parameter optimization method based on the sine-cosine algorithm (SCA) involved in the present invention. At the same time, an optimization method for a borehole image recognition model proposed based on the sine-cosine algorithm (SCA) of the present invention application is disclosed, including the following steps:

[0050] (1) Image collection; The imaging part of the image collection is composed of components such as a CCD camera and a controller. Among them, the CCD camera integrates key components such as a light source and a camera. The CCD camera is held in a pressure-resistant cylinder, and the lens is located in the upper part of the imaging section near the packer. The pressure-resistant cylinder loaded with the CCD camera is under atmospheric pressure, and its temperature is controlled by a suitable control system and / or heat insulation device. The light source is located near the packer. The light source illuminates the borehole wall, and the CCD camera synchronously captures the image information of the hole wall, collects clear and distinct pictures of the hole wall imaging. These pictures contain different response characteristics of the structural plane in the borehole image, including sine curve shape, straight line shape, open type structural plane, cracked type structural plane, etc., and a borehole image structural plane data set is established.

[0051] (2) Image cropping; Process the borehole image structural plane data set: Crop the borehole structural plane image into 512×512, and noise reduction processing is required for some images with more noise.

[0052] (3) Image annotation; Mark the pictures of the above data set in LABELME, use a polygon box to mark the structural plane, and label it with CRACK.

[0053] (4) Image preprocessing; Preprocess the borehole structural plane data set, including operations such as image scaling, grayscale conversion, normalization, etc., to meet the requirements of subsequent processing. At the same time, data augmentation techniques such as rotation, flipping, and translation can be used to increase the diversity of training data.

[0054] (5) Dataset division; divide the borehole structural plane dataset, and divide the dataset into a training set, a validation set, and a test set according to the ratio of 8:1:1 respectively.

[0055] (6) Resnet50 model; determine the input variables and output variables, and use the training set to train the Resnet50 network to complete the construction of the Resnet50 network model.

[0056] (7) Sine Cosine Algorithm (SCA) optimization; use the Sine Cosine Algorithm (SCA) to optimize the hyperparameters and thresholds of the Resnet50 network model to obtain the optimized Resnet50 network model.

[0057] (8) Optimize the Resnet50 model. Based on the samples in the test set, make predictions using the optimized Resnet50 network model to generate a prediction map and obtain the final result.

[0058] Perform SCA optimization to obtain the optimized Resnet50 model. The schematic diagram of the SCA optimization process of this invention application is as shown in the appendix Figure 2 as follows:

[0059] In step (6), select the learning rate, convolution kernel size, number of convolutional layers, batch size, and regularization parameter of the Resnet50 network as the hyperparameters to be optimized, and set the value range for each hyperparameter. Among them, the learning rate is set to 10 -6 to 10 -1 , and the convolution kernel size is between 3×3 and 7×7.

[0060] In step (7), initialize the SCA population; initialize the size of the SCA population to 50, and randomly generate a set of initial solutions in the hyperparameter space, where each solution represents a set of hyperparameter combinations.

[0061] K-fold cross-validation; select the validation set accuracy of the model as the fitness function to evaluate the performance of the hyperparameter combination, and at the same time use K-fold cross-validation to verify the model.

[0062] Update the individual position; update the position of each individual according to the periodic oscillation characteristics of the sine and cosine functions.

[0063] Calculate the fitness value of the individual; update the individuals in the population according to the fitness value, and select the individual with the highest fitness value in each iteration as the current optimal solution.

[0064] Specifically, the SCA-Resnet50 model designs a convolutional neural network model structure, including an input layer, a convolutional layer, a pooling layer, a fully connected layer, and an output layer; wherein the convolutional layer and the pooling layer are arranged in an alternating manner; initialize the SCA algorithm parameters, where the hyperparameters in the convolutional neural network structure include weights, thresholds, and biases, which are used as the number of particle dimensions in the particle swarm algorithm and are arranged in order; randomly generate m particles, each particle serving as the initial parameters of the convolutional neural network structure, input the training set into the convolutional neural network model, and use the model predicted image structural plane data and the mean square error as the fitness function of the particle swarm algorithm; set the number of iterations, and when the iteration is completed, the globally optimal particle found by the SCA algorithm is the optimal initial parameter of the model: weights, thresholds, and biases; assign the values of each dimension of the globally optimal particle position to the weights, thresholds, and biases of the convolutional neural network model in order; train the model, set the loss function as the mean root square error function, and determine whether the required accuracy is met; use the test set data to evaluate the performance of the SCA-Resnet50 model.

[0065] Among them, the Resnet50 network structure diagram can be referred to in the appendix Figure 3 The Resnet50 network structure diagram of the present invention and the appendix Figure 4 The network model structure of the Resnet50 network structure supplementary diagram is executed.

[0066] According to the periodic oscillation characteristics of the sine and cosine functions, set the initial individual weights:

[0067]

[0068] Among them, Nodein and Nodeout respectively represent the number of input and output nodes of each layer;

[0069] Step S7.1: Determine whether it is the first iteration. If so, directly calculate the fitness fi of each point Mi. Otherwise, first merge the latest population position M with the historical optimal population position F, then calculate its fitness fi, and sort the fitness fi of each point i from largest to smallest, and select the first N population positions as the historical optimal position F;

[0070] Step S7.2: Screen out the points among the N points whose fitness is greater than the fitness of the optimal point and whose fitness is the largest, replace the optimal point Pbest with the currently screened point with the largest fitness, and further assign the current point position to the best population position Best_pos; calculate the accuracy ACC of the support vector machine according to the internal K-fold cross-validation strategy in formula (2).

[0071]

[0072] Among them, acck represents the accuracy calculated on each fold of data;

[0073] Step S7.3: To perform development and exploration stably, adaptively change the sine and cosine ranges of the individual weights in Formula (1) using Formula (3):

[0074]

[0075] where t is the current iteration, T is the maximum number of iterations, and a is a constant;

[0076] Step S7.4: Determine whether the maximum number of iterations T is exceeded; if not, jump to Step S7.2; if so, execute the next Step S7.5;

[0077] Step S7.5: Output the position Best_pos of the optimal population Pbest and its corresponding fitness;

[0078] Step S7.6: Construct a prediction model shown in the following Formula (4), and classify and predict the samples to be classified based on the constructed prediction model; where K(xi, xj) is shown in Formula (5); xj represents the j-th normalized sample data; xi (i = 1...l) represents the training samples; yi (i = 1...l) represents the labels corresponding to the training samples, yi = 1 represents the positive class samples, and yi = -1 represents the negative class samples; b is the threshold; αi is the Lagrange coefficient;

[0079]

[0080] K(xi,xj) = exp(-r||xi - xj|| 2 )(5).

[0081] In the optimization process of the Sine Cosine Algorithm (SCA), the present invention adopts K-fold cross-validation to prevent the Sine Cosine Algorithm from falling into local extrema, can obtain a more efficient and accurate intelligent model, and can also prevent the algorithm from falling into local optimality and being unable to quickly find the global optimal solution, so as to obtain a more accurate prediction effect and make a more effective and reasonable decision.

[0082] Finally, the optimized Resnet50 model is obtained by combining the optimized hyperparameter combinations.

[0083] It should be noted that according to the needs of implementation, the various steps / components described in the present application can be split into more steps / components, or two or more steps / components or partial operations of steps / components can be combined into new steps / components to achieve the purpose of the present invention.

[0084] The foregoing description of the disclosed embodiments enables those skilled in the art to implement or use the present application. Various modifications to these embodiments will be apparent to those skilled in the art, and the general principles defined herein can be implemented in other embodiments without departing from the spirit or scope of the present application. Therefore, the present application is not intended to be limited to the embodiments shown herein, but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.

Claims

1. An intelligent recognition algorithm for drilling images, characterized in that: The steps include: (1) Image collection: The imaging part of the image collection is composed of components such as a CCD camera and a controller, wherein the CCD camera integrates key components such as a light source and a camera. The CCD camera is held in a pressure-resistant cylinder, and the lens is located at the upper part of the imaging section near the packer. The pressure-resistant cylinder carrying the CCD camera is under atmospheric pressure, and its temperature is controlled by a suitable control system and / or insulation device. The light source is located near the packer, and the light source illuminates the borehole wall. The CCD camera synchronously captures the borehole wall image information, and collects clear and distinct images of the borehole wall. These images contain different response characteristics of the structural surface in the borehole image, including sinusoidal curve shape, straight line shape, open structural surface, cracked structural surface, etc., to establish a borehole image structural surface dataset; (2) Image cropping: Processing the borehole image structure surface dataset: crop the borehole structure surface image into 512×512, and perform noise reduction on some images with high noise; (3) Image annotation: Label the images of the above dataset in LABELME, use polygonal boxes to mark the structural surfaces, and add the label CRACK; (4) Image preprocessing; Preprocess the borehole structural surface dataset, including image scaling, grayscale, normalization, and other operations, and use data enhancement techniques such as rotation, flipping, or translation to increase the diversity of training data; (5) Dataset division: The borehole structural surface dataset is divided into a training set, a validation set, and a test set in a ratio of 8:1:1; (6) Resnet50 model: Determine the input variables and output variables, use the training set to train the Resnet50 network, and complete the construction of the Resnet50 network model; (7) Sine-cosine algorithm (SCA) optimization: The sine-cosine algorithm (SCA) is used to optimize the hyperparameters and thresholds of the Resnet50 network model to obtain the optimized Resnet50 network model; (8) Optimize the CNN model based on the samples of the test set, make predictions based on the optimized Resnet50 network model, generate a prediction graph and obtain the final result.

2. The drilling image intelligent recognition algorithm according to claim 1, characterized in that: In step (6), the learning rate, convolution kernel size, number of convolution layers, batch size, and regularization parameter of the Resnet50 network are selected as the hyperparameters to be optimized, and the value range is set for each hyperparameter. The learning rate is set to 10 -6 to 10 -1 , the convolution kernel size is between 3×3 and 7×7.

3. The drilling image intelligent recognition algorithm according to claim 1, characterized in that: In step (7), the SCA population is initialized; the size of the initialized SCA population is 50, and a set of initial solutions is randomly generated in the hyperparameter space, where each solution represents a set of hyperparameter combinations.

4. The drilling image intelligent recognition algorithm according to claim 3, characterized in that: It also includes K-fold cross validation; the validation set accuracy of the model is selected as the fitness function to evaluate the performance of the hyperparameter combination, and K-fold cross validation is used to validate the model.

5. The drilling image intelligent recognition algorithm according to claim 3, characterized in that: It also includes updating individual positions; updating the position of each individual according to the periodic oscillation characteristics of the sine and cosine functions; calculating the fitness value of the individual; updating the individuals in the population according to the fitness value, and selecting the individual with the highest fitness value in each iteration to determine it as the current optimal solution.

6. The drilling image intelligent recognition algorithm according to claim 3, characterized in that: In step (7), the SCA-Resnet50 model designs a convolutional neural network model structure, including an input layer, a convolutional layer, a pooling layer, a fully connected layer and an output layer; wherein the convolutional layer and the pooling layer are arranged in an alternating manner; the SCA algorithm parameters are initialized, wherein the hyperparameters in the convolutional neural network structure include weights, thresholds and biases, which are used as the number of particle dimensions in the particle swarm algorithm and are arranged in order; m particles are randomly generated, each particle is used as the initial parameter of the convolutional neural network structure, the training set is input into the convolutional neural network model, and the model predicts the image structure surface data and the mean square error as the fitness function of the particle swarm algorithm; the number of iterations is set, and when the iteration is completed, the global optimal particle found by the SCA algorithm is the optimal initialization parameter of the model: weights, thresholds and biases; the value of each dimension of the global optimal particle position is assigned to the weights, thresholds and biases of the convolutional neural network model in order; Train the model, set the loss function to the mean root square error function, and determine whether it meets the required accuracy; use the test set data to evaluate the performance of the SCA-CNN model.

7. The drilling image intelligent recognition algorithm according to claim 6, characterized in that: According to the periodic oscillation characteristics of sine and cosine functions, the initial individual weights are set: Among them, Nodein and Nodeout represent the number of input and output nodes in each layer respectively.

8. The drilling image intelligent recognition algorithm according to claim 6, characterized in that: In step (7), the hyperparameter and threshold optimization includes: step S7.1, judging whether it is the first iteration, if so, directly calculating the fitness fi of each point Mi, otherwise first merging the latest population position M with the historical optimal population position F, and then calculating its fitness fi, and sorting the fitness fi of each point i from large to small, selecting the first N population positions as the historical optimal position F; step S7.2, screening out the fitness of the N points that are greater than the fitness of the optimal point and have the largest fitness, replacing the optimal point Pbest with the currently screened point with the largest fitness, and further assigning the current point position to the best population position Best_pos; it calculates the accuracy ACC of the support vector machine according to formula (2) with an internal K-fold cross-validation strategy; Among them, acck represents the accuracy calculated on each fold of data; Step S7.3: In order to develop and explore stably, use formula (3) to adaptively change the sine and cosine ranges of the individual weights in formula (1): Where t is the current iteration, T is the maximum number of iterations, and a is a constant; Step S7.4, determine whether the maximum number of iterations T is exceeded; if not, jump to step S7.2; if yes, execute the next step S7.5; Step S7.5, output the position Best_pos of the optimal population Pbest and its corresponding fitness; Step S7.6, construct the prediction model shown in the following formula (4), and classify and predict the samples to be classified based on the constructed prediction model; wherein K(xi, xj) is as shown in formula (5); xj represents the jth normalized sample data; xi(i=1...l) represents the training sample; yi(i=1...l) represents the label corresponding to the training sample, yi=1 represents the positive sample, yi=-1 represents the negative sample; b is the threshold; αi is the Lagrangian coefficient; K(xi,xj)=exp(-r||xi-xj|| 2 )....(5)。

Citation Information

Patent Citations

  • Method for constructing prediction model based on improved sine and cosine algorithm

    CN111079074A

  • Machine tool bearing state recognition method for optimizing convolutional neural network based on sine and cosine algorithm

    CN112699792A

  • TransUNet-based rock slice image granularity identification method, electronic equipment and storage medium

    CN116543256A

  • Intelligent surrounding rock fracture identification method based on borehole peeping

    CN117392548A

  • Drilling image-based rock mass fracture zone rapid identification method and device, and storage medium

    CN118397399A