A three-dimensional rock mechanics parameter prediction method based on a graph neural network

By introducing anisotropic K-nearest neighbor connections and virtual node mechanisms into graph neural networks, and combining graph convolution and feature smoothing modules, the prediction bias problem of existing methods in complex spatial scenarios is solved, and higher accuracy and robustness in rock mechanics parameter prediction are achieved.

CN121542642BActive Publication Date: 2026-05-29SOUTHWEST PETROLEUM UNIV

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
SOUTHWEST PETROLEUM UNIV
Filing Date
2026-01-15
Publication Date
2026-05-29

AI Technical Summary

Technical Problem

Existing methods for predicting rock mechanics parameters based on graph neural networks struggle to accurately reflect the directional correlations and heterogeneous connections between nodes in complex spatial scenarios, leading to prediction biases and instability. They are particularly ineffective in three-dimensional rock masses with well-developed fracture networks, significant bedding control, and strong anisotropy of tectonic stress fields.

Method used

By employing an anisotropic K-nearest neighbor connection method and a virtual node mechanism, and modeling the spatial correlation between observation points, combined with a graph convolution aggregation layer, a similarity alignment module, and a feature distribution smoothing module, a graph structure that better conforms to spatial structural characteristics is constructed, thereby enhancing prediction capabilities.

Benefits of technology

It improves the prediction accuracy and robustness under missing data conditions, adapts to uneven observation distribution and missing data scenarios, and enhances the prediction accuracy and generalization ability of three-dimensional rock mechanics parameters.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121542642B_ABST
    Figure CN121542642B_ABST
Patent Text Reader

Abstract

The application discloses a three-dimensional rock mechanics parameter prediction method based on a graph neural network. In the graph construction stage, first, scaling factors are introduced for three-dimensional coordinate axes according to spatial correlation analysis, and anisotropic linear transformation is performed on original coordinates; then, anisotropic KNN edge connection is implemented based on weighted Euclidean distance, so that the spatial dependence relationship between observation points is more truly reflected; for virtual nodes, a hybrid edge connection mechanism is introduced, which not only ensures the robustness of the graph structure, but also retains the anisotropic geometric relationship; finally, the augmented graph structure is input into the backbone network containing a graph convolution layer and a feature alignment module, and the prediction of the target attribute is realized. Compared with the existing method, the application can better model the heterogeneous spatial dependence, and has higher prediction accuracy and generalization ability in the scene of data loss and uneven distribution, and is especially suitable for the fields of environmental monitoring, sensor network and geological exploration.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of geological parameter prediction and graph neural network technology, and in particular to a method for predicting three-dimensional rock mechanical parameters based on graph neural networks. Background Technology

[0002] Rock mechanics parameters (such as uniaxial compressive strength UCS, elastic modulus E, Poisson's ratio ν, internal friction angle φ, cohesion c, tensile strength Rt, permeability k, etc.) are core inputs for underground engineering design and risk control, directly affecting key aspects such as well wall stability, tunnel and chamber support, hydraulic fracturing crack propagation, slope and dam foundation stability, rockburst and rockburst risk assessment, and geothermal and carbon dioxide geological sequestration. In practical engineering, obtaining these parameters relies on laboratory and in-situ tests (uniaxial / triaxial compression, shear, mercury injection, in-situ ballast, etc.), which are characterized by "sparse test sites, high cost, long cycle, and high destructiveness," making it difficult to cover the heterogeneous, non-stationary, and scale-dependent distribution of rock mass properties in three-dimensional space. Therefore, how to use available multi-source observation data to perform high-precision and generalizable three-dimensional prediction of target mechanical parameters has always been a common need in the fields of geotechnical and energy engineering.

[0003] Traditional approaches typically include three categories: (1) empirical formulas and index conversions, such as empirical regression based on acoustic transit time, density, porosity, mineral composition, or rebound value, or through... and (1) Parameter conversion between criteria to obtain strength and shear parameters; (2) Geostatistical interpolation and inversion, such as ordinary / co-kriging, variogram modeling and finite element / discrete element coupled inversion; (3) Statistical learning methods based on regular grids or voxels, such as linear / ridge regression, SVM, random forest, Boosting and multilayer perceptron. The above methods can achieve certain results when the data is sufficient and the spatial relationship is relatively simple, but in three-dimensional rock masses with well-developed fracture networks, significant bedding / joint control and strong anisotropy of tectonic stress field, the following limitations often occur: First, it is difficult to explicitly characterize the directional correlation and heterogeneous connection relationship between nodes; Second, it is sensitive to irregular distribution of observation points, missing data and noise; Third, the neighborhood definition based on Euclidean distance ignores the anisotropic propagation path induced by bedding dip, joint set direction, principal stress direction, sedimentary facies boundary, etc., leading to prediction bias and instability.

[0004] With the development of sensor networks and geophysical imaging technology, engineering sites can acquire multi-scale, multi-modal observation data, such as well logging curves. Wellbore imaging rock core Thin sections, 3D seismic attribute volumes, acoustic emission and strain monitoring, UAV / laser point clouds, etc. These data exhibit irregular sampling and significant directional correlation structures in 3D space: for example, strong correlation along bedding strike and weak vertical cross-layer correlation; high fracture connectivity along the direction of maximum principal stress and significant anisotropic infiltration channels controlled by shear weak surfaces. The graph neural network (GNN)-based modeling paradigm provides a natural advantage for this: using observation points or voxels as nodes, edges are used to depict the "paths through which information can propagate," and message passing mechanisms are used to achieve joint alignment and fusion of multi-hop correlations and cross-modal features.

[0005] In existing graph neural network-based prediction methods, common edge connection methods include: (1) random edge connection: establishing connections randomly between virtual nodes and observation points, and expanding neighbor relationships based on probability. This method can improve the connectivity of the graph, but lacks directionality and stability, resulting in insufficient accuracy of the structural information learned by the model. (2) uniform KNN edge connection: selecting several nearest neighbors for each observation point and establishing edges through Euclidean distance. This method has certain advantages in modeling spatial geometric relationships, but it assumes that each coordinate axis is equally important and cannot reflect the anisotropic characteristics of the actual space, which will bring certain deviations in real applications. Previous studies have shown that in complex spatial scenarios, the correlation between nodes often has directional differences. For example, in geological exploration, environmental monitoring, or industrial sensor networks, the spatial dependencies of the X, Y, and Z directions are not consistent. Therefore, the KNN graph construction method that relies solely on Euclidean distance is prone to ignoring this heterogeneity, thus affecting the prediction performance. To address the above problems, the KITS method proposes a graph augmentation strategy that introduces virtual nodes and random edge connections, which effectively improves the robustness of the model under missing data conditions. However, this method still has the following shortcomings: the random edge connection mechanism introduces structural noise, affecting the stability of the adjacency matrix; KNN based on uniform Euclidean distance cannot capture the correlation of anisotropic space; and the selection of neighbors for virtual nodes lacks adaptive modeling of spatial features. Summary of the Invention

[0006] To address the aforementioned technical problems, this invention provides a method for predicting three-dimensional rock mechanics parameters based on graph neural networks. By combining anisotropic K-nearest neighbor edge connection with a virtual node mechanism, and by modeling the spatial correlation between observation points, the method enhances the graph structure representation capability and achieves high-precision prediction of target attributes.

[0007] This invention is achieved using the following technical solution:

[0008] A method for predicting three-dimensional rock mechanical parameters based on graph neural networks includes the following steps:

[0009] Step S1: Collect observation sample data of the strata in the target area and perform normalized preprocessing, including three-dimensional coordinates. The samples and their corresponding attribute values ​​are used to generate missing value masks, handle outliers, and normalize them to form data tensors and masks for training, validation, and testing.

[0010] Step S2: Determine the anisotropic scaling factor based on spatial correlation analysis, expressed as... Anisotropic linear transformations are applied to the three-dimensional coordinates;

[0011] Step S3: Calculate the weighted Euclidean distance based on the transformed coordinates, and select for each observation point. The initial adjacency matrix is ​​generated from the nearest neighbors and then symmetricized and binarized to obtain the observation point graph structure.

[0012] Step S4: Insert several virtual nodes into the observation point graph structure and use a hybrid edge connection strategy to obtain the augmented adjacency matrix;

[0013] Step S5: Input the observed sample data processed by steps S1 to S4 along with the augmented adjacency matrix. The model sequentially passes through a graph convolutional aggregation layer and an interaction based on similarity alignment. Feature extraction and fusion are performed with the Feature Distribution Smoothing RFF module, and the prediction result of the target attribute is obtained through regression output; an inverted mask is constructed, the prediction result is used as a pseudo-label, the weights and augmented adjacency matrix are kept unchanged, and the KIS model is executed again to obtain a new prediction result;

[0014] Step S6: Train the model using masked regression loss, and evaluate the model performance based on mean squared error, mean absolute error (MAE), root mean square error (RMSE), relative error, and coefficient of determination.

[0015] Specifically, step S1 includes the following sub-steps:

[0016] Step S11: Perform duplicate value detection on the observation sample data of the strata in the target area, remove redundant samples, and filter out the outliers generated during the observation process;

[0017] Step S12: For observation points with missing attribute values, linear interpolation or nearest neighbor interpolation is used to fill in the missing values. The interpolation formula is expressed as:

[0018] ;

[0019] in, For missing positions, For interpolated values, , The coordinates and attribute values ​​of adjacent known observation points;

[0020] Step S13: Normalize the features to eliminate dimensional differences. The normalization formula is expressed as:

[0021] ;

[0022] in, The normalized value. These are the original values. , These are the minimum and maximum values ​​of the feature, respectively.

[0023] Step S14: Organize the processed sample data into a tensor structure according to spatial order.

[0024] Specifically, step S2 includes the following sub-steps:

[0025] Step S21: Analyze the three-dimensional coordinate data of the observed sample data. Pearson correlation coefficient was used. Correlation analysis of coordinate components in different directions is expressed as follows:

[0026] ;

[0027] in, Representing variables and covariance, and This represents the three-dimensional coordinates corresponding to the i-th observation sample data. and Let represent the mean of the eigenvectors, respectively. For the sample size, and Let represent the standard deviation, and the result range is . ;

[0028] Step S22: Based on the spatial correlation analysis results, assign corresponding scaling factors to different dimensions in the coordinate system. Its value reflects the weight of each dimension in spatial distance measurement;

[0029] Step S23: For the original three-dimensional coordinates Applying linear scaling, we obtain anisotropic coordinates, represented as follows: .

[0030] Specifically, step S3 includes the following sub-steps:

[0031] Step S31: Based on the coordinate system after transforming the anisotropic coordinates, for any two observation points and The weighted Euclidean distance is calculated as follows:

[0032] ;

[0033] in, , , These are the weighting factors for each dimension, determined based on the spatial correlation results.

[0034] Step S32: For each observation point Sort by weighted Euclidean distance in ascending order, and select the top... Find the nearest neighbor and establish an initial adjacency relationship;

[0035] Step S33: Treat the observation point as a node in the graph. If the point... With point If the nearest neighbor condition is met during the neighbor selection process, then in the adjacency matrix... The corresponding position is assigned a value of 1, otherwise it is 0, generating an asymmetric initial adjacency matrix;

[0036] Step S34: Perform a symmetry transformation operation on the initial adjacency matrix, as follows:

[0037] ;

[0038] in, This represents the logical "OR" operation, ensuring that if... and If there is a unidirectional connection, then a bidirectional connection is formed after symmetry.

[0039] Step S35: Simplify the graph representation by unifying the edge weights in the adjacency matrix. Assign a value of 1 to all existing edges and a value of 0 to unconnected edges, thus obtaining the final observation point graph structure matrix. .

[0040] Specifically, the hybrid edge connection strategy in step S4 is as follows:

[0041] According to anisotropy Connect to each virtual node Find the nearest neighbor observation points and use target degree constraints to make the virtual node degree close to the proportion of the median degree of the observation points. ;

[0042] Within the candidate set of one-hop virtual nodes, with a small probability Add random edges and set an upper limit ratio for the number of virtual incoming edges at observation points. .

[0043] Specifically, step S4 includes the following sub-steps:

[0044] Step S41: In addition to the original set of observation points, add several virtual nodes to enhance the connectivity and robustness of the graph structure. Each virtual node is regarded as an independent supplementary node and does not contain actual observation data values.

[0045] Step S42: For each virtual node First, a random observation point is selected. Force the establishment of an edge between the virtual node and the observation point; simultaneously, using probability... Decide whether to connect virtual nodes with Establish random edges between neighboring nodes;

[0046] Step S43: Based on the coordinate space after transforming the anisotropic coordinates, for each virtual node Select the nearest one according to the weighted Euclidean distance. Establish anisotropy at each observation point. Connect edges;

[0047] Step S44: Combining the edge establishment strategies of steps S42 and S43, the hybrid adjacency relationship of virtual nodes is obtained;

[0048] Step S45: Add the virtual nodes and their mixed edges to the observation point graph structure matrix. In this process, the extended augmented adjacency matrix is ​​obtained. .

[0049] Specifically, step S5 includes the following sub-steps:

[0050] Step S51: Combine the observed sample feature data processed through steps S1 to S4 with the augmented adjacency matrix. Simultaneously inputting the KIS model backbone graph neural network to form a graph-structured input;

[0051] Step S52: Through multi-layer graph convolution operations, node features are aggregated and propagated under the adjacency matrix constraint, so that each node integrates information from its neighboring nodes and obtains a preliminary spatial correlation representation.

[0052] Step S53: Introduce a similarity alignment mechanism based on graph convolution, and perform weighted information interaction based on the feature similarity between nodes;

[0053] Step S54: Perform distribution smoothing on the similarity-aligned feature representations to reduce the unbalanced differences between features at different nodes;

[0054] Step S55: Input the node representation after multi-layer feature fusion into the regression layer, and output the predicted value of the target attribute. This enables attribute estimation for unobserved locations;

[0055] Step S56: Construct the inverted mask ,use Pseudo-labels constrain non-observed locations; maintain the same set of weights and... Execute the KIS model again;

[0056] Step S57: During the model inference stage, for the predicted values ​​of the observed locations, a true value overlay strategy is adopted to directly replace the predicted values ​​with the true values.

[0057] Specifically, step S6 includes the following sub-steps:

[0058] Step S61: During the training phase, the loss is calculated only for the prediction results of unobserved locations. Observed locations are masked using a mask. The objective function for loss based on masked regression is expressed as:

[0059] ;

[0060] in, The mask indicates the set of unobserved locations. For the true value, This is a predicted value;

[0061] Step S62: Minimize the loss objective function in step S61 through backpropagation and gradient descent algorithms, and update the network parameters step by step;

[0062] Step S63: After training is completed, use multiple error metrics to comprehensively evaluate the model performance.

[0063] Specifically, the evaluation indicators in step S63 include:

[0064] Mean squared error: Calculated as the sum of squares of the distances between the predicted and actual values, expressed as:

[0065] ;

[0066] Mean Absolute Error (MAE): Calculated as the absolute value of the difference between the predicted and actual values, expressed as:

[0067] ;

[0068] Relative error: includes mean absolute percentage error and mean relative error, representing the proportion of prediction error to the true value, expressed as follows:

[0069] ;

[0070] ;

[0071] Coefficient of determination: An indicator for evaluating the goodness of fit of a regression model, expressed as:

[0072] ;

[0073] Where n is the number of samples. For the i-th true value, For the i-th predicted value, for The mean; The closer to 1, the better the model fit.

[0074] The beneficial effects of this invention are as follows: The proposed 3D rock mechanics parameter prediction method based on graph neural networks improves the traditional random edge connection method to anisotropic KNN edge connection, and adopts a hybrid edge connection mechanism (random + anisotropic KNN) between observed nodes and virtual nodes, which can better conform to spatial structure characteristics and node distribution patterns. By weighting the differences in different coordinate dimensions through anisotropic scaling factors, the construction of adjacency relationships not only depends on spatial distance, but also reflects directional features such as geological structure, thereby improving the expressive power of the graph structure. At the same time, the introduction of virtual nodes and hybrid edge connections enhance the connectivity and robustness of the graph, and improve the feature propagation of sparse regions or missing data nodes. Combining graph convolutional aggregation layers, similarity alignment modules, and feature distribution smoothing modules, this method can effectively improve the accuracy of feature transfer and fusion between nodes. In the prediction stage, through masked regression loss and multi-index evaluation (MSE, MAE, RMSE, MAPE / MRE), this invention improves the overall prediction accuracy while having stronger adaptability and generalization ability to uneven observation distribution and missing data.

[0075] Compared with existing methods, this invention can better model heterogeneous spatial dependencies and exhibits higher prediction accuracy and generalization ability in scenarios with missing data and uneven distribution. It is particularly suitable for fields such as environmental monitoring, sensor networks and geological exploration. Attached Figure Description

[0076] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art 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 the structures shown in these drawings without creative effort.

[0077] Figure 1 This is a basic flowchart of the three-dimensional rock mechanics parameter prediction method based on graph neural networks in this embodiment of the invention;

[0078] Figure 2This is a schematic diagram of the KIS model and inversion mask mechanism in an embodiment of the present invention;

[0079] Figure 3 This is a schematic diagram showing the implementation details of the SGC graph convolutional aggregation layer in an embodiment of the present invention;

[0080] Figure 4 To smooth the RFF feature distribution in this embodiment Module implementation details diagram. Detailed Implementation

[0081] 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 embodiments of the present invention, and not all embodiments. The components of the embodiments of the present invention described and shown in the accompanying drawings can generally be arranged and designed in various different configurations.

[0082] It should be noted that similar labels and letters in the following figures indicate similar items. Therefore, once an item is defined in one figure, it does not need to be further defined and explained in subsequent figures.

[0083] The following is in conjunction with the appendix Figure 1 ~Attached Figure 4 The following describes some embodiments of the present invention in detail. Unless otherwise specified, the following embodiments and features can be combined with each other.

[0084] This invention proposes a method for predicting three-dimensional rock mechanics parameters based on graph neural networks. In one embodiment, the prediction method is based on anisotropic edge connections. In the graph construction stage, a scaling factor is first introduced for the three-dimensional coordinate axes based on spatial correlation analysis, and anisotropic linear transformation is performed on the original coordinates. Then, anisotropic KNN edge connections are implemented based on weighted Euclidean distance to more realistically reflect the spatial dependencies between observation points. For virtual nodes, a hybrid edge connection mechanism (random edge connections + anisotropic KNN) is introduced to ensure the robustness of the graph structure and preserve anisotropic geometric relationships. Finally, the augmented graph structure is input into a backbone network containing graph convolutional layers and feature alignment modules to achieve the prediction of target attributes.

[0085] The basic process for predicting three-dimensional rock mechanical parameters is as follows: Figure 1 As shown, the specific steps include:

[0086] S1: Perform normalized preprocessing on the observation sample data of the target area, the samples including three-dimensional coordinates. The missing value mask is generated, outlier is handled and normalized, and the corresponding attribute values ​​are used to form a data tensor and mask for training, verification and testing.

[0087] S2: Determine the anisotropic scaling factor based on spatial correlation analysis. Anisotropic linear transformation is performed on the three-dimensional coordinates. Used for subsequent distance measurement;

[0088] S3: Calculate the weighted Euclidean distance based on the transformed coordinates, and select for each observation point. The initial adjacency matrix is ​​generated from the nearest neighbors and then symmetricized and binarized to obtain the observation point graph structure.

[0089] S4: Insert several virtual nodes into the graph and adopt a hybrid edge connection strategy: Firstly, based on anisotropy... Connect to each virtual node Find the nearest neighbor observation points and use target degree constraints to make the virtual node degree close to the proportion of the median degree of the observation points. Secondly, within the candidate set of one-hop virtual nodes, with a small probability... Add random edges and set an upper limit ratio for the number of virtual incoming edges at observation points. Thus, the augmented adjacency matrix is ​​obtained;

[0090] S5: Input the preprocessed data and the augmented adjacency matrix. Model, Model and inversion masking mechanism, such as Figure 2 As shown; sequentially through graph convolutional aggregation layers (SGC layers, as shown) Figure 3 (As shown), interaction based on similarity alignment Smoothing with feature distribution Modules (RFF modules, such as) Figure 4 Feature extraction and fusion are performed (as shown), and the prediction result of the target attribute is obtained through regression output; an inverted mask is constructed, the prediction result is used as a pseudo-label, the weights and augmented adjacency matrix are kept unchanged, and the KIS model is executed again to obtain a new prediction result;

[0091] S6: The model is trained using masked regression loss and based on mean squared error. Mean absolute error Root mean square error Relative error Coefficient of determination The model performance is evaluated using metrics such as [list of metrics].

[0092] In this embodiment, step S1 includes the following sub-steps:

[0093] S11: Perform duplicate value detection on the input stratigraphic observation point data and remove redundant samples; filter out anomalies generated during the observation process (such as unreasonable coordinates or abrupt changes in attribute values) to ensure the authenticity and consistency of the input data.

[0094] S12: For observation points with missing attribute values, linear interpolation or nearest neighbor interpolation is used to fill in the missing values. The interpolation formula is as follows:

[0095]

[0096] in, For missing positions, For interpolated values, , This refers to the coordinates and attribute values ​​of adjacent known observation points.

[0097] S13: Normalize the characteristics (such as density and porosity) to eliminate dimensional differences. The normalization formula is:

[0098]

[0099] in, The normalized value. These are the original values. , These are the minimum and maximum values ​​of the feature, respectively.

[0100] S14: Organize the processed sample data into a tensor structure according to spatial order so that it can be directly called when building the graph neural network later.

[0101] In this embodiment, step S2 includes the following sub-steps:

[0102] S21: Three-dimensional spatial coordinate data for the observation point Pearson correlation coefficient was used. Correlation analysis was performed on the coordinate components in different directions. The Pearson coefficient formula is as follows:

[0103]

[0104] in, Representing variables and covariance, and This represents the three-dimensional coordinates corresponding to the i-th observation sample data. and Let represent the mean of the eigenvectors, respectively. For the sample size, and Let represent the standard deviation, and the result range is . Through calculation The correlation strength in three directions determines the importance of different spatial dimensions.

[0105] S22: Based on the spatial correlation analysis results, assign corresponding scaling factors to different dimensions in the coordinate system. The scaling factor reflects the weight of each dimension in the spatial distance metric. The scaling factor can be determined by combining expert experience with statistical results.

[0106] S23: For the original three-dimensional coordinates Applying linear scaling, we obtain the anisotropic coordinates:

[0107]

[0108] This transformation preserves the original topological relationships while emphasizing the dimensions with strong correlations and weakening the influence of uncorrelated or weakly correlated dimensions.

[0109] S24: Transformed coordinates This will serve as the input for subsequent weighted Euclidean distance calculations, ensuring that spatial anisotropy is considered during the adjacency matrix construction process, and improving the graph structure's ability to represent real geological spatial relationships.

[0110] In this embodiment, step S3 includes the following sub-steps:

[0111] S31: In the coordinate system after the anisotropic linear transformation, for any two observation points and Its weighted Euclidean distance is defined as:

[0112]

[0113] in , , These are the weighting factors for each dimension, which can be determined based on the spatial correlation results.

[0114] S32: For each observation point Sort by weighted Euclidean distance in ascending order, and select the top... The graph establishes initial adjacency relationships by finding the nearest neighbors. This process ensures that the graph structure reflects the tight connectivity of the local space.

[0115] S33: Treat the observation point as a node in the graph. If the point... With point If the nearest neighbor condition is met during the neighbor selection process, then in the adjacency matrix... The corresponding position is assigned a value of 1, otherwise it is 0. This generates an asymmetric initial adjacency matrix.

[0116] S34: To ensure the undirected nature of the graph structure, a symmetric operation is performed on the initial adjacency matrix:

[0117]

[0118] in This represents the logical "OR" operation, ensuring that if... and If a unidirectional connection exists, a bidirectional connection is formed after symmetry.

[0119] S35: To simplify the graph representation, the edge weights in the adjacency matrix are standardized, i.e., all existing edges are assigned a value of 1, and unconnected edges are assigned a value of 0, resulting in the final observation point graph structure matrix. .

[0120] In this embodiment, step S4 includes the following sub-steps:

[0121] S41: In addition to the original set of observation points, several virtual nodes are added to enhance the connectivity and robustness of the graph structure. Each virtual node is considered an independent supplementary node and does not contain actual observation data values.

[0122] S42: For each virtual node First, a random observation point is selected. And force the establishment of an edge between the virtual node and the observation point. Simultaneously, using probability... Decide whether to connect virtual nodes with By establishing connections with neighboring nodes, the virtual nodes' ability to cover the local graph structure is enhanced.

[0123] S43: In the coordinate space after the anisotropic linear transformation, for each virtual node Select the nearest one according to the weighted Euclidean distance. Each virtual node is assigned an observation point and connected to it via edges. This process ensures that the virtual node can capture the geometric information of the global space.

[0124] S44: Combine the random edge-connection strategy (S42) with anisotropy By combining the edge-connection strategy (S43), a hybrid adjacency relationship is obtained for the virtual nodes. That is, the virtual nodes maintain connections with some randomly selected observation points, as well as with anisotropic... The selected neighboring points are connected, thus balancing the randomness of the graph structure with spatial correlation.

[0125] S45: Add the virtual node and its mixed edges to the adjacency matrix of the observation point. In this process, the extended adjacency matrix is ​​obtained. This matrix contains the complete graph structure relationship between observation points and virtual nodes, preparing it for subsequent input to the graph neural network.

[0126] In this embodiment, step S5 includes the following sub-steps:

[0127] S51: Combine the observation point feature data preprocessed in steps S1–S4 with the extended adjacency matrix. Simultaneously, the main graph neural network is input to form a graph-structured input.

[0128] S52: Through multi-layer graph convolution The operation, under the constraint of the adjacency matrix, completes the aggregation and propagation of node features, enabling each node to integrate information from its neighboring nodes and obtain a preliminary spatial correlation representation.

[0129] S53: A similarity alignment mechanism is introduced based on graph convolution. Weighted information interaction is performed based on the feature similarity between nodes, thereby reducing information offset caused by differences in feature distribution. This process can be achieved through similarity matrix construction and alignment transformation.

[0130] S54: The distribution smoothing process is applied to the feature representations that have been aligned by similarity to reduce the unbalanced differences between features at different nodes and improve the stability and generalization ability of the global feature representation.

[0131] S55: Input the node representation after multi-layer feature fusion into the regression layer, and output the predicted value of the target attribute. This enables attribute estimation for unobserved locations.

[0132] S56: Construct the inverted mask ,use Pseudo-labels constrain non-observed locations; maintain the same set of weights and... Then, execute the KIS model again.

[0133] S57: During the model inference phase, true value coverage is used for predicted values ​​at observed locations. The strategy is to directly replace the predicted value with the actual value to ensure the accuracy and consistency of the prediction results.

[0134] In this embodiment, step S6 includes the following sub-steps:

[0135] S61: During the training phase, the loss is calculated only for the prediction results at unobserved locations; observed locations are masked to ensure that the model's learning focuses on the missing value prediction task. Its objective function is as follows:

[0136]

[0137] in, The mask indicates the set of unobserved locations. For the true value, These are predicted values.

[0138] S62: Minimize the above masked regression loss function through backpropagation and gradient descent algorithms, gradually update the network parameters, and improve the model's fitting ability and generalization performance.

[0139] S63: After training, multiple error metrics are used to comprehensively evaluate the model performance, including:

[0140] S631: MSE stands for Mean Squared Error, which calculates the sum of squared distances between predicted and true values. It converges quickly and can apply appropriate penalty weights to the gradient, making the gradient update direction more accurate. MSE is specifically expressed as:

[0141]

[0142] S632: MAE (Mean Absolute Error) is calculated as the absolute value of the difference between the predicted and actual values, measuring the average error magnitude of the distance between the predicted and actual values. MAE is specifically expressed as:

[0143]

[0144] S633: Mean absolute percentage error / mean relative error represents the proportion of prediction error relative to the true value, providing a more intuitive representation of the error percentage. The calculation formula is:

[0145] ; ;

[0146] S634: The coefficient of determination is an indicator used to evaluate the goodness of fit of a regression model. It represents the proportion of data variance that the model can explain and is often used to compare the performance of different models. Specifically, it is expressed as follows:

[0147]

[0148] Where n is the number of samples. For the i-th true value, For the i-th predicted value, for The mean. The closer the value is to 1, the better the model fit. The smaller the values ​​of other indicators, the smaller the method error. MSE is the objective function.

[0149] In summary, the proposed 3D rock mechanics parameter prediction method based on graph neural networks aims to improve the prediction accuracy of graph neural networks in scenarios with sparse observation points. This method abandons random connection and uniform edge sampling in the graph construction stage, instead introducing anisotropic K-nearest neighbor (KNN) strategy. This strategy weights adjacent edges based on scaling factors of spatial coordinates in different directions, forming adjacent edges that better reflect spatial distribution characteristics. This approach avoids graph structure instability and information propagation noise caused by random edge connections, and adaptively maintains the geometric consistency of the original spatial topology during training. This scheme demonstrates higher stability and accuracy in both missing observation and high-dimensional prediction tasks, providing more accurate predictions for 3D stratigraphic reconstruction.

[0150] For the foregoing embodiments, in order to simplify the description, they are all described as a series of actions. However, those skilled in the art should understand that this application is not limited to the described order of actions, because according to this application, some steps can be performed in other orders or simultaneously. Furthermore, those skilled in the art should also understand that the embodiments described in the specification are preferred embodiments, and the actions involved are not necessarily essential to this application.

[0151] The above embodiments describe the basic principles, main features, and advantages of the present invention. Those skilled in the art should understand that the present invention is not limited to the above embodiments. The embodiments and descriptions in the specification are merely illustrative of the principles of the invention. Modifications and variations made by those skilled in the art without departing from the spirit and scope of the invention should be within the protection scope of the appended claims.

Claims

1. A method for predicting three-dimensional rock mechanical parameters based on graph neural networks, characterized in that, Includes the following steps: Step S1: Collect observation sample data of the strata in the target area and perform normalized preprocessing, including three-dimensional coordinates. The samples and their corresponding attribute values ​​are used to generate missing value masks, handle outliers, and normalize them to form data tensors and masks for training, validation, and testing. Step S2: Determine the anisotropic scaling factor based on spatial correlation analysis, expressed as... Anisotropic linear transformations are applied to the three-dimensional coordinates; Step S3: Calculate the weighted Euclidean distance based on the transformed coordinates, and select for each observation point. The initial adjacency matrix is ​​generated from the nearest neighbors and then symmetricized and binarized to obtain the observation point graph structure. Step S4: Insert several virtual nodes into the observation point graph structure and use a hybrid edge connection strategy to obtain the augmented adjacency matrix; the hybrid edge connection strategy is as follows: According to anisotropy Connect to each virtual node Find the nearest neighbor observation points and use target degree constraints to make the virtual node degree close to the proportion of the median degree of the observation points. ; Within the candidate set of one-hop virtual nodes, with a small probability Add random edges and set an upper limit ratio for the number of virtual incoming edges at observation points. ; Step S4 specifically includes the following sub-steps: Step S41: In addition to the original set of observation points, add several virtual nodes to enhance the connectivity and robustness of the graph structure. Each virtual node is regarded as an independent supplementary node and does not contain actual observation data values. Step S42: For each virtual node First, a random observation point is selected. Force the establishment of an edge between the virtual node and the observation point; simultaneously, using probability... Decide whether to connect virtual nodes with Establish random edges between neighboring nodes; Step S43: Based on the coordinate space after transforming the anisotropic coordinates, for each virtual node Select the nearest one according to the weighted Euclidean distance. Establish anisotropy at each observation point. Connect edges; Step S44: Combining the edge establishment strategies of steps S42 and S43, the hybrid adjacency relationship of virtual nodes is obtained; Step S45: Add the virtual nodes and their mixed edges to the observation point graph structure matrix. In this process, the extended augmented adjacency matrix is ​​obtained. ; Step S5: Input the observed sample data processed by steps S1 to S4 along with the augmented adjacency matrix. The model sequentially passes through a graph convolutional aggregation layer and an interaction based on similarity alignment. Feature extraction and fusion are performed with the Feature Distribution Smoothing (RFF) module, and the predicted result of the target attribute is obtained through regression output; an inverted mask is constructed, and the predicted result is used as a pseudo-label. The weights and augmented adjacency matrix are kept unchanged, and the KIS model is executed again to obtain a new prediction result; the specific steps include the following: Step S51: Combine the observed sample feature data processed through steps S1 to S4 with the augmented adjacency matrix. Simultaneously inputting the KIS model backbone graph neural network to form a graph-structured input; Step S52: Through multi-layer graph convolution operations, node features are aggregated and propagated under the adjacency matrix constraint, so that each node integrates information from its neighboring nodes and obtains a preliminary spatial correlation representation. Step S53: Introduce a similarity alignment mechanism based on graph convolution, and perform weighted information interaction based on the feature similarity between nodes; Step S54: Perform distribution smoothing on the similarity-aligned feature representations to reduce the unbalanced differences between features at different nodes; Step S55: Input the node representation after multi-layer feature fusion into the regression layer, and output the predicted value of the target attribute. This enables attribute estimation for unobserved locations; Step S56: Construct the inverted mask ,use Pseudo-labels constrain non-observed locations; maintain the same set of weights and... Execute the KIS model again; Step S57: In the model inference stage, for the predicted values ​​of the observed locations, the true value covering strategy is adopted to directly replace the predicted values ​​with the true values; Step S6: Train the model using masked regression loss, and evaluate the model performance based on mean squared error, mean absolute error (MAE), root mean square error (RMSE), relative error, and coefficient of determination.

2. The method for predicting three-dimensional rock mechanical parameters based on graph neural networks as described in claim 1, characterized in that, Step S1 specifically includes the following sub-steps: Step S11: Perform duplicate value detection on the observation sample data of the strata in the target area, remove redundant samples, and filter out the outliers generated during the observation process; Step S12: For observation points with missing attribute values, linear interpolation or nearest neighbor interpolation is used to fill in the missing values. The interpolation formula is expressed as: ; in, For missing positions, For interpolated values, , The coordinates and attribute values ​​of adjacent known observation points; Step S13: Normalize the features to eliminate dimensional differences. The normalization formula is expressed as: ; in, The normalized value. These are the original values. , These are the minimum and maximum values ​​of the feature, respectively. Step S14: Organize the processed sample data into a tensor structure according to spatial order.

3. The method for predicting three-dimensional rock mechanical parameters based on graph neural networks as described in claim 2, characterized in that, Step S2 specifically includes the following sub-steps: Step S21: Analyze the three-dimensional coordinate data of the observed sample data. Pearson correlation coefficient was used. Correlation analysis of coordinate components in different directions is expressed as follows: ; in, Representing variables and covariance, and This represents the three-dimensional coordinates corresponding to the i-th observation sample data. and Let represent the mean of the eigenvectors, respectively. For the sample size, and Let represent the standard deviation, and the result range is . ; Step S22: Based on the spatial correlation analysis results, assign corresponding scaling factors to different dimensions in the coordinate system. Its value reflects the weight of each dimension in spatial distance measurement; Step S23: For the original three-dimensional coordinates Applying linear scaling, we obtain anisotropic coordinates, represented as follows: .

4. The method for predicting three-dimensional rock mechanical parameters based on graph neural networks as described in claim 3, characterized in that, Step S3 specifically includes the following sub-steps: Step S31: Based on the coordinate system after transforming the anisotropic coordinates, for any two observation points and The weighted Euclidean distance is calculated as follows: ; in, , , These are the weighting factors for each dimension, determined based on the spatial correlation results. Step S32: For each observation point Sort by weighted Euclidean distance in ascending order, and select the top... Find the nearest neighbor and establish an initial adjacency relationship; Step S33: Treat the observation point as a node in the graph. If the point... With point If the nearest neighbor condition is met during the neighbor selection process, then in the adjacency matrix... The corresponding position is assigned a value of 1, otherwise it is 0, generating an asymmetric initial adjacency matrix; Step S34: Perform a symmetry transformation operation on the initial adjacency matrix, as follows: ; in, This represents the logical "OR" operation, ensuring that if... and If there is a unidirectional connection, then a bidirectional connection is formed after symmetry. Step S35: Simplify the graph representation by unifying the edge weights in the adjacency matrix. Assign a value of 1 to all existing edges and a value of 0 to unconnected edges, thus obtaining the final observation point graph structure matrix. .

5. The method for predicting three-dimensional rock mechanical parameters based on graph neural networks as described in claim 1, characterized in that, Step S6 specifically includes the following sub-steps: Step S61: During the training phase, the loss is calculated only for the prediction results of unobserved locations. Observed locations are masked using a mask. The objective function for loss based on masked regression is expressed as: ; in, The mask indicates the set of unobserved locations. For the true value, This is a predicted value; Step S62: Minimize the loss objective function in step S61 through backpropagation and gradient descent algorithms, and update the network parameters step by step; Step S63: After training is completed, use multiple error metrics to comprehensively evaluate the model performance.

6. The method for predicting three-dimensional rock mechanical parameters based on graph neural networks as described in claim 5, characterized in that, The evaluation indicators in step S63 specifically include: Mean squared error: Calculated as the sum of squares of the distances between the predicted and actual values, expressed as: ; Mean Absolute Error (MAE): Calculated as the absolute value of the difference between the predicted and actual values, expressed as: ; Relative error: includes mean absolute percentage error and mean relative error, representing the proportion of prediction error to the true value, expressed as follows: ; ; Coefficient of determination: An indicator for evaluating the goodness of fit of a regression model, expressed as: ; Where n is the number of samples. For the i-th true value, For the i-th predicted value, for The mean; The closer to 1, the better the model fit.