Wireless communication link quality confidence interval prediction method and system based on Transformer and multi-head graph attention network
By combining wavelet decomposition, multi-head graph attention network and Transformer model, the spatiotemporal characteristics of wireless communication link quality data are extracted, and the problem of difficulty in capturing the spatiotemporal changes in the existing technology is solved, and accurate prediction of link quality and robust confidence interval prediction are achieved.
Patent Information
- Application Number
- CN202510446592.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-10
- Publication Date
- 2025-06-10
- Estimated Expiration
- 2045-04-10
AI Technical Summary
The prior art is difficult to accurately capture the spatiotemporal changes of wireless communication links, especially in the case of link bursts and rapid changes, and traditional methods are difficult to provide accurate link quality predictions.
The method based on Transformer and multi-head graph attention network is adopted, combining wavelet decomposition and graph attention network, the spatiotemporal characteristics of link quality data are extracted, and the confidence interval of link quality is predicted through residual structure and self-attention mechanism.
It realizes more accurate prediction of the quality of wireless communication links, can capture the suddenness and rapid changes of the link, and provides a more robust reliability confidence interval.
Smart Images

Figure CN119966544B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of wireless communication link quality confidence interval prediction, and particularly to a method and system for predicting the wireless communication link quality confidence interval based on Transformer and multi-head graph attention network. Background Art
[0002] In a wireless communication system, link quality assessment and prediction are extremely crucial for ensuring network performance and assisting in the design of higher-layer protocols. Traditional methods such as hard metrics based on physical layer parameters and soft metrics based on packet reception statistics have many defects. Hard metric measurements are limited and vulnerable to interference, and soft metrics are insensitive to short-term link changes. The method of constructing a mapping relationship based on statistics and curve fitting depends on a large amount of data and a fixed time window, and it is difficult to adapt to the time-varying characteristics of the link. The bursty characteristics of the link make its limitations more prominent.
[0003] At the same time, the characteristics of wireless links themselves are complex. There are connected, transitional, and non-connected regions in space. The transitional region has large fluctuations and there are significant differences in the discrimination of intermediate links under different device scenarios. Temporally, the intermediate link is bursty, and traditional methods are difficult to cope with its rapid changes. All of these require accurately capturing the spatio-temporal changes of the link, comprehensively weighing multiple factors such as accuracy, speed, and stability, and flexibly adapting to different scenarios. However, existing methods are difficult to meet these requirements, and there is an urgent need for new solutions. Summary of the Invention
[0004] In view of this, the purpose of the present invention is to provide a method for predicting the wireless communication link quality confidence interval based on Transformer and multi-head graph attention network. This method combines wavelet decomposition, graph attention network, and Transformer model to effectively extract the spatio-temporal characteristics of link quality data, providing a more accurate basis for predicting the wireless communication link quality confidence interval.
[0005] To achieve the above purpose, the present invention provides the following technical solutions:
[0006] The method for predicting the wireless communication link quality confidence interval based on Transformer and multi-head graph attention network provided by the present invention includes the following steps:
[0007] S1, constructing a normalized quality assessment data matrix sequence of the wireless communication link and an adjacency matrix of the network topology structure;
[0008] S2, using wavelet decomposition to decompose the normalized quality assessment data matrix sequence into a stationary data matrix sequence and a noise data matrix sequence;
[0009] S3, calculating the standard deviation data matrix sequence of the noise data matrix sequence;
[0010] S4. Use the residual structure multi-head graph attention network to capture the residual structure output of the stationary data matrix sequence with spatial features and the residual structure output of the standard deviation data matrix sequence;
[0011] S5. Input the residual structure output of the stationary data matrix sequence with spatial features and the residual structure output of the standard deviation data matrix sequence into the Transformer respectively to predict the output of the next moment and calculate the confidence interval of the wireless communication link quality.
[0012] Furthermore, in the step S1, constructing the normalized quality evaluation data matrix sequence of the wireless communication link includes the following steps:
[0013] Model the original data as ;
[0014] where the matrix represents the k-th wireless communication link quality evaluation data matrix recorded within the time range t, K represents the number of all data matrices recorded within the time range t, N represents the total number of nodes in the wireless communication link network topology, and C represents the types of parameters for evaluating the wireless communication link quality.
[0015] Map the quality evaluation data matrix sequence to [0, 1] for normalization, and the normalization process is ;
[0016] where is the original data under the i-th quality evaluation parameter, and are the maximum and minimum values in the data under the i-th quality evaluation parameter respectively, and is the normalized data under the i-th quality evaluation parameter.
[0017] Furthermore, in the step S1, constructing the adjacency matrix A of the network topology includes the following steps:
[0018] Number the N nodes in the wireless communication link network from 0 to N - 1;
[0019] Create a all-zero matrix A as the adjacency matrix;
[0020] Add weight information to the edge , let , where represents a certain node, represents the neighbor node of the i-th node, and represents the weight value of the edge between the i-th node and the j-th node.
[0021] Furthermore, in the step S2, the wavelet decomposition includes the following steps:
[0022] Select the wavelet basis function as the db series wavelet;
[0023] Determine the threshold , where t is the number of elements in the normalized quality assessment data matrix sequence;
[0024] Determine the decomposition level L = 2;
[0025] Determine the threshold function ;
[0026] where b is the wavelet coefficient of the original sequence on the second layer during wavelet decomposition;
[0027] Perform wavelet decomposition on the normalized quality assessment data matrix sequence to obtain a stationary data matrix sequence and a noise data matrix sequence ;
[0028] where represents the k-th stationary data matrix within the time range t, represents the k-th noise data matrix within the time range t.
[0029] Furthermore, in step S3, calculating the standard deviation data matrix sequence of the noise data matrix sequence includes the following steps:
[0030] The standard deviation data matrix sequence of the noise data matrix sequence is expressed as:
[0031] ;
[0032] where is the standard deviation data matrix, N is the total number of nodes, C is the type of quality assessment parameter, and t is the time step;
[0033] Calculate the standard deviation, and its formula is:
[0034] ;
[0035] where , is the standard deviation value of the i-th node under the j-th quality evaluation parameter at the k-th time step, G is the length of the window used to calculate the standard deviation, is the noise data value of the i-th node under the j-th quality evaluation parameter at m time steps.
[0036] Furthermore, in step S4, the residual structure multi-head graph attention network capturing the residual structure outputs of the stationary data matrix sequence with spatial features and the residual structure output of the standard deviation data matrix sequence includes the following steps:
[0037] The stationary data matrix sequence and the adjacency matrix A of the network topology structure as input;
[0038] The sequence of stationary data matrices is linearly transformed into , and the process of linear transformation is:
[0039] ;
[0040] where represents the quality assessment data matrix at the k-th time step recorded within the time range t, is the transformed feature matrix, is the linear transformation matrix;
[0041] The attention mechanism of the graph attention network is used to calculate the correlation coefficient between nodes, and the calculation formula of the correlation coefficient is:
[0042] ;
[0043] where represents the attention coefficient between node i and its neighbor node j at the k-th time step, is the non-linear activation function, is the initialized learnable matrix, and respectively represent the feature vectors of node i and its neighbor node j at the k-th time step;
[0044] Normalize the attention coefficient:
[0045] ;
[0046] where is the set of neighbor nodes of node i;
[0047] The sequence of spatial feature matrices of the stationary data space is obtained by using the multi-head attention mechanism:
[0048] ;
[0049] where is the spatial feature matrix extracted at the k-th time step, N is the total number of nodes, and M is the spatial feature dimension of a single node at a certain time step.
[0050] The sequence of standard deviation data matrices and the adjacency matrix A of the network topology structure are used as input;
[0051] The sequence of spatial feature matrices of the standard deviation data space is obtained by the same steps as the sequence of stationary data matrices:
[0052] ;
[0053] Furthermore, a sequence of steady data space feature matrices is obtained by using the multi-head attention mechanism, which specifically includes the following steps:
[0054] Weighted sum of the features of neighbor nodes to obtain a single-head output:
[0055]
[0056] where is a non-linear activation function, is the normalized attention coefficient;
[0057] Concatenate the multi-head attention outputs, and the concatenation process is:
[0058] ;
[0059] where represents the output feature of the p-th attention head of the i-th node, represents the output feature of the p-th attention head of the neighbor node j, represents the feature vector of the i-th node at the k-th time step, is used to adjust the dimension of the concatenated features to the target dimension;
[0060] Furthermore, in step S4, the design steps of the residual structure are:
[0061] The sequence of steady data space feature matrices extracted by the multi-head graph attention network and the sequence of standard deviation data space feature matrices
[0062] ;
[0063] ;
[0064] where and are the sequence of steady data space feature matrices and the sequence of standard deviation data space feature matrices after batch normalization, respectively;
[0065] Connect the sequence of steady data space feature matrices after batch normalization and the sequence of standard deviation data space feature matrices to the input residual of the previous layer respectively. The process of the first-layer residual connection is:
[0066] ;
[0067] ;
[0068] Among them is the residual structure output of the stationary data matrix sequence, is the residual structure output of the sum and standard deviation data matrix sequences;
[0069] Input and into the above-mentioned residual structure again to obtain the final residual structure output of the stationary data matrix sequence and
[0070] the residual structure output of the standard deviation data matrix sequence ;
[0071] Furthermore, in step S5, inputting the residual structure output of the stationary data matrix sequence with spatial characteristics and the residual structure output of the standard deviation data matrix sequence into the Transformer respectively to predict the output of the next moment and integrating them to obtain the wireless communication link quality confidence interval includes the following steps:
[0072] Input the residual structure output of the stationary data matrix sequence and
[0073] the residual structure output of the standard deviation data matrix sequence unfold along the time steps;
[0074] Among them represents the standard deviation spatial feature matrix at the k-th time step, N is the total number of nodes, and C is the type of quality evaluation parameters;
[0075] For each time step matrix and add dynamic position encoding respectively, and the formula is:
[0076]
[0077]
[0078] Among them and are the node-level position encoding matrices generated based on the time step k, used to retain the temporal and spatial correlations;
[0079] Input the matrix sequences after position encoding and into the Transformer encoder respectively, capture the time-dependent relationships between different time steps through the self-attention mechanism, and output the predicted stationary data feature matrix of the next moment and the standard deviation feature matrix ;
[0080] For and Perform node-level inverse normalization to restore to the original data scale. The formula is:
[0081]
[0082]
[0083] where and and and are respectively the original data and the standard deviation extreme value of the i-th node;
[0084] After calculating the node-level inverse normalization and Obtain the lower confidence limit matrix and the upper confidence limit matrix of the wireless communication link quality for C types of quality evaluation parameters;
[0085] where is the quantile of the standard normal distribution, represents the significance level;
[0086] Weighted average the predicted confidence levels under different types of quality evaluation parameters to obtain the reliability confidence interval matrix including all nodes;
[0087] where is the weight matrix for different types of quality evaluation parameters, satisfying , and C is the type of quality evaluation parameter;
[0088] The wireless communication link quality confidence interval prediction system based on Transformer and graph attention network provided by the present invention includes a memory, a processor, and a computer program stored on the memory and executable on the processor. When the processor executes the program, the above method is implemented.
[0089] The beneficial effects of the present invention are as follows:
[0090] The wireless communication link quality confidence interval prediction method based on Transformer and multi-head graph attention network provided by the present invention relates to the field of wireless communication link quality confidence interval prediction, and includes constructing a normalized quality evaluation data matrix sequence of a wireless communication link and an adjacency matrix of a network topology structure; decomposing the normalized quality evaluation data matrix sequence into a stationary data matrix sequence and a noise data matrix sequence by using wavelet decomposition; calculating a standard deviation data matrix sequence of the noise data matrix sequence; using a residual structure multi-head graph attention network to capture the residual structure output of the stationary data matrix sequence with spatial features and the residual structure output of the standard deviation data matrix sequence; inputting the residual structure output of the stationary data matrix sequence with spatial features and the residual structure output of the standard deviation data matrix sequence into Transformer respectively to predict the output of the next moment and calculate the wireless communication link quality confidence interval. This method of the present invention combines wavelet decomposition, a residual structure multi-head graph attention network and a Transformer model, effectively extracts the spatio-temporal features of link quality data, and provides a more accurate basis for the prediction of the wireless communication link quality confidence interval.
[0091] In this method, the wireless communication link quality evaluation data is a multivariate time series, which is modeled as a matrix sequence. The signal-to-noise ratio, signal strength, and link quality evaluation parameters such as packet reception and retransmission of each node can be predicted simultaneously. The confidence interval of a single parameter is easily affected by noise and outliers, while combining multiple parameters can reduce the influence of these factors and make the finally obtained reliability confidence interval more robust.
[0092] This method uses a wavelet decomposition preprocessing mechanism to decompose the wireless communication link quality evaluation data matrix sequence into a stationary matrix sequence and a non-stationary matrix sequence, which is beneficial to quickly identify and predict the short-term changes of the intermediate link quality, effectively captures the burst characteristics of the link. This decomposition method can also reduce the data complexity, enabling the subsequent model to focus more on data with different characteristics and improving the model's ability to process complex data.
[0093] This method uses a multi-head graph attention network. The multi-head attention mechanism can simultaneously focus on different feature subspaces of nodes and capture the complex relationships between nodes from multiple angles. In the scenario of wireless communication link quality prediction, different attention heads can respectively focus on different link quality evaluation parameters such as received signal strength, signal-to-noise ratio, packet reception and retransmission, so as to comprehensively explore the spatial correlation between nodes. Compared with single-head attention, multi-head attention provides richer information and helps the model to depict node relationships more meticulously.
[0094] This method models the data sequence of the wireless communication link and the network topology structure. First, it extracts spatial features through the graph attention network residual structure, comprehensively considering the spatial correlation between nodes with close geographical locations and the temporal features between sequences. It can be applied to the scenario of split-stream transmission, providing a more fine-grained and flexible option for the quality assessment and prediction of wireless communication links. Then, the result is input into the Transformer, which can adaptively capture the long-range temporal dependencies of the link quality data and mine complex temporal associations. The combination of the two can comprehensively capture the spatio-temporal features of the wireless communication link quality data.
[0095] This method combines wavelet decomposition, Transformer, and multi-head graph attention network technologies to realize the prediction of the confidence interval of wireless communication link quality, providing key information about prediction reliability for network managers and helping them make more scientific and reasonable decisions.
[0096] Other advantages, objectives, and features of the present invention will be described to some extent in the subsequent specification, and to some extent, will be obvious to those skilled in the art based on the study of the following text, or can be learned from the practice of the present invention. The objectives and other advantages of the present invention can be achieved and obtained through the following specification. Brief Description of the Drawings
[0097] To make the objectives, technical solutions, and beneficial effects of the present invention clearer, the present invention provides the following drawings for illustration.
[0098] Figure 1 It is a simplified process schematic diagram of this method.
[0099] Figure 2 It is a multi-head graph attention network diagram of this method.
[0100] Figure 3 It is a principle framework diagram of this method.
[0101] Figure 4 It is a comparison diagram of the prediction results of each model for the wireless communication link quality of Node 1 under three parameters: RSSI, SNR, and PRT.
[0102] Figure 5 It is the average error of each model under different parameters. Detailed Embodiments
[0103] The following further illustrates the present invention in conjunction with the drawings and specific embodiments, so that those skilled in the art can better understand the present invention and be able to implement it, but the embodiments cited do not limit the present invention.
[0104] Refer to Figure 1 as shown Figure 1This is a schematic diagram of the simplified process of this method. This embodiment discloses a method for predicting the confidence interval of wireless communication link quality based on Transformer and multi-head graph attention network, including the following steps:
[0105] S1. Construct a normalized quality evaluation data matrix sequence of the wireless communication link and an adjacency matrix of the network topology structure;
[0106] It should be noted that the quality evaluation parameters of the wireless communication link include hard metrics (received signal strength, signal-to-noise ratio, link quality indicator, etc.), soft metrics (data link layer packet reception or retransmission time), and hybrid metrics. In this embodiment, three wireless communication link quality evaluation parameters, namely signal-to-noise ratio (SNR), received signal strength (RSSI) in hard metrics, and data link layer packet reception or retransmission time statistics data (PRT) in soft metrics, are adopted.
[0107] It should be noted that during data collection, a wireless communication network with 5 nodes was constructed. The nodes were randomly distributed within the range of 0 to 100 meters, and the positions were located by GPS. Each node was equipped with an IEEE 802.11 wireless communication module supporting dual bands of 2.4 GHz and 5 GHz. The data collection frequency was once every 10 minutes for 24 hours. The collection parameters included received signal strength (RSSI, unit: dBm), signal-to-noise ratio (SNR, unit: dB), and packet reception time (PRT, unit: ms). During the collection process, random noise and periodic interference were introduced, and burst interference was simulated during the periods of 8:00 - 10:00 and 18:00 - 20:00 every day, resulting in a decrease in RSSI, a decrease in SNR, and an increase in PRT. The collected data was stored in matrix form, and the matrix dimensions corresponded to time points, nodes, and quality evaluation parameters respectively.
[0108] It should be noted that the steps for constructing the normalized quality evaluation data matrix sequence of the wireless communication link in S1 include the following:
[0109] S101. Model the original data as ;
[0110] Among them, the matrix represents the k-th wireless communication link quality evaluation data matrix recorded within the time range t. K represents the total number of all data matrices recorded within the time range t, N represents the total number of nodes in the wireless communication link network topology structure, and C represents the types of parameters for evaluating the quality of the wireless communication link.
[0111] S102. Normalize and map the quality evaluation data matrix sequence to [0, 1]. The normalization process is as follows:
[0112]
[0113] Among them, is the original data under the i-th quality evaluation parameter, and are respectively the maximum and minimum values in the data under the i-th quality evaluation parameter, is the normalized data under the i-th quality evaluation parameter.
[0114] It should be noted that the construction of the adjacency matrix A of the network topology structure in S1 includes the following steps:
[0115] S111, number the N nodes in the wireless communication link network from 0 to N - 1;
[0116] S112, create a full-zero matrix A as the adjacency matrix;
[0117] S113, add the weight information to the edge , let , where represents a certain node, represents the neighbor node of the i-th node; represents the weight value of the edge between the i-th node and the j-th node.
[0118] S2, use wavelet decomposition to decompose the normalized quality evaluation data matrix sequence into a stationary data matrix sequence and a noise data matrix sequence;
[0119] It should be noted that the wavelet decomposition in S2 includes the following steps:
[0120] S201, select the wavelet basis function as the db series wavelet;
[0121] S202, determine the threshold , where t is the number of elements in the normalized quality evaluation data matrix sequence;
[0122] S203, determine the decomposition level L = 2;
[0123] S204, determine the threshold function ;
[0124] where b is the wavelet coefficient of the original sequence on the second layer during wavelet decomposition;
[0125] S205, perform wavelet decomposition on the normalized quality evaluation data matrix sequence to obtain a stationary data matrix sequence and a noise data matrix sequence ;
[0126] Among them, represents the k-th stationary data matrix within the time range t, Denote the k-th noise data matrix within the time range t.
[0127] S3. Calculate the standard deviation data matrix sequence of the noise data matrix sequence;
[0128] It should be noted that calculating the standard deviation data matrix sequence of the noise data matrix sequence in S3 includes the following steps:
[0129] S301. The standard deviation data matrix sequence of the noise data matrix sequence is expressed as:
[0130] ;
[0131] Where is the standard deviation data matrix, N is the total number of nodes, C is the type of quality evaluation parameter, and t is the time step;
[0132] S302. Calculate the standard deviation, and its formula is: ;
[0133] Where , is the standard deviation value of the i-th node under the j-th quality evaluation parameter at the k-th time step, G is the length of the window used to calculate the standard deviation, is the noise data value of the i-th node under the j-th quality evaluation parameter in m time steps.
[0134] S4. Use the residual structure multi-head graph attention network to capture the residual structure outputs of the stationary data matrix sequence with spatial features and the residual structure output of the standard deviation data matrix sequence;
[0135] It should be noted that in S4, the residual structure multi-head graph attention network capturing the residual structure outputs of the stationary data matrix sequence with spatial features and the residual structure output of the standard deviation data matrix sequence includes the following steps:
[0136] S401. Take the stationary data matrix sequence and the adjacency matrix A of the network topology as inputs;
[0137] S402. Linearly transform the stationary data matrix sequence into . The process of the linear transformation is:
[0138]
[0139] Where represents the quality evaluation data matrix at the k-th time step recorded within the time range t, is the transformed feature matrix, is the linear transformation matrix;
[0140] S403. Calculate the correlation coefficient between nodes using the attention mechanism of the graph attention network. The formula for the correlation coefficient is as follows:
[0141] ;
[0142] Among them, represents the attention coefficient between node i and its neighbor node j at the k-th time step, is a non-linear activation function, is an initialized learnable matrix, and respectively represent the feature vectors of node i and its neighbor node j at the k-th time step;
[0143] S404. Normalize the attention coefficients:
[0144] ;
[0145] Among them, is the set of neighbor nodes of node i;
[0146] S405. Obtain a sequence of spatial feature matrices of stationary data using the multi-head attention mechanism:
[0147] ;
[0148] Among them, is the spatial feature matrix extracted at the k-th time step, N is the total number of nodes, and M is the spatial feature dimension of a single node at a certain time step.
[0149] S406. Take the sequence of standard deviation data matrices and the adjacency matrix A of the network topology as inputs;
[0150] S407. Obtain a sequence of spatial feature matrices of standard deviation data using the same steps as for the sequence of stationary data matrices:
[0151] ;
[0152] It should be noted that the steps for obtaining the sequence of spatial feature matrices of stationary data using the multi-head attention mechanism in S405 include the following steps:
[0153] S411. Weight and sum the features of neighbor nodes to obtain a single-head output: Among them, is a non-linear activation function, is the normalized attention coefficient;
[0154] S412. Concatenate the multi-head attention outputs. The concatenation process is as follows:
[0155] ;
[0156] Among them, represents the output feature of the p-th attention head of the i-th node, represents the output feature of the p-th attention head of the neighbor node j, represents the feature vector of the i-th node at the k-th time step, is used to adjust the dimension of the concatenated features to the target dimension. As Figure 2 shown, Figure 2 shows that the three single-head outputs are merged together through the concat splicing function.
[0157] It should be noted that in S4, the design steps of the residual structure are as follows:
[0158] S421, batch-normalize the sequence of stationary data space feature matrices extracted by the multi-head graph attention network and the sequence of standard deviation data space feature matrices , and its calculation formula is:
[0159] ;
[0160] ;
[0161] Among them and are respectively the sequence of stationary data space feature matrices and the sequence of standard deviation data space feature matrices after batch normalization;
[0162] S422, respectively connect the sequence of stationary data space feature matrices after batch normalization and the sequence of standard deviation data space feature matrices to the input residual of the previous layer. The process of the first-layer residual connection is:
[0163] ;
[0164] ;
[0165] Among them is the output of the residual structure of the stationary data matrix sequence, is the output of the residual structure of the sum and standard deviation data matrix sequence;
[0166] S423, input and into another above-mentioned residual structure to obtain the final output of the residual structure of the stationary data matrix sequence and
[0167] Residual structure output of the standard deviation data matrix sequence ;
[0168] S5. Input the residual structure output of the stationary data matrix sequence with spatial characteristics and the residual structure output of the standard deviation data matrix sequence into the Transformer respectively to predict the output of the next moment and calculate the confidence interval of the wireless communication link quality.
[0169] In summary, after the quality assessment data matrix sequence and the adjacency matrix are analyzed and processed, and the stationary data prediction result and the standard deviation prediction result are obtained through the residual block and the Transformer respectively, the confidence interval prediction result is finally output; as Figure 3 shown, Figure 3 is the principle framework diagram of this method, Figure 3 which shows the working principle between each module in this method. It should be noted that in S5, inputting the residual structure output of the stationary data matrix sequence with spatial characteristics and the residual structure output of the standard deviation data matrix sequence into the Transformer respectively to predict the output of the next moment and integrating to obtain the confidence interval of the wireless communication link quality specifically includes the following steps:
[0170] S501. Unfold the residual structure output of the stationary data matrix sequence and
[0171] the residual structure output of the standard deviation data matrix sequence by time step;
[0172] where represents the standard deviation spatial feature matrix at the k-th time step, N is the total number of nodes, and C is the type of quality assessment parameters;
[0173] S502. Add dynamic position encoding to the matrix and at each time step respectively, and the formula is:
[0174] , ;
[0175] where and are the node-level position encoding matrices generated based on the time step k, which are used to retain the temporal and spatial correlations;
[0176] S503. Input the matrix sequences and after position encoding into the Transformer encoder respectively, capture the time-dependent relationships between different time steps through the self-attention mechanism, and output the predicted stationary data feature matrix of the next moment and the standard deviation feature matrix ;
[0177] S504, Calculate the and after node-level denormalization to obtain the lower confidence limit matrix of the wireless communication link quality for C types of quality evaluation parameters and the upper confidence limit matrix ;
[0178] where is the quantile of the standard normal distribution, representing the significance level;
[0179] S505, Weighted-average the predicted confidence levels under different types of quality evaluation parameters to obtain the reliability confidence interval matrix including all nodes ;
[0180] where is the weight matrix for different types of quality evaluation parameters, satisfying , and C is the number of types of quality evaluation parameters.
[0181] As Figure 4 shown, Figure 4 is a comparison chart of the prediction results of each model for the wireless communication link quality of node 1 under three parameters: RSSI, SNR, and PRT. It can be seen from the figure that this method combines wavelet decomposition, multi-head graph attention network, and Transformer model, and shows higher fitting accuracy in the prediction of RSSI, SNR, and PRT parameters. The degree of coincidence between its prediction curve and the true value is significantly better than that of other models. Especially during the sudden interference period, the model provided in this embodiment can adapt to the drastic changes in link quality more quickly, with smaller fluctuations in the prediction results, showing higher robustness and stability. In contrast, the prediction errors of other models are larger during the sudden interference period, and the curves deviate significantly from the true value.
[0182] As Figure 5 shown, Figure 5is the average error of each model under different parameters. It can be seen from the figure the comparison of the average errors of this method and other models in three parameters: received signal strength, signal-to-noise ratio, and packet reception time. The average error of the model provided by this method is significantly lower than that of other models in all parameters, indicating that its prediction accuracy is higher. In contrast, the LSTM model has the highest average error, and the errors of the GAT-LSTM and GAT-Transformer models are between the two. This shows that the model provided in this embodiment can effectively extract the spatio-temporal features of link quality data, reduce the prediction error, and provide a reliable basis for wireless communication link quality assessment and prediction by combining wavelet decomposition, multi-head graph attention network, and Transformer model. This embodiment also provides a wireless communication link quality confidence interval prediction system based on Transformer and multi-head graph attention network, including a memory, a processor, and a computer program stored on the memory and executable on the processor. When the processor executes the program, the above method is implemented.
[0183] The above embodiments are only preferred embodiments given to fully illustrate the present invention, and the protection scope of the present invention is not limited thereto. Equivalent substitutions or transformations made by those skilled in the art on the basis of the present invention are all within the protection scope of the present invention. The protection scope of the present invention is subject to the claims.
Claims
1. A wireless communication link quality confidence interval prediction method based on Transformer and multi-head graph attention network, characterized by: The following steps are involved: S1, constructs a normalized quality assessment data matrix sequence of wireless communication links and an adjacency matrix of the network topology structure; S2, using wavelet decomposition to decompose the normalized quality assessment data matrix sequence into a stationary data matrix sequence and a noise data matrix sequence; S3, calculate the standard deviation data matrix sequence of the noise data matrix sequence; S4, using the residual structure multi-head graph attention network to capture the residual structure output of the stationary data matrix sequence with spatial characteristics and the residual structure output of the standard deviation data matrix sequence; S5, inputting the residual structure output of the stationary data matrix sequence with spatial characteristics and the residual structure output of the standard deviation data matrix sequence into the Transformer to predict the output at the next moment and calculate the confidence interval of the wireless communication link quality; In step S1, constructing a normalized quality assessment data matrix sequence of a wireless communication link includes the following steps: Model the original data as X = [X 1 ,X 2 ,…,X k ,…,X K ]; Among them, the matrix X k ∈R N×C represents the kth wireless communication link quality evaluation data matrix recorded within the time range t, K represents the number of all data matrices recorded within the time range t; N represents the total number of nodes in the wireless communication link network topology structure, and C represents the type of parameters for evaluating the quality of the wireless communication link; The quality assessment data matrix sequence is normalized and mapped to [0,1]. The normalization process is: Among them, x i is the original data under the i-th quality assessment parameter, and are the maximum and minimum values in the data under the i-th quality assessment parameter, respectively. is the normalized data under the i-th quality assessment parameter; In step S1, constructing the adjacency matrix A of the network topology structure includes the following steps: Numbering N nodes in the wireless communication link network from 0 to N-1; Create an N×N all-zero matrix A as the adjacency matrix; Add weight information to edge (i, j, w), let A ij =A ji =w, where i represents a node, j represents the neighbor node of the i-th node, and w represents the weight value of the edge between the i node and the j node.
2. The wireless communication link quality confidence interval prediction method based on Transformer and multi-head graph attention network according to claim 1 is characterized in that: In step S2, wavelet decomposition comprises the following steps: Select the wavelet basis function as db series wavelet; Determine the threshold Where t is the number of elements in the normalized quality assessment data matrix sequence; Determine the number of layers of wavelet decomposition L = 2; Determine the threshold function Where b is the wavelet coefficient of the original sequence on the second layer during the wavelet decomposition process; Decompose the normalized quality assessment data matrix sequence with wavelet to obtain a stationary data matrix sequence S = [S 1 ,S 2 ,…,S t ] and the noise data matrix sequence Z = [Z 1 ,Z 2 ,…,Z t ]; Among them, S k ∈R N×C represents the kth stationary data matrix within the time range t, Z k ∈R N×C represents the kth noise data matrix within the time range t.
3. The wireless communication link quality confidence interval prediction method based on Transformer and multi-head graph attention network according to claim 1 is characterized in that: In step S3, calculating the standard deviation data matrix sequence of the noise data matrix sequence includes the following steps: The standard deviation of the noise data matrix sequence is expressed as: σ = [σ 1 ,σ 2 ,…,σ t ]; Among them, σ t ∈R N×C is the standard deviation data matrix, N is the total number of nodes, C is the type of quality assessment parameters, and t is the time step; Calculate the standard deviation using the formula: in, is the standard deviation value of the i-th node under the j-th quality evaluation parameter at the K-th time step, G is the length of the standard deviation window used to calculate, is the noise data value under the jth quality evaluation parameter of the ith node in m time steps.
4. The wireless communication link quality confidence interval prediction method based on Transformer and multi-head graph attention network according to claim 1 is characterized in that: In step S4, the residual structure multi-head graph attention network captures the residual structure output of the stationary data matrix sequence with spatial characteristics and the residual structure output of the standard deviation data matrix sequence, including the following steps: The stationary data matrix sequence S = [S 1 ,S 2 ,…,S t ] and the adjacency matrix A of the network topology as input; The stationary data matrix sequence S = [S 1 ,S 2 ,…,S t ] is linearly transformed to H = [H 1 ,H 2 ,…,H t ], the process of linear transformation is: H k =S k W; Among them, S k ∈R N×C represents the quality assessment data matrix recorded at the kth time step within the time range t, H k ∈R N ×C′ is the transformed feature matrix, W∈R C×C′ is the linear transformation matrix; The attention mechanism of the graph attention network is used to calculate the correlation coefficient between nodes. The correlation coefficient calculation formula is: Among them, e ij represents the attention coefficient between node i and its neighbor node j at the kth time step, LeakyRelu is a nonlinear activation function, a∈R 2C′ is the initialized learnable matrix, and Respectively represent the feature vectors of node i and its neighbor node j at the kth time step; Normalize the attention coefficient: Among them, N i is the set of neighbor nodes of node i The multi-head attention mechanism is used to obtain a stable data space feature matrix sequence: in, is the spatial feature matrix extracted at the kth time step, N is the total number of nodes, and M is the spatial feature dimension of a single node at a certain time step; The standard deviation data matrix sequence σ=[σ 1 ,σ 2 ,…,σ t ] and the adjacency matrix A of the network topology as input; The standard deviation data space feature matrix sequence is obtained by using the same stationary data matrix sequence steps:
5. The wireless communication link quality confidence interval prediction method based on Transformer and multi-head graph attention network according to claim 4 is characterized in that: The multi-head attention mechanism is used to obtain a stable data space feature matrix sequence, which specifically includes the following steps: The weighted sum of the features of neighboring nodes is used to obtain a single-head output: Among them, σ is a nonlinear activation function, α ij is the normalized attention coefficient; Concatenate the multi-head attention outputs. The concatenation process is: in, represents the output feature of the pth attention head of the i-th node, represents the output feature of the p-th attention head of neighbor node j, represents the feature vector of the i-th node at the k-th time step, W o Used to adjust the concatenated feature dimension to the target dimension.
6. The wireless communication link quality confidence interval prediction method based on Transformer and multi-head graph attention network according to claim 1 is characterized in that: In step S4, the design steps of the residual structure are: The stationary data space feature matrix sequence extracted by the multi-head graph attention network And standard deviation data space characteristic matrix sequence Perform batch normalization, the calculation formula is: in and They are respectively the batch normalized stationary data space feature matrix sequence and the standard deviation data space feature matrix sequence; The batch-normalized stationary data space feature matrix sequence And standard deviation data space characteristic matrix sequence They are connected to the previous layer input residual respectively, and the process of the first layer residual connection is: in is the residual structure output of the stationary data matrix sequence, The residual structure output of the standard deviation data matrix sequence; Will and Then input the above residual structure to obtain the residual structure output of the final stationary data matrix sequence The residual structure output of the standard deviation data matrix sequence 7. The wireless communication link quality confidence interval prediction method based on Transformer and multi-head graph attention network according to claim 1 is characterized in that: The step S5, inputting the residual structure output of the stationary data matrix sequence with spatial characteristics and the residual structure output of the standard deviation data matrix sequence into the Transformer to predict the output at the next moment and calculate the confidence interval of the wireless communication link quality, comprises the following steps: Output the residual structure of the stationary data matrix sequence as well as Residual structure output for standard deviation data matrix sequence Expand by time step; in represents the standard deviation spatial feature matrix of the kth time step, N is the total number of nodes, and C is the type of quality assessment parameters; The matrix for each time step is and Add dynamic position coding respectively, the formula is: in and is the node-level position encoding matrix generated based on time step k, which is used to preserve temporal and spatial associations; The matrix sequence after position encoding and The Transformer encoder is input separately, and the temporal dependency between time steps is captured through the self-attention mechanism, and the predicted stable data feature matrix for the next moment is output. and standard deviation feature matrix right and Perform node-level denormalization to restore the original data scale. The formula is: in and are the original data and standard deviation extreme value of the i-th node respectively; Calculate the node-level denormalized and Get the wireless communication link quality confidence lower limit matrix of C quality assessment parameters and the upper confidence limit matrix in, is the α / 2 quantile of the standard normal distribution, where α represents the significance level; The weighted average of the predicted confidence levels under different quality assessment parameter types is used to obtain the reliability confidence interval matrix [V1·w c ,V2·w c ]; where w c is the weight matrix of different quality assessment parameter types, satisfying C is the type of quality assessment parameter.
8. A wireless communication link quality confidence interval prediction system based on Transformer and multi-head graph attention network, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the program, the method according to any one of claims 1 to 7 is implemented.
Citation Information
Patent Citations
Fault positioning method and system based on line carrier
CN118444086A
Time sequence data modeling method for body-equipped agent based on frequency domain learning
CN119357642A