An Adaptive Spatiotemporal Graph Neural Network Missing Data Completion Method

Through the adaptive spatiotemporal graph neural network method, combined with global and local feature information, the performance of the Transformer framework in dealing with high-dimensional nonlinear spatiotemporal coupled features is solved, and efficient data completion effect is achieved.

CN120256845BActive Publication Date: 2025-08-22湖南工商大学
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202510751431.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-06-06
Publication Date
2025-08-22
Estimated Expiration
2045-06-06

AI Technical Summary

Technical Problem

When the existing data completion model based on Transformer framework processes real-world data with high-dimensional nonlinear space-time coupled features, it fails to effectively integrate the correlation characteristics of the data in the spatial dimension, and ignores the differences in the importance of nodes in the spatial topological relationship, resulting in insufficient performance.

Method used

Adaptive spatiotemporal graph neural network method is adopted to complete data by constructing mask matrix, multi-head attention mechanism and adaptive graph structure, combining global feature information and local feature information.

Benefits of technology

It realizes efficient data completion under complex space-time coupling features, improves the model's timing modeling accuracy and spatial structure fidelity, and improves the performance of data completion.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120256845B_ABST
    Figure CN120256845B_ABST
Patent Text Reader

Abstract

The present application relates to an adaptive spatiotemporal graph neural network missing data completion method, which includes: constructing a mask matrix based on missing positions in time series data; splicing the time series data and the mask matrix and inputting them into a fully connected layer to obtain a first feature; subjecting the first feature to a multi-head attention mechanism to obtain a second feature; constructing an adaptive graph structure to extract global feature information and local feature information from the graph structure; weightedly combining the local feature information and the global feature information to obtain a third feature; normalizing the sum of the first feature and the third feature to obtain a fourth feature; performing a linear change on the fourth feature to obtain completed data; splicing the completed data with the mask matrix, and repeatedly executing the completed data calculation step until a preset number of times is reached; obtaining final completed data based on the completed data obtained in each iteration; completing the time series data based on the final completed data to obtain completed time series data.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the technical field of data completion, and in particular to a method for completing missing data in an adaptive spatiotemporal graph neural network. Background Art

[0002] The existing data completion model based on the Transformer framework has the following problems:

[0003] 1. The core attention computational paradigm of Transformer-based data completion models suffers from fundamental limitations: this mechanism is primarily designed for the temporal dimension and fails to effectively integrate the spatial correlation characteristics of data. This architectural flaw often results in the model failing to meet expectations when processing real-world data characterized by high-dimensional, nonlinear spatiotemporal coupling.

[0004] 2. Existing traditional data completion methods based on the Transformer architecture have significant flaws in their information aggregation process. Specifically, these methods perform global information fusion based solely on the semantic similarity of variable nodes, completely ignoring the differences in node importance within spatial topological relationships. This singular reliance on semantic features makes it difficult for the model to accurately identify and enhance the influence of key nodes in complex spatial structures, thereby limiting data completion performance. Summary of the Invention

[0005] Based on this, it is necessary to provide an adaptive spatiotemporal graph neural network missing data completion method, which includes:

[0006] S1: Collect the time series data of the sensor in the selected time period and construct a mask matrix based on the missing positions in the time series data;

[0007] S2: The time series data and the mask matrix are concatenated and input into the fully connected layer to obtain the first feature; the first feature is projected into the query matrix, key matrix, and value matrix respectively, and the second feature is obtained through the multi-head attention mechanism;

[0008] S3: Construct an adaptive graph structure, obtain the corresponding attenuation matrix based on the sparse graph structure, and use the attention mechanism to calculate the global feature information by combining the second feature and the attenuation matrix. Aggregate the features of each node in the sparse graph structure with the features of its neighboring nodes to obtain local feature information. The local feature information and the global feature information are weighted and combined to obtain the third feature.

[0009] S4: Normalize the sum of the first feature and the third feature to obtain the fourth feature; perform a linear transformation on the fourth feature to obtain the completed data; concatenate the completed data with the mask matrix, and repeat steps S2-S4 until a preset number of times is reached;

[0010] S5: Based on the completed data obtained in each iteration, the final completed data is obtained; based on the final completed data, the time series data is completed to obtain the completed time series data.

[0011] Preferably, the time series data includes the observed values ​​of each variable at each time point within a selected time period in the debutanizer refining process.

[0012] Preferably, constructing a mask matrix based on missing positions in the time series data includes:

[0013] Each missing position in the time series data is marked as 0, otherwise it is marked as 1 to obtain a mask matrix.

[0014] Preferably, constructing an adaptive graph structure and obtaining a corresponding attenuation matrix based on the sparse graph structure includes:

[0015] Define a learning matrix where the values ​​of each node in the learning matrix are random values, and the number of nodes in the learning matrix corresponds to the number of observations at any time point in the time series data;

[0016] Multiply the learning matrix by the transpose of the learning matrix, pass the first product through the ReLU activation function, and pass the first activation result through the softmax activation function to construct an adaptive graph structure;

[0017] Determine whether the value of each node in the graph structure is greater than or equal to a preset threshold. If so, retain the value of the corresponding node; otherwise, set the value of the corresponding node to 0 to obtain a sparse graph structure.

[0018] Based on the sparse graph structure, the in-degree strength of each node is calculated to construct the node in-degree strength matrix;

[0019] The node in-degree intensity matrix is ​​normalized to obtain the attenuation matrix.

[0020] Preferably, the calculation process of the global feature information includes:

[0021] Projecting the second feature into a second query matrix, a second key matrix, and a second value matrix respectively;

[0022] Multiplying the second query matrix and the second key matrix element by element, and dividing the obtained second product by the dimension of the second feature to obtain a semantic similarity matrix including the semantic similarity between each node;

[0023] The semantic similarity matrix is ​​multiplied element-by-element by the attenuation matrix, the third product is passed through the softmax activation function, and the second activation result is multiplied by the second value matrix to obtain the global feature information.

[0024] Preferably, the calculation process of local feature information includes:

[0025] In a sparse graph structure,

[0026] Multiply the value of the selected node by the first weight matrix to obtain a fourth product, and multiply the value of any neighboring node by the second weight matrix to obtain a fifth product;

[0027] The fourth product and the fifth product are activated by the LeakyReLU function, and the third activation result is activated by the softmax function to obtain the attention weight between the corresponding two nodes;

[0028] Traverse all neighbor nodes of the selected node, calculate the attention weights between the selected node and all its neighbor nodes, and the fifth product of all its neighbor nodes;

[0029] Calculate the product of the fifth product of any neighbor node and the corresponding attention weight to obtain the corresponding feature of the neighbor node;

[0030] The features corresponding to all neighboring nodes of the selected node are summed up, and the summation result is passed through the sigmoid activation function to obtain local feature information.

[0031] Preferably, the weighted combination of local feature information and global feature information includes:

[0032] Multiplying the global feature information by the first weight parameter element by element to obtain a sixth product;

[0033] Multiplying the local feature information by the balance number of the first weight parameter about 1 element by element to obtain a seventh product;

[0034] Adding the sixth product to the seventh product yields the third characteristic.

[0035] Preferably, the preset number of times is 2 times.

[0036] Preferably, the calculation process of the final completed data is:

[0037] The completed data obtained twice are passed through the fully connected layer in sequence to obtain the first completed data and the second completed data respectively;

[0038] Multiplying the first completed data by the second weight parameter to obtain an eighth product;

[0039] Multiplying the second completed data by a balance number of the second weight parameter about 1 to obtain a ninth product;

[0040] Add the eighth product and the ninth product to obtain the final completed data.

[0041] Preferably, the process of obtaining the completed time series data includes:

[0042] Multiply the time series data by the mask matrix element by element, multiply the final completed data by the balance number of the mask matrix about 1 element by element, and add the two multiplication results to obtain the completed time series data.

[0043] Beneficial effects: This method constructs a mask matrix based on the missing positions in the time series data; splices the time series data and the mask matrix and inputs them into the fully connected layer to obtain the first feature; the first feature is passed through a multi-head attention mechanism to obtain the second feature; an adaptive graph structure is constructed to extract global feature information and local feature information from the graph structure; weighted combination of local feature information and global feature information is performed to obtain the third feature; the sum of the first feature and the third feature is normalized to obtain the fourth feature; a linear change is performed on the fourth feature to obtain the completed data; the completed data is spliced ​​with the mask matrix, and the completed data calculation steps are repeated until a preset number of times is reached; based on the completed data obtained in each iteration, the final completed data is obtained; the time series data is completed based on the final completed data to obtain the completed time series data, thereby realizing the completion of missing data. BRIEF DESCRIPTION OF THE DRAWINGS

[0044] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without any creative work.

[0045] Figure 1 This is a flowchart of the method for completing missing data in an adaptive spatiotemporal graph neural network in an embodiment of the present application. DETAILED DESCRIPTION

[0046] To make the above-mentioned objects, features, and advantages of the present application more clearly understood, the specific embodiments of the present application are described in detail below with reference to the accompanying drawings. The following description sets forth many specific details to facilitate a full understanding of the present application. However, the present application can be implemented in many other ways than those described herein, and those skilled in the art can make similar improvements without violating the scope of the present application. Therefore, the present application is not limited to the specific embodiments disclosed below.

[0047] Furthermore, the terms "first" and "second" are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of the technical features being referred to. Thus, a feature defined as "first" or "second" may explicitly or implicitly include at least one of such features. Throughout the description of this application, "plurality" means at least two, for example, two, three, etc., unless otherwise specifically defined.

[0048] Traditional data completion based on the Transformer architecture fails to effectively capture the correlation features of spatial dimensions, nor can it highlight the key nodes in the spatial topology. This makes it difficult to simultaneously ensure the accuracy of time series modeling and the fidelity of spatial structure when processing high-dimensional data with complex spatiotemporal coupling characteristics. This embodiment provides an adaptive spatiotemporal graph neural network missing data completion method, such as Figure 1 As shown, the method includes:

[0049] S1: Collect the time series data of the sensor in the selected time period and construct a mask matrix based on the missing positions in the time series data.

[0050] In this embodiment, the time series data includes the observed values ​​of each variable at each time point in a selected time period during the debutanizer refining process.

[0051] A debutanizer is a fractionating tower used to recover butane and natural gas components in a shallow, cold, light hydrocarbon recycle process. It exploits the differences in boiling points of various hydrocarbons by heating the mixture and providing precise temperature control within the tower. The debutanizer consists of six main sections: a heat exchanger, an overhead condenser, a bottoms reboiler, an overhead reflux pump, a separator feed pump, and a reflux drum. The purpose of this process is to remove propane and butane from the naphtha stream, with the goal of minimizing the butane content in the debutanizer bottoms material.

[0052] In this example, the variables monitored during the debutanizer refining process include: bottom temperature A (N1), bottom temperature B (N2), top temperature (N3), top pressure (N4), reflux flow (N5), flow to the next process (N6), and sixth tray temperature (N7). The observed values ​​of these variables are all in the same dimension and lie within the interval [0, 1].

[0053] Furthermore, constructing a mask matrix based on the missing positions in the time series data includes:

[0054] Each missing position in the time series data is marked as 0, otherwise it is marked as 1 to obtain a mask matrix.

[0055] S2: The time series data and the mask matrix are concatenated and input into the fully connected layer to obtain the first feature; the first feature is projected into the query matrix, key matrix and value matrix respectively, and the second feature is obtained through the multi-head attention mechanism.

[0056] Specifically, the process of obtaining the first feature includes:

[0057] Concatenate the time series data with the mask matrix to obtain a concatenated matrix;

[0058] The concatenation matrix is ​​multiplied by the weights of the fully connected layer, and the multiplication result is added to the bias of the fully connected layer. The addition result is then passed through a sigmoid activation function. Finally, the activation result is added to the position code to obtain the first feature. In this embodiment, the position code is calculated using the sine and cosine functions.

[0059] The process of obtaining the second feature includes:

[0060] Project the first feature into query matrix, key matrix and value matrix respectively through the fully connected layer;

[0061] In any attention head,

[0062] Multiply the query matrix by the transpose of the key matrix, divide the resulting product by the feature dimension of the value matrix, pass the resulting quotient through the softmax activation function, and perform matrix multiplication of the resulting activation result with the value matrix to obtain the feature components of the corresponding attention head;

[0063] Traverse all attention heads, obtain the feature components corresponding to each attention head, sum up all feature components, and pass the summation result through the fully connected layer to obtain the second feature.

[0064] S3: Construct an adaptive graph structure and obtain the corresponding attenuation matrix based on the sparse graph structure. Use the attention mechanism to calculate the global feature information by combining the second feature and the attenuation matrix. Aggregate the features of each node in the sparse graph structure with the features of its neighboring nodes to obtain local feature information. Weighted combination of local feature information and global feature information is performed to obtain the third feature.

[0065] Specifically, constructing an adaptive graph structure and obtaining the corresponding attenuation matrix based on the sparse graph structure includes:

[0066] Define a learning matrix where the values ​​of each node in the learning matrix are random values, and the number of nodes in the learning matrix corresponds to the number of observations at any time point in the time series data;

[0067] Multiply the learning matrix by the transpose of the learning matrix, pass the first product through the ReLU activation function, and pass the first activation result through the softmax activation function to construct an adaptive graph structure;

[0068] Determine whether the value of each node in the graph structure is greater than or equal to a preset threshold. If so, retain the value of the corresponding node; otherwise, set the value of the corresponding node to 0 to obtain a sparse graph structure.

[0069] Based on the sparse graph structure, the in-degree strength of each node is calculated to construct the node in-degree strength matrix;

[0070] The node in-degree intensity matrix is ​​normalized in the row dimension to obtain the attenuation matrix.

[0071] In this embodiment, calculating the in-degree strength of each node based on the sparse graph structure to construct a node in-degree strength matrix includes:

[0072] In a sparse graph structure,

[0073] For any node, sum the values ​​of all nodes in its row to get the node out-degree strength of the corresponding node; sum the values ​​of all nodes in its column to get the node in-degree strength of the corresponding node; multiply the node out-degree strength of the corresponding node with the node in-degree strength to get the node in-degree strength of the corresponding node;

[0074] Traverse all nodes in the sparse graph structure to obtain the in-degree strength of each node, thereby constructing the node in-degree strength matrix.

[0075] Furthermore, the calculation process of global feature information includes:

[0076] Projecting the second feature into a second query matrix, a second key matrix, and a second value matrix respectively;

[0077] Multiplying the second query matrix and the second key matrix element by element, and dividing the obtained second product by the dimension of the second feature to obtain a semantic similarity matrix including the semantic similarity between each node;

[0078] The semantic similarity matrix is ​​multiplied element-by-element by the attenuation matrix, the third product is passed through the softmax activation function, and the second activation result is multiplied by the second value matrix to obtain the global feature information.

[0079] Furthermore, the calculation process of local feature information includes:

[0080] In a sparse graph structure,

[0081] Multiply the value of the selected node by the first weight matrix to obtain a fourth product, and multiply the value of any neighboring node by the second weight matrix to obtain a fifth product;

[0082] The first weight matrix / the second weight matrix is ​​used to linearly transform the value of the node into a new space;

[0083] The fourth product and the fifth product are activated by the LeakyReLU function, and the third activation result is normalized by the softmax activation function to obtain the attention weight between the corresponding two nodes;

[0084] Traverse all neighbor nodes of the selected node, calculate the attention weights between the selected node and all its neighbor nodes, and the fifth product of all its neighbor nodes;

[0085] Calculate the product of the fifth product of any neighbor node and the corresponding attention weight to obtain the corresponding feature of the neighbor node;

[0086] The features corresponding to all neighboring nodes of the selected node are summed up, and the summation result is passed through the sigmoid activation function to obtain local feature information.

[0087] Furthermore, the weighted combination of local feature information and global feature information includes:

[0088] Multiplying the global feature information by the first weight parameter element by element to obtain a sixth product;

[0089] Multiplying the local feature information by the balance number of the first weight parameter about 1 element by element to obtain a seventh product;

[0090] Adding the sixth product to the seventh product yields the third characteristic.

[0091] In this embodiment, the first weight parameter is a learnable weight parameter, and its value is a positive constant between 0 and 1.

[0092] S4: Normalize the sum of the first feature and the third feature to obtain the fourth feature; perform a linear transformation on the fourth feature to obtain the completed data; concatenate the completed data with the mask matrix, and repeat steps S2-S4 until a preset number of times is reached.

[0093] In this embodiment, the preset number of times is 2 times, and the number of times can also be set according to actual needs.

[0094] The fourth feature is obtained by normalizing the sum of the first and third features (through a normalization layer). This prevents vanishing or exploding gradients while maintaining numerical stability during training. The fourth feature undergoes a linear transformation to obtain the completed data. To achieve better completion, this completed data is concatenated with the mask matrix, and steps S2-S4 are repeated for feature learning, yielding a deeper feature representation.

[0095] S5: Based on the completed data obtained in each iteration, the final completed data is obtained; based on the final completed data, the time series data is completed to obtain the completed time series data.

[0096] Specifically, the calculation process of the final completed data is:

[0097] The completed data obtained twice are passed through the fully connected layer in sequence to obtain the first completed data and the second completed data respectively;

[0098] Multiplying the first completed data by the second weight parameter to obtain an eighth product;

[0099] Multiplying the second completed data by a balance number of the second weight parameter about 1 to obtain a ninth product;

[0100] Add the eighth product and the ninth product to obtain the final completed data.

[0101] In this embodiment, the second weight parameter is a learnable weight parameter, and its value is a positive constant between 0 and 1.

[0102] Furthermore, the process of obtaining the completed time series data includes:

[0103] Multiply the time series data by the mask matrix element by element, multiply the final completed data by the balance number of the mask matrix about 1 element by element, and add the two multiplication results to obtain the completed time series data.

[0104] This embodiment also provides a model training process, including:

[0105] Acquire second time series data of the sensor in multiple historical time periods, and construct a corresponding second mask matrix based on the missing position in each second time series data;

[0106] Performing a masking operation on each second time series data based on the corresponding second mask matrix (discarding values ​​in proportion) to obtain a masked data set;

[0107] The masked dataset is divided into training set, test set, and validation set in a ratio of 7:2:1.

[0108] During the training process, additional artificial omissions are introduced to the data in the training set, that is, existing data are randomly selected in the data and masked. Specifically, the values ​​of the artificially masked positions in the data are set to 1, and the rest are set to 0. An artificial mask matrix is ​​constructed, and the corresponding data in the training set are masked based on the artificial mask matrix to obtain the data after secondary masking, which is convenient for inputting into the model for training and evaluating the effect of model data completion.

[0109] Based on the data after the secondary masking, steps S2-S5 are executed in sequence to complete both the real missing values ​​and the artificially missing values ​​in the training set data to obtain the final completed training data.

[0110] Specifically, in order to better train the model, the completion error loss and reconstruction error are designed. The completion error loss and the reconstruction error are added together to obtain the total loss, and the model is trained by backpropagating the total loss.

[0111] Based on the completed data outputted after two iterations of the twice-masked data, data completion is performed on the twice-masked data to obtain the first completed training data and the second completed training data.

[0112] Substitute the twice-masked data, the second mask matrix, and the training data after the first completion into the mean absolute error calculation formula to calculate the reconstruction error of the first completion; substitute the twice-masked data, the second mask matrix, and the training data after the second completion into the mean absolute error calculation formula to calculate the reconstruction error of the second completion; take the average of the reconstruction error of the first completion and the reconstruction error of the second completion to construct the reconstruction error, and constrain the model by calculating the reconstruction error between the observed value and its reconstructed value to prevent the model from overfitting.

[0113] The twice-masked data, the artificial mask matrix, and the final completed training data are substituted into the mean absolute error calculation formula to construct the completion error loss. The model is trained by calculating the error between the true value of the artificially missing position and the completed value.

[0114] Based on the above model training process, the model parameters corresponding to the lowest total loss are saved and loaded. The model is evaluated using the data in the validation set. The mean absolute error is selected as the evaluation indicator. The performance of the model is measured by calculating the mean absolute error between the final completed value of the model and the true value of the missing position.

[0115] To evaluate the performance of the method provided in this example, the data completion method proposed in this invention was evaluated using data collected during a debutanizer refinery process. The data missing rate was set to 20%. Experiments showed that the adaptive graph neural network missing data completion method proposed in this example, based on in-degree intensity information fusion, was able to complete missing data from the debutanizer refinery process with minimal error between the completed data and the true missing values, demonstrating excellent data completion capabilities.

[0116] The adaptive spatiotemporal graph neural network missing data completion method provided in this embodiment has the following beneficial effects:

[0117] The method constructs a mask matrix based on the missing positions in the time series data; concatenates the time series data and the mask matrix and inputs them into a fully connected layer to obtain a first feature; the first feature is passed through a multi-head attention mechanism to obtain a second feature; an adaptive graph structure is constructed based on the time series data, and global feature information and local feature information are extracted from the graph structure; the local feature information and the global feature information are weightedly combined to obtain a third feature; the sum of the first feature and the third feature is normalized to obtain a fourth feature; a linear change is performed on the fourth feature to obtain completed data; the completed data is concatenated with the mask matrix, and the completed data calculation step is repeated until a preset number of times is reached; the final completed data is obtained based on the completed data obtained in each iteration; the time series data is completed based on the final completed data to obtain completed time series data. This method designs an adaptive graph structure learning mechanism, which extracts global feature information by fusing the in-and-out intensity information of nodes in the graph structure with the semantic similarity between nodes. Secondly, by combining global feature information and local feature information, it alleviates the over-smoothing and squeezing problems of graph neural networks. Finally, based on the mask matrix, the completion value corresponding to the missing position in the final completed data is taken out and filled into the corresponding missing position in the time series data, thereby realizing missing data completion.

[0118] The technical features of the above-mentioned embodiments can be combined arbitrarily. In order to make the description concise, not all possible combinations of the technical features in the above-mentioned 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.

[0119] The above-described embodiments merely represent several implementation methods of the present application. While the descriptions are relatively specific and detailed, they should not be construed as limiting the scope of the patent application. It should be noted that a person of ordinary skill in the art may make various modifications and improvements without departing from the spirit of the present application, and these modifications and improvements fall within the scope of protection of the present application. Therefore, the scope of protection of the present patent application shall be determined by the appended claims.

Claims

1. An adaptive spatiotemporal graph neural network missing data completion method, characterized by: include: S1: Collect the time series data of the sensor in the selected time period and construct a mask matrix based on the missing positions in the time series data; The time series data includes the observed values ​​of each variable at each time point in a selected time period during the debutanizer refining process; The variables monitored during the debutanizer refining process include: bottom temperature A, bottom temperature B, top temperature, top pressure, reflux flow, flow to the next process, and sixth tray temperature; S2: The time series data and the mask matrix are concatenated and input into the fully connected layer to obtain the first feature; the first feature is projected into the query matrix, key matrix, and value matrix respectively, and the second feature is obtained through the multi-head attention mechanism; S3: Construct an adaptive graph structure and obtain the corresponding attenuation matrix based on the sparse graph structure. The second feature and the attenuation matrix are combined through the attention mechanism to calculate the global feature information. Each node in the sparse graph structure aggregates the features of its neighboring nodes to obtain local feature information. The local feature information and the global feature information are weighted and combined to obtain the third feature. S4: Normalize the sum of the first feature and the third feature to obtain the fourth feature; perform a linear transformation on the fourth feature to obtain the completed data; concatenate the completed data with the mask matrix, and repeat steps S2-S4 until a preset number of times is reached; S5: Based on the completed data obtained in each iteration, the final completed data is obtained; based on the final completed data, the time series data is completed to obtain the completed time series data.

2. The method for completing missing data of an adaptive spatiotemporal graph neural network according to claim 1 is characterized in that: Constructing a mask matrix based on missing locations in time series data involves: Each missing position in the time series data is marked as 0, otherwise it is marked as 1 to obtain a mask matrix.

3. The method for completing missing data of an adaptive spatiotemporal graph neural network according to claim 1, characterized in that: Constructing an adaptive graph structure and obtaining the corresponding attenuation matrix based on the sparse graph structure includes: Define a learning matrix where the values ​​of each node in the learning matrix are random values, and the number of nodes in the learning matrix corresponds to the number of observations at any time point in the time series data; Multiply the learning matrix by the transpose of the learning matrix, pass the first product through the ReLU activation function, and pass the first activation result through the softmax activation function to construct an adaptive graph structure; Determine whether the value of each node in the graph structure is greater than or equal to a preset threshold. If so, retain the value of the corresponding node; otherwise, set the value of the corresponding node to 0 to obtain a sparse graph structure. Based on the sparse graph structure, the in-degree strength of each node is calculated to construct the node in-degree strength matrix; The node in-degree intensity matrix is ​​normalized to obtain the attenuation matrix.

4. The method for completing missing data of an adaptive spatiotemporal graph neural network according to claim 1, characterized in that: The calculation process of global feature information includes: Projecting the second feature into a second query matrix, a second key matrix, and a second value matrix respectively; Multiplying the second query matrix and the second key matrix element by element, and dividing the obtained second product by the dimension of the second feature to obtain a semantic similarity matrix including the semantic similarity between each node; The semantic similarity matrix is ​​multiplied element-by-element by the attenuation matrix, the third product is passed through the softmax activation function, and the second activation result is multiplied by the second value matrix to obtain the global feature information.

5. The method for completing missing data of an adaptive spatiotemporal graph neural network according to claim 1, characterized in that: The calculation process of local feature information includes: In a sparse graph structure, Multiply the value of the selected node by the first weight matrix to obtain a fourth product, and multiply the value of any neighboring node by the second weight matrix to obtain a fifth product; The fourth product and the fifth product are activated by the LeakyReLU function, and the third activation result is activated by the softmax function to obtain the attention weight between the corresponding two nodes; Traverse all neighbor nodes of the selected node, calculate the attention weights between the selected node and all its neighbor nodes, and the fifth product of all its neighbor nodes; Calculate the product of the fifth product of any neighbor node and the corresponding attention weight to obtain the corresponding feature of the neighbor node; The features corresponding to all neighboring nodes of the selected node are summed up, and the summation result is passed through the sigmoid activation function to obtain local feature information.

6. The method for completing missing data of an adaptive spatiotemporal graph neural network according to claim 1, characterized in that: The weighted combination of local feature information and global feature information includes: Multiplying the global feature information by the first weight parameter element by element to obtain a sixth product; Multiplying the local feature information by the balance number of the first weight parameter about 1 element by element to obtain a seventh product; Adding the sixth product to the seventh product yields the third characteristic.

7. The method for completing missing data in an adaptive spatiotemporal graph neural network according to claim 1, characterized in that: The preset number of times is 2 times.

8. The method for completing missing data of an adaptive spatiotemporal graph neural network according to claim 7, characterized in that: The calculation process of the final completed data is: The completed data obtained twice are passed through the fully connected layer in sequence to obtain the first completed data and the second completed data respectively; Multiplying the first completed data by the second weight parameter to obtain an eighth product; Multiplying the second completed data by a balance number of the second weight parameter about 1 to obtain a ninth product; Add the eighth product and the ninth product to obtain the final completed data.

9. The method for completing missing data of an adaptive spatiotemporal graph neural network according to claim 1, characterized in that: The process of obtaining the completed time series data includes: Multiply the time series data by the mask matrix element by element, multiply the final completed data by the balance number of the mask matrix about 1 element by element, and add the two multiplication results to obtain the completed time series data.

Citation Information

Patent Citations

  • Attention-based knowledge graph link prediction method and device, equipment and medium

    CN116186295A

  • Transform-based traffic flow prediction method and device capable of sensing local-global time-space relationship

    CN119990191A