Photovoltaic power generation power prediction method based on VMD-ISSA-BiGRU
The BiGRU-Transformer model, optimized by variational mode decomposition and an improved sparrow search algorithm, solves the problem of insufficient long-term dependencies in photovoltaic power generation prediction, achieving higher prediction accuracy and dynamic adaptability, and improving the model's engineering applicability and generalization ability.
Patent Information
- Application Number
- CN202511657044.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-11-13
- Publication Date
- 2025-12-12
- Estimated Expiration
- 2045-11-13
AI Technical Summary
Existing photovoltaic power generation prediction models have limitations in handling long-term series dependencies. Traditional correlation coefficient methods have limited ability to mine high-dimensional nonlinear meteorological features, resulting in low prediction accuracy and poor dynamic processing capabilities.
We employ variational mode decomposition (VMD) to decompose photovoltaic power sequences, combine Pearson correlation coefficients to screen time-series features, and use an improved sparrow search algorithm (ISSA) to optimize the hyperparameters of the BiGRU-Transformer model. We construct a hybrid deep learning architecture to capture local and global dependencies, optimize the hyperparameters of the BiGRU-Transformer model through ISSA, and enhance the global search capability of the algorithm by combining Circle chaotic mapping, Levy flight, and Cauchy mutation strategies.
It significantly improves the accuracy and engineering applicability of photovoltaic power generation prediction, and can better model nonlinear dynamic changes under complex meteorological conditions, thereby improving the model's generalization ability and training efficiency.
Smart Images

Figure CN121124032A_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of new energy power generation, and particularly relates to a photovoltaic power generation power prediction method based on VMD-ISSA-BiGRU. BACKGROUND
[0002] With the rapid development of global new energy power, solar photovoltaic power generation has been widely used in power systems due to its safety, high efficiency and cleanliness. However, photovoltaic power generation has significant volatility, intermittency and instability, and is significantly affected by weather conditions, which brings serious challenges to the stable operation and power scheduling of the power grid. Therefore, improving the prediction accuracy of photovoltaic power generation power has become a key technical problem to ensure the safety of the power system and optimize energy deployment.
[0003] In the past few decades, photovoltaic power generation prediction research has made significant progress, especially with the development of artificial intelligence and optimization algorithms, data-driven prediction methods have gradually become mainstream. At present, a variety of models have been proposed and applied to photovoltaic power prediction. For example: Short-Term Photovoltaic Power Forecasting Based on VMD and ISSA-GRU in IEEE Open Access Journal of Power and Energy, 2021, 9: 105939-105950, this method reduces the non-stationarity of the original power sequence through VMD (Variational Mode Decomposition) decomposition, combines Pearson and Spearman correlation coefficients to screen meteorological factors, and uses ISSA (Improved Sparrow Search Algorithm) to optimize GRU (Gated Recurrent Unit) hyperparameters to improve prediction accuracy. However, this model has limitations in dealing with long time series dependencies, and the GRU structure is difficult to fully capture the long-term dynamic changes of photovoltaic power under complex weather conditions, and the traditional correlation coefficient method has limited ability to mine high-dimensional nonlinear meteorological features.
[0004] and A novel integrated photovoltaic power forecasting model based on variational mode decomposition and CNN-BiGRU considering meteorological variables, Electric Power Systems Research, 2022, 213, 108796, extracts deep features between meteorological factors and power through a convolutional neural network (CNN), and captures temporal dependencies before and after using a bidirectional gated recurrent unit (BiGRU). Although this model performs well in local feature extraction, its modeling ability for long-term dependencies is still insufficient, and it does not introduce an intelligent optimization algorithm for hyperparameter tuning, which can easily fall into local optima, affecting the model's generalization ability and prediction accuracy.
[0005] Therefore, we propose a prediction method that can improve prediction accuracy and engineering applicability. SUMMARY
[0006] The purpose of the present application is to provide a photovoltaic power prediction method based on VMD-ISSA-BiGRU, which solves the problems of low prediction accuracy and poor dynamic processing ability of traditional methods.
[0007] The present application is achieved by the following technical solutions: A photovoltaic power prediction method based on VMD-ISSA-BiGRU, specifically comprising: Obtain the photovoltaic power sequence and meteorological data sequence, divide the original data into training set, validation set and test set according to the ratio of 8:1:1, and preprocess the data; Perform variational mode decomposition on the photovoltaic power sequence to obtain 8 intrinsic mode components; Extract the time series features of each intrinsic mode component and meteorological data sequence, and use the Pearson correlation coefficient to analyze the correlation between each time series feature and the power output, and retain the time series features with an absolute value greater than 0.3; Optimize the hyperparameters of the BiGRU-Transformer model using ISSA; Based on the optimized hyperparameters and retained time series features, construct a BiGRU-Transformer model; Input the 8 intrinsic mode components into the BiGRU-Transformer model for calculation to obtain the prediction values of each component; Linearly reconstruct the prediction results of all components to obtain the photovoltaic power prediction sequence.
[0008] Furthermore, the process of optimizing the hyperparameters of the BiGRU-Transformer model using ISSA is as follows: S1. Set the ISSA algorithm parameters, determine the hyperparameters to be optimized and their search range, and define the fitness function; S2. Use Circle chaotic mapping to generate the initial sparrow population; S3. Set the current iteration number ; S4. For each individual in the population, construct a BiGRU-Transformer model using the hyperparameter combination it represents, and compute its fitness value on the validation set; S5. Sort the current population according to fitness values, assign the top 20% with the best fitness as discoverers, and the rest as followers. Then, according to the warning mechanism, randomly select 10% of the individuals in the population as scouts. S6. Update the positions of the discoverer, follower, and scout respectively, and check the positions of all newly generated individuals to ensure that they do not exceed the preset hyperparameter search range; S7. Compare the fitness values of all individuals. If there is an individual that is better than the current global optimum, then update the optimum and its corresponding optimum fitness. S8. Order ,like If the result is positive, return to S4; otherwise, terminate the iteration and output the global historical best position.
[0009] Furthermore, the initial sparrow population is generated using the Circle chaotic mapping, and the calculation formula is as follows:
[0010] In the formula, For the first The chaotic mapping value of the second time; This represents the number of iterations. , , For control coefficients; For finding the remainder function.
[0011] Furthermore, the location update mechanism for the discoverer is calculated using the following formula:
[0012] In the formula, For the first The discoverer's position in the next iteration; The total number of discoverers; A random number between 0 and 1; This represents the maximum number of iterations. Random numbers that satisfy a normal distribution; For all elements equal to 1 matrix; This is a warning value; This is the safety threshold.
[0013] Furthermore, a strategy of non-linear decreasing weights is introduced to optimize the location update mechanism of the discoverer. The specific formula is as follows:
[0014]
[0015] in, For the first The discoverer was in the first Position on the dimension To update the weights, This indicates the current iteration number.
[0016] Furthermore, the Levy flight strategy is used to optimize the location update mechanism of the discoverer. The specific formula is as follows:
[0017] in, This indicates the location of the discoverer after optimization using the Levy flight strategy. This indicates the discoverer's position after optimization using non-linear decreasing weights. This indicates the step size control parameter. This represents the current optimal solution. Indicates the search path, satisfying The Levy flight path was obtained using the Mantegna algorithm:
[0018] in, and It is a random variable that follows a normal distribution; For stability parameters; for Standard deviation; This is a gamma function.
[0019] Furthermore, the position update mechanism of the follower is calculated using the following formula:
[0020] In the formula, For the first The position of the follower in the next iteration. For the first The worst position of the follower in the next iteration; for the i-th iteration the optimal position of the follower in the i-th iteration is a matrix, and the matrix elements are randomly 1 or -1 is the total number of followers.
[0021] Further, the position updating mechanism of the follower is improved by using the Cauchy variation strategy, specifically:
[0022] wherein, is the new position of the follower in the d-th dimension is the optimal position of the follower in the i-th iteration is the global optimal position in the current iteration i is the standard Cauchy distribution function, specifically:
[0023] wherein, is the probability density function of the Cauchy distribution is a random variable.
[0024] Further, the position updating mechanism of the scout is calculated by the formula:
[0025] wherein, is the optimal position of the scout in the i-th iteration is a random number satisfying the normal distribution is the position of the follower at time step t is a random number between -1 and 1 is the current fitness value is the global best fitness is the worst fitness is a very small constant. Further, the eight intrinsic modal components are respectively input into the BiGRU-Transformer model for calculation to obtain the predicted values of each component, specifically including: the local dependence relationship of the time sequence characteristics in a certain intrinsic modal component is captured by the BiGRU part
[0026]
[0027] wherein, and respectively represent the hidden state of the BiGRU network at time step t and i respectively; represent a forward hidden state sequence, represent a reverse hidden state sequence; the processed results are input into the Transformer part; The global dependence relationship of the intrinsic modal component in the time sequence feature is captured by the Transformer part, and a prediction value is obtained.
[0028] The technical scheme of the application has at least the following advantages and beneficial effects: The application discloses a photovoltaic power prediction method based on VMD-ISSA-BiGRU, which combines variational modal decomposition with a BiGRU-Transformer hybrid model to construct a complete "decomposition-prediction-reconstruction" prediction framework; and the VMD effectively suppresses the non-stationarity and noise interference of the original photovoltaic power sequence; the BiGRU-Transformer model fully utilizes the synergistic advantages of BiGRU (Bidirectional Gated Recurrent Unit) in capturing local time sequence dependence and the Transformer (transformer model) in capturing global long-term dependence, so that the nonlinear dynamic changes of photovoltaic power under complex weather conditions can be more accurately modeled.
[0029] In addition, the ISSA is used to automatically optimize the hyperparameters of the BiGRU-Transformer model, overcoming the defects of strong subjectivity and easy falling into local optimum of traditional manual parameter adjustment, and through the improvement of Circle chaotic mapping initialization, nonlinear decreasing weight, Levy flight strategy and Cauchy mutation strategy, the global search ability, convergence speed and population diversity of the algorithm are significantly enhanced, so that the optimal hyperparameter combination can be adaptively found, the model performance is further improved, and the engineering adaptability of the method is improved.
[0030] In addition, by screening high correlation time sequence features through the Pearson correlation coefficient, the data dimension and the calculation complexity are effectively reduced, while the key influencing factors are retained, the model training efficiency and the generalization ability are improved. BRIEF DESCRIPTION OF DRAWINGS
[0031] Figure 1 A VMD-ISSA-BiGRU-based photovoltaic power prediction method flowchart of the application; Figure 2 A bidirectional GRU network structure diagram of the application; Figure 3 A random population distribution and Circle chaotic mapping distribution diagram of the application; Figure 4 A schematic diagram of the Levy flight for the present application. DETAILED DESCRIPTION
[0032] For the purposes of the present application, the technical solutions and advantages of the embodiments will be clearer, the technical solutions of the embodiments of the present application will be described clearly and completely below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, rather than all the embodiments. The components of the embodiments of the present application described and shown in the drawings herein can be arranged and designed in various different configurations.
[0033] Embodiment 1 As Figure 1 shown in a photovoltaic power prediction method based on VMD-ISSA-BiGRU, specifically comprising: Obtain the photovoltaic power sequence and the meteorological data sequence, divide the original data into a training set, a validation set and a test set according to the ratio of 8:1:1, and preprocess the data; Wherein the meteorological data sequence includes total irradiance, ambient temperature, time, wind speed and humidity, etc., and the preprocessing process is to fill in the missing values, remove the outliers and normalize the data.
[0034] The photovoltaic power sequence is decomposed by variational mode decomposition to obtain 8 intrinsic mode components; Wherein, the parameter setting of variational mode decomposition is: the number of decomposition layers , the penalty factor , the noise tolerance , and the direct current component ; and the purpose of variational mode decomposition is to suppress non-stationarity and noise interference.
[0035] Extract the time series features of each intrinsic mode component and the meteorological data sequence, respectively, and use the Pearson correlation coefficient to analyze the correlation between each time series feature and the power output, and retain the time series features with an absolute value of the correlation coefficient greater than 0.3; Wherein the time series features can be extracted by first-order difference before and after, sliding window mean (window size is 4), and time series lag (lag=3) and other methods.
[0036] The hyperparameters of the BiGRU-Transformer model are optimized by ISSA; Firstly, it effectively overcomes the defects of strong subjectivity and easy to fall into local optimum of traditional manual parameter adjustment, secondly, ISSA improves the global search ability, convergence speed and population diversity through Circle chaotic mapping initialization, nonlinear decreasing weight, Levy flight strategy and Cauchy mutation strategy, so as to adaptively find the optimal hyperparameter combination, further improve the model performance, and improve the engineering adaptability of the method.
[0037] Based on the optimized hyperparameters and the preserved temporal features, a BiGRU-Transformer model is constructed. This model is a hybrid deep learning architecture that deeply integrates bidirectional gated recurrent units (BiGRU) and Transformer encoders. It is specifically designed for the strong volatility, intermittency and nonlinear characteristics of photovoltaic power sequences that are highly dependent on meteorological factors. It can collaboratively capture local fine-grained temporal dependencies and global long-range feature associations in the sequence. The BiGRU-Transformer model comprises a BiGRU part and a Transformer part. BiGRU is an optimized structure for traditional recurrent neural networks (RNNs). Traditional RNNs struggle to effectively learn long-range dependencies when analyzing sequential data, while BiGRU alleviates this problem to some extent by introducing a gating mechanism to regulate information transmission. The GRU unit mainly includes two key structures: an update gate and a reset gate. The update gate controls the extent to which hidden state information from the previous time step is passed to the current state, used to capture long-term dependencies; the reset gate controls the influence of the previous state on the current candidate state, helping to capture short-term fluctuations or abrupt changes. In photovoltaic forecasting, BiGRU can effectively handle time-series inputs such as irradiance, temperature, wind speed, and historical power, capturing their dynamic characteristics over time. Therefore, BiGRU adopts a bidirectional architecture based on GRU, simultaneously capturing historical and future information through two independent GRU networks: a forward GRU and a backward GRU. The forward GRU processes the input sequence in chronological order, gradually accumulating historical information; the backward GRU processes the same sequence in reverse chronological order, pointing from "future" to "past," effectively supplementing the subsequent contextual dependencies that the forward network did not fully capture. Finally, the forward and backward hidden states at each time step are concatenated or weighted and fused to form a joint hidden state output containing more comprehensive temporal features. This structure is particularly suitable for photovoltaic power generation prediction because it can simultaneously model the past evolution and future trends of meteorological factors (such as cloud movement and gradual changes in illumination), improving the ability to perceive complex weather changes and patterns such as diurnal and seasonal cycles. In addition, a BiGRU network consisting of a two-layer GRU network, such as Figure 2 As shown, this model can capture bidirectional information from the past and future, providing richer feature representations for photovoltaic power generation prediction. The forward GRU processes the input sequence in a forward-looking manner, while the backward GRU processes the information in reverse order. The output of the entire network is ultimately generated from the forward and backward outputs, as described below:
[0038] In the formula, Represents the forward hidden state sequence, The model represents the reverse hidden state sequence. The input layer receives multi-dimensional temporal features, including historical power data from the photovoltaic power plant, real-time irradiance, ambient temperature, humidity, wind speed, wind direction, and meteorological parameters such as cloud cover. These parameters are standardized and input step-by-step. Each gating unit in the GRU hidden layer calculates the gating signal and candidate state based on the current input (e.g., irradiance and temperature at time t) and the previous hidden state. The bidirectional GRU further extracts higher-level temporal features through a two-layer structure: the first-layer GRU learns local time dependencies and instantaneous fluctuations, while the second layer captures longer-term periodic and trend patterns. Finally, the hidden state sequence output by the BiGRU (i.e., the concatenation of forward and reverse states) contains rich temporal dynamic features from the photovoltaic power generation data, such as short-term fluctuations, responses to sudden weather changes, solar radiation intensity changes, and equipment operating status, providing robust feature representations for the subsequent Transformer module.
[0039] The Transformer, a deep learning model proposed by Google in 2017, uses a self-attention mechanism at its core to generate representations of input and output, gradually replacing traditional convolutional neural networks (CNNs) and recurrent neural networks (RNNs). This mechanism can capture the dependencies between any two elements in a sequence and supports parallel processing of the entire sequence, thus significantly improving computational efficiency. The model employs an encoder-decoder architecture, mainly including input embedding, output embedding, positional encoding, a multi-head self-attention module, and a feedforward neural network.
[0040] In photovoltaic (PV) power prediction, the Transformer model first maps input data, including PV power sequences, meteorological observation data, and temporal features, into high-dimensional vectors through an input embedding layer, and introduces positional encoding to preserve temporal sequence information. Utilizing a multi-head self-attention mechanism in the encoder, it computes the global correlations between features at different time steps in parallel, identifying the potential impact of key meteorological events such as persistent cloudy weather and sudden gusts on power generation, and outputting a high-dimensional feature representation that integrates global contextual information. The decoder then generates future power prediction sequences based on the encoded features, using either autoregressive or non-autoregressive methods. Finally, the prediction result is obtained through a linear output layer. This structure not only simultaneously models the complex interaction between historical power data and future meteorological conditions but also possesses stronger temporal feature extraction capabilities and higher computational efficiency, making it suitable for accurate prediction of highly volatile PV power generation.
[0041] BiGRU combined with Transformer can give full play to the advantages of both. Transformer is good at capturing global dependencies, while BiGRU can better handle local dependencies. This combination can more effectively model and predict photovoltaic power sequence data.
[0042] In addition, adaptive temporal embedding can be introduced into the BiGRU-Transformer model to encode the original photovoltaic power data at different time scales (such as daily cycles, seasonal cycles, etc.), further improving the model's ability to represent photovoltaic power time series patterns. The time feature vector The description is as follows:
[0043] In the formula is a normalized time offset; is a daily cycle regularity encoding; is a monthly cycle regularity encoding; is a yearly cycle regularity encoding; In addition, in view of the strong volatility, intermittency and high dependence on meteorological factors of photovoltaic power sequence, the project introduces a meteorological attention module. This module explicitly models the nonlinear relationship between meteorological factors and photovoltaic power output by weighting and fusing meteorological factors, where the attention weight of each meteorological factor is calculated by a gating network from photovoltaic power sequence data, and the specific calculation process is as follows:
[0044] In the formula, represents the hidden state of the historical photovoltaic power sequence after BiGRU encoding at the current time step , which contains the time series features of historical power generation; represents the original meteorological data vector at the current time step , usually including temperature, irradiance, humidity, wind speed, cloud cover and other meteorological factors; represents the vector concatenation operation, which fuses power features and meteorological features into joint representation; is the weight and bias of the first layer linear transformation, is the activation function (such as ReLU); is the weight and bias of the second layer linear transformation; is the Sigmoid activation function, which compresses the output to the [0, 1] interval, representing the importance weight of each meteorological factor; is the final generated weather attention weight vector, whose dimension is consistent with the weather data , and each element corresponds to the weight of a weather factor. Finally, the weighted weather representation is obtained by element-wise multiplication of the original weather data and the attention weight:
[0045] where is the original weather data (such as temperature, cloud cover, etc.).
[0046] Finally, the IMF component features, the weighted weather representation , and the time feature vector are concatenated to form an enhanced input feature to be fed into the Transformer encoder. This design allows the model to adaptively adjust the attention degree to each weather factor according to the current power generation state, significantly improving the prediction robustness under complex weather conditions. In addition, the time embedding explicitly provides multi-scale periodic information such as day, month, and year, enabling the model to fully utilize the time series regularity of photovoltaic power generation and improve the prediction accuracy of periodic fluctuations.
[0047] According to the needs, the BiGRU-Transformer model parameters optimized by ISSA are as follows: BiGRU layer: number of layers: 2 layers, number of hidden units per layer: 128, output feature dimension: 256 (after concatenation of both directions).
[0048] Transformer encoder: number of layers: 2 layers, number of attention heads (Head): 8, feed-forward network dimension (Feed-Forward Dimension): 512.
[0049] Output layer: fully connected layer (Linear activation), output dimension is 1 (power prediction value).
[0050] Training parameters: optimizer: Adam, learning rate (lr): 0.001, momentum parameters: , , batch size: 64, number of training rounds (Epochs): 200.
[0051] Early stopping method: monitor the validation set loss, if it does not decrease for 15 consecutive rounds, terminate the training to prevent overfitting.
[0052] Loss function: mean squared error (MSE) for gradient backpropagation.
[0053] The eight intrinsic modal components are respectively input into the BiGRU-Transformer model for calculation to obtain the predicted values of each component, and the specific process is as follows: The BiGRU part captures the local dependence relationship of the time sequence characteristics in a certain intrinsic modal component, and the specific calculation formula is as follows:
[0054] In the formula, and respectively represent the hidden states of the BiGRU network at time steps t and i, which contain the sequence information learned by the network up to the current time step. represents the forward hidden state sequence, represents the reverse hidden state sequence; The processed results are input into the Transformer part. The Transformer part captures the global dependence relationship of the time sequence characteristics in the intrinsic modal component to obtain the predicted value.
[0055] The predicted results of all components are linearly reconstructed to obtain the photovoltaic power prediction sequence.
[0056] Embodiment 2 As an embodiment, since the photovoltaic power sequence has significant volatility, intermittency and nonlinearity, and is highly dependent on meteorological factors such as irradiance, temperature and humidity, the traditional parameter optimization method is difficult to adapt to its complex time-varying characteristics and is prone to fall into local optimum. The sparrow search algorithm (SSA) is a group optimization algorithm that simulates the foraging behavior of sparrows, and achieves global optimization through the cooperation and competition mechanism of three types of individuals: discoverers, followers and scouts. Therefore, on the basis of the traditional SSA (Sparrow Search Algorithm), a number of improvement strategies are introduced, namely ISSA (Improved Sparrow Search Algorithm), which is more suitable for photovoltaic power prediction scenarios.
[0057] In photovoltaic power prediction, ISSA is used to optimize the hyperparameters of the BiGRU-Transformer model, such as the number of network layers, the number of hidden units, the learning rate, the number of attention heads, etc., to improve the prediction accuracy and generalization ability. In ISSA, the position of an individual in the sparrow population represents a combination of hyperparameters to be optimized. The sparrow population includes: discoverers represent the current optimal hyperparameter configuration and are responsible for guiding the population to search for better areas; followers represent suboptimal configurations and further optimize them by learning and following the discoverers; scouts are responsible for jumping out of local optimum to avoid premature convergence.
[0058] In addition, the ISSA is used to optimize the hyperparameters of the BiGRU-Transformer model, and the specific process is as follows: S1. Set ISSA algorithm parameters, determine the hyperparameters to be optimized and their search range, and define the fitness function; S2. Generate initial sparrow population using Circle chaotic mapping; S3. Set the current iteration number ; S4. For each individual in the population, use the hyperparameter combination it represents to build a BiGRU-Transformer model and calculate its fitness value on the validation set; S5. Sort the current population according to the fitness value, divide the top 20% with the best fitness as discoverers, the remaining as followers, and randomly select 10% of the individuals from the population as scouts according to the alarm mechanism; S6. Update the positions of discoverers, followers, and scouts respectively, and check the positions of all newly generated individuals to ensure they do not exceed the preset hyperparameter search range; S7. Compare the fitness values of all individuals, if there is an individual better than the current global optimal solution, update the optimal solution and its corresponding optimal fitness; Where the fitness function is the prediction error of the BiGRU-Transformer model on the validation set, so the optimization goal is to minimize the mean square error (MSE) on the validation set, and the hyperparameters to be optimized include: BiGRU layer number [1, 2, 3], BiGRU hidden unit number [64, 128, 256], Transformer encoder layer number [1, 2], attention head number [4, 8, 16], feedforward network dimension [256, 512, 1024], and learning rate [0.0001, 0.001, 0.01]; S8. Let If , return to S4; if not, terminate the iteration and output the global historical optimal position.
[0059] In addition, since the sparrow search algorithm uses random generation method in population initialization stage, it is easy to produce uneven and single initial population distribution, which reduces the optimization efficiency of the algorithm. Therefore, by introducing Circle chaotic sequence for population initialization, the sparrow search algorithm can make the initial population distribution more uniform, ensure the optimization result ergodicity, and improve the early convergence speed of the algorithm. The specific calculation formula is:
[0060] In the formula, is the chaotic mapping value of the th time; is the iteration number; , , is the control coefficient; As the modulo function is used, it can be seen that adding the Circle chaotic map can enhance the diversity of the SSA population (i.e., the breadth of hyperparameter combinations, avoiding getting trapped in local optima) and improve the global solution capability of the SSA algorithm. A comparison of the random population distribution and the Circle chaotic map distribution is shown below. Figure 3 As shown in the figure, (a) is the random population distribution and (b) is the Circle chaotic mapping distribution. Compared with the random mapping distribution, adding the Circle chaotic mapping can distribute the SSA population more evenly, making the distribution of individuals in the population more uniform, avoiding local clustering, and reducing the possibility of SSA getting trapped in local optima.
[0061] The location update mechanism for the discoverer, as needed, is calculated using the following formula:
[0062] In the formula, For the first The discoverer's position in the next iteration; The total number of discoverers; A random number between 0 and 1; This represents the maximum number of iterations. Random numbers that satisfy a normal distribution are used to introduce random perturbations; For all elements equal to 1 Matrix is used for dimension alignment; This is a warning value used to simulate environmental risks (i.e., increased prediction errors caused by factors such as sudden weather changes). The safety threshold represents the level of environmental safety (i.e., the prediction error is within an acceptable range).
[0063] Furthermore, since the position update of the discoverer often uses a fixed weight during the iteration process of SSA, this may cause the algorithm to converge prematurely to a local optimum rather than a global optimum. Therefore, to overcome this defect, a non-linear decreasing weight strategy is introduced to optimize the position update mechanism of the discoverer, enabling it to search the solution space more broadly and avoid falling into the trap of local optima. The specific formula is as follows:
[0064]
[0065] in, For the first The discoverer was in the first Position on the dimension To update the weights, represents the current iteration number, and the weight gradually decreases nonlinearly as the iteration number increases, that is, in the later search stage, the explorer gradually narrows down the search range and turns to a more fine local search, so as to accurately locate the global optimal solution; In addition, although the introduction of the nonlinearly decreasing weight strategy in the position updating formula can improve the convergence effect, the algorithm may still fall into a local optimum when dealing with high-dimensional complex problems. Therefore, the global search ability of the explorer can be effectively improved by combining the Levy flight which has the characteristics of long-distance jumping and short-distance fine search, so as to integrate the Levy flight term, which can make the explorer perform a large range of jumping (i.e. moving greatly in the solution space and exploring a wider area) with a certain probability, thereby jumping out of the local optimal region and improving the randomness and diversity of the solution. Therefore, the Levy flight strategy is adopted to optimize the position updating mechanism of the explorer, and the specific formula is:
[0066] wherein, represents the position of the explorer after optimization by the Levy flight strategy, represents the position of the explorer after optimization by the nonlinearly decreasing weight, that is, , represents a step control parameter, , represents the current optimal solution, represents a search path, satisfying The Levy flight path obtained by the Mantegna algorithm is:
[0067] wherein, is a random step length of the Levy flight, and are random variables obeying a normal distribution, which are used to generate the Levy flight path by the Mantegna algorithm; is a normal distribution function, is a stability parameter related to the characteristic index of the Levy distribution, and is usually taken as a value in the range of (0, 2] for controlling the shape of the Levy distribution; is a standard deviation of ; is a gamma function; The combination of the Levy flight mechanism and the nonlinearly decreasing weight enables the algorithm to generate high-quality solutions during the solving process, greatly enhancing the search ability of the algorithm. The Levy flight schematic diagram is shown in Figure 4 .
[0068] According to needs, the position updating mechanism of the follower has a calculation formula:
[0069] In the formula, For the first The position of the follower in the next iteration. For the first The worst position of the follower in the next iteration; For the first The optimal position of the follower in the next iteration; for A matrix, where the matrix elements are randomly set to 1 or -1; The total number of followers.
[0070] In addition, the position update mechanism of the follower is improved by adopting the Cauchy mutation strategy, specifically as follows:
[0071] in, For followers In the The new position on the dimension represents the updated position of the follower individual after the Cauchy mutation. The current iteration number The global optimal position represents the best hyperparameter combination found so far; and The standard Cauchy distribution function is as follows:
[0072] in, Let be the probability density function of the Cauchy distribution; The variable is a random variable; the Cauchy distribution is introduced to generate the variant, which enhances the diversity and global exploration capability of the algorithm, thus allowing the algorithm to flexibly switch between fine-grained search in a small range and large-scale leap exploration.
[0073] The location update mechanism for the scouts, as needed, is calculated using the following formula:
[0074] In the formula, For the first The scout's optimal position in the next iteration; Random numbers that satisfy a normal distribution; For followers At time step Location; A random number between -1 and 1; This is the current fitness value; For the best global fitness; The worst fitness; A very small positive number introduced to prevent division by zero errors in mathematical calculations.
[0075] In summary, due to the strong volatility, intermittency and significant meteorological dependence of photovoltaic output, traditional models often rely on manual parameter tuning and are difficult to adapt to complex and variable meteorological-power mapping relationships. The ISSA optimization mechanism has strong global search ability and adaptive adjustment mechanism, which can dynamically adjust hyperparameters according to different meteorological conditions (such as seasonal changes, irradiance fluctuations, etc.), better adapt to the nonlinear and time-varying characteristics of photovoltaic power generation, and adaptively search for the most suitable hyperparameter combination for local climate and seasonal characteristics, thereby improving the prediction robustness of the model under different climate backgrounds.
[0076] In addition, the ISSA parameter settings are as follows: sparrow population size 50, maximum iteration number 100, warning value ST=0.8, discoverer ratio PD=20%, and scout ratio SD=10%. The algorithm simulates the foraging behavior of sparrows and divides individuals into three categories: discoverers, followers, and scouts. In photovoltaic power prediction, discoverers are responsible for global exploration in a wide parameter space, and their position updates introduce a nonlinear decreasing weight, allowing the algorithm to extensively explore in the early iterations and finely tune in the later iterations to adapt to the non-stationary changes of photovoltaic data. Followers enhance local search diversity through Cauchy mutation strategies, improving the response capability to short-term meteorological disturbances such as irradiance mutations. Scouts jump out of local optima in time according to the warning mechanism to avoid premature convergence to suboptimal solutions.
[0077] Example 3 As an embodiment, for the photovoltaic power prediction sequence output by the BiGRU-Transformer model, a secondary verification can be performed, specifically: Calculate the following evaluation indicators on the test set: root mean square error (RMSE), mean absolute error (MAE), and coefficient of determination (R²); Then compare the performance of the model with traditional prediction models (LSTM, SVR, ARIMA); If the model reduces by more than 10% in RMSE and MAE, and R² reaches more than 0.98, then the photovoltaic power prediction sequence is the final prediction result; If not, re-optimize the hyperparameters of the BiGRU-Transformer model using ISSA and perform prediction; Output the final prediction result and performance indicators, and draw the comparison curve of true value and predicted value, residual distribution graph, and error histogram to visually display the prediction effect of the model.
[0078] The above merely describes the preferred embodiments of the present application, and is not used to limit the present application. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present application shall be included in the protection scope of the present application.
Claims
1. A photovoltaic power generation prediction method based on VMD-ISSA-BiGRU, characterized in that, Specifically, it includes: Acquire photovoltaic power sequences and meteorological data sequences, divide the raw data into training set, validation set and test set in a ratio of 8:1:1, and preprocess the data; Variational mode decomposition was performed on the photovoltaic power sequence to obtain eight intrinsic mode components; For each intrinsic mode component and meteorological data sequence, time series features are extracted, and Pearson correlation coefficient is used to analyze the correlation between each time series feature and power output, retaining time series features with an absolute value of correlation coefficient greater than 0.3; The hyperparameters of the BiGRU-Transformer model were optimized using ISSA. Based on the optimized hyperparameters and the preserved temporal features, a BiGRU-Transformer model is constructed. The eight intrinsic mode components are input into the BiGRU-Transformer model for calculation to obtain the predicted values of each component. The prediction results of all components are linearly reconstructed to obtain the photovoltaic power prediction sequence.
2. The photovoltaic power generation prediction method based on VMD-ISSA-BiGRU according to claim 1, characterized in that: The process of optimizing the hyperparameters of the BiGRU-Transformer model using ISSA is as follows: S1. Set the ISSA algorithm parameters, determine the hyperparameters to be optimized and their search range, and define the fitness function; S2. Use Circle chaotic mapping to generate the initial sparrow population; S3. Set the current iteration number ; S4. For each individual in the population, construct a BiGRU-Transformer model using the hyperparameter combination it represents, and compute its fitness value on the validation set; S5. Sort the current population according to fitness values, assign the top 20% with the best fitness as discoverers, and the rest as followers. Then, according to the warning mechanism, randomly select 10% of the individuals in the population as scouts. S6. Update the positions of the discoverer, follower, and scout respectively, and check the positions of all newly generated individuals to ensure that they do not exceed the preset hyperparameter search range; S7. Compare the fitness values of all individuals. If there is an individual that is better than the current global optimum, then update the optimum and its corresponding optimum fitness. S8. Order ,like If the result is positive, return to S4; otherwise, terminate the iteration and output the global historical best position.
3. The photovoltaic power generation prediction method based on VMD-ISSA-BiGRU according to claim 2, characterized in that: The initial sparrow population is generated using Circle chaotic mapping, and the calculation formula is as follows: In the formula, For the first The chaotic mapping value of the second time; This represents the number of iterations. , , For control coefficients; For finding the remainder function.
4. The photovoltaic power generation prediction method based on VMD-ISSA-BiGRU according to claim 2, characterized in that: The location update mechanism for the discoverer is calculated using the following formula: In the formula, For the first The discoverer's position in the next iteration; The total number of discoverers, It is an exponential function; A random number between 0 and 1; This represents the maximum number of iterations. Random numbers that satisfy a normal distribution; For all elements equal to 1 matrix; This is a warning value; This is the safety threshold.
5. The photovoltaic power generation prediction method based on VMD-ISSA-BiGRU according to claim 4, characterized in that: A strategy of introducing non-linear decreasing weights is used to optimize the discoverer's position update mechanism. The specific formula is as follows: in, For the first The discoverer was in the first Position on the dimension To update the weights, This indicates the current iteration number.
6. The photovoltaic power generation prediction method based on VMD-ISSA-BiGRU according to claim 5, characterized in that: The Levy flight strategy is used to optimize the location update mechanism for the discoverer. The specific formula is as follows: in, This indicates the location of the discoverer after optimization using the Levy flight strategy. This indicates the discoverer's position after optimization using non-linear decreasing weights. This indicates the step size control parameter. This represents the current optimal solution. Indicates the search path, satisfying The Levy flight path was obtained using the Mantegna algorithm: in, Let be the random step size of Levy's flight. and It is a random variable that follows a normal distribution. It is a normal distribution function. For stability parameters; for Standard deviation; This is a gamma function.
7. The photovoltaic power generation prediction method based on VMD-ISSA-BiGRU according to claim 4, characterized in that: The position update mechanism for the followers is calculated using the following formula: In the formula, For the first The position of the follower in the next iteration. For the first The worst position of the follower in the next iteration; For the first The optimal position of the follower in the next iteration; for A matrix, where the matrix elements are randomly set to 1 or -1; The total number of followers.
8. The photovoltaic power generation prediction method based on VMD-ISSA-BiGRU according to claim 7, characterized in that: The position update mechanism of the follower is improved by adopting the Cauchy mutation strategy, specifically as follows: in, For followers In the The new position on the dimensional, The current iteration number The global optimal position; and The standard Cauchy distribution function is as follows: in, Let be the probability density function of the Cauchy distribution; It is a random variable.
9. The photovoltaic power generation prediction method based on VMD-ISSA-BiGRU according to claim 7, characterized in that: The location update mechanism for the scout is calculated using the following formula: In the formula, For the first The scout's optimal position in the next iteration; Random numbers that satisfy a normal distribution; For followers At time step Location; A random number between -1 and 1; This is the current fitness value; For the best global fitness; The worst fitness; It is a very small constant.
10. The photovoltaic power generation prediction method based on VMD-ISSA-BiGRU according to claim 1, characterized in that: The step of inputting the eight intrinsic mode components into the BiGRU-Transformer model for calculation to obtain the predicted value of each component specifically includes: The BiGRU part captures the local dependencies of temporal features in a certain intrinsic mode component; In the formula, and These represent the time steps of the BiGRU network. and The hidden state; Represents the forward hidden state sequence, Represents the reverse hidden state sequence; Input the processed result into the Transformer section; The Transformer part captures the global dependencies of temporal features in the intrinsic modal components to obtain the predicted values.
Citation Information
Patent Citations
Combined load prediction method fusing sequence decomposition and feature selection
CN115498627A
Photovoltaic power generation power prediction method and system based on neural network
CN117117859A
Ultra-short-term photovoltaic power prediction method based on improved whale optimization algorithm
CN117318036A
Short-term photovoltaic power prediction method based on VMD-BiGRU-AE model
CN117933751A
Short-term photovoltaic power prediction method based on optimized decomposition and combined neural network
CN120566410A
Cited By
Spatial-temporal feature fusion ultra-short-term photovoltaic power generation prediction method and device, related equipment and medium
CN121863371A
A photovoltaic power prediction method and system based on multi-strategy optimization MVMD
CN122365424A