CN-122020609-A - TimeGAN-based photovoltaic power prediction method under consideration of turning weather
Abstract
The invention belongs to the field of photovoltaic power prediction, and discloses a TimeGAN-based photovoltaic power prediction method under turning weather, which is characterized in that a reconstruction error is utilized to detect abnormal values, missing data is filled through a weather similarity weighted bidirectional K nearest neighbor algorithm, high-correlation weather characteristics are selected, a turning weather data set is expanded through a time sequence generation countermeasure network according to the condition that a turning weather sample is insufficient, a photovoltaic output characteristic sequence is output through a CEEMDAN-VMD double decomposition algorithm, and the photovoltaic output prediction is carried out by inputting the photovoltaic output characteristic sequence and the high-correlation weather characteristic sequence into an SSA-LSSVM model together. According to the invention, the photovoltaic output and meteorological characteristic sequences are fully extracted through correlation analysis and double decomposition, the prediction model is input in a combined way, parameter selection is optimized, the influence of meteorological driving force on system uncertainty in the turning weather is enhanced, and the accuracy and stability of photovoltaic output prediction in the turning weather are improved.
Inventors
- ZHOU XIA
- ZHANG XIZE
- ZHANG TENGFEI
- DAI JIANFENG
Assignees
- 南京邮电大学
Dates
- Publication Date
- 20260512
- Application Date
- 20260205
Claims (7)
- 1. A method for TimeGAN-based photovoltaic power prediction under consideration of turning weather, comprising the steps of: s1, preprocessing data of original photovoltaic output and meteorological data, detecting an abnormal value by using a reconstruction error, and filling missing data by a bidirectional K nearest neighbor algorithm weighted by meteorological similarity; S2, analyzing the correlation between each meteorological factor and the historical photovoltaic output data by a Pelson correlation coefficient method based on the preprocessed data, and screening high-correlation meteorological features; S3, generating turning weather data which is matched with the photovoltaic Time sequence characteristic through Time sequence generation countermeasure network Time-GAN, and expanding a turning weather data set; s4, based on the expanded data set, performing double decomposition on the historical original photovoltaic output sequence by using a K-means clustering algorithm combining complementary set empirical mode decomposition and variation mode decomposition, and extracting a photovoltaic output characteristic mode sequence; s5, constructing an SSA-LSSVM combined prediction model, combining high-correlation weather features, constructing a double-layer feature sequence of a weather feature sequence and a photovoltaic output feature mode sequence, inputting the double-layer feature sequence into the combined prediction model, and outputting a photovoltaic output prediction result.
- 2. The method for predicting photovoltaic power based on TimeGAN under consideration of turning weather according to claim 1, wherein in S1, based on the difference between normal data and abnormal data in distribution characteristics, the abnormal value is detected by using reconstruction error: , wherein s (x) is a reconstruction error, x is an original sample, Reconstruction data output from the encoder; abnormality determination principle: , and when the reconstruction error of a certain sample is greater than the 95% quantile of the reconstruction error of the data set, judging that the error is abnormal.
- 3. The method for predicting photovoltaic power based on TimeGAN under consideration of turning weather according to claim 1, wherein in S1, missing data is filled by a weather similarity weighted bidirectional K nearest neighbor algorithm, and the formula is calculated: , , Wherein K is a neighborhood radius, w i is a weather similarity weight of a moment i and a missing moment m, F i is a weather feature vector of the ith moment, F m is a weather feature vector of the current moment to be filled, sigma is a bandwidth parameter, x m is a missing value to be filled, and x i is a photovoltaic output value at the moment i.
- 4. The method for predicting photovoltaic power based on TimeGAN under consideration of turning weather according to claim 1, wherein S2 is specifically: S21, measuring the correlation and the degree of correlation between different characteristic variables and the photovoltaic output through the Pearson correlation coefficient, wherein the calculation formula is as follows: , wherein: And Values representing two variables, respectively; And Respectively representing sample average values of two variables; And Respectively represent And N represents the number of samples.
- 5. The method for predicting photovoltaic power based on TimeGAN under consideration of turning weather according to claim 1, wherein S3 specifically is: s31, defining S, X as the vector space of the static and dynamic characteristics respectively, the distribution is that The distribution obtained by training the real data set is that The global optimization target and the local optimization target for constructing the Time-GAN are respectively as follows: , , wherein: a feature vector space representing from time t=1 to t=t; Representing the dynamic characteristics at the time t-1; S32, realizing an embedded function e through a cyclic neural network, and converting the high-dimensional characteristics into a latent code with lower dimension: , The recovery function r is a feedforward neural network, and the latent codes are recovered to dynamic and static characteristics in the original dimension: , the expression of the dimension reduction and dimension increase process is as follows: , In the formula, Respectively represent static and dynamic characteristic vectors, Is a low-dimensional feature vector; s33, based on a global optimization target and a local optimization target, simultaneously learning the distribution characteristics and time dynamics of the time sequence through countermeasure training and supervised learning, wherein the training targets are as follows: aiming at the global optimization target, performing countermeasure training in a potential space: , , Wherein, theta e 、θ r 、θ g 、θ d represents embedding, recovering, generating and judging network parameters, L s represents supervision loss, L U represents countermeasures loss, L R represents reconstruction loss, and lambda and eta are balance super parameters; aiming at a local optimization target, introducing supervision loss constraint timing consistency: , wherein the formula is: is the true value at the time t, The predicted value is used for the time t, Indicating that the numerical desire is taken.
- 6. The method for predicting the photovoltaic power based on TimeGAN under consideration of turning weather according to claim 1, wherein the step S4 is based on an extended dataset, and performs double decomposition on a historical original photovoltaic output sequence by combining complementary set empirical mode decomposition and variation mode decomposition with a K-means clustering algorithm, and extracts a photovoltaic output characteristic mode sequence, and comprises the following steps: S41, CEEMDAN, using the original power curve P (t) +epsilon 0 ω j (t), M experiments were performed in the first phase, i.e. k=1, where ω j (t) is gaussian white noise in conformity with normal distribution, j=1, 2, M, epsilon 0 is gaussian white noise amplitude constant, and the 1 st eigenmode function I j,1 is obtained by decomposing it by EMD, and one component obtained by CEEMDAN is the average of all I j,1 , i.e.: , In stage 1, the residual sequence r 1 (t) of the 1 st time is calculated: , Performing M times of EMD decomposition on the sequence r 1 (t)+ε 1 E 1 (ω j (t)) by adaptively adding noise until the 1 st IMF is obtained, wherein epsilon 1 is a Gaussian white noise adaptive coefficient added after the 1 st stage, E 1 (∙) is the 1 st component obtained by EMD, and at the moment, calculating the 2 nd component I 2 of CEEMDAN; , For each of the remaining phases k, S23 is repeated and the k+1 modal component is calculated as follows: , , Wherein r k (t) is the residual sequence of the kth time, epsilon k is the adaptive coefficient corresponding to Gaussian white noise added after the kth stage, E k ([ delta ]) is the kth component obtained by EMD; Until the obtained residual signal does not execute any IMF any more, and the standard condition is that the IMF cannot be extracted from the residual, the number of polar points is not more than 2; the final residual signal is: , Wherein K is the total number of modal components; Thus, the original power P (t) is finally decomposed into CEEMDAN: , s42, calculating analysis signals related to a modal function u k (t) obtained by VMD decomposition by utilizing Hilbert transformation to obtain a single-side frequency spectrum; First, hilbert transform is applied to the model function u k (t), and an analytic signal is obtained: , In the formula, Is the Hilbert transform of u k (t); fourier transforming z k (t) to obtain a frequency representation thereof: , Wherein F represents Fourier transform, and ω is angular frequency; Since the analytic signal z k (t) contains only positive frequency components, the fourier transform z k (ω) thereof is also unilateral, and therefore, a unilateral spectrum can be directly extracted from z k (ω), which is generally represented as a magnitude spectrum |z k (ω); Demodulating the signals through Gaussian smoothing, and calculating the bandwidth of each u k (t) to obtain corresponding constraint variation problems; Gaussian function definition: , wherein sigma is the standard deviation of a Gaussian function, and the degree of smoothing is controlled; the signal u k (t) is gaussian smoothed: , Wherein ∗ denotes a convolution operation; For smoothed signals) The bandwidth can be estimated by calculating its fourier transform: , bandwidth constraint problem: , where B 0 is the given upper bandwidth limit; converting the constraint problem to an unconstrained problem using a quadratic penalty and a Lagrangian multiplier: , Wherein { u k }、{ω k } is the set of all mode functions and the center frequency thereof, lambda is Lagrange multiplier, alpha is a secondary penalty factor, delta (t) is a Dirac function, j is an imaginary part; and finally, obtaining a final modal function and center frequency through iterative updating.
- 7. The method for TimeGAN-based photovoltaic power prediction under consideration of turning weather according to claim 1, wherein in S5, the SSA-LSSVM combined prediction model includes: 1) The double-layer feature construction layer is used for constructing a double-layer feature sequence of a meteorological feature sequence and a photovoltaic output feature mode sequence as a training sample set: , Wherein x d is a high-correlation meteorological feature vector, y d is a photovoltaic output feature sequence, and z d is a dual-channel combined input sequence; 2) And the dual-channel nuclear mapping layer is used for mapping an input sample from an original space to a high-dimensional characteristic space by adopting a dual-channel mixed nuclear function and outputting a fused nuclear matrix: , , , Wherein K m is a meteorological channel sub-core, K y is a power inertia channel sub-core, K R is a core function for capturing nonlinearity of meteorological factors, K P is a core function for retaining linear trend between meteorological and power, h is a hysteresis channel bandwidth, For reference to the hysteresis power vector, K fus is the fusion core, As a result of the mixing coefficient, The weight is a double-channel fusion weight; 3) And the optimal decision function output layer is used for constructing an optimal decision function to fit the sample set by utilizing a nonlinear high-dimensional feature space, converting the regression problem into a secondary optimization problem by utilizing a structure minimization theory, and solving parameters of the optimal decision function: , wherein J (w, e) is an optimization target, w is a weight vector, w T is a transpose of the weight vector, b is a bias term, e is an error vector, A is the total number of training samples, e a is a fitting error of an a-th sample, C is a penalty parameter, y a is a true value of the a-th sample, Referring to the nonlinear mapping function, z a is the input feature of sample a; Inputting a nuclear matrix output by a dual-channel nuclear mapping layer established by K fus , training a real photovoltaic output value of a sample, punishment parameters and the total number of the training samples, outputting Lagrange multipliers and optimal bias items, constructing a final optimal decision function based on the Lagrange multipliers and the optimal bias items, and outputting a photovoltaic output predicted value: , wherein y new is a predicted value, For the lagrangian multiplier, z new is the characteristic of the new sample to be predicted, As a meteorological feature of the a-th training sample, As a meteorological feature of the sample to be predicted, The photovoltaic output characteristics of the a-th training sample, The photovoltaic output characteristics of the sample to be predicted are obtained; the Lagrangian multiplier obtained after the Lagrangian solution and the double-channel kernel function are weighted and summed at one time to obtain a final photovoltaic output predicted value; 4) In the LSSVM prediction process, the LSSVM is optimized through SSA to quickly find out the optimal parameters 、 And C, and reduce photovoltaic power prediction errors.
Description
TimeGAN-based photovoltaic power prediction method under consideration of turning weather Technical Field The invention belongs to the field of photovoltaic power prediction, and particularly relates to a TimeGAN-based photovoltaic power prediction method under consideration of turning weather. Background In order to respond to the 'double-carbon' target, the global installed capacity of the photovoltaic power generation continuously increases at a high speed, however, the photovoltaic power generation power is influenced by strong coupling of weather factors such as solar irradiance, temperature, wind speed, cloud cover and the like, and the photovoltaic power generation power has extremely strong randomness, volatility and nonlinear characteristics, particularly, in turning weather (such as sudden weather changes of strong wind, low temperature, strong convection and the like), the photovoltaic power output is easy to generate cliff type fluctuation or sudden change, the power balance and the scheduling safety of a power system are seriously influenced, and irreversible damage to a photovoltaic module and grid-connected equipment is possibly caused. The accurate photovoltaic power prediction is a core technical support for guaranteeing safe and stable operation of the power grid and reducing the light rejection rate after high-proportion photovoltaic grid connection, can be classified into ultra-short term prediction, short term prediction and medium-long term prediction according to a prediction time domain, and can be classified into a physical model, a statistical model, an artificial intelligent model and a mixed model according to a technical route. In recent years, deep learning technology has become a mainstream technology direction of photovoltaic power prediction by virtue of its strong time sequence modeling capability, and models such as long and short term memory network (LSTM), artificial Neural Network (ANN), least Square Support Vector Machine (LSSVM) and the like are widely used. The prior art still faces related problems that firstly, turning weather has burstiness and contingency, so that a history sample of the scene is extremely scarce, a newly built photovoltaic station is particularly prominent, uneven distribution of model training data and insufficient generalization capability are directly caused, extreme scene prediction accuracy is greatly reduced, secondly, complex nonlinear association exists between photovoltaic data and meteorological variables, influence mechanism differences are obvious in different seasons and different weather types, key driving factors are difficult to accurately capture by a traditional feature screening method, the complexity of the model is increased and the prediction stability is reduced by redundant variables, thirdly, the non-stationarity of a photovoltaic output sequence is strong, deep time sequence features of the model are difficult to fully extract by a single data decomposition or a single prediction model, and particularly, the model is difficult to adapt to the rapid fluctuation characteristic of output in the case of weather mutation. In addition, the existing expansion method aiming at the problem of small samples is mostly dependent on a traditional generation countermeasure network (GAN), so that the time sequence dependency relationship between the photovoltaic power and the meteorological data is difficult to accurately capture, the generated data is easy to collapse or distort in a mode, in the data preprocessing link, the abnormal value detection and the missing value filling are mostly adopting a fixed threshold value or a simple interpolation method, and the meteorological driving characteristic of the photovoltaic data is not fully combined, so that the data quality is difficult to support high-precision prediction. Therefore, an integrated scheme for integrating time series data expansion, accurate feature extraction and stable prediction model is needed to solve the problems of accuracy and stability of photovoltaic power prediction in turning weather. Disclosure of Invention In order to solve the technical problems, the invention provides a photovoltaic power prediction method based on TimeGAN in consideration of turning weather, introduces a TimeGAN sample expansion method aiming at the condition of insufficient turning weather samples, fully considers the internal correlation among sequences, aims at improving the photovoltaic power prediction precision, and has important significance for photovoltaic output prediction, photovoltaic grid-connected operation and scheduling plan establishment in the turning weather. The invention provides a TimeGAN-based photovoltaic power prediction method under consideration of turning weather, which comprises the following steps: s1, preprocessing data of original photovoltaic output and meteorological data, detecting an abnormal value by using a reconstruction error, and filling missing