Long-time sequence prediction method based on channel independence and bidirectional normalization

Through the model designed by two-way normalization and channel independence, the problem of distributed displacement of deep learning models in long-term time series prediction is solved, and the prediction accuracy and stability is improved. It is suitable for complex application scenarios of multivariate time series.

CN119226718AActive Publication Date: 2024-12-31XIDIAN UNIV

Patent Information

Application Number
CN202411298836.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-09-18
Publication Date
2024-12-31
Estimated Expiration
2044-09-18

AI Technical Summary

Technical Problem

Deep learning models face distribution displacement problems in long-term series prediction, resulting in reduced prediction accuracy and unstable model. Traditional methods are difficult to cope with the distribution changes between inputs and outputs and between channels.

Method used

Using a bidirectional normalized learning subnet and a channel-independent dual predictive subnet, the input and output sequences are processed through forward and reverse normalization, combined with the sparse attention mechanism to fuse the channel information, and adaptively adjust the model parameters to Cope with distributed displacement.

Benefits of technology

It significantly improves the accuracy and stability of long-term time series prediction, reduces the dependence on manually set parameters, reduces the model's sensitivity to data distribution changes, and adapts to complex application scenarios of multivariate time series.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119226718A_ABST
    Figure CN119226718A_ABST
Patent Text Reader

Abstract

The invention discloses a long-time sequence prediction method based on channel independence and bidirectional normalization. The long-time sequence prediction method comprises the following steps: constructing a bidirectional normalization learnable sub-network; constructing a dual-path prediction sub-network based on channel independence; constructing a complete long-time sequence prediction network; constructing a multivariate time series prediction data set; setting a training environment, and training the long-time sequence prediction network; and predicting the long-time sequence. The bidirectional normalized learnable sub-network can effectively process the problem of distribution displacement between input sequences and between input and output, the problem of distribution displacement between channels in a multivariable time sequence is solved through the channel-independent two-way prediction sub-network, and the prediction precision and stability of the model are improved. The method can be suitable for long-term time sequence prediction in multiple fields such as electric power, weather and traffic.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the field of data processing technology, and further relates to a long time series prediction method based on channel independence and bidirectional normalization in the field of electronic data processing technology. The present invention can be widely used in long time series prediction scenarios such as power load prediction, traffic flow prediction, weather prediction, and economic prediction. Background Art

[0002] Deep neural networks play a vital role in many application scenarios in the field of long-term time series forecasting (LTSF), such as power forecasting, traffic flow forecasting, weather forecasting, and economic forecasting based on deep learning. However, time series data often show changes in statistical distribution over time, a phenomenon known as "distribution shift". The existence of this problem makes the data distribution of deep learning models inconsistent between the training phase and the test phase, which in turn affects the accuracy and stability of the prediction. Therefore, it is a major challenge in the field of long-term prediction based on deep learning. In the long-term time series prediction task, distribution shift is mainly reflected in three aspects: First, the distribution shift between input sequences: at different time points in the same time series, the statistical distribution of input data may change significantly. For example, in power load forecasting, the power demand patterns in winter and summer are usually different, which will lead to inconsistent distributions between training data and predicted data. Second, the distribution shift between input and output: the relationship between the input sequence and the prediction target will also shift due to changes in the external environment. For example, in weather forecasting, the statistical relationship between the input historical weather data and the predicted future weather conditions may change due to climate change or emergencies. Third, distribution shift between channels: In multivariate time series, the statistical relationship between different variables may change over time. This covariate shift is particularly common in multi-channel time series prediction, and traditional mixed channel processing methods often have difficulty coping with such complex distribution changes.

[0003] Traditional time series forecasting methods, such as the Autoregressive Integrated Moving Average Model (ARIMA), mainly rely on the statistical characteristics of historical data and assume that the data distribution is relatively stable during the forecast period. However, in reality, time series data often leads to dynamic changes in distribution due to changes in the external environment, which makes traditional methods ineffective when facing distribution displacement. With the development of deep learning technology, models such as Recurrent Neural Networks (RNN), Convolutional Neural Networks (CNN) and Transformer-based models have gradually been applied to time series forecasting. However, when these methods are used for long time series forecasting, they do not deal with the distribution displacement problem on the basis of the model. Therefore, they still face the problem of reduced prediction accuracy and model instability due to the distribution displacement problem.

[0004] Kim et al. proposed a learnable normalization method based on a simple linear network for time series forecasting in their paper "Reversible instance normalization for accurate time-series forecasting against distribution shift" (International Conference on Learning Representations (ICLR), 2021). This method adopts a two-stage form, and its implementation steps are: first, the input sequence is processed by a linear neural network to obtain the fluctuation term and the scale term; then the input sequence is normalized to convert it to a uniformly distributed space. Secondly, after the time series prediction network prediction, the model output is reverse normalized using the previous fluctuation term and scale term and converted back to the original space. This method enables different time series to complete model operations in the same distribution space through nonlinear transformation, alleviating the problem of uneven distribution between different input sequences. However, the method still has the disadvantage that the simple linear network used has limited performance when processing complex nonlinear data, and only adaptively scales the input sequence, so it cannot effectively solve the distribution shift problem between input and output and between channels.

[0005] Hangzhou Dianzi University disclosed a time series prediction method implemented through multiple steps in its patent document "A time series prediction method based on multivariate long-term time series analysis" (application number: CN 202410603210.3, application publication number: CN 118349806 A). The implementation steps of this method are, first, data preprocessing and segmentation, setting the length of the historical sequence and the prediction sequence according to different application scenarios, and dividing the data into a training set and a test set. Secondly, the training data is pre-trained based on the statistical value linear fitting network, and the bias generation network, multi-dimensional graph learning network and dual data stream learning network are combined for feature learning and prediction, and finally a prediction sequence is generated. This method can better capture the complex relationships in the time series through the multi-dimensional graph learning network and the dual data stream learning network, and use the bias generation network to fit the statistical values, and solve the distribution displacement problem on the basis of RevIN. However, the method still has the disadvantage that it requires pre-training of the linear fitting network and the steps are relatively complicated. At the same time, this method only deals with the distribution shift scaling between input sequences, and still fails to effectively solve the distribution shift problem between input and output and between channels in multivariate time series. Summary of the invention

[0006] The purpose of the present invention is to address the deficiencies of the above-mentioned prior art and propose a long time series prediction method based on channel independence and bidirectional normalization, aiming to solve the problems of decreased prediction accuracy and unstable training caused by three types of distribution displacement problems in long-term time series prediction.

[0007] To achieve the above purpose, the idea of ​​the present invention is to introduce a new model architecture method that combines a bidirectional normalized learnable subnetwork and a two-way prediction subnetwork based on channel independence. Among them, the bidirectional normalized learnable subnetwork uses two multi-layer perceptron modules with the same structure to predict the fluctuation term and scale term of the input sequence and the output sequence respectively, and normalizes and denormalizes the input sequence and the model output sequence respectively, so as to effectively deal with the distribution displacement problem between input sequences and between input and output sequences. The present invention introduces a two-way prediction subnetwork based on channel independence, adopts a two-way method, one way uses a channel-independent method to independently predict each channel mode, and the other way uses a sparse attention mechanism to fuse the information between channels, and the two are adaptively fused to solve the problem of distribution displacement between channels and improve the feature capture of related channels. During the training process, the present invention can effectively deal with the distribution displacement problem in long-term time series prediction through an adaptive adjustment strategy for model parameters, thereby improving the accuracy and stability of long-term time series prediction.

[0008] The present invention comprises the following steps:

[0009] Step 1, build two multilayer perceptron modules with the same structure, set one of the multilayer perceptron modules as a forward normalization learning module, and set the other multilayer perceptron module as a reverse normalization learning module to obtain a bidirectional normalized learnable subnetwork;

[0010] Step 2: After building a multi-layer perceptron prediction module and a sparse attention prediction module in parallel, they are then connected in series with a dual-path output fusion module to form a dual-path prediction subnetwork based on channel independence;

[0011] Step 3, the forward normalization learning module, the channel-independent dual-path prediction sub-network, and the reverse normalization learning module are sequentially connected in series to form a long time series prediction network;

[0012] Step 4: Use the sliding window segmentation method to segment and predict the historical data of the future time series S = {s i |i∈[1,T],s i ∈R 1×m}, we get the multivariate time series data set X = {x1, x2..., x n}; Divide the data set into training set, validation set and test set in chronological order, where m is the dimension of historical data and s is i is the multidimensional historical data at the i-th moment, T is the length of the historical data sequence, and n is the total number of samples in the multivariate time series data set;

[0013] Step 5: Adaptively adjust network parameters:

[0014] Set up the training environment for the long time series prediction network, input the training set into the long time series prediction network calculation, use the gradient function to iteratively update the network parameters, during which the model is tuned through the validation set until the network loss function converges, and the performance indicators of the model are evaluated through the test set to obtain the trained time series prediction network;

[0015] Step 6: Use the same method as step 4 to perform sliding window segmentation on the long time series data to be predicted, input it into the trained time series prediction network, and output the prediction result.

[0016] Compared with the prior art, the present invention has the following advantages:

[0017] First, the present invention uses a bidirectional normalized learnable subnetwork and adaptively adjusts the normalization and inverse normalization parameters to effectively solve the distribution displacement problem between input sequences and between input and output in long-term time series prediction. This enables the present invention to significantly improve the prediction accuracy and stability of the model while ensuring the consistency of data scale, reduce the dependence on manually set parameters, and reduce the sensitivity of the model to changes in data distribution.

[0018] Second, the present invention successfully addresses the problem of distribution displacement between channels in multivariate time series prediction through a dual-path prediction subnetwork based on channel independence. One path is based on a channel-independent multi-layer perceptron prediction module, which makes the feature extraction of each channel more accurate; the other path is a sparse attention prediction module, which effectively integrates the information between different channels by focusing on the channel features with high correlation, so that the present invention improves the overall accuracy of the prediction results, while reducing the computational complexity and adapting to the processing requirements of high-dimensional data.

[0019] Third, the present invention can effectively deal with the distribution displacement problem in long-term time series prediction through the adaptive adjustment strategy of model parameters, so that the present invention can significantly improve the accuracy and robustness of the prediction model, especially in the complex application scenarios of multi-channel time series, and has significant application advantages. BRIEF DESCRIPTION OF THE DRAWINGS

[0020] Figure 1 is a flow chart of the present invention;

[0021] Figure 2 It is a framework diagram of the dual-path prediction subnetwork of the present invention;

[0022] Figure 3 It is a framework diagram of the long time series prediction model of the present invention;

[0023] Figure 4 , Figure 5 , Figure 6 Result diagram of three simulation experiments of the present invention. DETAILED DESCRIPTION

[0024] The specific embodiments and effects of the present invention are further described in detail below in conjunction with the accompanying drawings.

[0025] Reference Figure 1 , the implementation steps of the embodiments of the present invention are further described in detail.

[0026] Step 1: Build two multilayer perceptron modules with the same structure, set one of the multilayer perceptron modules as a forward normalization learning module, and set the other multilayer perceptron module as a reverse normalization learning module to obtain a bidirectional normalized learnable subnetwork.

[0027] The forward normalization learning module and the reverse normalization learning module are composed of a first linear layer, an activation layer, and a second linear layer connected in series. The input dimensions of the first linear layer are L and H, respectively, and the output is set to 64. The activation layer is implemented using the ReLU function. The input dimension of the second linear layer is set to 64, and the output size is 2. The parameters and bias of the second linear layer are initialized to 0, where the value of L is equal to the length of the historical time series of a sample, and the value of H is equal to the length of the future time series to be predicted.

[0028] Since time series data may have significant distribution differences between different time periods, this distribution shift will affect the learning and prediction capabilities of the model. The introduction of learnable normalization parameters can enable the model to automatically adjust the normalization process according to data characteristics, so as to better adapt to different input data. The bidirectional normalization method can not only alleviate the distribution shift problem between different inputs, but also solve the distribution shift problem between input and output.

[0029] Step 2: After building a multi-layer perceptron prediction module and a sparse attention prediction module in parallel, they are then connected in series with the dual-path output fusion module to form a channel-independent dual-path prediction sub-network.

[0030] according to Figure 2 The framework diagram of the dual-path prediction sub-network shown in FIG. 1 further describes in detail the combination of various modules implemented by the dual-path prediction sub-network into a complete long time series prediction model.

[0031] The channel-independent multi-layer perceptron prediction module is composed of linear layers in parallel whose number is equal to the dimension of historical data. The input dimension of each linear layer is equal to the value of the length L of the historical time series of the sample, and the output dimension is set to be equal to the value of the length H of the predicted future time series. This module processes each channel independently to fully capture the feature information of each channel, avoid interference, and make the feature extraction of each channel more accurate.

[0032] The specific implementation of the channel independence processing step is: model each channel separately, assuming that the input channel of the multivariate time series is For each channel Independently build model f i , and obtain their respective feature representations:

[0033]

[0034] in, Indicates channel characteristics.

[0035] The structure of the sparse attention prediction module is: linear transformation layer, encoder attention layer, linear projection layer; the input dimension of the linear transformation layer of the sparse attention prediction module is equal to the value of the length L of the historical time series, the output dimension is set to 512, the attention layer scaling factor dropout is set to 0.3, the hidden layer dimension is set to 2048, the activation function is implemented using the GELU function, the input dimension of the linear projection layer is set to 512, and the output dimension is equal to the value of the length H of the predicted future time series. The sparse attention prediction module only pays attention to the most relevant inter-channel information, making up for the shortcomings of the channel-independent multi-layer perceptron prediction module that does not fully utilize other channel information, while maintaining the ability to capture important information.

[0036] The structure of the dual-channel output fusion module is [m,2] learnable parameters, where m is the dimension of the historical data, and the parameters of the learnable parameter layer of the dual-channel output fusion module are all set to 0.5. In high-dimensional multi-channel data, the number of channels is large and the relationships between them are complex. A simple independent channel sub-network may ignore the collaborative information between channels, while a simple fusion process may result in excessive computation or excessive fusion of information. Therefore, the combination of independent channel processing and sparse attention mechanism can selectively fuse the correlation between key channels while capturing channel independent information to cope with the complexity of the data.

[0037] Step 3, according to Figure 3 The model structure shown combines the various modules implemented in the previous process into a complete long time series prediction model for further detailed description. Specifically, the forward normalization learning module, the channel-independent dual-path prediction sub-network, and the reverse normalization learning module are connected in series to form a long time series prediction network.

[0038] Step 4: predict the historical data of the future time series S = {s i |i∈[1,T],s i ∈R 1×m}Using sliding window segmentation, construct a multivariate time series data set X = {x1, x2..., x n}, and divide the data set into training set, validation set and test set in chronological order, where m is the dimension of historical data, s i is the multidimensional historical data at the i-th moment, T is the length of the historical data sequence, and n is the total number of samples in the multivariate time series data set.

[0039] By dividing the time series data into smaller time windows, the model can focus on capturing local time series patterns and changing trends, rather than trying to capture all information in the entire series. This helps to assume that the data is stationary within each time window, making the modeling process simpler and more effective. Therefore, in time series analysis and prediction tasks, continuous time series data is often divided into multiple time windows for processing. The specific steps of data processing are: given a time series S = {s i |i∈[1,T],s i ∈R 1×m}, where T is the total length of the sequence and m is the variable dimension. The data is segmented using a fixed rolling window of length L+H. Where n represents the number of samples after segmentation. The data in a window sequence is divided into two parts: the input sequence is the historical observation value X t ={s t-L+1 ,...,s t}, the output sequence is the predicted value Y t ={s t+1 ,...,s t+H}, where L is the length of historical data in a sample, i.e., the input length, and H is the length of the predicted future sequence. The data set is divided into training set, validation set, and test set in chronological order with a ratio of 8:1:1.

[0040] Step 5, adaptively adjust the network parameters: set up the training environment of the long time series prediction network, input the training set into the long time series prediction network calculation, use the gradient function to iteratively update the network parameters, and during this period, tune the model through the validation set until the network loss function converges. Evaluate the performance indicators of the model through the test set to obtain a trained time series prediction network.

[0041] The training environment of the long time series prediction network is as follows: the network loss function adopts the mean square error MSE, the optimizer uses Adam, the initial learning rate is set to 0.001, the bathsize is set to 32, and the early stop of the training process is set to 10 epochs.

[0042] The calculation steps of the long time series prediction network are as follows:

[0043] In the first step, the original multidimensional time series sample X of the prediction task is input into the long time series prediction network. After the forward normalization learning module, the input original multidimensional time series Normalization is performed to eliminate the distribution displacement between the original input sequences and obtain the multidimensional time series after the input offset is repaired. The expression is as follows:

[0044]

[0045] Where X represents the input time series data, μ and σ are the mean and standard deviation, γ and β are learnable scaling and offset parameters, and ⊙ represents element-wise multiplication.

[0046] In the second step, the multidimensional time series data after input offset repair is input through the channel-independent dual-path prediction sub-network, one path is input into the channel-independent multi-layer perceptron prediction module, each channel is input into the corresponding multi-layer perceptron, and the independent feature representation of each channel is extracted, that is, the channel-independent result matrix, which is expressed as follows:

[0047]

[0048]

[0049] Where i represents the i-th dimension, f i represents the multilayer perceptron of the i-th dimension, is the eigenvector of the i-th channel, is the channel-independent result matrix.

[0050] On the other hand, the sparse attention network prediction module captures the correlation and covariate information between channels in each channel sequence to obtain the result of the sparse attention mechanism. That is, the result matrix of multi-channel attention prediction is expressed as follows:

[0051]

[0052] Where Embedding(·) represents the linear transformation layer calculation, attention(·) represents the sparse attention calculation, and Projection(·) represents the mapping layer calculation. It is the result matrix of multi-channel attention prediction.

[0053] In the third step, the channel-independent result matrix and the result matrix of multi-channel attention prediction are jointly input into the dual-channel output fusion module to obtain the dual-channel fusion result matrix, which is expressed as follows:

[0054]

[0055] Where merge(·) represents the calculation of two-way fusion. Represents the result matrix of two-way fusion;

[0056] In the fourth step, the result matrix of the dual-path fusion is subjected to inverse normalization processing by the inverse normalization learning module to restore the original scale of the prediction result and eliminate the distribution displacement between the input and output. The expression is as follows:

[0057]

[0058] Among them, μ' and σ' are the learnable mean and standard deviation, γ' and β' are learnable scaling and offset parameters, and the final multidimensional time series predicted in the future is obtained.

[0059] The gradient function is used to iteratively update the network parameters. During this period, the model is tuned through the validation set until the network loss function converges. The performance indicators of the model are evaluated through the test set to obtain a trained time series prediction network. The network loss function is as follows:

[0060]

[0061] Among them, Y represents the real future sequence of training set samples, It represents the future sequence finally predicted by the long time series prediction model, m represents the total number of channels, H represents the length of the predicted future sequence, i represents the i-th channel, and j represents the j-th time point of the future sequence.

[0062] Step 6: Use the same method as step 4 to perform sliding window segmentation on the long time series data to be predicted, input it into the trained time series prediction network, and output the prediction result.

[0063] The effect of the present invention can be further demonstrated through the following simulation.

[0064] 1. Simulation experimental conditions.

[0065] The simulation platform of the present invention is: an Intel(R) Core(TM) i7-10700K CPU with a main frequency of 3.80GHz, 64.0GB of memory, a graphics card of GeForce RTX 3090*1, an operating system of Ubuntu 22.04, and a development platform of PyCharm2024.2.

[0066] The simulation experiment of the present invention is carried out on the public time series prediction data sets of Electricity, Weather, Traffic and ETT. The Electricity data set is the hourly electricity consumption of 321 customers collected from 2012 to 2014 by Portuguese researcher Artur Trindade. The Weather data set collects 21 weather indicators in a certain area of ​​Germany in 2020, such as air temperature and humidity, and records data every 10 minutes. The Traffic data set collects 48 months (2015-2016) of hourly data from the California Department of Transportation, describing the road occupancy measured by different sensors on highways in the San Francisco Bay Area. These data sets are all real and public multidimensional time series data sets in various fields, and are widely used in the field of time series prediction research.

[0067] 2. Analysis of simulation content and results.

[0068] The simulation experiment of the present invention has three simulations respectively performed on a Traffic data set, a Weather data set, and an Electricity power consumption data set.

[0069] 2.1 Simulation Experiment 1 is a simulation of the Traffic data set.

[0070] Simulation experiment 1 of the present invention uses the method of the present invention and two existing technologies: Informer algorithm and DLinear algorithm to simulate the Traffic data set, and obtains the time series prediction results with the historical input sequence length of 336 and the predicted future length of 96, 192, 336, and 720, and compares them with the real data to obtain the MSE, and then plots the obtained scores as shown below: Figure 4 The bar graph shown in .

[0071] In simulation experiment 1, the two existing technologies used specifically refer to:

[0072] The prior art Informer algorithm is a long time series prediction method proposed by Zhou H et al. in their paper “Informer: Beyond Efficient Transformer for Long Sequence Time-Series Forecasting” (The Thirty-Fifth AAAI Conference on Artificial Intelligence (AAAI), pp 11106-11115, 2021), referred to as the Informer algorithm.

[0073] The prior art DLinear algorithm is a long time series prediction method proposed by Zeng A et al. in their paper “Are transformers effective for time series forecasting?” (The Thirty-Seventh AAAI Conference on Artificial Intelligence (AAAI), 2023), referred to as the DLinear algorithm.

[0074] 2.2 Simulation Experiment 2 is a simulation of the Weather dataset.

[0075] Simulation experiment 2 of the present invention uses the method of the present invention and three existing technologies to simulate the Weather data set, and obtains the time series prediction results with a historical input sequence length of 336 and a predicted future length of 96, 192, 336, and 720, and compares them with the real data to obtain the MSE, and then plots the obtained scores as shown below: Figure 5 The bar graph shown in .

[0076] The three existing technologies used in simulation experiment 2 are: DLinear algorithm, PatchTST algorithm, and TimesNet algorithm, among which the DLinear algorithm is consistent with that in simulation experiment 1. The other two existing technologies used specifically refer to:

[0077] The prior art PatchTST algorithm is a long time series prediction method proposed by Nie Y et al. in their paper “A time series is worth 64 words: Long-term forecasting with transformers” (International Conference on Learning Representations (ICLR), 2023), referred to as the PatchTST algorithm.

[0078] The prior art TimesNet algorithm is a time series analysis method proposed by Wu H et al. in their published paper “TimesNet: Temporal 2D-Variation Modeling for General Time Series Analysis” (International Conference on Learning Representations (ICLR), 2023), referred to as the TimesNet algorithm.

[0079] 2.3 Simulation Experiment 3 is a simulation of the Electricity power consumption dataset.

[0080] Simulation experiment 3 of the present invention adopts the method of the present invention and four existing technologies: DLinear algorithm, PatchTST algorithm, TimesNet algorithm, and Informer algorithm, and simulates the Electricity power consumption data set respectively, and obtains the time series prediction results with the historical input sequence length of 336 and the predicted future length of 96, 192, 336, and 720, and compares them with the real data to obtain the MSE, and then plots the obtained scores as shown below Figure 6 The bar graph shown in .

[0081] In simulation experiment 3, the four existing technologies used are the same as those mentioned in simulation experiments 1 and 2.

[0082] The effects of the present invention are further described below in conjunction with the provided simulation diagrams.

[0083] Figure 4 The MSE results on the Traffic dataset are shown in Figure 2. The horizontal axis represents the predicted future length, and the vertical axis represents the mean square error MSE. The bar graphs respectively represent the relationship between the mean square error and the predicted future length obtained by the method proposed in the present invention, and the relationship between the mean square error and the predicted future length obtained by simulating the existing technologies DLinear and Informer. Figure 4 It can be seen that in all predicted future lengths, the MSE obtained by the method of the present invention is always lower than the simulation results of the prior art DLinear and Informer, especially in long-term prediction (such as 720 time steps), the advantage of the method of the present invention is more obvious.

[0084] Figure 5 The MSE results on the Weather dataset are shown. The physical meanings of the horizontal and vertical axes are the same as before. Among them, each bar graph represents the relationship between the mean square error and the predicted future length obtained by simulating the present invention and the prior art PatchTST, DLinear and TimesNet. Figure 5 It is shown in Figure 2 that the MSE values ​​of the proposed method are better than those of other existing technologies at all prediction time intervals. In particular, in long-term predictions (336 and 720 time steps), the proposed method has lower errors than PatchTST and TimesNet, which highlights the ability of the proposed method to maintain prediction accuracy over a long period of time.

[0085] Figure 6 The MSE results on the Electricity dataset are shown in Figure 2. The physical meanings of the horizontal and vertical axes are the same as before. The bar graphs respectively represent the relationship between the mean square error and the predicted future length obtained by simulating the present invention and the prior art PatchTST, DLinear, TimesNet and Informer. Figure 6 It can be seen that: although all methods perform similarly in shorter-term predictions (96 and 192 time steps), the method of the present invention shows a significantly lower MSE at longer prediction intervals (336 and 720 time steps), indicating its high efficiency and accuracy in dealing with the prediction of complex dynamic systems.

[0086] In summary, the simulation experiment results of the present invention confirm the effectiveness and superiority of the method of the present invention on various time series data sets, especially in long-term prediction tasks, and are applicable to multiple key fields such as electricity, transportation, and weather. In addition, the present invention optimizes the generalization ability and adaptability of the model through bidirectional normalization and channel independence design, so that it can achieve consistent high performance in the application scenarios of complex dynamic systems.

Claims

1. A long time series prediction method based on channel independence and bidirectional normalization, characterized in that: A bidirectional normalized learnable sub-network consisting of a forward normalization learning module and a reverse normalization learning module is constructed; a two-way prediction sub-network based on channel independence is constructed; the steps of the prediction method include the following: Step 1, build two multilayer perceptron modules with the same structure, set one of the multilayer perceptron modules as a forward normalization learning module, and set the other multilayer perceptron module as a reverse normalization learning module to obtain a bidirectional normalized learnable subnetwork; Step 2: After building a multi-layer perceptron prediction module and a sparse attention prediction module in parallel, they are then connected in series with a dual-path output fusion module to form a channel-independent dual-path prediction subnetwork; Step 3, connecting the forward normalization learning module, the channel-independent dual-path prediction sub-network, and the reverse normalization learning module in series to form a long time series prediction network; Step 4: Construct a multivariate time series dataset: The sliding window segmentation method is used to segment and predict the historical data of future time series S = {s i |i∈[1,T],s i ∈R 1×m }, we get the multivariate time series data set X = {x1, x2..., x n }, divide the dataset into training set, validation set and test set in chronological order, where n represents the total number of samples in the multivariate time series dataset, s i represents the multidimensional historical data at the i-th moment, T represents the length of the historical data sequence, and m represents the dimension of the historical data; Step 5: Adaptively adjust network parameters: Set up the training environment for the long time series prediction network, input the training set into the long time series prediction network calculation, use the gradient function to iteratively update the network parameters, during which the model is tuned through the validation set until the network loss function converges, and the performance indicators of the model are evaluated through the test set to obtain the trained time series prediction network; Step 6: Use the same method as step 4 to perform sliding window segmentation on the long time series data to be predicted, input it into the trained time series prediction network, and output the prediction result.

2. The long time series prediction method based on channel independence and bidirectional normalization according to claim 1 is characterized in that: The forward normalization learning module described in step 1 is composed of a first linear layer, an activation layer, and a second linear layer connected in series in sequence; the input dimension of the first linear layer is L, the output is set to 64, the activation layer is implemented using the ReLU function, the input dimension of the second linear layer is set to 64, the output size is 2, and the parameters and bias of the second linear layer are initialized to 0, where the value of L is equal to the length of the historical time series of a sample.

3. The long time series prediction method based on channel independence and bidirectional normalization according to claim 1 is characterized in that: The inverse normalization learning module described in step 1 is composed of a first linear layer, an activation layer, and a second linear layer connected in series in sequence; the input dimension of the first linear layer is H, the output dimension is set to 64, the activation layer is implemented using the ReLU function, the input dimension of the second linear layer is set to 64, the output dimension is 2, and the parameters and bias of the second linear layer are initialized to 0, where the value of H is equal to the length of the future time series to be predicted.

4. The long time series prediction method based on channel independence and bidirectional normalization according to claim 1 is characterized in that: The multi-layer perceptron prediction module described in step 2 is composed of linear layers in parallel, the number of which is equal to the dimension of historical data. The input dimension of each linear layer is equal to the value of the length L of the historical time series of the sample, and the output dimension is set to be equal to the value of the length H of the predicted future time series.

5. The long time series prediction method based on channel independence and bidirectional normalization according to claim 4 is characterized in that: The structure of the sparse attention prediction module described in step 2 is: linear transformation layer, encoder attention layer, linear projection layer; the input dimension of the linear transformation layer of the sparse attention prediction module is equal to the value of the length L of the historical time series, the output dimension is set to 512, the attention layer scaling factor dropout is set to 0.3, the hidden layer dimension is set to 2048, the activation function is implemented using the GELU function, the input dimension of the linear projection layer is set to 512, and the output dimension is equal to the value of the length H of the predicted future time series.

6. The long time series prediction method based on channel independence and bidirectional normalization according to claim 5 is characterized in that: The structure of the dual-channel output fusion module described in step 2 is [m, 2] learnable parameters, where m is equal to the dimension of the historical data, and the parameters of the learnable parameter layer of the dual-channel output fusion module are all set to 0.

5.

7. The long time series prediction method based on channel independence and bidirectional normalization according to claim 1, characterized in that: The ratio of the training set, validation set, and test set described in step 4 is 8:1:

1.

8. The long time series prediction method based on channel independence and bidirectional normalization according to claim 1 is characterized in that: The calculation steps of the long time series prediction network described in step 5 are as follows: In the first step, the original multidimensional time series sample X of the prediction task is input into the long time series prediction network. After the forward normalization learning module, the input original multidimensional time series is normalized to eliminate the distribution offset between the original input sequences, and the multidimensional time series after the input offset is repaired is obtained. The expression is as follows: Where X represents the input time series data, γ and β represent the learnable scaling and offset parameters, ⊙ represents the element-by-element multiplication sign, and μ and σ represent the mean and standard deviation, respectively. The second step is to input the offset-corrected multidimensional time series data. Input the dual-path prediction sub-network based on channel independence, one path inputs the channel-independent multi-layer perceptron prediction module, each channel is input into the corresponding multi-layer perceptron, and the independent feature representation of each channel is extracted, that is, the channel-independent result matrix Its expression is as follows: in, represents the ith channel feature vector, f i represents the multilayer perceptron calculation of the i-th dimension, m represents the total number of channels, is the channel-independent result matrix; The other channel in the channel-independent dual-channel prediction subnetwork is predicted by the sparse attention network prediction module to capture the correlation and covariate information between channels in each channel sequence and obtain the result of the sparse attention mechanism. That is, the result matrix of multi-channel attention prediction is expressed as follows: in, Represents the result matrix of multi-channel attention prediction, Projection(·) represents the mapping layer calculation, attention(·) represents the sparse attention calculation, and Embedding(·) represents the linear transformation layer calculation; Step 3: Channel-independent result matrix The result matrix of multi-channel attention prediction The two-way output fusion module is input together to obtain the result matrix of the two-way fusion, which is expressed as follows: in, represents the result matrix of two-way fusion, and merge(·) represents the calculation of two-way fusion; In the fourth step, the result matrix of the dual-path fusion is subjected to inverse normalization processing by the inverse normalization learning module to restore the original scale of the prediction result and eliminate the distribution offset between the input and output. The expression is as follows: in, denoted by the multidimensional time series that is finally predicted into the future, μ' and σ' represent the learnable mean and standard deviation, respectively, and γ and β represent the learnable scaling and offset parameters, respectively.

9. The long time series prediction method based on channel independence and bidirectional normalization according to claim 1, characterized in that: The training environment of the long time series prediction network described in step 5 is that the network loss function adopts the mean square error MSE, the optimizer uses Adam, the initial learning rate is set to 0.001, the batch size is set to 32, and the training process EarlyStopping is set to 10 epochs.

10. The long time series prediction method based on channel independence and bidirectional normalization according to claim 1, characterized in that: The network loss function described in step 5 is as follows: Among them, Y represents the real future sequence of training set samples, It represents the future sequence predicted by the long time series prediction model, m represents the total number of channels with the same dimension as the historical data, H represents the length of the predicted future sequence, i represents the sequence number of the channel, and j represents the sequence number of the time point of the future sequence.

Citation Information

Patent Citations

  • Short-term electricity consumption prediction model construction method, prediction method and device

    CN113554466A

  • Long-period multivariate time sequence prediction method based on multivariate information interaction

    CN117786602A

  • Prediction method based on irregular time series data

    CN118194242A

  • Short-term carbon emission prediction method and device, computer readable storage medium and product

    CN118628121A

  • Multi-scale hybrid attention mechanism modeling method for predicting remaining useful life of aero engine

    WO2024087128A1

Cited By

  • Time sequence prediction method and device based on MPDLINE model and medium

    CN120144960A

  • Method and device for predicting service life of aero-engine based on Dline-CNN (Convolutional Neural Network) model

    CN120316434A