Multi-modal volcanic rock fine-grained lithology identification method and system based on temperature scaling probability calibration
By independently training image expert networks and well logging expert networks and calibrating temperature scaling probabilities, the problems of multiple solutions and overconfidence in fine-grained lithology identification in deep volcanic reservoir exploration are solved, achieving high-precision and low-cost lithology identification, suitable for exploration scenarios with small samples and limited resources.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- LIAONING TECHNICAL UNIVERSITY
- Filing Date
- 2026-05-25
- Publication Date
- 2026-07-14
AI Technical Summary
In the exploration of deep volcanic rock reservoirs, existing technologies cannot simultaneously acquire macroscopic rock physics information and microscopic mineral structure information using single-mode methods. This leads to multiple solutions and uncertainties in the identification of fine-grained volcanic rocks. Decision-level fusion methods suffer from decreased accuracy under low signal-to-noise ratio and imbalance conditions, and have a large number of parameters and high computational costs, making it difficult to meet the needs of rapid deployment.
A multimodal volcanic rock fine-grained lithology identification method based on temperature scaling probability calibration is adopted. The features of rock thin section images and well logging data are extracted by image expert network and well logging expert network respectively. After independent training, temperature scaling and probability distribution transformation are performed, and finally weighted summation is performed to obtain the final lithology prediction result.
It achieves multimodal information complementarity, overcomes the problem of multiple solutions in single-modal recognition, improves recognition accuracy, solves the overconfidence problem of deep neural networks, reduces computational costs, and is suitable for rapid deployment in scenarios with small samples and limited resources.
Smart Images

Figure CN122388946A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of interdisciplinary technology of artificial intelligence and geophysical exploration, and in particular to a method and system for identifying fine-grained lithology of multimodal volcanic rocks based on temperature scaling probability calibration. Background Technology
[0002] In deep volcanic reservoir exploration, lithology identification is fundamental to reservoir evaluation. With the development of artificial intelligence technology, utilizing multimodal data fusion to improve lithology identification accuracy has become a research hotspot. However, existing technologies still have many shortcomings:
[0003] Early single-modal methods, such as well logging identification based on support vector machines or random forests and core image classification based on convolutional neural networks, rely on only a single data source and cannot simultaneously acquire macroscopic rock physical information and microscopic mineral structure information, resulting in inherent ambiguity and uncertainty in fine-grained (e.g., 18 categories) volcanic rock identification.
[0004] The decision-level fusion method improves the recognition effect to some extent by weighting and fusing the probabilities of the dual-channel outputs of conventional logging and elemental logging. However, its second modality only contains chemical composition data and lacks visual information such as mineral morphology and pore structure, making it difficult to distinguish fine-grained subclasses. Furthermore, it directly uses uncalibrated Softmax probabilities for fusion, which is affected by the "overconfidence" problem of deep neural networks. High-confidence erroneous predictions will dominate the final decision, resulting in poor fusion reliability.
[0005] Current mainstream feature-level fusion methods, through cross-attention mechanisms, perform cross-modal feature interactions at deep layers. While these methods can uncover complex correlations, they are prone to overfitting to spurious statistical relationships in training data under geological conditions such as low signal-to-noise ratios in well logging data and extreme imbalance in lithological samples (some lithologies have only two thin section images). This leads to a significant drop in accuracy during cross-regional blind well prediction and severely insufficient generalization ability. Furthermore, these methods still do not address the issue of unreliable probability outputs, and their large parameter count and high computational cost make them unsuitable for rapid field deployment.
[0006] Therefore, there is an urgent need for a multimodal volcanic rock fine-grained lithology identification method that can guarantee recognition accuracy and generalization ability under small sample and low signal-to-noise ratio conditions, and output reliable confidence. Summary of the Invention
[0007] To address the aforementioned issues, this invention proposes a multimodal volcanic rock fine-grained lithology identification method and system based on temperature scaling probability calibration.
[0008] To achieve the above objectives, the present invention employs the following technical solution:
[0009] A multimodal volcanic rock fine-grained lithology identification method based on temperature scaling probability calibration includes:
[0010] Well logging data and corresponding thin section images of rocks were collected, preprocessed, and then divided into training and validation sets.
[0011] An image expert network is used to extract features from the preprocessed thin section rock image to obtain an image feature vector, and an unnormalized image prediction value is output based on the image feature vector. A well logging expert network is used to encode features from the preprocessed well logging data to obtain a well logging feature vector, and an unnormalized well logging prediction value is output based on the well logging feature vector.
[0012] Based on the training set, the image expert network and the well logging expert network were trained independently. Based on the validation set, image temperature parameters and well logging temperature parameters were fitted to the trained image expert network and well logging expert network, respectively. After temperature scaling, the unnormalized image prediction values and unnormalized well logging prediction values were converted into image probability distribution and well logging probability distribution.
[0013] The image probability distribution and the well logging probability distribution are weighted and summed to obtain a fused probability distribution. The volcanic rock lithology category with the highest predicted probability value in the fused probability distribution is selected as the final volcanic rock lithology prediction result.
[0014] As a preferred embodiment of the present invention, the well logging data includes: natural gamma curve, compensated neutron curve, density curve, sonic transit time curve and deep lateral resistivity curve; the rock thin section images include: single-polarized thin section images and orthogonally polarized thin section images.
[0015] As a preferred embodiment of the present invention, the preprocessing includes: applying robust standardization to the well logging data, i.e., standardizing by subtracting the median and dividing by the interquartile range; adjusting the resolution of the rock thin section image to 224×224 pixels and standardizing it using the mean and variance of the ImageNet dataset; and performing data augmentation operations, including random cropping and horizontal flipping, on the minority class samples in the 18 types of volcanic rocks where the number of samples is less than a preset threshold.
[0016] As a preferred embodiment of the present invention, based on the preprocessed well logging data and the corresponding rock thin section images, a grouped five-fold cross-validation strategy is adopted, and the training set and validation set are divided by physical sampling points as the grouping unit, so that the single-polarized thin section images and orthogonal polarized thin section images of the same physical sampling point are divided into the same training set or validation set.
[0017] As a preferred embodiment of the present invention, the step of using an image expert network to extract features from the preprocessed rock thin section image to obtain an image feature vector, and outputting an unnormalized image prediction value based on the image feature vector, includes:
[0018] The image expert network consists of a backbone feature extraction subnetwork and a fully connected classification subnetwork.
[0019] The backbone feature extraction subnetwork uses ResNet-34 pre-trained on the ImageNet dataset as its backbone structure, and freezes the shallow parameter region to preserve general texture edge features; after thawing the deep parameter region, fine-tuning is performed to learn the crystal fragments, glass fragments, and vesicular structure features of volcanic rocks; the preprocessed rock thin section image is input into the backbone feature extraction subnetwork, and the deep feature map of the image is output and compressed into an image feature vector by global average pooling;
[0020] The fully connected classification subnetwork consists of a fully connected classification layer and outputs unnormalized image prediction values based on the image feature vector.
[0021] As a preferred embodiment of the present invention, the step of using a logging expert network to perform feature encoding on the preprocessed logging data to obtain a logging feature vector, and outputting an unnormalized logging prediction value based on the logging feature vector, includes:
[0022] The well logging expert network consists of a well logging feature coding subnetwork and a linear classification subnetwork;
[0023] The well logging feature coding subnetwork uses a multilayer perceptron as the encoder, and each MLP layer consists of a fully connected layer, layer normalization, and ReLU activation function in sequence. After the preprocessed well logging data is mapped layer by layer by the two MLP layers of the encoder, the well logging feature vector is output.
[0024] The linear classification subnetwork consists of a fully connected linear classification layer, which outputs unnormalized well logging predictions based on well logging feature vectors.
[0025] As a preferred embodiment of the present invention, an adaptive moment estimation optimizer with decoupled weight decay and a weighted cross-entropy loss function are used to train the image expert network and the well logging expert network independently, respectively. The weights of each volcanic rock lithology category in the weighted cross-entropy loss function are set according to the inverse ratio of the number of samples of each volcanic rock lithology category in the training set, and an early stopping strategy is set during training.
[0026] As a preferred embodiment of the present invention, the step of fitting image temperature parameters and well logging temperature parameters to the trained image expert network and well logging expert network based on the validation set, respectively, and converting the unnormalized image prediction values and unnormalized well logging prediction values into image probability distributions and well logging probability distributions after temperature scaling, includes:
[0027] By minimizing the negative log-likelihood loss, image temperature parameters and well logging temperature parameters are fitted to the image expert network and well logging expert network respectively, and optimization is performed only on the validation set;
[0028] The temperature scaling is achieved by dividing the unnormalized image prediction value by the image temperature parameter, and by dividing the unnormalized well logging prediction value by the well logging temperature parameter.
[0029] After dividing the unnormalized image prediction value by the image temperature parameter, it is converted into a calibrated image probability distribution using the Softmax function, as expressed by:
[0030]
[0031] In the formula, For the image probability distribution, These are the predicted values for the unnormalized image. For image temperature parameters;
[0032] After dividing the unnormalized logging prediction by the logging temperature parameter, the result is converted into a calibrated logging probability distribution using the Softmax function. The expression is as follows:
[0033]
[0034] In the formula, Well logging probability distribution These are unnormalized well logging predictions. These are logging temperature parameters.
[0035] As a preferred embodiment of the present invention, the step of weighted summing of the image probability distribution and the well logging probability distribution to obtain a fused probability distribution, and selecting the volcanic rock lithology category with the highest predicted probability value in the fused probability distribution as the final volcanic rock lithology prediction result, includes:
[0036] Based on the learnable weight parameters obtained through optimization on the validation set, the image probability distribution and the well logging probability distribution are weighted and summed to obtain the fused probability distribution, expressed as:
[0037]
[0038] In the formula, For the fusion probability distribution, These are learnable weight parameters;
[0039] After performing the Argmax operation on the fusion probability distribution, the volcanic rock lithology category with the highest predicted probability value in the fusion probability distribution is selected as the final volcanic rock lithology prediction result.
[0040] A multimodal volcanic rock fine-grained lithology identification system based on temperature scaling probability calibration includes:
[0041] The acquisition and preprocessing module is used to acquire well logging data and corresponding thin rock images, and after preprocessing, divide them into training and validation sets;
[0042] The expert network module is used to extract features from the preprocessed rock thin section image using an image expert network to obtain an image feature vector, and output unnormalized image prediction values based on the image feature vector; and to encode the preprocessed logging data using a logging expert network to obtain a logging feature vector, and output unnormalized logging prediction values based on the logging feature vector.
[0043] The temperature scaling module is used to independently train the image expert network and the well logging expert network based on the training set; and based on the validation set, it fits image temperature parameters and well logging temperature parameters to the trained image expert network and well logging expert network respectively. After temperature scaling, the unnormalized image prediction values and unnormalized well logging prediction values are converted into image probability distribution and well logging probability distribution.
[0044] The weighted fusion module is used to sum the image probability distribution and the well logging probability distribution in a weighted manner to obtain a fused probability distribution, and select the volcanic rock lithology category with the highest predicted probability value in the fused probability distribution as the final volcanic rock lithology prediction result.
[0045] The beneficial effects of this invention are as follows: By independently extracting the microscopic visual features of rock thin sections and the macroscopic physical features of well logging from the image expert network and the well logging expert network respectively, and performing probabilistic fusion at the decision layer, multimodal information complementarity is achieved, effectively overcoming the problem of strong ambiguity in the identification of 18 types of fine-grained volcanic rocks by a single modality, and significantly improving the identification accuracy. By fitting temperature parameters to the two expert networks on the validation set and performing temperature scaling, the original output is converted into a calibrated probability distribution, effectively solving the "overconfidence" problem commonly found in deep neural networks. This ensures that subsequent weighted fusion is based on reliable probabilities that truly reflect the model's confidence, and can still make correct judgments when there is a conflict between image and well logging modality predictions. The image expert network and the well logging expert network are trained independently and decoupled, avoiding the risk of overfitting caused by deep feature interactions. This allows each expert network to learn independent and effective geological features, maintaining a stable high accuracy rate even in cross-regional and cross-well blind well prediction scenarios. By adopting a decision-level fusion mechanism rather than a complex feature-level cross-attention mechanism, the two expert networks can be trained independently and in parallel. With fewer parameters and faster training and inference speeds, they are more suitable for the rapid deployment needs of large-scale well logging data processing and scenarios with limited on-site computing resources. Attached Figure Description
[0046] To more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings used in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort. Wherein: Figure 1 This is a flowchart of the method in an embodiment of the present invention; Figure 2 This is a schematic diagram illustrating the application scenario of multimodal volcanic rock lithology identification in the target well section according to an embodiment of the present invention; Figure 3 This is a system structure diagram in an embodiment of the present invention. Detailed Implementation
[0047] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of the present invention. All other embodiments obtained by those skilled in the art based on the described embodiments of the present invention are within the scope of protection of the present invention.
[0048] like Figures 1-2 As shown, this is an embodiment of the present invention, which provides a multimodal volcanic rock fine-grained lithology identification method based on temperature scaling probability calibration, including:
[0049] S1. Collect well logging data and corresponding thin rock section images, and after preprocessing, divide them into training and validation sets.
[0050] In this embodiment, the logging data includes: natural gamma curve, compensated neutron curve, density curve, sonic transit time curve, and deep lateral resistivity curve; the rock thin section images include: single-polarized thin section images and orthogonally polarized thin section images.
[0051] Specifically, from the completion logging data of the target exploration block, five conventional logging curves with the strongest sensitivity to volcanic lithology were extracted. All logging curves were then depth-aligned to ensure that the five logging curves at the same depth point corresponded to the same core sampling location. The collected logging curves are as follows:
[0052] Natural gamma curve (GR), compensated neutron curve (CNL), density curve (DEN), acoustic transit time curve (AC), and deep lateral seropotency curve (RLA5).
[0053] Preliminary quality control was performed on the collected logging curves, and well sections with severe mud intrusion and data loss exceeding 10% were removed. For local missing points on a single logging curve, linear interpolation of three adjacent valid data points was used to complete the curve.
[0054] Corresponding one-to-one with the well logging data depth, thin section micrographs of rock samples from the same depth are acquired. For each physical sampling point, images in two polarization modes must be acquired simultaneously. Specifically:
[0055] Single-polarized thin section images are used to observe the color, crystal form, cleavage, and rock structure of minerals; cross-polarized thin section images are used to observe the optical characteristics of minerals, such as interference colors, twinning, and extinction types.
[0056] Image acquisition uses uniform microscope parameter settings to ensure that the magnification, light intensity, and exposure time of all images are consistent; the original images are saved in a lossless format, such as TIFF, to avoid compression distortion.
[0057] The preprocessing includes: applying robust standardization to the well logging data, i.e., standardizing by subtracting the median and dividing by the interquartile range; adjusting the resolution of the rock thin section image to 224×224 pixels and standardizing it using the mean and variance of the ImageNet dataset; and performing data augmentation operations, including random cropping and horizontal flipping, on the minority class samples in the 18 types of volcanic rocks where the number of samples is less than a preset threshold.
[0058] Specifically, a robust normalization method is used to normalize the logging data. This robust normalization method is insensitive to outliers and can effectively suppress the interference of outliers such as clay interlayers and casing effects in the logging curves. The specific operation steps are as follows:
[0059] Using only the training set data, statistics were calculated for each logging curve separately, specifically:
[0060] Calculate the median of all samples of the corresponding logging curve in the training set, and calculate the upper quartile and lower quartile of all training samples of the logging curve to obtain the interquartile range; perform standardization calculation for each data point of the logging curve in the training and validation sets, as shown in the expression:
[0061]
[0062] In the formula, For standardized well logging data, The raw well logging data, This is the median of all samples corresponding to the well logging curves in the training set. The interquartile range is the corresponding logging curve within the training set.
[0063] The validation set is standardized using the median and interquartile range calculated from the training set, without using the validation set's own statistics, in order to prevent data leakage.
[0064] Perform a uniform preprocessing operation on all single-polarized and cross-polarized thin-film images, specifically:
[0065] Bilinear interpolation was used to uniformly adjust all rock thin section images to a fixed resolution of 224×224 pixels, linearly mapping the pixel range of the rock thin section images from integers 0-255 to floating-point numbers 0-1. Standardization was performed using the predefined RGB channel mean and variance from the ImageNet dataset. The calculation formula is as follows:
[0066]
[0067] In the formula, For the standardized rock thin section image Pixel values of image channels The first image of the original rock thin section Pixel values of image channels For the ImageNet dataset, the first Predefined pixel mean of image channels, For the ImageNet dataset, the first Predefined pixel standard deviation of image channels; This is the image channel index, and its specific values are:
[0068] Red image channel: , ;
[0069] Green image channel: , ;
[0070] Blue image channel: , .
[0071] To address the issue of extremely imbalanced sample distribution across 18 types of volcanic rocks, data augmentation was performed only on a minority of samples in the training set, while no augmentation was applied to the validation and test sets. Specifically:
[0072] The sample size of each of the 18 volcanic rock lithologies in the training set was statistically analyzed, and a sample size threshold was set. In this embodiment, the threshold was 10, which can be flexibly adjusted according to the sample distribution characteristics of different datasets. Lithology categories with fewer than this threshold were marked as minority classes, and the following two enhancement operations were performed on the thin section images of the minority classes:
[0073] A 200×200 pixel region is randomly cropped from the original 224×224 pixel image, and then adjusted back to 224×224 pixels using bilinear interpolation. Each image is also horizontally flipped with a probability of 0.5.
[0074] After data augmentation, the number of minority class samples is expanded to a ratio of no less than 1:5 with the number of majority class samples, mitigating the impact of sample imbalance on model training.
[0075] Based on the preprocessed well logging data and the corresponding rock thin section images, a grouped five-fold cross-validation strategy is adopted, and the training set and validation set are divided by physical sampling points as the grouping unit, so that single-polarized thin section images and orthogonal polarized thin section images of the same physical sampling point are assigned to the same training set or validation set.
[0076] Specifically, a grouped five-fold cross-validation strategy using physical sampling points as the grouping unit is adopted to prevent data leakage at the source and ensure the authenticity and reliability of the evaluation results. The specific steps are as follows:
[0077] Each physical sampling point is defined as an indivisible minimum group. Each group contains 5 logging curves, single-polarized thin-slice images and orthogonal-polarized thin-slice images corresponding to that physical sampling point, ensuring that all data from the same physical sampling point are not split into different training or validation sets.
[0078] For multiple physical sampling points with consistent lithology and continuous depth within the same well, they are merged into a larger group to prevent data from being split across sets for the same continuous geological body; all groups are then randomly shuffled and divided into 5 non-overlapping subsets with balanced sample sizes.
[0079] In each round of cross-validation, four subsets are selected as the training set and the remaining subset is selected as the validation set. This process is repeated for five rounds, ensuring that each subset has one and only one opportunity to be used as the validation set. Additionally, all data from a cross-regional independent well that did not participate in the above grouping is selected as an independent test set. The data from this independent test set is used only to evaluate the cross-regional generalization ability.
[0080] S2. An image expert network is used to extract features from the preprocessed thin section rock image to obtain an image feature vector, and an unnormalized image prediction value is output based on the image feature vector; a well logging expert network is used to encode features from the preprocessed well logging data to obtain a well logging feature vector, and an unnormalized well logging prediction value is output based on the well logging feature vector.
[0081] In this embodiment, the image expert network consists of a backbone feature extraction subnetwork and a fully connected classification subnetwork. The backbone feature extraction subnetwork uses ResNet-34 pre-trained on the ImageNet dataset as its backbone structure, and freezes the shallow parameter region to preserve general texture edge features. After thawing the deep parameter region, fine-tuning is performed to learn the crystal fragments, glass fragments, and vesicular structure features of volcanic rocks. The preprocessed rock thin section image is input into the backbone feature extraction subnetwork, which outputs the deep feature map of the image and compresses it into an image feature vector through global average pooling. The fully connected classification subnetwork consists of a fully connected classification layer and outputs unnormalized image prediction values based on the image feature vector.
[0082] Specifically, the image expert network consists of a backbone feature extraction subnetwork and a fully connected classification subnetwork cascaded together. The input is a preprocessed rock thin section image, and the output is the unnormalized image prediction value.
[0083] We use ResNet-34, which is pre-trained on the ImageNet dataset, as the basic backbone structure. This basic backbone structure performs stably on general image feature vector extraction tasks and has a moderate number of parameters, making it suitable for small sample fine-tuning scenarios.
[0084] The shallow parameter region is frozen by setting `requires_grad` to False for all parameters of the ResNet-34's conv1 layer (the first 7×7 convolutional layer), layer1 layer (three residual blocks), and layer2 layer (four residual blocks), including convolutional layer weights and biases, as well as the running mean, running variance, scaling factor, and offset of all batch normalized layers. This operation preserves the learned general textures, edges, contours, and other basic visual features, preventing the destruction of these features in small sample sizes. `requires_grad` is a boolean attribute of all tensors in PyTorch, specifically controlling whether the gradient of this tensor is calculated during backpropagation.
[0085] Unfreezing the deep parameter region involves setting `requires_grad` to `True` for all parameters in ResNet-34's layer 3 (6 residual blocks) and layer 4 (3 residual blocks), allowing updates during training. This operation enables the learning of unique microscopic visual features specific to volcanic rocks, such as crystal morphology, glass fragment distribution, pore structure, and cementation type.
[0086] Load the ResNet-34ImageNet pre-trained weights provided by PyTorch, ensuring that the weights are loaded completely without missing layers or parameter mismatch issues.
[0087] The forward propagation process of the backbone feature extraction subnetwork is as follows:
[0088] Input the preprocessed rock thin section image with dimensions Batch×3×224×224, where Batch is the batch size for training or inference, 3 represents the three RGB image channels, and 224×224 is the fixed resolution of the preprocessed image.
[0089] The rock thin section image is propagated forward layer by layer through conv1, max pooling, layer1, layer2, layer3, and layer4 to output a deep feature map with dimensions of Batch×512×7×7, where 512 is the number of output channels of layer4 and 7×7 is the spatial size of the deep feature map.
[0090] A global average pooling operation is performed on the aforementioned deep image feature map. This involves calculating the arithmetic mean of all spatial elements for each image channel, compressing the two-dimensional deep image feature map into a one-dimensional feature vector, and outputting a 512-dimensional image feature vector with a dimension of Batch×512. This operation avoids the risks of parameter explosion and overfitting that can occur when flattening feature maps using fully connected layers.
[0091] The forward propagation of the fully connected classification subnetwork is as follows:
[0092] The fully connected classification subnetwork consists of a single fully connected layer with an input dimension of 512 and an output dimension of 18, corresponding to the 18 categories of fine-grained volcanic rock lithology defined in this invention.
[0093] The weights of the fully connected layer are initialized uniformly using Xavier, and the bias is initialized to 0. The 512-dimensional image feature vector output by global average pooling is input into the fully connected layer, and the unnormalized image prediction value is output.
[0094] The well logging expert network consists of a well logging feature encoding subnetwork and a linear classification subnetwork. The well logging feature encoding subnetwork uses a multilayer perceptron as the encoder, and each MLP layer consists of a fully connected layer, layer normalization, and ReLU activation function in sequence. After the preprocessed well logging data is mapped layer by layer by the two MLP layers of the encoder, the well logging feature vector is output. The linear classification subnetwork consists of a linear fully connected classification layer, which outputs unnormalized well logging prediction values based on the well logging feature vector.
[0095] Specifically, the well logging expert network consists of a well logging feature coding subnetwork and a linear classification subnetwork cascaded together. The input is preprocessed well logging data, and the output is unnormalized well logging predictions, including:
[0096] A two-layer multilayer perceptron (MLP) is used as the well logging feature encoder. Each MLP layer is cascaded in the order of fully connected layer → layer normalization (LayerNorm) → ReLU activation function. This structure has a strong ability to capture nonlinear patterns in well logging data, and layer normalization is robust to small batch sizes, outperforming batch normalization.
[0097] The first layer of MLP has an input dimension of 5, corresponding to 5 lithology-sensitive logging curves: natural gamma curve, compensated neutron curve, density curve, sonic transit time curve, and deep lateral resistivity curve; the output dimension is 64.
[0098] The second-layer MLP has an input dimension of 64 and an output dimension of 128.
[0099] The weights of all fully connected layers are uniformly initialized using He, which adapts to the characteristics of the ReLU activation function and alleviates the gradient vanishing problem; the biases of all fully connected layers are initialized to 0; the scaling factor of all normalized layers is initialized to 1, and the offset is initialized to 0.
[0100] The forward propagation process of the well logging feature coding subnetwork is as follows:
[0101] The first layer of MLP forward propagation is as follows:
[0102] The input 5-dimensional well logging data first passes through the first fully connected layer, which maps it to a 64-dimensional intermediate vector. Layer normalization is then performed on the 64-dimensional intermediate vector to normalize the feature dimensions of each sample, stabilizing the training process and accelerating convergence. After introducing a nonlinear transformation through the ReLU activation function, the result of the first layer MLP is output, with a dimension of Batch×64.
[0103] The second-layer MLP forward propagation is as follows:
[0104] The 64-dimensional output of the first MLP layer is input into the second fully connected layer, mapping it to a 128-dimensional high-dimensional feature vector. Layer normalization and ReLU activation are then performed again, outputting the final logging feature vector with a dimension of Batch×128. This logging feature vector captures the nonlinear physical patterns related to volcanic rock lithology in the logging response.
[0105] The forward propagation of the linear classification subnetwork is as follows:
[0106] The linear classification subnetwork consists of a single linear fully connected layer with an input dimension of 128 and an output dimension of 18. The weights of this linear fully connected layer are initialized uniformly using Xavier, and the bias is initialized to 0. The 128-dimensional well logging feature vector is input into this linear fully connected layer, and the output is an unnormalized well logging prediction value with a dimension of Batch×18.
[0107] The parameters of the two expert networks are completely independent, with no shared layers or parameters. The training processes of the two expert networks are completely decoupled, each using its own optimizer and loss function for independent training without interference. The forward propagation processes of the two expert networks are completely independent; the image expert network only receives rock thin section images as input, and the logging expert network only receives logging data as input, with no cross-modal data interaction.
[0108] S3. Based on the training set, the image expert network and the well logging expert network are trained independently. Based on the validation set, image temperature parameters and well logging temperature parameters are fitted to the trained image expert network and well logging expert network, respectively. After temperature scaling, the unnormalized image prediction values and unnormalized well logging prediction values are converted into image probability distribution and well logging probability distribution.
[0109] In this embodiment, an adaptive moment estimation optimizer with decoupled weight decay and a weighted cross-entropy loss function are used to train the image expert network and the well logging expert network independently, respectively. The weights of each volcanic rock lithology category in the weighted cross-entropy loss function are set according to the inverse ratio of the number of samples of each volcanic rock lithology category in the training set, and an early stopping strategy is set during training.
[0110] Specifically, the training processes of the image expert network and the well logging expert network are completely independent and can be executed sequentially. The image expert network can be trained first, followed by the well logging expert network, or they can be trained in parallel, or simultaneously on different computing devices. During training, the parameters, gradients, and optimizer states of the two expert networks do not interfere with each other; there is no cross-network parameter transfer or gradient flow. Only the training set of the current fold obtained from the grouped five-fold cross-validation is used for model parameter updates; only the validation set of the current fold is used for loss monitoring, early stopping judgment, and learning rate adjustment. The validation set data does not participate in any parameter update process to avoid data leakage. Both expert networks use identical training hyperparameter configurations, including optimizer parameters, batch size, and maximum training epochs; only the network structure and input data differ, ensuring fairness in subsequent probability fusion.
[0111] This embodiment uses the AdamW optimizer instead of the traditional Adam optimizer. Its core advantage is decoupling weight decay from gradient updates, which more effectively prevents overfitting in deep neural networks, making it particularly suitable for the small-sample training scenarios of this invention. Specific parameter configurations are as follows:
[0112] The initial learning rate is The weight decay coefficient is The core parameter for decoupling weight decay is used to limit the L2 norm of the parameters and prevent overfitting due to excessively large parameters; the exponential decay rate of the first moment estimate is 0.9; the exponential decay rate of the second moment estimate is 0.999; the numerical stability term is... ;
[0113] For image expert networks, only parameters with requires_grad set to True are passed to the AdamW optimizer for management, i.e., the parameters of ResNet-34's layer 3 and layer 4 layers and the fully connected classifier subnetwork.
[0114] For the logging expert network, all learnable parameters, parameters of the fully connected layers of the two-layer multilayer perceptron, layer normalization parameters, and parameters of the linear classification subnetwork are all fed into the AdamW optimizer for management.
[0115] Enabling PyTorch's Automatic Mixed Precision (AMP) training, and using torch.cuda.amp.GradScaler to scale gradients, improves training speed by about 2 times while maintaining training accuracy and reducing GPU memory usage.
[0116] To address the extreme imbalance in the 18 types of volcanic rock samples, with some lithological categories containing only two thin section images (a difference of over 100 times compared to the majority class), a weighted cross-entropy loss function is employed. By increasing the loss weight for minority class samples, this approach forces greater attention to minority class identification, avoiding bias towards the majority class. The specific implementation steps are as follows:
[0117] For the current training set, count the number of samples for each of the 18 volcanic rock lithologies, calculate the initial weights for each category according to the inverse proportion of the sample count, and then perform normalization to ensure that the sum of all weights is 18. The calculation formula is:
[0118]
[0119] In the formula, Let i be the loss weight of the i-th type of volcanic rock lithology in the weighted cross-entropy loss function. Let i be the number of samples of the i-th type of volcanic rock lithology in the current training set. For the current training set, the first The number of samples of volcanic rock lithology, where i is the index of the volcanic rock lithology category. The summation traversal index is used to traverse all 18 types of volcanic rock lithology.
[0120] Use PyTorch's torch.nn.CrossEntropyLoss class to initialize the weighted cross-entropy loss function, pass the loss weights calculated above to the weight parameter, and set the reduction parameter to 'mean', which means returning the average loss of all samples in the batch.
[0121] For a batch of input data, the unnormalized predicted values output by the expert network and the corresponding lithology labels are fed into the cross-entropy loss function to directly calculate the weighted cross-entropy loss value for that batch. The lithology labels correspond one-to-one with the lithology categories, and their values range from 0 to 17.
[0122] Monitor the weighted cross-entropy loss value on the validation set of the current fold, and set the patience value to 7. If the weighted cross-entropy loss value on the validation set does not decrease after 7 consecutive training epochs, the training process is terminated early to prevent overfitting.
[0123] After each training round, if the weighted cross-entropy loss of the current validation set is the lowest value in history, then all current parameters are saved as the optimal weights; after training terminates, the optimal weights are loaded as the final training result of the expert network.
[0124] The torch.optim.lr_scheduler.ReduceLROnPlateau learning rate scheduler is used in conjunction with an early stopping strategy, specifically as follows:
[0125] Consistent with the early stopping strategy, monitor the weighted cross-entropy loss value of the validation set. The patience value is set to 3, meaning that if the weighted cross-entropy loss value of the validation set does not decrease after 3 consecutive training epochs, the current learning rate is multiplied by the decay factor.
[0126] The decay factor is set to 0.1, meaning that each time a learning rate adjustment is triggered, the learning rate becomes one-tenth of its original value.
[0127] The minimum learning rate (MinLR) is set to This is to prevent the learning rate from being too low, which would prevent further convergence.
[0128] For each fold of the grouped five-fold cross-validation, the complete training process described above is repeated to obtain five trained image expert networks and five trained well logging expert networks. The training process for each fold is completely independent, using only the training and validation set data of that fold, without using any data from other folds.
[0129] This step ultimately outputs the trained image expert network and well logging expert network for each fold under five-fold cross-validation, providing a foundation for subsequent steps.
[0130] By minimizing the negative log-likelihood loss, image temperature parameters and well logging temperature parameters are fitted to the image expert network and well logging expert network respectively, and optimization is performed only on the validation set; the temperature scaling is: dividing the unnormalized image prediction value by the image temperature parameter, and dividing the unnormalized well logging prediction value by the well logging temperature parameter.
[0131] Specifically, all parameters of the trained image expert network and well logging expert network are frozen, meaning the `requires_grad` attribute of all parameters is set to `False`, with only the temperature parameter being the sole optimizable variable. Furthermore, the fitting processes for the image temperature parameter and the well logging temperature parameter are completely independent, each optimized based on the output of its respective expert network on the validation set, without interfering with the other.
[0132] Minimizing the negative log-likelihood (NLL) loss is used as the optimization objective, and the L-BFGS optimizer is employed to fit the optimal temperature parameters. The L-BFGS optimizer offers fast convergence and high accuracy for single-parameter optimization scenarios, significantly outperforming gradient descent-based optimizers such as Adam and SGD.
[0133] The temperature parameter is initialized to a scalar of 1.0. This initial value corresponds to the original state without any temperature scaling. If the probabilistic calibration is good, the final fitted temperature parameter will be close to 1.0. If there is a significant overconfidence problem, the final temperature parameter will be greater than 1.0.
[0134] The formula for calculating the minimum negative log-likelihood loss after temperature scaling is:
[0135]
[0136] In the formula, The temperature parameter to be fitted, To verify the total number of samples, For the first The unnormalized predicted values for each sample. For the first The lithological label of each sample is an integer between 0 and 17, and each integer uniquely corresponds to one of the 18 fine-grained volcanic rock lithological categories defined in this invention. After scaling for temperature, for the first Predicted probability of lithological labels for each sample The temperature parameter is The negative log-likelihood loss value at that time.
[0137] The L-BFGS optimizer is initialized as follows:
[0138] Wrap the temperature parameter as a PyTorch tensor and set `requires_grad` to `True`, making it the only optimizable variable. Initialize the L-BFGS optimizer, passing only the temperature parameter to it for management.
[0139] Configure the core parameters of the L-BFGS optimizer as follows:
[0140] The maximum number of iterations is 1000 (sufficient to guarantee single-parameter convergence);
[0141] Function tolerance is When the change in the loss function is less than this value, the optimization is terminated early.
[0142] Gradient tolerance is When the norm of the gradient is less than this value, the optimization is terminated prematurely.
[0143] The historical size is 10, which is the number of historical gradient vectors stored by the L-BFGS algorithm;
[0144] A closure function is passed to the L-BFGS optimizer, which recalculates the loss and performs backpropagation. The specific logic of the closure function is as follows:
[0145] Clear the optimizer's gradient cache; divide the pre-collected and frozen validation set unnormalized prediction tensor by the current temperature parameter to obtain the scaled unnormalized prediction; calculate the negative log-likelihood loss between the scaled unnormalized prediction and the lithology label; perform backpropagation based on the negative log-likelihood loss to automatically calculate the partial derivative of the loss function with respect to the temperature parameter; finally, return the negative log-likelihood loss for this iteration.
[0146] Call the step() method of the L-BFGS optimizer, pass in the above closure function, and start iterative optimization. During the optimization process, the L-BFGS algorithm automatically adjusts the temperature parameters until the loss function converges or the maximum number of iterations is reached. After optimization, the value in the temperature parameter tensor is the optimal temperature parameter of the expert network.
[0147] Following the exact same process described above, image temperature parameters are obtained by fitting an image expert network, and well logging temperature parameters are obtained by fitting a well logging expert network. The fitting processes for the two temperature parameters are completely independent and do not affect each other.
[0148] After dividing the unnormalized image prediction value by the image temperature parameter, it is converted into a calibrated image probability distribution using the Softmax function, as expressed by:
[0149]
[0150] In the formula, For the image probability distribution, These are the predicted values for the unnormalized image. This refers to the image temperature parameter.
[0151] After dividing the unnormalized logging prediction by the logging temperature parameter, the result is converted into a calibrated logging probability distribution using the Softmax function. The expression is as follows:
[0152]
[0153] In the formula, Well logging probability distribution These are unnormalized well logging predictions. These are logging temperature parameters.
[0154] Specifically, when the temperature parameter is greater than 1, the output of the Softmax activation function becomes smoother, reducing confidence and alleviating the problem of overconfidence.
[0155] When the temperature parameter is equal to 1, it is equivalent to not performing any temperature scaling and outputting the original probability distribution.
[0156] When the temperature parameter is less than 1, the output of the Softmax activation function becomes sharper, increasing confidence. This situation almost never occurs in the scenario of this invention.
[0157] S4. The image probability distribution and the well logging probability distribution are weighted and summed to obtain the fused probability distribution. The volcanic rock lithology category with the highest predicted probability value in the fused probability distribution is selected as the final volcanic rock lithology prediction result.
[0158] In this embodiment, based on the learnable weight parameters obtained through optimization on the validation set, the image probability distribution and the well logging probability distribution are weighted and summed to obtain the fused probability distribution, expressed as:
[0159]
[0160] In the formula, For the fusion probability distribution, These are learnable weight parameters.
[0161] After performing the Argmax operation on the fusion probability distribution, the volcanic rock lithology category with the highest predicted probability value in the fusion probability distribution is selected as the final volcanic rock lithology prediction result.
[0162] Wherein, the fusion probability distribution is of dimension A tensor, wherein the tensor contains the first... Line 1 Column elements That is, the first The sample belongs to the first The predicted probability value for volcanic-like lithology is calculated by summing all 18 predicted probability values, with a range of (0,1). Since the probability distributions of the first two single modes have been calibrated for temperature scaling, this predicted probability value can accurately reflect the actual confidence level in identifying this lithology category.
[0163] Specifically, all parameters of the image expert network and the well logging expert network, as well as the image temperature parameter and the well logging temperature parameter, are kept completely frozen, and their requires_grad attribute is set to False. Only the weight parameter can be learned as the only optimizable variable.
[0164] The learnable weight parameters are restricted to a closed interval [0,1]. A learnable weight parameter of 0 indicates complete reliance on well logging modes for decision-making, while a learnable weight parameter of 1 indicates complete reliance on image modes. This constraint ensures that the fused weights have a clear physical meaning, representing the contribution of the image modes to the final decision. The contribution of logging modes to the final decision.
[0165] This embodiment uses the minimization of negative log-likelihood (NLL) as the optimization objective and employs an L-BFGS optimizer with boundary constraints to fit the optimal learnable weight parameters. The learnable weight parameters are initialized to a scalar of 0.5, which corresponds to a neutral state where the contribution of the image mode and the logging mode to the final decision is equal, thus avoiding an initial bias towards a certain mode that could lead to the optimization getting trapped in a local optimum.
[0166] The formula for calculating the negative log-likelihood loss after fusion is:
[0167]
[0168] In the formula, For the first The predicted probability value corresponding to the lithology label in the probability distribution of the calibrated image for each sample. For the first The predicted probability values corresponding to lithology labels in the well logging probability distribution after sample calibration. The learnable weight parameters are The negative log-likelihood loss value at that time.
[0169] The negative log-likelihood loss directly quantifies the degree of fit between the fusion probability distribution and the lithology label. By minimizing the negative log-likelihood loss on the validation set, the globally optimal learnable weight parameters are obtained, resulting in the highest overall recognition accuracy of the weighted fusion decision of image mode and well logging mode on this dataset.
[0170] The L-BFGS optimizer is initialized as follows:
[0171] The learnable weight parameters are wrapped as PyTorch tensors and requires_grad is set to True to make them the only optimizable variables. The L-BFGS optimizer with boundary constraints is initialized, and only the learnable weight parameters are passed to the L-BFGS optimizer for management.
[0172] The core parameters of the L-BFGS optimizer are configured as follows:
[0173] The maximum number of iterations is 1000; the function tolerance is... Gradient tolerance is The historical size is 10, which is the number of historical gradient vectors stored by the L-BFGS algorithm; the range of values for the learnable weight parameters is set to ensure that they are always within the [0,1] interval.
[0174] A closure function is passed to the L-BFGS optimizer. This closure function recalculates the negative log-likelihood loss and performs backpropagation. The specific logic of the closure function is as follows:
[0175] The gradient cache of the learnable weight parameters managed by the L-BFGS optimizer is cleared to avoid historical gradient accumulation interfering with the current iteration calculation. Following the weighted fusion formula of this invention, element-wise weighted summation is performed on the image probability distribution and well logging probability distribution after validation set calibration to obtain the fused probability distribution under the current weight parameters. The predicted probability value corresponding to the lithology label of each sample in the fused probability distribution is extracted to form a one-dimensional true class probability tensor. The natural logarithm of each element of the one-dimensional true class probability tensor is taken, and its arithmetic mean is calculated and then negative to obtain the negative log-likelihood loss value under the current weight parameters. Backpropagation is performed based on the above negative log-likelihood loss value to automatically calculate the partial derivative of the loss function with respect to the learnable weight parameters, and the gradient value is stored in the gradient attribute of the learnable weight parameter. The negative log-likelihood loss value of this iteration is returned for the L-BFGS optimizer to perform parameter updates and convergence judgment.
[0176] Call the `step()` method of the L-BFGS optimizer, passing in the aforementioned closure function, to begin iterative optimization. During optimization, the L-BFGS algorithm automatically adjusts the values of the learnable weight parameters within the range [0,1] until the negative log-likelihood loss converges or the maximum number of iterations is reached; after optimization, the optimal learnable weight parameters are obtained.
[0177] The Argmax operation is performed on the fusion probability distribution, which returns the index corresponding to the element with the largest predicted probability value in the fusion probability distribution. This index is the final volcanic rock lithology prediction result, corresponding to the 18 fine-grained volcanic rock lithology categories defined in this invention. At the same time, the largest predicted probability value is extracted as the confidence level of the prediction result and output.
[0178] like Figure 2 As shown, the inference chain for implementing the method of the present invention is roughly visualized, where GR, CNL, DEN, AC, and RLA5 are the natural gamma curve, compensated neutron curve, density curve, acoustic transit time curve, and deep lateral resistivity curve, respectively.
[0179] Based on a dataset from a specific region, experimental verification was conducted. Under the same data partitioning, the same single-modal expert network, and the same training protocol, the following seven baselines were compared to ensure fairness: ① Image-only expert model; ② Logs-only expert model; ③ Early Concat-MLP (feature-level direct concatenation and fusion); ④ Lightweight Transformer fusion model (TCMT); ⑤ CCA-Embedded model (classical linear joint embedding); ⑥ Cross-attention feature-level fusion model (CAFN and its controlled variant CAFN-Base); ⑦ Decision-level fusion model of this invention (LFN).
[0180] All models use the same training configuration as this invention. This experiment employs a three-pronged evaluation system: classification accuracy, probability calibration, and statistical significance test. Each indicator includes:
[0181] Classification accuracy metrics: Overall Accuracy (OA), Macro-F1, Macro-Precision, Macro-Recall, and Matthews Correlation Coefficient (MCC).
[0182] Probabilistic calibration metrics: Negative Log-Likelihood (NLL) and Expected Calibration Error (ECE, calculated based on 15 equally spaced intervals after temperature scaling).
[0183] Statistical significance test: paired t-test, significance level 0.005;
[0184] All experiments were conducted on the same physical server to avoid the impact of hardware differences on the experimental results. The specific environment configuration is as follows:
[0185] Operating system: Ubuntu 22.04 LTS 64-bit;
[0186] Central Processing Unit: Intel Core i9-13900K (24 cores, 32 threads, 3.0GHz).
[0187] Graphics processor: AMD Radeon RX 7900 XTX (24GB GDDR6 video memory);
[0188] Memory: 64GB DDR5-5600;
[0189] Deep learning framework: PyTorch 2.1.0;
[0190] Other dependent libraries: NumPy 1.24.3, Scikit-learn 1.3.0, Matplotlib 3.7.1.
[0191] 1. Performance evaluation of grouped five-fold cross-validation
[0192] The objective of this experiment is to evaluate the overall classification accuracy of the decision-level fusion model of this invention on the target dataset and to compare it with all baseline models. The experimental method involves performing 25 independent runs (5 folds × 5 seeds) on the experimental dataset according to the aforementioned unified training protocol, and calculating the classification accuracy index for each model.
[0193] The experimental results are as follows: The decision-level fusion model of this invention has an overall accuracy of 99.24%±0.14%, a macro average F1 score of 98.76%±0.31%, a macro average precision of 98.40%±0.48%, a macro average recall of 99.19%±0.13%, and a Matthews correlation coefficient of 0.9914±0.0016.
[0194] Cross-Attention Feature-Level Fusion Model (CAFN): Overall accuracy was 98.26% ± 0.31%, and macro-average F1 was 97.38% ± 0.52%. The overall accuracy of the well logging expert alone was 87.96%, the overall accuracy of the image expert alone was 64.67%, the overall accuracy of the early stitched multilayer perceptron model was 94.11%, the overall accuracy of the lightweight Transformer fusion model was 96.36%, and the overall accuracy of the CCA joint embedding model was 88.17%. Statistical significance test: Paired t-test results showed p < 0.005, indicating that the performance of the decision-level fusion model of this invention is significantly better than that of the cross-attention feature-level fusion model.
[0195] The decision-level fusion model of this invention achieves optimal values in all five classification accuracy metrics. Compared with the mainstream feature-level fusion method, the cross-attention feature-level fusion model, the overall accuracy is improved by 0.98 percentage points and the macro-average F1 score is improved by 1.38 percentage points. It effectively solves the problems of strong ambiguity in single-modality recognition and overfitting in feature-level fusion.
[0196] 2. Probabilistic Calibration Quality Assessment
[0197] The objective of this experiment is to verify the effect of the temperature scaling probabilistic calibration mechanism on improving the reliability of the model's output probability. The experimental method involves calculating the negative log-likelihood loss (NLL) and expected calibration error (ECE) for each model on the validation set.
[0198] The experimental results are as follows: The expected calibration error after temperature scaling of the decision-level fusion model of this invention is 0.018±0.003, and the negative log-likelihood loss is 0.31±0.02. The expected calibration error after temperature scaling and the negative log-likelihood loss of all comparison models are higher than those of the decision-level fusion model of this invention. Among them, the expected calibration error after temperature scaling of the cross-attention feature-level fusion model is 0.067±0.008, and the negative log-likelihood loss is 0.72±0.05.
[0199] The temperature scaling probability calibration mechanism introduced in this invention reduces the expected calibration error of the model to 0.018, which is significantly better than all the comparison methods. This shows that the predicted probability value output by the decision-level fusion model of this invention can truly reflect the recognition confidence of the model, effectively solve the problem of overconfidence in deep neural networks, and provide a reliable probabilistic basis for subsequent decision-level fusion.
[0200] 3. Independent verification of blind wells across regions
[0201] The purpose of this experiment is to evaluate the cross-regional generalization capability of the decision-level fusion model of this invention, which is a core indicator for measuring the engineering practicality of geological exploration models. The experimental method uses an independent well in a certain region that has not participated in any training or optimization process as the test set. The test well section is 2800~2905.125m, with a total length of 105.125m, and includes 13 types of volcanic rock lithology.
[0202] The experimental results are as follows: The decision-level fusion model of this invention has an overall accuracy of 97.74%, a macro-average F1 score of 97.3%, and a Matthews correlation coefficient of 0.971; The cross-attention feature-level fusion model (CAFN) has an overall accuracy of 88.72%, a macro-average F1 score of 87.5%, and a Matthews correlation coefficient of 0.868.
[0203] In cross-regional blind well testing, the overall accuracy of the decision-level fusion model of this invention was 9.02 percentage points higher than that of the cross-attention feature-level fusion model, maintaining extremely high accuracy and stability in the identification of 13 types of volcanic rocks. This indicates that the decoupled decision-level fusion architecture of this invention can effectively avoid the overfitting problem of feature-level fusion methods on small sample and low signal-to-noise ratio data, has significant cross-regional generalization ability, and can meet the deployment needs of actual engineering exploration.
[0204] 4. Model stability assessment
[0205] The purpose of this experiment is to evaluate the performance stability of the decision-level fusion model of this invention in multiple independent runs; the experimental method is to statistically analyze the standard deviation of the overall accuracy of each model in 25 independent runs.
[0206] The experimental results are as follows: The decision-level fusion model of this invention has an overall accuracy standard deviation of only ±0.14%; the cross-attention feature-level fusion model (CAFN) has an overall accuracy standard deviation of ±0.31%.
[0207] The performance standard deviation of the decision-level fusion model of this invention is much lower than that of the cross-attention feature-level fusion model, indicating that the decoupled decision-level fusion architecture has higher stability on complex geological data, better repeatability of model training results, and can provide consistent and reliable recognition results for engineering applications.
[0208] 5. Robustness test
[0209] The purpose of the experiment is to verify the robustness of the decision-level fusion model of the present invention in low signal-to-noise ratio and small sample scenarios, which is an important practical feature of geological exploration models.
[0210] The experimental method involved conducting two types of robustness tests:
[0211] a. Noise Resistance Test: Zero-mean Gaussian noise was added to the logging curves, with noise standard deviations set to 0.5 and 1.0 respectively, to test the macro-average F1 reduction of the model;
[0212] b. Small sample test: Reduce the amount of training data to 50% and 25% of the original amount of data respectively, retrain the model, and test the macro average F1 reduction.
[0213] Experimental Results: In all robustness tests, the macro-average F1 reduction of the decision-level fusion model of this invention was smaller than that of all comparative methods. For example, when the amount of training data was reduced to 25%, the macro-average F1 of the decision-level fusion model of this invention decreased by only 3.2 percentage points, while the cross-attention feature-level fusion model decreased by 8.7 percentage points.
[0214] The robustness of this invention over complexity has been fully verified. The decoupled single-modal expert network architecture can maintain stable performance in low signal-to-noise ratio and small sample scenarios, which is significantly better than complex feature-level fusion methods.
[0215] 6. Computational efficiency evaluation
[0216] The purpose of this experiment is to evaluate the training and inference efficiency of the decision-level fusion model of this invention and to verify its feasibility for engineering deployment.
[0217] The experimental method involved statistically analyzing the total number of parameters, the number of trainable parameters, and the average training time for completing a full 5-fold × 5-seed experiment for each model.
[0218] The experimental results show that the decision-level fusion model of this invention has a total of 21,305,316 parameters, 19,957,412 trainable parameters, and an average training time of 126.86 minutes for the complete experiment.
[0219] Cross-Attention Feature-Level Fusion Model (CAFN): Total number of parameters: 36,721,428; Average training time for the complete experiment: 218.53 minutes.
[0220] Lightweight Transformer Fusion Model (TCMT): Total number of parameters 42,156,896, average training time for the complete experiment 238.62 minutes.
[0221] The total number of parameters in the decision-level fusion model of this invention is only 58% of that of the cross-attention feature-level fusion model, and the training time is only 58% of that of the cross-attention feature-level fusion model and 53% of that of the lightweight Transformer fusion model. Under the same hardware conditions, the decision-level fusion model of this invention significantly saves training resources, has a faster inference speed, and is more suitable for engineering deployment in large-scale well logging data processing and scenarios with limited on-site computing resources.
[0222] like Figure 3 As shown, this is an embodiment of the present invention, which provides a multimodal volcanic rock fine-grained lithology identification system based on temperature scaling probability calibration, comprising:
[0223] The acquisition and preprocessing module is used to acquire well logging data and corresponding thin rock images, and after preprocessing, divide them into training and validation sets;
[0224] The expert network module is used to extract features from the preprocessed rock thin section image using an image expert network to obtain an image feature vector, and output unnormalized image prediction values based on the image feature vector; and to encode the preprocessed logging data using a logging expert network to obtain a logging feature vector, and output unnormalized logging prediction values based on the logging feature vector.
[0225] The temperature scaling module is used to independently train the image expert network and the well logging expert network based on the training set; and based on the validation set, it fits image temperature parameters and well logging temperature parameters to the trained image expert network and well logging expert network respectively. After temperature scaling, the unnormalized image prediction values and unnormalized well logging prediction values are converted into image probability distribution and well logging probability distribution.
[0226] The weighted fusion module is used to sum the image probability distribution and the well logging probability distribution in a weighted manner to obtain a fused probability distribution, and select the volcanic rock lithology category with the highest predicted probability value in the fused probability distribution as the final volcanic rock lithology prediction result.
[0227] In summary, the decision-level multimodal volcanic rock fine-grained lithology identification method based on temperature scaling probability calibration proposed in this invention systematically solves the core pain points of existing technologies from the perspective of architecture design, and has multi-dimensional technical advantages and engineering value.
[0228] First, a decoupled dual-expert network architecture is adopted, which eliminates the complex deep cross-modal feature interaction and fundamentally avoids the overfitting problem of feature-level fusion methods that are prone to learning spurious statistical associations in geological scenarios with small samples and low signal-to-noise ratios. The two expert networks are trained independently and do not interfere with each other, and can focus on learning the microscopic mineral structure features of rock thin sections and the macroscopic physical response features of well logging data, respectively. The geological features extracted by each network are more independent and effective.
[0229] Secondly, it pioneers a decision-level fusion paradigm of calibration before fusion. Before fusion, a temperature scaling mechanism corrects the overconfidence bias commonly found in deep neural networks, ensuring that the output probability truly reflects the model's actual confidence level. This design completely solves the problem of high-confidence erroneous predictions dominating decision-making in traditional decision-level fusion, enabling reliable discrimination even when multimodal information conflicts, and significantly improving the scientific rigor and credibility of the fusion decision.
[0230] Furthermore, the overall architecture of the method is simple and clear, with a small number of parameters and high computational efficiency. It does not require complex attention mechanisms or large-scale computing power, and its training and inference speeds are far superior to mainstream feature-level fusion methods. At the same time, the decoupled modular design facilitates subsequent individual upgrades and optimizations of models of a specific modality, and is also easy to port and deploy to edge computing devices in field exploration, enabling rapid adaptation to the automated processing needs of large-scale well logging data.
[0231] Finally, robust standardization, grouped cross-validation, and weighted loss functions were designed to address the inherent characteristics of geological data. These mechanisms fully adapt to the imbalanced sample size, numerous outliers, and susceptibility to data leakage in geological data, ensuring the stability and versatility of the method in practical engineering applications.
[0232] In the above embodiments, implementation can be achieved, in whole or in part, through software, hardware, firmware, or any other combination thereof. When implemented in software, it can be implemented, in whole or in part, as a computer program product, which includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, all or part of the processes or functions according to this application are generated. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions can be stored in a computer-readable storage medium or transferred from one computer-readable storage medium to another.
[0233] Furthermore, the functional units in the various embodiments of this application can be integrated into a processing module, or each unit can exist physically separately, or two or more units can be integrated into a module. The integrated module can be implemented in hardware or as a software functional module. If the integrated module is implemented as a software functional module and sold or used as an independent product, it can also be stored in a computer-readable storage medium. This storage medium can be a read-only memory, a disk, or an optical disk, etc.
[0234] The above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any person skilled in the art can easily conceive of various variations or substitutions within the technical scope disclosed in this application, and these should all be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.
Claims
1. A multimodal volcanic rock fine-grained lithology identification method based on temperature scaling probability calibration, characterized in that, include: Well logging data and corresponding thin section images of rocks were collected, preprocessed, and then divided into training and validation sets. An image expert network is used to extract features from the preprocessed thin section rock image to obtain an image feature vector, and an unnormalized image prediction value is output based on the image feature vector. A well logging expert network is used to encode features from the preprocessed well logging data to obtain a well logging feature vector, and an unnormalized well logging prediction value is output based on the well logging feature vector. Based on the training set, the image expert network and the well logging expert network were trained independently, respectively. Based on the validation set, image temperature parameters and well logging temperature parameters are fitted to the trained image expert network and well logging expert network, respectively. After temperature scaling, the unnormalized image prediction values and unnormalized well logging prediction values are converted into image probability distributions and well logging probability distributions. The image probability distribution and the well logging probability distribution are weighted and summed to obtain a fused probability distribution. The volcanic rock lithology category with the highest predicted probability value in the fused probability distribution is selected as the final volcanic rock lithology prediction result.
2. The multimodal volcanic rock fine-grained lithology identification method based on temperature scaling probability calibration according to claim 1, characterized in that, The well logging data includes: natural gamma curve, compensated neutron curve, density curve, sonic transit time curve, and deep lateral resistivity curve; the rock thin section images include: single-polarized thin section images and orthogonally polarized thin section images.
3. The multimodal volcanic rock fine-grained lithology identification method based on temperature scaling probability calibration according to claim 2, characterized in that, The preprocessing includes: applying robust standardization to the well logging data, i.e., standardizing by subtracting the median and dividing by the interquartile range; adjusting the resolution of the rock thin section image to 224×224 pixels and standardizing it using the mean and variance of the ImageNet dataset; and performing data augmentation operations, including random cropping and horizontal flipping, on the minority class samples in the 18 types of volcanic rocks where the number of samples is less than a preset threshold.
4. The multimodal volcanic rock fine-grained lithology identification method based on temperature scaling probability calibration according to claim 3, characterized in that, Based on the preprocessed well logging data and the corresponding rock thin section images, a grouped five-fold cross-validation strategy is adopted, and the training set and validation set are divided by physical sampling points as the grouping unit, so that single-polarized thin section images and orthogonal polarized thin section images of the same physical sampling point are assigned to the same training set or validation set.
5. The multimodal volcanic rock fine-grained lithology identification method based on temperature scaling probability calibration according to claim 1, characterized in that, The step of using an image expert network to extract features from the preprocessed rock thin section image to obtain an image feature vector, and then outputting an unnormalized image prediction value based on the image feature vector, includes: The image expert network consists of a backbone feature extraction subnetwork and a fully connected classification subnetwork. The backbone feature extraction subnetwork uses ResNet-34 pre-trained on the ImageNet dataset as its backbone structure, and freezes the shallow parameter region to preserve general texture edge features; after thawing the deep parameter region, fine-tuning is performed to learn the crystal fragments, glass fragments, and vesicular structure features of volcanic rocks; the preprocessed rock thin section image is input into the backbone feature extraction subnetwork, and the deep feature map of the image is output and compressed into an image feature vector by global average pooling; The fully connected classification subnetwork consists of a fully connected classification layer and outputs unnormalized image prediction values based on the image feature vector.
6. The multimodal volcanic rock fine-grained lithology identification method based on temperature scaling probability calibration according to claim 1, characterized in that, The process of using a well logging expert network to perform feature encoding on the preprocessed well logging data to obtain well logging feature vectors, and outputting unnormalized well logging prediction values based on the well logging feature vectors, includes: The well logging expert network consists of a well logging feature coding subnetwork and a linear classification subnetwork; The well logging feature coding subnetwork uses a multilayer perceptron as the encoder, and each MLP layer consists of a fully connected layer, layer normalization, and ReLU activation function in sequence. After the preprocessed well logging data is mapped layer by layer by the two MLP layers of the encoder, the well logging feature vector is output. The linear classification subnetwork consists of a fully connected linear classification layer, which outputs unnormalized well logging predictions based on well logging feature vectors.
7. The multimodal volcanic rock fine-grained lithology identification method based on temperature scaling probability calibration according to claim 1, characterized in that, An adaptive moment estimation optimizer with decoupled weight decay and a weighted cross-entropy loss function were used to train the image expert network and the well logging expert network independently, respectively. The weights of each volcanic rock lithology category in the weighted cross-entropy loss function were set according to the inverse ratio of the number of samples of each volcanic rock lithology category in the training set, and an early stopping strategy was set during training.
8. The multimodal volcanic rock fine-grained lithology identification method based on temperature scaling probability calibration according to claim 1, characterized in that, The validation set-based method involves fitting image temperature parameters and well logging temperature parameters to the trained image expert network and well logging expert network, respectively. After temperature scaling of the unnormalized image predictions and unnormalized well logging predictions, they are converted into image probability distributions and well logging probability distributions, including: By minimizing the negative log-likelihood loss, image temperature parameters and well logging temperature parameters are fitted to the image expert network and well logging expert network respectively, and optimization is performed only on the validation set; The temperature scaling is achieved by dividing the unnormalized image prediction value by the image temperature parameter, and by dividing the unnormalized well logging prediction value by the well logging temperature parameter. After dividing the unnormalized image prediction value by the image temperature parameter, it is converted into a calibrated image probability distribution using the Softmax function, as expressed by: ; In the formula, For the image probability distribution, These are the predicted values for the unnormalized image. Image temperature parameters; After dividing the unnormalized logging prediction by the logging temperature parameter, the result is converted into a calibrated logging probability distribution using the Softmax function. The expression is as follows: ; In the formula, Well logging probability distribution These are unnormalized well logging predictions. These are logging temperature parameters.
9. The multimodal volcanic rock fine-grained lithology identification method based on temperature scaling probability calibration according to claim 8, characterized in that, The step of weighted summing of the image probability distribution and the well logging probability distribution to obtain a fused probability distribution, and selecting the volcanic rock lithology category with the highest predicted probability value in the fused probability distribution as the final volcanic rock lithology prediction result, includes: Based on the learnable weight parameters obtained through optimization on the validation set, the image probability distribution and the well logging probability distribution are weighted and summed to obtain the fused probability distribution, expressed as: ; In the formula, For the fusion probability distribution, These are learnable weight parameters; After performing the Argmax operation on the fusion probability distribution, the volcanic rock lithology category with the highest predicted probability value in the fusion probability distribution is selected as the final volcanic rock lithology prediction result.
10. A multimodal volcanic rock fine-grained lithology identification system based on temperature scaling probability calibration, employing the multimodal volcanic rock fine-grained lithology identification method based on temperature scaling probability calibration as described in any one of claims 1 to 9, characterized in that... include: The acquisition and preprocessing module is used to acquire well logging data and corresponding rock thin section images, and after preprocessing, divide them into training and validation sets; The expert network module is used to extract features from the preprocessed rock thin section image using an image expert network to obtain an image feature vector, and output unnormalized image prediction values based on the image feature vector; and to encode the preprocessed logging data using a logging expert network to obtain a logging feature vector, and output unnormalized logging prediction values based on the logging feature vector. The temperature scaling module is used to independently train the image expert network and the well logging expert network based on the training set; Based on the validation set, image temperature parameters and well logging temperature parameters are fitted to the trained image expert network and well logging expert network, respectively. After temperature scaling, the unnormalized image prediction values and unnormalized well logging prediction values are converted into image probability distributions and well logging probability distributions. The weighted fusion module is used to sum the image probability distribution and the well logging probability distribution in a weighted manner to obtain a fused probability distribution, and select the volcanic rock lithology category with the highest predicted probability value in the fused probability distribution as the final volcanic rock lithology prediction result.