Time sequence prediction method based on VMD-CEEMDAN-BO-LSTM hybrid model and application
The VMD-CEEMDAN-BO-LSTM hybrid model decomposes and predicts the power load data, solves the modal aliasing and noise problems in complex power load prediction, improves the prediction accuracy and robustness, and is suitable for scheduling optimization and resource configuration of power systems.
Patent Information
- Application Number
- CN202510540079.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-27
- Publication Date
- 2025-08-08
AI Technical Summary
When the existing power load prediction methods deal with complex nonlinear and unstable data, there are problems such as modal aliasing, high signal noise, and frequency drift, which affect the robustness and accuracy of the prediction model. Especially when large-scale power load data and various influencing factors, the power demand changes are difficult to accurately capture.
The VMD-CEEMDAN-BO-LSTM hybrid model is adopted to decompose the power load data through VMD and CEEMDAN quadratic decomposition technology, and combine the Bayesian optimization algorithm to optimize the hyperparameters of the long and short-term memory network model, and build a deep learning model to predict it effectively denoising, reducing modal aliasing, and extracting pure signal characteristics.
It improves the accuracy and robustness of power load prediction, adapts to complex signals, and shows significant advantages in high noise, non-stationary, and intermittent power load data prediction, expands the application field of power load prediction technology, and supports power system scheduling optimization and resource allocation.
Smart Images

Figure CN120450475A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of power load forecasting, and specifically relates to a time series forecasting method and application based on a VMD-CEEMDAN-BO-LSTM hybrid model. Background Art
[0002] With the rapid development of science and technology, time series forecasting technology has been widely applied in various fields, particularly in power load forecasting. Its core goal is to accurately predict future changes in power demand through the analysis and modeling of historical data, thereby providing decision support for power system scheduling and management. In power systems, accurate load forecasting not only helps ensure stable grid operation but also effectively optimizes resource utilization, improving the economic efficiency and sustainability of the power system. It holds significant application value in promoting the integration of renewable energy, ensuring the stability of power supply, and promoting the marketization of electricity. Traditional power load forecasting methods, such as time series and regression analysis, while effective in some simple scenarios, often suffer from low prediction accuracy in complex power load forecasting due to their simple model structures, weak feature extraction capabilities, and difficulty handling nonlinear and unstable data. Especially when processing large-scale power load data and considering multiple influencing factors, traditional methods often fail to accurately capture the changing patterns of power demand.
[0003] To overcome these limitations, combined forecasting methods that combine the strengths of different technologies have been widely used in recent years. For example, some studies have used multi-layer feedforward neural network models to improve forecast accuracy. By combining different modal decomposition techniques, they can effectively reduce the impact of noise and improve forecast accuracy. However, these methods still face challenges with complex nonlinear time series data, such as modal aliasing, high signal noise, and frequency drift, which affect the robustness and accuracy of the forecasting models.
[0004] To address these problems, the present invention proposes a new time series prediction method and application, which constructs a VMD-CEEMDAN-BO-LSTM hybrid model, which can not only effectively denoise, reduce modal aliasing, and extract purer signal features, but also enhance the accuracy and robustness of prediction and adapt to complex signals. Summary of the Invention
[0005] The object of the present invention is to provide a time series prediction method based on the VMD-CEEMDAN-BO-LSTM hybrid model, which achieves accurate prediction and improves the processing capability of complex time series data by combining and integrating the VMD-CEEMDAN-BO-LSTM hybrid model.
[0006] In order to achieve the above objectives, the technical solutions adopted are:
[0007] A time series prediction method based on a VMD-CEEMDAN-BO-LSTM hybrid model includes the following steps:
[0008] S10: normalize the original time series data to obtain processed data;
[0009] S20: Decomposing the processed data by VMD-CEEMDAN secondary decomposition into a plurality of refined modal components (IMFs);
[0010] S30: Build a deep learning model, which is a long short-term memory network model;
[0011] S40: Using a Bayesian optimization algorithm to perform global optimization on the hyperparameters of the long short-term memory network model to determine the optimal hyperparameter combination of each modal component IMF;
[0012] S50: After substituting each of the optimal hyperparameter combinations into the long short-term memory network model, each of the modal components IMF is predicted, and the prediction results are reconstructed into a complete time series prediction value.
[0013] Furthermore, the secondary decomposition process in step S20 is as follows: decomposing the original time series data into several modal components by VMD, calculating the sample entropy of each modal component, selecting the modal components with high sample entropy and performing secondary decomposition by CEEMDAN, adding white noise and applying EMD for decomposition, and then removing the noise to obtain several refined modal components IMF.
[0014] Furthermore, the VMD decomposition process is as follows:
[0015] The objective function and constraints of the VMD algorithm are as follows:
[0016]
[0017] Where f(t) is the original signal; ω k is the center frequency of the kth modal component after decomposition; δ(t) is the Dirac function; * is the convolution operator.
[0018] Secondly, by introducing the Lagrangian operator λ and the quadratic penalty factor α, we can get the augmented expression of the formula, using the following formula:
[0019]
[0020] Finally, the alternating direction method of the multiplication operator is used for secondary optimization. After optimization, the modal components and the center frequencies of the modal components are obtained using the following formula:
[0021]
[0022] Furthermore, the sample entropy is calculated using the following formula:
[0023]
[0024] The C m (r) is the matching degree, which is the similarity between all embedded vectors, using the following formula:
[0025]
[0026] Where θ(r) is a step function. When ||X i -X j It is 1 when ||≤r, otherwise it is 0.
[0027] Furthermore, in step S40, the process of using the Bayesian optimization algorithm to globally optimize the hyperparameters of the long short-term memory network model is as follows:
[0028] S41: Based on the Bayesian optimization algorithm, the constructed long short-term memory network model is used to predict the decomposed time series data to obtain the predicted value of each series;
[0029] S42: Randomly select hyperparameter combinations, train long short-term memory network models, evaluate their performance, and construct Gaussian process surrogate models;
[0030] S43: Based on the known (initial combination of hyperparameters and the RMSE value corresponding to the initial combination of hyperparameters), a probabilistic model is established to predict the value of the objective function at other unevaluated points. The goal is to estimate the performance of the objective function at different hyperparameter combinations by providing the posterior distribution of the objective function.
[0031] S44: Use the defined expected improvement to select the next hyperparameter combination;
[0032] S45: Bayesian optimization evaluates the next hyperparameter combination; after each evaluation, the new hyperparameter combination and its corresponding RMSE value are added to the dataset and the Gaussian process model is retrained;
[0033] S46: Repeat steps S42-S45, select the most promising hyperparameter combination for evaluation, and determine the optimal hyperparameter combination.
[0034] Furthermore, in step S42, the Gaussian process proxy model adopts the following formula:
[0035] X0={x1,x2,···,x n}, y0={f(x1),f(x2),···,f(x n )};
[0036] Among them, X0 is the initial combination of hyperparameters, and y0 is the corresponding RMSE value.
[0037] Furthermore, in step S43, the objective function adopts the following formula:
[0038] f(x)~GP(m(x),k(x,x′));
[0039] Where f(x) is the objective function, m(x) is the value function (usually 0), and k(x, x′) is the kernel function used to measure the similarity between different hyperparameters.
[0040] Furthermore, in step S44, the next hyperparameter combination x is selected by defining the expected improvement. n+1 , using the following formula:
[0041] EI(x)=E[max(0,f(x + )-f(x))];
[0042] Among them, f(x + ) is the current optimal objective function value, f(x) is the predicted objective function value at the hyperparameter combination x, max(0,f(x + )-f(x)) is the improved value.
[0043] Furthermore, in step S40, the hyperparameters are the learning rate, the number of neurons in the hidden layer, and the number of samples.
[0044] Another object of the present invention is to provide an application of the above-mentioned time series prediction method based on the VMD-CEEMDAN-BO-LSTM hybrid model in power load forecasting.
[0045] Compared with the prior art, the present invention has the following beneficial effects:
[0046] The present invention discloses a time series prediction method and application based on a VMD-CEEMDAN-BO-LSTM hybrid model. It is a combined prediction method that combines integrated empirical mode decomposition and noise (CEEMDAN), variational mode decomposition (VMD), Bayesian optimization (BO) and long short-term memory network (LSTM). The method first decomposes the original power load data through the VMD+CEEMDAN secondary decomposition technology and converts it into components of different frequencies, thereby effectively eliminating irregular fluctuations and noise in the data. Subsequently, the Bayesian optimization algorithm is used to optimize the model parameters to further improve the prediction accuracy. Finally, the decomposed data is accurately predicted by the LSTM deep learning model, which improves the processing ability of complex time series data.
[0047] The technical solution of this invention not only effectively removes noise, reduces modal aliasing, and extracts purer signal features, but also enhances the accuracy and robustness of predictions and adapts to complex signals. This approach offers significant advantages, particularly in applications involving the prediction of high-noise, non-stationary, and intermittent power load data. The application of this technology expands the scope of power load forecasting technology, improves its accuracy, and provides stronger technical support for power system scheduling optimization, resource allocation, and the development of the power market. BRIEF DESCRIPTION OF THE DRAWINGS
[0048] Figure 1 Flowchart of the present invention
[0049] Figure 2 This is the VMD-CEEMDAN secondary decomposition flow chart;
[0050] Figure 3 Schematic diagram of the long short-term memory network structure;
[0051] Figure 4 Optimizing LSTM models for Bayesian
[0052] Figure 5 Flowchart for VMD-CEEMDAN-BO-LSTM time series prediction. DETAILED DESCRIPTION
[0053] To further illustrate the present invention's method and application for time series prediction based on a VMD-CEEMDAN-BO-LSTM hybrid model and achieve its intended purpose, the following describes, in conjunction with preferred embodiments, a detailed description of the present invention's method and application for time series prediction based on a VMD-CEEMDAN-BO-LSTM hybrid model, including its specific implementation, structure, features, and effectiveness. In the following description, different references to "one embodiment" or "embodiment" do not necessarily refer to the same embodiment. Furthermore, specific features, structures, or characteristics of one or more embodiments may be combined in any suitable manner.
[0054] The following is a detailed introduction to a time series prediction method based on a VMD-CEEMDAN-BO-LSTM hybrid model and its application in conjunction with specific embodiments:
[0055] In order to solve the problems that existing technologies still face when processing complex nonlinear time series data, such as modal aliasing, high signal noise, and frequency drift, which affect the robustness and accuracy of the prediction model, the present invention proposes a time series prediction method and application based on a VMD-CEEMDAN-BO-LSTM hybrid model. The technical solution of the present invention is based on the VMD-CEEMDAN-BO-LSTM hybrid model, which is a combined algorithm for optimizing data preprocessing and neural network hyperparameter selection. The technical solution of the present invention is as follows:
[0056] A time series prediction method based on a VMD-CEEMDAN-BO-LSTM hybrid model includes the following steps:
[0057] S10: normalize the original time series data to obtain processed data;
[0058] S20: Decomposing the processed data by VMD-CEEMDAN secondary decomposition into a plurality of refined modal components (IMFs);
[0059] S30: Build a deep learning model, which is a long short-term memory network model;
[0060] S40: Using a Bayesian optimization algorithm to perform global optimization on the hyperparameters of the long short-term memory network model to determine the optimal hyperparameter combination of each modal component IMF;
[0061] S50: After substituting each of the optimal hyperparameter combinations into the long short-term memory network model, the modal component IMF is predicted, and the prediction result is reconstructed into a complete time series prediction value.
[0062] Preferably, the secondary decomposition process in step S20 is: decomposing the original time series data into several modal components by VMD, then calculating the sample entropy of each modal component, selecting the modal component with high sample entropy and performing secondary decomposition by CEEMDAN, adding white noise and applying EMD for decomposition, and then removing the noise to obtain several refined modal components IMF.
[0063] Further preferably, the VMD decomposition process is:
[0064] The objective function and constraints of the VMD algorithm are as follows:
[0065]
[0066] Where f(t) is the original signal; ω k is the center frequency of the kth modal component after decomposition; δ(t) is the Dirac function; * is the convolution operator.
[0067] Secondly, by introducing the Lagrangian operator λ and the quadratic penalty factor α, we can get the augmented expression of the formula, using the following formula:
[0068]
[0069] Finally, the alternating direction method of the multiplication operator is used for secondary optimization. After optimization, the modal components and the center frequencies of the modal components are obtained using the following formula:
[0070]
[0071] Further preferably, the sample entropy adopts the following formula:
[0072]
[0073] The C m (r) is the matching degree, which is the similarity between all embedded vectors, using the following formula:
[0074]
[0075] Where θ(r) is a step function. When ||X i -X j It is 1 when ||≤r, otherwise it is 0.
[0076] Preferably, in step S40, the process of using the Bayesian optimization algorithm to perform global optimization on the hyperparameters of the long short-term memory network model is as follows:
[0077] S41: Based on the Bayesian optimization algorithm, the constructed long short-term memory network model is used to predict the decomposed time series data to obtain the predicted value of each series;
[0078] S42: Randomly select hyperparameter combinations, train long short-term memory network models, evaluate their performance, and construct Gaussian process surrogate models;
[0079] S43: Based on the known (initial combination of hyperparameters and the RMSE value corresponding to the initial combination of hyperparameters), a probabilistic model is established to predict the value of the objective function at other unevaluated points. The goal is to estimate the performance of the objective function at different hyperparameter combinations by providing the posterior distribution of the objective function.
[0080] S44: Use the defined expected improvement to select the next hyperparameter combination;
[0081] S45: Bayesian optimization evaluates the next hyperparameter combination; after each evaluation, the new hyperparameter combination and its corresponding RMSE value are added to the dataset and the Gaussian process model is retrained;
[0082] S46: Repeat steps S42-S45, select the most promising hyperparameter combination for evaluation, and determine the optimal hyperparameter combination.
[0083] Further preferably, in step S42, the Gaussian process proxy model adopts the following formula:
[0084] X0={x1,x2,···,x n}, y0={f(x1),f(x2),···,f(x n )};
[0085] Among them, X0 is the initial combination of hyperparameters, and y0 is the corresponding RMSE value.
[0086] Furthermore, in step S43, the objective function adopts the following formula:
[0087] f(x)~GP(m(x),k(x,x′));
[0088] Where f(x) is the objective function, m(x) is the value function (usually 0), and k(x, x′) is the kernel function used to measure the similarity between different hyperparameters.
[0089] Further preferably, in step S44, the next hyperparameter combination x is selected by defining the expected improvement. n+1 , using the following formula:
[0090] EI(x)=E[max(0,f(x + )-f(x))];
[0091] Among them, f(x + ) is the current optimal objective function value, f(x) is the predicted objective function value at the hyperparameter combination x, max(0,f(x + )-f(x)) is the improved value.
[0092] Preferably, in step S40, the hyperparameters are the learning rate, the number of neurons in the hidden layer, and the number of samples.
[0093] Figure 1-5 This paper presents an implementation of a time series prediction method based on the VMD-CEEMDAN-BO-LSTM hybrid model. The method first decomposes the raw data using VMD+CEEMDAN secondary decomposition. Secondly, a Bayesian optimization algorithm is used to optimize the hyperparameters of the long-short-term memory network (LSTM) of the deep learning model to obtain the optimal model parameters for time series prediction. Finally, the hybrid model is applied to time series prediction. This technical solution offers improved prediction results, effectively enhancing prediction accuracy and stability, and is therefore suitable for complex power systems and material performance prediction involving intermittent energy sources such as wind power and photovoltaics.
[0094] The specific embodiments of the present invention are as follows:
[0095] Example 1.
[0096] Combine Figure 1 , the specific steps are as follows:
[0097] S10: Normalize the original time series data and divide the processed data into training set data and test set data.
[0098] S20: Decompose the training set data using VMD-CEEMDAN secondary decomposition, splitting the data into several stable intrinsic mode functions (IMFs), i.e., several refined modal component IMFs.
[0099] S30: Build a deep learning model - long short-term memory network model.
[0100] S40: A Bayesian optimization algorithm is used to globally optimize the hyperparameters of the long short-term memory network model (such as the number of hidden layer units, learning rate, training batch size, etc.) to determine the optimal hyperparameter combination for each modal component IMF.
[0101] S50: According to the optimal value found by the Bayesian optimization algorithm, the hyperparameters of the long short-term memory network are brought into play, that is, the optimal hyperparameter combination is substituted into the long short-term memory network model.
[0102] S60: Forecast the decomposed time series, that is, predict each modal component IMF, and reconstruct the predicted results into a complete time series prediction value.
[0103] S70: Use the test set data to experimentally verify the above method and obtain the prediction results.
[0104] Example 2.
[0105] Combine Figure 2-5 Based on Example 1, the method is refined. The specific steps are as follows:
[0106] S20: VMD-CEEMDAN secondary decomposition is used to process the original time series data and decompose it into several stable intrinsic mode functions (IMFs).
[0107] In this embodiment, a prediction method combining VMD and CEEMDAN secondary decomposition is adopted. Figure 2 First, the original signal is decomposed into multiple modal components using VMD. Modes with high sample entropy are selected by calculating sample entropy. Then, CEEMDAN performs a secondary decomposition of these modes, adding noise and performing multiple EMD decompositions to remove noise and extract precise signal components. The resulting modal components retain the signal's effective information while reducing noise interference, resulting in purer, more clearly decomposed IMF components, enabling more accurate time series analysis.
[0108] The key points of each step are:
[0109] (1) Variational Mode Decomposition (VMD)
[0110] Variational Mode Decomposition (VMD) is an adaptive technique for signal decomposition. Its core idea is to automatically match the center frequency and bandwidth of the signal by constructing a variational problem and solving it using an iterative optimization method. VMD is known for its high computational efficiency and strong noise immunity. It has excellent performance in the field of signal reconstruction and can decompose non-stationary signals into multiple components with different center frequencies under limited bandwidth conditions. For a given original signal, it can be decomposed into k modal components u k .
[0111] The objective function and constraints of the VMD algorithm in this embodiment are as follows:
[0112]
[0113] Where f(t) is the original signal; ω k is the center frequency of the kth modal component after decomposition; δ(t) is the Dirac function; * is the convolution operator.
[0114] Secondly, by introducing the Lagrangian operator λ and the quadratic penalty factor α, the augmented expression of the formula is obtained as follows:
[0115]
[0116] Finally, the alternating direction method of the multiplication operator is used for secondary optimization. After optimization, the modal components and the center frequencies of the modal components are obtained using the following formula:
[0117]
[0118]
[0119] (2) Sample Entropy (SampEn)
[0120] Sample entropy is used to measure the complexity of a sequence. It is calculated by measuring the frequency of similar patterns. Given a time series x = (x1, x2, ..., x N ), the calculation steps of sample entropy are as follows:
[0121] ①Construct the embedding space: Use a window size m and tolerance r to construct a vector:
[0122] X i =(x i , x i+1 ,...,x i+m-1 ), i=1, 2, ..., N-m+1 (Formula 5)
[0123] ② Calculate the matching degree: Calculate the similarity between all embedded vectors, defined as:
[0124]
[0125] Where θ(r) is a step function. When ||X i -X j It is 1 when ||≤r, otherwise it is 0.
[0126] ③ Sample entropy calculation: Sample entropy SampEn is calculated by the following formula:
[0127]
[0128] Among them, C m (r) is the matching degree when the embedding dimension is m, C m+1 (r) is the matching degree with embedding dimension m + 1. The higher the sample entropy, the more complex the sequence.
[0129] (3) CEEMDAN decomposition
[0130] CEEMDAN is an extended version of EMD. It reduces the interference of noise and improves the decomposition accuracy of the signal by adding noise to the signal and performing multiple decompositions. Assuming that we already have a signal x(t), its CEEMDAN decomposition process is as follows:
[0131] ① Add noise: Add white noise η(t) to the signal x(t) to obtain a new signal using the following formula:
[0132]
[0133] Here, the noise η(t) has a Gaussian distribution with a mean of zero.
[0134] ② First EMD decomposition: Perform empirical mode decomposition (EMD) on the signal y(t) with added noise to obtain several modal components using the following formula:
[0135]
[0136] Among them, the IMF k (t) is the kth intrinsic mode function (IMF), and r(t) is the residual signal.
[0137] ③ Denoising: IMF of the obtained modal component k (t) Perform denoising to remove noise components and obtain more accurate modes.
[0138] ④ Repeat the process: In each iteration, by adding different noises and performing EMD decomposition, we gradually obtain clearer and more accurate modal components. After each iteration, the noise will affect the decomposition of the signal, thus ensuring the extraction of details in the signal.
[0139] ⑤Final IMF: After multiple iterations, the final IMF series can accurately represent the intrinsic modes of the signal, and the influence of noise has been significantly reduced.
[0140] (4) Mathematical model of CEEMDAN
[0141] The mathematical formula of CEEMDAN can be written as: IMF k (t) = EMD (x(t) + η(t)) (Formula 10)
[0142] Where η(t) is the noise signal generated by the k-th noise addition, and EMD is the empirical mode decomposition operation applied to the signal.
[0143] In each round of noise decomposition, CEEMDAN generates a new set of IMFs and repeats this process multiple times to obtain more accurate modal components. In this way, the low-frequency and high-frequency components in the signal are accurately separated and the impact of noise on the results is minimized.
[0144] (5) Combining VMD and CEEMDAN
[0145] In the process of combining VMD and CEEMDAN, multiple modal components u are first obtained by VMD decomposition. k (t), then the sample entropy of each mode is calculated, and the modal components with higher sample entropy are selected for CEEMDAN re-decomposition.
[0146] Among them, the combination formula of VMD and CEEMDAN is as follows:
[0147] u k (t) = VMD(x(t)) (modal components after VMD decomposition) (Equation 11)
[0148] SampEn(u k )(Calculate sample entropy)(Formula 12)
[0149] After selecting the modal components with high sample entropy, CEEMDAN is applied to them, and the formula is as follows: IMF k (t)=EMD(u k (t) + η(t)) (Formula 13)
[0150] The present invention improves the problem of VMD modal aliasing through VMD-CEEMDAN, denoises the input time series data, divides the input time series data into several components, and improves the prediction performance.
[0151] Steps S30-S40: After constructing the deep learning model long short-term memory network model (LSTM), the Bayesian optimization algorithm (BO) is used to optimize the hyperparameters of the deep learning model long short-term memory network model (LSTM).
[0152] The advantages of the LSTM model in time series forecasting lie primarily in its ability to model nonlinear and complex dynamic relationships, its ability to capture both long-term and short-term dependencies, and its robustness to irregular and noisy data. Through automatic feature learning and multivariate input processing, LSTM provides an accurate and efficient forecasting solution, effectively processing time series data.
[0153] This embodiment uses the hyperparameters of the LSTM model as the optimization object of BO, takes RMSE as the fitness value of the objective function, finds the hyperparameters corresponding to the minimum RMSE, and trains to obtain the optimal hyperparameters of the model.
[0154] LSTM neural networks require many hyperparameters to be configured, which can affect the model's convergence speed, generalization ability, and ultimately its prediction performance. Using BO to tune hyperparameters avoids the uncertainty of manual tuning, reduces randomness, and provides more stable optimization results.
[0155] In this embodiment, the learning rate (α), the number of hidden layer neurons (n t ), batch sample size (m b ) as the optimization target of BO. The learning rate controls the step size of each parameter update, the number of hidden layer neurons represents the number of neurons in each hidden layer, and the number of batch samples represents the number of samples selected for each training (i.e., batch size).
[0156] The specific steps of the BO-LSTM algorithm proposed in step S30 of this embodiment are as follows:
[0157] S30: Determine the initial structure of LSTM (build LSTM model)
[0158] The structure of a single LSTM is as follows Figure 3 As shown, the forget gate (f t ): By controlling the retention and forgetting of information in the cell state of the previous time step, the LSTM network is provided with a strong long-term memory capability. The calculation formula is shown as follows:
[0159] f t =σ(W f [h t-1 ,x t ]+b f )(Formula 14)
[0160] Input gate (v t ) controls the acceptance of new input information through the Sigmoid activation function, and together with the candidate value generated by tanh, determines the update of the memory unit state, thus playing a key role in learning long-term dependencies and processing time series data. The calculation formula is as follows:
[0161] v t =σ(W v [h t-1 ,x t ]+b v )(Formula 15)
[0162] Output gate (o t ): Controls the output of the next time step. It determines which parts of the current memory cell state will be output as hidden states. The calculation formula is as follows:
[0163] o t =σ(W o [ht-1 ,x t ]+b o ) (Formula 16)
[0164] g t is the input state of the memory cell, is the storage cell value adjusted by the information, and is the candidate memory cell state. The calculation formula is as follows:
[0165] g t =tanh(W g [h t-1 ,x t ]+b g )(Formula 17)
[0166] The cell state at the current time step t is as follows:
[0167]
[0168] The hidden state (output) at the current time step t is as follows:
[0169]
[0170] Among them, W f 、W v 、W g 、W o is the weight matrix; b f 、b v 、b g 、b o is bias; Represents bitwise multiplication of the elements in a vector.
[0171] S40: Combined Figure 4 , BO is used to optimize the LSTM hyperparameters and update them to determine the best hyperparameter combination for each modal component IMF. The optimization process for the best hyperparameter combination for each modal component IMF is:
[0172] Step S41: Based on the Bayesian optimization algorithm, the constructed LSTM is used to predict the decomposed time series data (the k subsequences after VMD-CEEMDAN decomposition are divided into training data and test data, and the training data is used here) to obtain the predicted value of each sequence.
[0173] Step S42: Randomly select some hyperparameter combinations, train the LSTM model, and evaluate its performance (calculate RMSE). These initial evaluation points will be used to build the Gaussian process surrogate model. The formula is as follows:
[0174] X0={x1,x2,···,x n} (Formula 20)
[0175] y0={f(x1),f(x2),···,f(x n )} (Formula 21)
[0176] Where X0 is the initial combination of hyperparameters and y0 is the corresponding RMSE value (objective function evaluation).
[0177] Step S43: Build a probability model based on the known (X0, y0) to predict the value of the objective function at other unevaluated points. The goal is to estimate the performance of the objective function under different hyperparameter combinations by providing the posterior distribution of the objective function.
[0178] f(x)~GP(m(x),k(x,x′))(Formula 22)
[0179] Where f(x) is the objective function, m(x) is the value function (usually 0), and k(x, x′) is the kernel function used to measure the similarity between different hyperparameters.
[0180] Step S44: Use the metric that defines the expected improvement to select the next sampling point, that is, the next hyperparameter combination to evaluate. The expected improvement aims to select those hyperparameter combinations that are likely to lead to a significant improvement in the objective function value.
[0181] EI(x)=E[max(0,f(x + )-f(x))](Formula 23)
[0182] Among them, f(x + ) is the current optimal objective function value, f(x) is the predicted objective function value at the hyperparameter combination x, max(0,f(x + )-f(x)) is the improved value.
[0183] Step S45: The next hyperparameter combination is selected and the Bayesian optimization will evaluate this combination. After each evaluation, the new hyperparameter combination and its corresponding RMSE value will be added to the dataset and the Gaussian process model will be retrained using this data.
[0184] Step S46: Bayesian optimization will repeat the above steps, select the most promising hyperparameter combination for evaluation, continuously improve the surrogate model, and finally find the optimal hyperparameter combination and the best hybrid model.
[0185] S50: Substitute the best hyperparameter combination obtained by Bayesian optimization into the LSTM model
[0186] 1) Initialize the population size, determine the learning rate, the number of hidden layer neurons, and the number of samples.
[0187] 2) Use the best hyperparameter combination (such as learning rate, number of hidden layer neurons, etc.) obtained from the Bayesian optimization algorithm to configure the LSTM model. In this way, the hyperparameters of the LSTM model will be optimally set to make predictions on the given time series data.
[0188] 3) Use the LSTM model's prediction performance (e.g., RMSE) on the test data as the fitness function and calculate the model's fitness under the current hyperparameter settings. By evaluating RMSE, we can measure the accuracy of the model's predictions and further optimize the model's performance.
[0189] RMSE calculates the root mean square error between the predicted value and the true value, and the formula used is as follows:
[0190]
[0191] Where n is the number of observations in the test sample, y i and are the actual observed values and the predicted values, respectively.
[0192] S60: Forecast the decomposed time series. This involves applying the LSTM model optimized in S50 to each modal component IMF, and then reconstructing the predicted results into a complete time series forecast. In other words, each modal component IMF undergoes a separate BO-LSTM forecast process, and the resulting results are reconstructed into a complete time series forecast.
[0193] Example 3.
[0194] Based on Example 2, the specific steps are as follows:
[0195] (1) Obtain the time series data of a certain region to form the original data set, that is, the original time series.
[0196] (2) Clean the original time series and data, fill in missing values, remove outliers with excessive deviations, and perform normalization.
[0197] ① Missing data processing: Check whether there are missing values in the original data set. Since the time series is continuous, the missing data is filled using the mean method, that is, the average of the sum of the two data before and after the missing point is calculated.
[0198] ② Deviation data processing: In view of the periodic characteristics of time series and the small fluctuation in the short term, the detected outliers are replaced with the data at the same time point one week ago.
[0199] ③ Normalization: Normalize the data according to Formula 25.
[0200]
[0201] Among them, y i is the normalized value, x i is the original value of the data, x max and x min are the maximum and minimum values of the data respectively.
[0202] (3) VMD and CEEMDAN are used to process the original time series data and decompose it into several modal functions (IMFs).
[0203] (4) Establish a BO-LSTM prediction model.
[0204] (5) K modal functions (IMFs) are obtained, and the parameter range of the Bayesian optimization algorithm is set, including the search space of the number of hidden layer units and the number of layers, as well as optimization control parameters such as the maximum number of evaluations and the number of initial sampling points.
[0205] Build an LSTM network and initialize its basic architecture. Define the root mean square error (RMSE) as the objective function. Bayesian optimization uses a Gaussian process surrogate model and acquisition function to dynamically select the optimal parameter combination and find the network hyperparameters that minimize RMSE.
[0206] Finally, the optimized hyperparameters are applied to the LSTM network, and the predicted value sequences of all subsequences are reconstructed and denormalized to obtain the final predicted value and judged based on the mean absolute percentage error (MAPE). The calculation formula is as follows:
[0207]
[0208] Among them, y i represents the true value, Represents the predicted value.
[0209] Example 4.
[0210] The method proposed in the present invention is compared with other classic prediction methods in terms of time series prediction accuracy on a data set of power load (questions from the 9th Electrical Mathematical Modeling Competition (2016)). A single LSTM model, a BO-LSTM model, a VMD-BO-LSTM model, and a VMD-CEEMDAN-BO-LSTM model (i.e., the technical solution of the present invention) are used.
[0211] The prediction results MAPE are shown in Table 1.
[0212] Table 1 Comparison of MAPE of prediction results
[0213]
[0214] As shown in Table 1, the accuracy and reliability of the method proposed in the present invention are verified by comparison with other methods.
[0215] The above is merely a preferred embodiment of the present invention and does not constitute any form of limitation to the embodiments of the present invention. Any simple modifications, equivalent changes, and modifications made to the above embodiments based on the technical essence of the embodiments of the present invention are still within the scope of the technical solutions of the embodiments of the present invention.
Claims
1. A time series prediction method based on VMD-CEEMDAN-BO-LSTM hybrid model, characterized in that: The following steps are involved: S10: normalize the original time series data to obtain processed data; S20: Decomposing the processed data by VMD-CEEMDAN secondary decomposition into a plurality of refined modal components (IMFs); S30: Build a deep learning model, which is a long short-term memory network model; S40: Using a Bayesian optimization algorithm to perform global optimization on the hyperparameters of the long short-term memory network model to determine the optimal hyperparameter combination of each modal component IMF; S50: After substituting each of the optimal hyperparameter combinations into the long short-term memory network model, each of the modal components IMF is predicted, and the prediction results are reconstructed into a complete time series prediction value.
2. The time series prediction method according to claim 1, characterized in that The secondary decomposition process in step S20 is as follows: decomposing the original time series data into several modal components by VMD, calculating the sample entropy of each modal component, selecting the modal components with high sample entropy and performing secondary decomposition by CEEMDAN, adding white noise and applying EMD for decomposition, and then removing the noise to obtain several refined modal components IMF.
3. The time series prediction method according to claim 2, characterized in that The VMD decomposition process is as follows: The objective function and constraints of the VMD algorithm are as follows: Where f(t) is the original signal; ω k is the center frequency of the kth modal component after decomposition; δ(t) is the Dirac function; * is the convolution operator. Secondly, by introducing the Lagrangian operator λ and the quadratic penalty factor α, we can get the augmented expression of the formula, using the following formula: Finally, the alternating direction method of the multiplication operator is used for secondary optimization. After optimization, the modal components and the center frequencies of the modal components are obtained using the following formula:
4. The time series prediction method according to claim 2, characterized in that The sample entropy is expressed using the following formula: The C m (r) is the matching degree, which is the similarity between all embedded vectors, using the following formula: Where θ(r) is a step function. When ||X i -X j It is 1 when ||≤r, otherwise it is 0.
5. The time series prediction method according to claim 1, wherein: In step S40, the process of using the Bayesian optimization algorithm to globally optimize the hyperparameters of the long short-term memory network model is as follows: S41: Based on the Bayesian optimization algorithm, the constructed long short-term memory network model is used to predict the decomposed time series data to obtain the predicted value of each series; S42: Randomly select hyperparameter combinations, train long short-term memory network models, evaluate their performance, and construct Gaussian process surrogate models; S43: Based on the known (initial combination of hyperparameters and the RMSE value corresponding to the initial combination of hyperparameters), a probability model is established to predict the value of the objective function at other unevaluated points; The goal is to estimate the performance of the objective function on different hyperparameter combinations by providing the posterior distribution of the objective function; S44: Use the defined expected improvement to select the next hyperparameter combination; S45: Bayesian optimization evaluates the next hyperparameter combination; after each evaluation, the new hyperparameter combination and its corresponding RMSE value are added to the dataset and the Gaussian process model is retrained; S46: Repeat steps S42-S45, select the most promising hyperparameter combination for evaluation, and determine the optimal hyperparameter combination.
6. The time series prediction method according to claim 5, characterized in that: In step S42, the Gaussian process proxy model uses the following formula: X0={x1,x2,···,x n },y0={f(x1),f(x2),···,f(x n )}; Among them, X0 is the initial combination of hyperparameters, and y0 is the corresponding RMSE value.
7. The time series prediction method according to claim 5, characterized in that: In step S43, the objective function adopts the following formula: f(x)~GP(m(x),k(x,x′)); Where f(x) is the objective function, m(x) is the value function (usually 0), and k(x, x′) is the kernel function used to measure the similarity between different hyperparameters.
8. The time series prediction method according to claim 5, characterized in that: In step S44, the next hyperparameter combination x is selected by defining the expected improvement. n+1 , using the following formula: EI(x)=E[max(0,f(x) + )-f(x))]; Among them, f(x + ) is the current optimal objective function value, f(x) is the predicted objective function value at the hyperparameter combination x, max(0,f(x + )-f(x)) is the improved value.
9. The time series prediction method according to claim 1, characterized in that: In step S40, the hyperparameters are the learning rate, the number of neurons in the hidden layer, and the number of samples.
10. Application of the time series forecasting method based on the VMD-CEEMDAN-BO-LSTM hybrid model according to any one of claims 1 to 9 in power load forecasting.