Disease condition outcome prediction method and device based on gating adaptive mechanism

By adopting a multi-layer GAT hybrid model based on a gating adaptive mechanism and Gram angle field conversion technology in the prediction of chronic diseases in the elderly, the complex problems of data acquisition and feature extraction in the existing technology are solved, and the prediction accuracy and accuracy are improved.

CN119694582AActive Publication Date: 2025-03-25HAINAN UNIV
View PDF 6 Cites 0 Cited by

Patent Information

Application Number
CN202411747695.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-02
Publication Date
2025-03-25
Estimated Expiration
2044-12-02

AI Technical Summary

Technical Problem

The prior art has difficulty in predicting chronic disease outcomes in the elderly, insufficient data sharing, complex feature selection and extraction, and traditional methods are difficult to capture complex interactions between variables, and is prone to overfitting problems, resulting in poor performance of the model on new data.

Method used

Using a method based on the gating adaptive mechanism, the feature correlation analysis and graph data generation are obtained by obtaining chronic disease-related data, and prediction is performed using a multi-layer GAT hybrid model, including the GATConv layer, the LSTMAggregation layer and the feature fusion layer based on the gating adaptive. Finally, the time series is output as a result matrix using the Gram angle field.

Benefits of technology

The performance of the disease outcome prediction model is improved, the graph feature extraction ability is enhanced, the prediction accuracy and accuracy are effectively improved, and further outcome analysis is facilitated through the outcome matrix.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119694582A_ABST
    Figure CN119694582A_ABST
Patent Text Reader

Abstract

The invention relates to an illness condition outcome prediction method and device based on a gating adaptive mechanism. The method comprises the following steps: acquiring chronic disease related data, performing feature correlation analysis according to the chronic disease related data, generating graph data, and performing feature enhancement on the graph data; based on the graph data, utilizing a multi-layer GAT hybrid model to carry out prediction, and obtaining a time sequence of a transition state; wherein the multi-layer GAT hybrid model comprises a plurality of GATConv layers, a plurality of LSTMAggregation layers and a feature fusion layer based on gating self-adaption; and outputting the time sequence of the conversion state as a conversion matrix by using a Grubm angle field. According to the method, graph-level global feature fusion is carried out through a gating mechanism and an attention mechanism, so that the multi-layer GAT hybrid model has a strong graph feature extraction capability, and the precision and accuracy of power prediction can be effectively improved. Meanwhile, the multi-layer GAT hybrid model is used for carrying out outcome prediction on each data point of each patient, and then a Gream angle field is adopted to generate an outcome matrix, so that further outcome analysis is facilitated.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of data processing technology, and in particular to a method and device for predicting disease progression based on a gated adaptive mechanism. Background Art

[0002] As the global population ages, the proportion of the elderly population gradually increases, and the incidence and mortality of chronic diseases in this population also rise. Chronic diseases such as cardiovascular disease, diabetes, chronic respiratory diseases, etc. have become major public health issues, causing tremendous pressure on personal health, medical resources and social economy. By predicting the progression of chronic diseases, early intervention can be achieved, improving the quality of life of patients and reducing medical costs.

[0003] The prognosis prediction of elderly patients with chronic diseases is to conduct risk assessment for each patient and predict their future disease progression by analyzing the patient's information, including medical history, laboratory test results, lifestyle, medical records, etc. Based on the prediction results, a personalized intervention and management plan is formulated, including drug treatment, lifestyle changes, regular monitoring, etc.

[0004] With the development of technologies such as data analysis, artificial intelligence, and machine learning, researchers have proposed different prediction methods to solve the problem of chronic disease progression prediction. Chronic disease progression prediction can be divided into statistical methods, methods based on artificial intelligence (AI), and methods based on deep learning. Among the statistical methods, there are: logistic regression, linear regression, analysis of variance (ANOVA), Cox proportional hazard model, etc. Among the traditional machine learning methods, there are: support vector machine (SVM), decision tree, random forest, k-nearest neighbor algorithm (k-NN, K-Nearest Neighbor), etc. Prediction models based on neural networks, such as: Feedforward Neural Network (FNN), which is suitable for regression and classification tasks and can automatically extract data features; Convolutional Neural Networks (CNN), which is suitable for image data analysis, such as medical image processing, and can discover spatial features; Recurrent Neural Networks (RNN), Long Short-Term Memory (LSTM), which are suitable for processing time series data and can capture dynamic features that change over time.

[0005] However, although existing technologies for predicting the prognosis of chronic diseases in the elderly have made progress in many aspects, it is difficult to collect data related to chronic diseases in elderly patients, and data sharing between different medical institutions is insufficient. At the same time, chronic diseases in the elderly usually involve multiple factors (such as physiological, psychological, and social), multiple chronic diseases coexist, and the feature selection and extraction process is complicated. Traditional methods may find it difficult to capture the complex interactions between variables; and complex models are prone to overfitting the training data, resulting in poor performance on new data. Therefore, although modern technology has made significant progress in medical diagnosis, it still faces many challenges in achieving model generalization, coexistence of multiple diseases, and clinical application. Summary of the invention

[0006] Based on this, it is necessary to provide a disease outcome prediction method and device based on a gated adaptive mechanism to address the above technical problems and improve the performance of the outcome prediction model.

[0007] In a first aspect, the present application provides a method for predicting disease progression based on a gated adaptive mechanism.

[0008] The method includes:

[0009] Obtain chronic disease-related data, perform feature correlation analysis based on the chronic disease-related data, generate graph data, and perform feature enhancement on the graph data;

[0010] Based on the graph data, a multi-layer GAT hybrid model is used to make predictions and obtain the time series of the outcome status; wherein the multi-layer GAT hybrid model includes several GATConv layers, several LSTMAggregation layers, and a feature fusion layer based on gated adaptation;

[0011] The time series of transition states is output as a transition matrix using the Gram angle field.

[0012] In one embodiment, after acquiring the chronic disease related data, the method further includes: preprocessing the chronic disease related data;

[0013] Preprocessing of chronic disease related data includes:

[0014] Clean and fill data related to chronic diseases based on expert prior knowledge;

[0015] Standardize continuous feature data by Z-score;

[0016] One-hot encodes discrete feature data.

[0017] In one embodiment, performing feature correlation analysis based on chronic disease related data, generating graph data and performing feature enhancement on the graph data includes:

[0018] The KNN algorithm and Euclidean distance are used to convert chronic disease related data into graph data;

[0019] Based on graph data, the node2vec algorithm is used to enhance graph features.

[0020] In one embodiment, in a multi-layer GAT hybrid model, several GATConv layers are cascaded, and each GATConv layer is connected to an LSTMAggregation layer corresponding to the GATConv layer one by one, and each LSTMAggregation layer is connected to a feature fusion layer based on gated adaptation.

[0021] In one embodiment, the chronic disease related data include historical statistical data before admission and physiological indicators in the hospital.

[0022] In one embodiment, the multi-layer GAT hybrid model further includes: a fully connected layer connected to the gated adaptive feature fusion layer.

[0023] In a second aspect, the present application also provides a disease progression prediction device based on a gated adaptive mechanism. The device comprises:

[0024] The data processing module is used to obtain chronic disease related data, perform feature correlation analysis based on the chronic disease related data, generate graph data and perform feature enhancement on the graph data;

[0025] The model prediction module is used to predict based on the graph data using a multi-layer GAT hybrid model to obtain the time series of the outcome status; wherein the multi-layer GAT hybrid model includes several GATConv layers, several LSTMAggregation layers, and a feature fusion layer based on gated adaptation;

[0026] The transition matrix generation module is used to output the time series of transition states into a transition matrix using the Gram angle field.

[0027] In a third aspect, the present application further provides a computer device, which includes a memory and a processor, wherein the memory stores a computer program, and the processor implements the steps in the above-mentioned disease outcome prediction method based on the gated adaptive mechanism when executing the computer program.

[0028] In a fourth aspect, the present application further provides a computer-readable storage medium having a computer program stored thereon, which implements the steps in the above-mentioned disease outcome prediction method based on the gated adaptive mechanism when executed by a processor.

[0029] In a fifth aspect, the present application also provides a computer program product, including a computer program, which implements the steps in the above-mentioned disease outcome prediction method based on the gated adaptive mechanism when executed by a processor.

[0030] The above-mentioned method and device for predicting disease outcome based on the gated adaptive mechanism obtains chronic disease related data, performs feature correlation analysis based on the chronic disease related data, generates graph data and performs feature enhancement on the graph data; predicts based on the graph data using a multi-layer GAT hybrid model to obtain a time series of outcome status; wherein the multi-layer GAT hybrid model includes several GATConv layers, several LSTMAggregation layers and a feature fusion layer based on gated adaptation; and uses the Gram angular field to output the time series of outcome status as a transition matrix. The present invention performs global feature fusion at the graph level through a gating mechanism and an attention mechanism, so that the multi-layer GAT hybrid model has a powerful graph feature extraction capability, which can effectively improve the precision and accuracy of power prediction. At the same time, the above-mentioned multi-layer GAT hybrid model is used to perform outcome prediction for each data point of each patient, and then the Gram angular field is used to generate a transition matrix, which is convenient for further outcome analysis. BRIEF DESCRIPTION OF THE DRAWINGS

[0031] Figure 1 It is a flowchart of a method for predicting disease outcome based on a gated adaptive mechanism in one embodiment;

[0032] Figure 2 A schematic diagram of the data structure in one embodiment;

[0033] Figure 3 A schematic diagram of the structure of a disease outcome prediction model of a gated adaptive mechanism in one embodiment;

[0034] Figure 4 A schematic diagram of calculating the attention coefficient of the GATConv layer in one embodiment;

[0035] Figure 5 A schematic diagram of multi-head attention calculation of the GATConv layer in one embodiment;

[0036] Figure 6 This is an internal structure diagram of LSTMAggregation in one embodiment;

[0037] Figure 7 A visualization diagram of the outcome matrix of two randomly selected patients in one embodiment;

[0038] Figure 8 The figure is a schematic diagram of the overall process of a disease outcome prediction method based on a gated adaptive mechanism in one embodiment. DETAILED DESCRIPTION

[0039] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.

[0040] The present application embodiment provides a method for predicting disease progression based on a gated adaptive mechanism, such as Figure 1 As shown, the following steps are included:

[0041] Step 102, obtaining chronic disease related data, performing feature correlation analysis based on the chronic disease related data, generating graph data and performing feature enhancement on the graph data.

[0042] This embodiment aims at predicting the progression of chronic diseases in the elderly, and the original data used can be provided by the hospital. The original data includes historical statistical data at the time of admission and multiple physiological index examination information during the hospital stay. Some index information is shown in Table 1 and Table 2, where Table 1 is a partial example of admission information and Table 2 is a partial example of physiological indicators in the hospital.

[0043] Table 1 Admission information

[0044]

[0045] Table 2 Physiological indicators in hospital

[0046] Serial number Indicator characteristics Serial number Indicator characteristics 1 Urea nitrogen 13 Hematocrit 2 glucose 14 platelets 3 Hemoglobin 15 Antithrombin III 4 body temperature 16 breathe 5 Systolic blood pressure 17 pulse 6 Uric acid 18 Total cholesterol 7 Creatinine (enzymatic method) 19 Glycated hemoglobin 8 Blood oxygen pressure 20 Blood oxygen saturation_x 9 Actual body temperature plasma pH 21 C-reactive protein (high sensitivity) 10 Heart rate 22 Neutrophil percentage 11 Albumin (bromocresol green method) 23 HDL cholesterol 12 LDL cholesterol 24 Fibrinogen

[0047] The original data also include four discharge statuses: "improved", "not cured", "worsened" and "death". The above discharge status is the outcome status.

[0048] First, we selected data with high availability from the original data. Specifically, we selected data with fewer missing values ​​from the physiological index data during hospitalization, and merged them with the historical statistical data at the time of admission according to the patient number, and screened out several data sets.

[0049] Then, the correlation analysis of the indicators is performed. Specifically, each case of data is taken as a graph, each indicator feature is taken as a separate node, and the corresponding discharge status is taken as the graph label. For the construction of edges, the unsupervised KNN algorithm is used to select associated nodes. Specifically, the Euclidean distance is used to measure the similarity between indicator features; the Euclidean distance between each feature is calculated, and a smaller value means that the association between the two indicator features is stronger, that is, the correlation is stronger. Edge connections are established between the node and its k nearest neighbors, and the feature sequence is converted into a graph data representation. Through graph representation learning, information about changes in physiological indicator conditions at different times can be captured to enhance the representation ability of samples, help the prediction model to more deeply understand the intrinsic connection between data, and can intuitively represent the relationship between entities, which helps to discover hidden patterns in the data.

[0050] Then, the features of the graph nodes are enhanced. Specifically, the node2vec algorithm is used to generate node embedding vectors and concatenate them with the original features of the nodes. Node2vec is an effective graph representation learning algorithm that aims to map the nodes in the graph to vector representations in a low-dimensional space while retaining the neighbor information in its graph structure. Using node2vec to enhance the features of the graph nodes can well reflect the connection patterns and distances between the nodes in the original graph. The generated node embedding vector captures the contextual information of the node, which helps to improve the performance of the model on downstream prediction tasks.

[0051] Step 104, using a multi-layer GAT hybrid model to make predictions based on the graph data to obtain a time series of the outcome status; wherein the multi-layer GAT hybrid model includes a plurality of GATConv layers, a plurality of LSTMAggregation layers, and a feature fusion layer based on gated adaptation.

[0052] The multi-layer GAT hybrid model is built based on the python programming language, pytorch framework and torch_geometric library. In this model, GATConv is a graph convolution operation based on the graph attention mechanism. By introducing the attention mechanism to dynamically learn the interaction weights between nodes, it can adaptively determine the degree of influence of neighbor nodes on the current node according to the relationship between the features of neighbor nodes and the features of the current node, so as to more effectively capture the complex relationship in the graph structure. As an aggregation mechanism, LSTMAggregation can be used in the message passing process in graph neural networks. It uses the ability of long short-term memory network (LSTM) to aggregate the information of neighbor nodes to capture the sequential dependencies between nodes. It can effectively process long sequence data and selectively remember or forget information at different positions in the sequence. The aggregation mechanism can dynamically adjust the retention or forgetting of information according to the importance and contextual relationship of neighbor nodes, thereby improving the quality and flexibility of information aggregation. The feature fusion layer based on gated adaptation uses the gating mechanism to control the flow of information. According to the importance of the input features, a weight vector is generated to dynamically determine which features should be strengthened and which can be suppressed. The similarity between features is calculated through the attention mechanism to focus on the most relevant information. Finally, the graph-level global features from different layers or different models are combined to obtain richer information representation.

[0053] In one embodiment, several GATConv layers are cascaded. The output of each GATConv layer uses a separate LSTMAggregation layer to aggregate the global features of the entire graph. Then, the output of the LSTMAggregation layer corresponding to each GATConv layer is input into a feature fusion layer based on gated adaptation to perform information fusion between multiple network layers. Finally, the fused information of multiple network layers is input into the fully connected layer of the output layer to obtain the final prediction result.

[0054] Due to the local perception nature of the convolution operation, it is able to encode the spatial relationship of the input data. In a single-layer GATConv, each node can only interact directly with its first-order neighbors. In a multi-layer GATConv, as the number of layers increases, each node can indirectly exchange information with more distant neighbors. This means that the model can take into account a wider range of neighborhood information, which helps to better understand the global structure in the graph. By stacking multiple convolutional layers, the model can gradually extract higher-level feature representations to better understand the input data. However, the superposition of network layers will lead to model degradation. In order to avoid model degradation and improve the predictive ability of the model, a feature fusion layer based on gated adaptation is designed. It is based on the idea of ​​residual connection, and adds gated units and attention mechanisms to adaptively fuse graph-level features of different levels together, enhancing the ability to extract global features of spatial graphs and the ability to learn graph representations.

[0055] Step 106: Output the time series of transition states as a transition matrix using the Gram angle field.

[0056] The multi-layer GAT hybrid model is used to predict the in-hospital data of each patient in turn, and the time series of the outcome status of each data point of a single patient is obtained. The Gramian Angular Field is then used to convert the time series of the outcome status into a transition matrix. Based on the transition matrix, the outcome status can be further analyzed and predicted. Gramian Angular Field (GAF) is a method for converting time series data into a matrix representation. It can combine the data points in the time series in pairs, calculate the cosine of the angle between them, and represent the result as the element value of the matrix. The transition matrix generated in this way, in which the position and size of each element reflects the relationship between the time series data points. And the transition matrix can be used for image visualization and reflect the structure, periodicity and change trend of time series data.

[0057] In one embodiment, after obtaining chronic disease related data, the method also includes: preprocessing the chronic disease related data; preprocessing the chronic disease related data includes: data cleaning and data filling of the chronic disease related data based on expert prior knowledge; Z-score standardization of continuous feature data; one-hot encoding of discrete feature data.

[0058] In order to improve data reliability, this embodiment preprocesses chronic disease-related data. Specifically, based on the expert's prior knowledge, check whether there is data missing or abnormal in the chronic disease-related data, fill the missing values ​​of each indicator with random normal values, restore the patient's real data without affecting the severity of the disease, and clean the data that cannot be supplemented. Standardize the continuous and discrete data after data cleaning and data filling.

[0059] Among them, for continuous features, Z-score standardization is performed, and the standardization formula is:

[0060]

[0061] In the formula, X is the data to be standardized, μ is the mean of the data, σ is the standard deviation of the data, and Z is the normalized result.

[0062] For discrete features, one-hot encoding is performed, that is, the target column is mapped to the target value 0 or 1.

[0063] In one embodiment, feature correlation analysis is performed based on chronic disease related data to generate graph data and perform feature enhancement on the graph data, including: converting the chronic disease related data into graph data using the KNN algorithm and Euclidean distance; and based on the graph data, performing graph feature enhancement using the node2vec algorithm.

[0064] This embodiment calculates feature correlation by Euclidean distance and constructs a correlation graph in combination with KNN.

[0065] Graph feature enhancement specifically utilizes the node2vec graph representation learning model. In one feasible embodiment, the learning model specifies the dimension of the embedding vector dimensions = 16, that is, each node is represented as a 16-dimensional vector; specifies the step length of each random walk walk_length = 5, that is, the number of steps moved on each node in the graph; specifies the number of random walks num_walks = 10 for each node to generate training samples; specifies the number of working threads used in parallel computing workers = 4, which can speed up the calculation process. The node2vec graph representation learning model is trained using graph data, and the node embedding vector can be generated based on the trained node2vec graph representation learning model, and spliced ​​with the original features of the node to complete the graph feature enhancement. Figure 2 The figure shows the specific structure of the graph data.

[0066] In one embodiment, the structure of the multi-layer GAT hybrid model is as follows Figure 3 As shown, its construction and training process is as follows:

[0067] The graph data processed in step 102 is randomly divided into a training data set and a test data set, 80% of which is used as the training data set and the remaining 20% ​​is used as the test data set. Both the training data set and the test data set are from labeled data.

[0068] Taking the multi-layer GAT hybrid model to define three GATConv layers as an example, the three graph attention convolution layers (conv1, conv2, conv3) are used to learn the attention weights of node features and enhance the representation ability of the model through the multi-head attention mechanism. Each GATConv layer accepts node features and edge indexes as input and outputs updated node features. Figure 4 As shown, this is a schematic diagram of the attention coefficient calculation of the GATConv layer. Figure 5 Schematic diagram of multi-head attention calculation of GATConv layer.

[0069] The information flow process of the GATConv layer is as follows:

[0070]

[0071] Among them, W (1) ∈R m×l , W (j) ∈R l×l (when j>1) represent the trainable weight matrices of the first to third GATConv layers respectively. Represent the outputs of the first to third GATConv layers respectively.

[0072] By using the graph attention mechanism, the model can learn the dependencies between nodes in an adaptive manner, and adaptively assign different attention weights to each node. This mechanism makes the model more effective in capturing the importance and neighborhood information of nodes in the graph, thereby producing richer and more distinguishable node representations. The multi-head attention mechanism further enhances the model's ability to capture complex patterns. By learning the representations of multiple relationships between nodes in parallel, it can capture features from different subspaces, increasing the model's expressive power.

[0073] By stacking multiple GATConv layers, feature representations of different scales are learned. Each layer can capture the information of neighbors with different hop counts, so that the model can integrate a wider range of contextual information and improve the expressiveness of features.

[0074] The activation function used by the GATConv layer is the nonlinear activation function ReLU. The use of ReLU helps to maintain the nonlinear expression ability of the network.

[0075] Corresponding to the multi-layer GAT hybrid model with three GATConv layers defined above, three LSTMAggregation layers (lstm_, lstm_2, lstm_3) are defined. Figure 6 The diagram below shows the structure calculation of the LSTMAggregation layer. The three LSTMAggregation layers aggregate the information of the entire graph to capture global dependencies. Each LSTMAggregation layer accepts node features and data batch information batch as input and outputs the global features of the graph.

[0076] The information flow process of the LSTMAggregation layer is as follows:

[0077]

[0078] in, Represent the outputs of the first to third LSTMAggregation layers respectively.

[0079] The LSTMAggregation global pooling layer can take into account the order between nodes and effectively aggregate the information of the entire graph. This is especially important for graph structured data. Because traditional pooling operations (such as average pooling or maximum pooling) usually only focus on the extraction of static features, they cannot directly handle the dynamic changes of the graph and cannot capture the sequential information between nodes. Through LSTMAggregation processing, the model can dynamically learn the representation of global information in the graph, which is of great significance for understanding the structure and feature distribution of the entire graph.

[0080] For traditional neural networks, if you simply increase the number of network layers, you will often encounter problems such as gradient vanishing or gradient exploding during training. These problems cause the network training effect to become worse and worse. To this end, a feature fusion layer based on gated adaptive Fusion Block is designed, such as Figure 3 It is based on the idea of ​​residual connection and adds gating units and attention mechanisms to adaptively fuse graph-level features at different levels.

[0081] In the Fusion Block, three gate units are first used to adaptively weight features at different levels and then add them element-wise to obtain a feature vector V. After that, the feature vector V is input into a FC (Fully Connected) layer for linear transformation. After that, a Tanh activation function is added to map the input value to the interval [-1,1] to enhance the nonlinear representation of the feature. Next, another FC layer is used to encode the attention score of the feature, which is then normalized using the Softmax function to convert the attention score into a probability distribution matrix K. Finally, the attention probability matrix K is multiplied by each element of V to obtain a new graph-level feature matrix. This module fuses the graph-level features of each level, so that the effective features of each level are retained and enhanced, the global features are effectively extracted, and the representation ability of key features is enhanced. The feature vector V and the attention probability matrix K are obtained by the following equations:

[0082]

[0083] K = softmax(FC(tanh(FC(V))))

[0084] Among them, ω j Represents three trainable parameters.

[0085] The multi-layer GAT hybrid model also defines a fully connected layer lin to convert the final aggregated features into a single output value for the final prediction. The output of the fully connected layer is:

[0086] pred=FC(V*K)

[0087] In one feasible embodiment, the feature dimension of the output from conv1 to conv3 is 3, the number of attention heads is defined as 8, and the activation function is ReLU. In addition, conv1 receives node inputs with 17 features, and conv2 and conv3 both receive node inputs with 24 features. The selected nonlinear activation function ReLU helps to maintain the nonlinear expression ability of the network.

[0088] The input and output dimensions of lstm_1 to lstm_3 are all set to 24.

[0089] The input dimension of the first fully connected layer in the Fusion Block is set to 24, and the output dimension is set to 24; the input dimension of the second fully connected layer is set to 24, and the output dimension is set to 1.

[0090] The input dimension of the fully connected layer lin is set to 24 and the output dimension is set to 1.

[0091] First, the data passes through conv1; its output is input to conv2 and lstm_1 respectively; the output of conv2 is input to conv3 and lstm_2 respectively; the output of conv3 is input to lstm_3. Then, lstm_1 to lstm_3 perform element-level multiplication operations with gate units w1 to w3 respectively, and the results are input to Fusion Block; finally, they are input to lin for final prediction.

[0092] After completing the construction of the multi-layer GAT hybrid model, the model is trained with the training set. In the forward operation of the neural network, the loss function is set to CrossEntropyLoss. Cross entropy loss gives a higher loss value to samples with poor classification effect in the early stage of model training, which can accelerate the model's learning of difficult-to-classify samples; its calculation formula is as follows:

[0093]

[0094] Where N is the number of samples; M is the number of sample categories; y ic is a sign function (0 or 1), if the true category of sample i is equal to c, it takes 1, otherwise it takes 0; p ic is the probability that the i-th sample is predicted to belong to category c.

[0095] Neural networks adjust parameters through back propagation to improve performance. Here, the optimizer is set to Adam. Compared with other optimizers, such as Adagrad and RMSProp, Adam has an adaptive learning rate mechanism, fewer hyperparameters, and can adaptively adjust the gradient, which is simpler, more stable, and more efficient.

[0096] The accuracy and loss value of the model and the accuracy of the confusion matrix were evaluated using the test data set. The target value was the patient's outcome status, and the model's outcome prediction accuracy reached 80%.

[0097] The accuracy of model classification is one of the important criteria for evaluating model performance. A high accuracy rate means that the model correctly identifies most of the sample data, indicating that the model has good classification and generalization capabilities. The formula is:

[0098]

[0099] TP represents the number of samples correctly predicted as positive by the model, TN represents the number of samples correctly predicted as negative by the model, FP represents the number of samples incorrectly predicted as positive by the model, and FN represents the number of samples incorrectly predicted as negative by the model.

[0100] Precision can be predicted as the accuracy in the positive sample, and its formula is:

[0101]

[0102] In order to illustrate the impact of the semi-supervised model of the present invention on the overall performance, ablation experiments of different components were conducted. Without changing the parameters of the network model, two models with and without feature fusion layers were trained, and the accuracy and precision of the model were used as comparison indicators of the ablation experiment. The comparison results are shown in Table 3.

[0103] Table 3 Experimental comparison of the performance of the two models

[0104] Accuracy Accuracy GAT without feature fusion 74% 70.05% GAT has feature fusion 82% 79.8%

[0105] It can be seen from Table 3 that the accuracy and precision of the model with feature fusion layer are greatly improved.

[0106] In one embodiment, the specific process of generating the patient outcome matrix is ​​as follows: extract the chronic disease-related data of each patient from the original data set, arrange them in chronological order, and select several patients with the largest amount of data to generate the outcome matrix. Specifically, the data of each patient is input into the trained multi-layer GAT hybrid model in chronological order to obtain the time series of the predicted outcome status. The Gramian Angular Field (GAF) is used to convert the time series into the outcome matrix.

[0107] Construct an N×N Gram matrix G, where G(i,j) represents the cosine of the angle between data points xi and xj. Standardize the values ​​of the Gram matrix G to the range [0,1]. Convert the standardized Gram matrix to a grayscale image matrix, with each pixel value corresponding to the value in the standardized Gram matrix. Call the GramianAngularField method of the pyts library to convert the transition state time series into a transition matrix, and use the matplotlib library for visualization. The final view is as follows: Figure 7 shown.

[0108] The present invention uses a multi-layer GAT hybrid model for the first time in the task of predicting the prognosis of elderly chronic diseases, and applies the test on the in-hospital data set of chronic disease patients. The missing values ​​of the indicators are scientifically filled according to expert experience; the feature correlation is analyzed by the KNN algorithm to generate a graph data representation, which helps to discover hidden patterns in the data; the node embedding vector is generated by the node2vec graph representation learning model, and it is spliced ​​with the original features of the node to enhance the graph features. The node vector obtained by node2vec captures the contextual information of the node, which helps to improve the performance of the model on these tasks; the GAT hybrid model adopts a multi-layer structure, that is, multiple graph attention convolution layers, multiple LSTMAggregation layers and fully connected layers are superimposed together. The multi-layer structure can gradually extract higher-level feature representations, and increase the nonlinear ability and expression ability of the model by stacking different layers. The present invention comprehensively utilizes the advantages of the graph attention network and LSTMAggregation, in which GAT can effectively learn the local features of the graph, while LSTMAggregation aggregates node features and models the global information of the graph. By combining them together, the model can more comprehensively capture the feature information in the prognosis state prediction task and improve the performance of the model. In addition, the feature fusion strategy proposed in the present invention can help the network better capture features and improve the learning ability of the network. Through the attention mechanism based on the gated unit, the model can be adaptively adjusted according to the importance of global features at different levels to achieve flexible feature fusion. Such a design enables the network to better utilize features extracted from different levels and improves the performance of the model. Finally, the patient dynamic outcome matrix is ​​generated by the Gram angle field, which can be used for image visualization and can intuitively reflect the structure, periodicity and change trend of patient outcome-related time series data.

[0109] like Figure 8 As shown, it is an overall flow chart of the disease outcome prediction method based on the gated adaptive mechanism disclosed in the present invention.

[0110] The present invention mainly includes three creative contents: data processing, model building and model application.

[0111] 1. Data processing method combines expert prior knowledge and uses KNN algorithm, distance metric and Node2Vec to process data. The elderly chronic disease dataset used includes four prognosis states for the first time. This data processing method can not only capture information about changes in physiological indicators at different times, but also help the prediction model to more deeply understand the intrinsic connection between data, improve the accuracy of data processing and the prediction ability of the model.

[0112] 2. The constructed multi-layer GAT hybrid model uses multiple GATs in series to extract neighbor information of different hops, and LSTMAggregation aggregates global features at different levels to enhance the model's feature extraction capabilities. Through the feature fusion strategy based on the attention mechanism of the gated unit, the common gradient vanishing problem in deep networks is effectively alleviated, ensuring the stability and effectiveness of model training.

[0113] 3. This model was first applied to the prognosis prediction of chronic diseases in the elderly, achieving comprehensive evaluation and diagnosis of four prognosis states and generating a prognosis matrix based on GAF. This application fills the gap in the diagnosis model of chronic diseases in the elderly in the prediction of disease progression and provides a new technical means for clinical practice.

[0114] The specific beneficial results of the present invention are as follows:

[0115] The KNN algorithm analyzes the correlation to generate graph data representation to improve the efficiency of information transmission and the depth of understanding. Graph feature enhancement captures the contextual information of the nodes and strengthens the graph structure features. A multi-layer GAT hybrid model was established, which not only has the advantages of capturing both local and global graph features, but also avoids the loss and deformation of information in deep network transmission. An attention mechanism based on gated units was proposed to achieve flexible global feature fusion. GAF was used to generate the prognosis matrix, which intuitively reflects the transition information of the patient's prognosis status. These beneficial results enable this method to achieve higher performance, which can assist doctors to better understand the patient's disease condition and design more reasonable treatment plans for patients.

[0116] It should be understood that, although the various steps in the flowcharts involved in the above-mentioned embodiments are displayed in sequence according to the indication of the arrows, these steps are not necessarily executed in sequence according to the order indicated by the arrows. Unless there is a clear explanation in this article, the execution of these steps does not have a strict order restriction, and these steps can be executed in other orders. Moreover, at least a part of the steps in the flowcharts involved in the above-mentioned embodiments can include multiple steps or multiple stages, and these steps or stages are not necessarily executed at the same time, but can be executed at different times, and the execution order of these steps or stages is not necessarily to be carried out in sequence, but can be executed in turn or alternately with other steps or at least a part of the steps or stages in other steps.

[0117] Based on the same inventive concept, the embodiment of the present application also provides a device for predicting disease outcomes based on a gated adaptive mechanism for implementing the disease outcome prediction method based on a gated adaptive mechanism. The implementation scheme for solving the problem provided by the device is similar to the implementation scheme recorded in the above method, so the specific limitations in the embodiments of one or more disease outcome prediction devices based on a gated adaptive mechanism provided below can refer to the limitations of the disease outcome prediction method based on a gated adaptive mechanism above, and will not be repeated here.

[0118] In one embodiment, a device for predicting disease progression based on a gated adaptive mechanism is provided, comprising:

[0119] The data processing module is used to obtain chronic disease related data, perform feature correlation analysis based on the chronic disease related data, generate graph data and perform feature enhancement on the graph data;

[0120] The model prediction module is used to predict based on the graph data using a multi-layer GAT hybrid model to obtain the time series of the outcome status; wherein the multi-layer GAT hybrid model includes several GATConv layers, several LSTMAggregation layers, and a feature fusion layer based on gated adaptation;

[0121] The transition matrix generation module is used to output the time series of transition states into a transition matrix using the Gram angle field.

[0122] In one embodiment, the data processing module is also used to preprocess chronic disease related data; preprocessing chronic disease related data includes: data cleaning and data filling of chronic disease related data based on expert prior knowledge; Z-score standardization of continuous feature data; one-hot encoding of discrete feature data.

[0123] In one embodiment, the data processing module is also used to convert chronic disease related data into graph data using the KNN algorithm and Euclidean distance; based on the graph data, the node2vec algorithm is used to enhance graph features.

[0124] In one embodiment, in a multi-layer GAT hybrid model, several GATConv layers are cascaded, and each GATConv layer is connected to an LSTMAggregation layer corresponding to the GATConv layer one by one, and each LSTMAggregation layer is connected to a feature fusion layer based on gated adaptation.

[0125] In one embodiment, the chronic disease related data include historical statistical data before admission and physiological indicators in the hospital.

[0126] In one embodiment, the multi-layer GAT hybrid model further includes: a fully connected layer connected to the gated adaptive feature fusion layer.

[0127] Each module in the above-mentioned disease outcome prediction device based on the gated adaptive mechanism can be implemented in whole or in part by software, hardware, or a combination thereof. Each of the above-mentioned modules can be embedded in or independent of the processor in the computer device in the form of hardware, or can be stored in the memory in the computer device in the form of software, so that the processor can call and execute the operations corresponding to each of the above modules.

[0128] In one embodiment, a computer device is provided, including a memory and a processor, wherein a computer program is stored in the memory, and the processor implements the steps in all the above method embodiments when executing the computer program.

[0129] In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the steps in all the above method embodiments are implemented.

[0130] In one embodiment, a computer program product is provided, including a computer program, which implements the steps in all the above method embodiments when executed by a processor.

[0131] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of relevant data must comply with relevant laws, regulations and standards of relevant countries and regions.

[0132] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to the memory, database or other medium used in the embodiments provided in the present application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetoresistive random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. As an illustration and not limitation, RAM can be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM). The database involved in each embodiment provided in this application may include at least one of a relational database and a non-relational database. Non-relational databases may include distributed databases based on blockchains, etc., but are not limited to this. The processor involved in each embodiment provided in this application may be a general-purpose processor, a central processing unit, a graphics processor, a digital signal processor, a programmable logic device, a data processing logic device based on quantum computing, etc., but are not limited to this.

[0133] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.

[0134] The above-described embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the present application. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the present application shall be subject to the attached claims.

Claims

1. A method for predicting disease outcome based on a gated adaptive mechanism, characterized in that: The method comprises: Acquire chronic disease related data, perform feature correlation analysis based on the chronic disease related data, generate graph data, and perform feature enhancement on the graph data; Based on the graph data, a multi-layer GAT hybrid model is used to make predictions to obtain a time series of the outcome status; wherein the multi-layer GAT hybrid model includes a plurality of GATConv layers, a plurality of LSTMAggregation layers, and a feature fusion layer based on gated adaptation; The time series of the transition states is output as a transition matrix using the Gram angle field.

2. The method according to claim 1, characterized in that After acquiring the chronic disease related data, the method further includes: preprocessing the chronic disease related data; The preprocessing of the chronic disease related data includes: Performing data cleaning and data filling on the chronic disease-related data based on expert prior knowledge; Standardize continuous feature data by Z-score; One-hot encodes discrete feature data.

3. The method according to claim 1, characterized in that: The performing feature correlation analysis according to the chronic disease related data, generating graph data and performing feature enhancement on the graph data comprises: The chronic disease related data are converted into graph data using KNN algorithm and Euclidean distance; Based on the graph data, the node2vec algorithm is used to enhance graph features.

4. The method according to claim 1, characterized in that: In the multi-layer GAT hybrid model, several GATConv layers are cascaded, and each GATConv layer is respectively connected to the LSTMAggregation layer corresponding to the GATConv layer one by one, and each LSTMAggregation layer is connected to the feature fusion layer based on gated adaptation.

5. The method according to claim 1, characterized in that The chronic disease-related data include historical statistical data before admission and physiological indicators in the hospital.

6. The method according to claim 1, characterized in that The multi-layer GAT hybrid model also includes: a fully connected layer connected to the gated adaptive feature fusion layer.

7. A device for predicting disease progression based on a gated adaptive mechanism, characterized in that: The device comprises: A data processing module, used to obtain chronic disease related data, perform feature correlation analysis based on the chronic disease related data, generate graph data and perform feature enhancement on the graph data; A model prediction module, used to predict based on the graph data using a multi-layer GAT hybrid model to obtain a time series of the outcome status; wherein the multi-layer GAT hybrid model includes a plurality of GATConv layers, a plurality of LSTMAggregation layers, and a feature fusion layer based on gated adaptation; The transition matrix generation module is used to output the time series of the transition state as a transition matrix using the Gram angle field.

8. A computer device comprising a memory and a processor, wherein the memory stores a computer program, wherein: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 6 are implemented.

9. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 6 are implemented.

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

Citation Information

Patent Citations

  • Risk prediction method for chronic diseases and related equipment

    CN115862842A

  • Network traffic matrix prediction method based on improved GAT and spatial-temporal characteristics

    CN116668317A

  • Time series data prediction method associated with time-space relationship

    CN117668743A

  • Simulated medical information detection method and system based on AI algorithm

    CN118471539A

  • Time series data anomaly detection method combining graph learning and double attention mechanism

    CN118779804A