CN117200199A - Photovoltaic power prediction method and system based on weather typing - Google Patents

Photovoltaic power prediction method and system based on weather typing Download PDF

Info

Publication number
CN117200199A
CN117200199A CN202311141370.2A CN202311141370A CN117200199A CN 117200199 A CN117200199 A CN 117200199A CN 202311141370 A CN202311141370 A CN 202311141370A CN 117200199 A CN117200199 A CN 117200199A
Authority
CN
China
Prior art keywords
weather
data
day
historical
photovoltaic power
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202311141370.2A
Other languages
Chinese (zh)
Other versions
CN117200199B (en
Inventor
张莹
徐冰雁
李峰
陈佳俊
陈龙
郭磊
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
State Grid Shanghai Electric Power Co Ltd
Original Assignee
State Grid Shanghai Electric Power Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by State Grid Shanghai Electric Power Co Ltd filed Critical State Grid Shanghai Electric Power Co Ltd
Priority to CN202311141370.2A priority Critical patent/CN117200199B/en
Publication of CN117200199A publication Critical patent/CN117200199A/en
Application granted granted Critical
Publication of CN117200199B publication Critical patent/CN117200199B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Photovoltaic Devices (AREA)

Abstract

The application relates to a photovoltaic power prediction method and system based on weather typing, belongs to the technical field of photovoltaic power generation, and aims to solve the problem that the accuracy of an existing photovoltaic power prediction method is low. The method of the application comprises the following steps: dividing the daily weather types of the region where the photovoltaic electric field to be predicted is located in the historical period into two types of stationary weather and turning weather; constructing a training data set of stationary weather and a training data set of turning weather; training the photovoltaic power prediction model through training data sets of stationary weather and turning weather respectively; and determining the weather type of the prediction day, and selecting a corresponding sub-photovoltaic power prediction model according to the weather type of the prediction day to obtain the predicted photovoltaic power. According to the method, the weather types are divided into two types of stationary weather and turning weather, and sub-photovoltaic prediction models of the stationary weather and the turning weather are obtained, so that the accuracy of a photovoltaic power prediction result is improved.

Description

Photovoltaic power prediction method and system based on weather typing
Technical Field
The application relates to the technical field of photovoltaic power generation, in particular to a photovoltaic power prediction method and system based on weather typing.
Background
Photovoltaic power generation is a renewable, clean and flexible distributed energy source and plays an important role in meeting the increasing clean energy demands worldwide. With the integration of photovoltaic power generation, obvious economic benefit and environmental benefit are brought, the permeability of the photovoltaic power generation is gradually improved, but the high popularization rate of the photovoltaic power generation brings a plurality of new problems for the operation of the existing power grid system. Particularly, the photovoltaic output has volatility and intermittence, and the photovoltaic power station can bring impact to a power system after being connected into a power grid in a high proportion. In order to solve the above problems, the demand for photovoltaic output prediction is continuously increasing, wherein the distributed photovoltaic power station output prediction based on refined weather typing recognition in a microclimate environment is an important field of photovoltaic output prediction, and the accuracy of photovoltaic power prediction can be improved through effective division of weather types.
In the prior art, weather typing techniques for photovoltaic output prediction are mostly subdivided for all weather types, for example, weather types are divided into three types by definition indexes, or sunny types are further divided into three types by introducing total cloud amount cross subdivision. However, in engineering application, due to uncertainty of meteorological environment factors, the influence of turning weather (namely weather with severe weather changes) with large fluctuation in one day on photovoltaic output and stability and scheduling of a power grid is large, and the influence is usually considered when photovoltaic grid-connected energy storage design is carried out, but the day of turning weather with large power fluctuation cannot be well identified by the conventional weather type division, so that the accuracy of photovoltaic power prediction is low.
Disclosure of Invention
In view of the above analysis, the embodiment of the application aims to provide a weather-parting photovoltaic power prediction method and a weather-parting photovoltaic power prediction system, which are used for solving the problem that the accuracy of the existing photovoltaic power prediction method is low.
In one aspect, an embodiment of the present application provides a method for predicting photovoltaic power based on weather typing, where the method includes the following steps:
based on weather changes and photovoltaic output fluctuation conditions, dividing the daily weather types of the region where the photovoltaic electric field to be predicted is located in a historical period into two types of stationary weather and turning weather;
preprocessing the historical weather data and the historical photovoltaic power data of the stationary weather day to construct a training data set of the stationary weather day, and preprocessing the historical weather data and the historical photovoltaic power data of the turning weather day to construct a training data set of the turning weather day;
training a pre-established photovoltaic power prediction model through a training data set of a stationary weather day and a training data set of a turning weather day respectively to obtain a trained sub-prediction model of the stationary weather day and a trained sub-prediction model of the turning weather day;
and determining the weather type of the prediction day, and selecting a corresponding sub-photovoltaic power prediction model according to the weather type of the prediction day to obtain the predicted photovoltaic power.
Based on the further improvement of the method, the weather type of the region where the photovoltaic electric field to be predicted is located in the historical period is divided into two types of stationary weather and turning weather based on weather change and photovoltaic output fluctuation conditions, and the method comprises the following steps:
acquiring power change rate data according to historical photovoltaic power data of the photovoltaic electric field to be predicted in a historical period;
clustering and dividing the power change rate data into at least two types based on an SOM network, and screening the type with the largest power fluctuation range to serve as a potential turning weather sample;
calculating a definition index of the period corresponding to the potential turning weather sample according to the historical solar radiation data;
and identifying the weather type of the day on which the potential turning weather sample is located, the definition index of which is smaller than the definition threshold value, as turning weather, and the weather type of the other days in the historical period as stationary weather.
Based on the further improvement of the method, the power change rate data is obtained according to the historical photovoltaic power data of the photovoltaic electric field to be predicted in the historical period, and the method comprises the following steps:
calculating a solar altitude angle of a region where a photovoltaic electric field to be predicted is located, and taking a time period when the solar altitude angle is larger than a preset angle as a photovoltaic output statistic time period;
and calculating the power change rate of the photovoltaic output statistic time period according to the historical photovoltaic power data so as to acquire power change rate data.
Based on a further improvement of the method, the power change rate is a time-by-time power difference and is calculated according to the following formula:
ΔP=P i+1 -P i
wherein, the delta P is the time-by-time power change rate, P i+1 For the power value at time i+1 daily, P i The power value at time i is the value of power at time i per day.
Based on a further improvement of the above method, the weather type of the predicted day is determined by the following method:
establishing a weather identification model;
training the weather type recognition model through the historical weather data of the steady weather and the historical weather data of the turning weather to obtain a trained weather type recognition model;
and inputting the predicted weather data of the predicted day into a trained weather type recognition model to obtain the weather type of the predicted day.
Based on a further improvement of the above method, the preprocessing of the historical weather data and the historical photovoltaic power data for the stationary weather day to construct a training data set for the stationary weather day, and the preprocessing of the historical weather data and the historical photovoltaic power data for the turning weather day to construct a training data set for the turning weather day, includes:
performing correlation analysis on historical weather data and historical photovoltaic power data of the stable weather day, and selecting at least two types of weather characteristic data with high correlation from the historical weather data of the stable weather day to construct an input data sequence of the stable weather day;
and performing correlation analysis on the historical weather data and the historical photovoltaic power data of the turning weather day, and selecting at least two types of weather characteristic data with high correlation from the historical weather data of the turning weather day to construct an input data sequence of the turning weather day.
Based on a further improvement of the method, the photovoltaic power prediction model is a lightweight convolutional neural network model, and the lightweight convolutional neural network model comprises:
the first convolution layer is used for extracting shallow layer characteristics of input data and outputting the shallow layer characteristics;
a max pooling layer for reducing the dimension of shallow features;
the plurality of shuffleNet modules are used for extracting deep semantic features from the dimension-reduced shallow feature data in a point-by-point group rolling and channel shuffling mode;
and the second convolution layer is used for reducing the channel dimension of the deep semantic features and outputting a prediction result.
Based on further improvement of the method, after the predicted photovoltaic power of the prediction day is obtained, the accuracy of the prediction result is evaluated by adopting a root mean square error and an absolute value error.
Based on a further improvement of the above method, the method further comprises:
dividing a prediction period into a plurality of prediction days;
and superposing the predicted photovoltaic power of the plurality of predicted days according to the time sequence, thereby obtaining the predicted photovoltaic power of the predicted period.
In another aspect, an embodiment of the present application provides a weather-based photovoltaic power prediction system, including:
the weather classification module classifies the daily weather types of the region where the photovoltaic electric field to be predicted is located in the historical period into two types of stationary weather and turning weather based on weather changes and photovoltaic output fluctuation conditions,
the data processing module is used for preprocessing the historical weather data and the historical photovoltaic power data of the stable weather day to construct a training data set of the stable weather day, and preprocessing the historical weather data and the historical photovoltaic power data of the turning weather day to construct a training data set of the turning weather day;
the model training module is used for training a pre-established photovoltaic power prediction model through a training data set of a stationary weather day and a training data set of a turning weather day respectively to obtain a trained sub-prediction model of the stationary weather day and a trained sub-prediction model of the turning weather day;
and the power prediction module is used for determining the weather type of the prediction day, and selecting a corresponding sub-photovoltaic power prediction model according to the weather type of the prediction day to obtain the predicted photovoltaic power of the sub-photovoltaic power prediction model.
Compared with the prior art, the application has at least one of the following beneficial effects:
1. according to the photovoltaic power prediction model, the fact that the turning weather with larger change in weather in one day causes large fluctuation of photovoltaic power is considered, and the influence on photovoltaic output is larger is considered, so that weather types are divided into two types of stationary weather and turning weather based on weather change and photovoltaic output fluctuation, and then the photovoltaic power prediction model is trained through the historical weather data and historical photovoltaic power data of the stationary weather day and the turning weather day after pretreatment, so that the sub photovoltaic power prediction models corresponding to the two weather types are obtained, the corresponding sub photovoltaic power prediction model is selected according to the weather types of the prediction day to obtain photovoltaic prediction power, and the accuracy of a photovoltaic power prediction result is improved.
2. According to the application, the power change rate is adopted to represent historical photovoltaic power data fluctuation, then clustering primary screening is carried out on the power change rate data, and secondary screening is carried out by combining astronomical meteorological factors-definition indexes, so that turning weather with larger amplitude of power fluctuation is accurately identified, the weather type is effectively divided, and the accuracy of photovoltaic power prediction results is ensured.
3. According to the method, after the daily weather types in the historical period are accurately divided into stationary weather and turning weather, the weather type identification model is trained through the historical weather data of the stationary weather and the historical weather data of the turning weather, so that the trained weather type identification model is obtained, and the weather type of the predicted day can be accurately identified according to the predicted weather data of the predicted day.
4. According to the application, the photovoltaic prediction model is a lightweight convolutional neural network model, and the model structure is improved, so that the calculation amount is reduced while the prediction accuracy is ensured, the prediction efficiency is improved, a self-attention module is added to extract more accurate characteristics, and the shuffleNet unit is improved, so that the calculation amount of the network can be effectively reduced while the accuracy loss is not great.
In the application, the technical schemes can be mutually combined to realize more preferable combination schemes. Additional features and advantages of the application will be set forth in the description which follows, and in part will be obvious from the description, or may be learned by practice of the application. The objectives and other advantages of the application may be realized and attained by the structure particularly pointed out in the written description and drawings.
Drawings
The drawings are only for purposes of illustrating particular embodiments and are not to be construed as limiting the application, like reference numerals being used to refer to like parts throughout the several views.
FIG. 1 is a flow chart of a photovoltaic power prediction method based on weather typing according to an embodiment of the present application;
FIG. 2 is a flow chart of weather type division according to an embodiment of the present application;
FIG. 3 is a graph showing the predicted and measured photovoltaic power curves (turning weather) of example 1 of the present application;
FIG. 4 is a graph of the predicted and measured photovoltaic power curves (stationary weather) for example 2 of the present application;
fig. 5 shows a photovoltaic power prediction curve and a photovoltaic power actual measurement curve (without weather typing) of a comparative example of the present application.
Detailed Description
The following detailed description of preferred embodiments of the application is made in connection with the accompanying drawings, which form a part hereof, and together with the description of the embodiments of the application, are used to explain the principles of the application and are not intended to limit the scope of the application.
One embodiment of the present application provides a method for predicting photovoltaic power based on weather typing, as shown in fig. 1. The method comprises the following steps:
step 1, based on weather change and photovoltaic output fluctuation conditions, dividing the daily weather types of the area where the predicted photovoltaic electric field is located in a historical period into two types of stationary weather and turning weather;
step 2, preprocessing historical weather data and historical photovoltaic power data of a stationary weather day to construct a training data set of the stationary weather, and preprocessing historical weather data and historical photovoltaic power data of a turning weather day to construct a training data set of the turning weather;
step 3, training a pre-established photovoltaic power prediction model through a training data set of a stationary weather day and a training data set of a turning weather day respectively to obtain a trained sub-prediction model of the stationary weather and a trained sub-prediction model of the turning weather;
and 4, determining the weather type of the prediction day, and selecting a corresponding sub-photovoltaic power prediction model according to the weather type of the prediction day to obtain the predicted photovoltaic power of the sub-photovoltaic power prediction model.
In implementation, the input data of the photovoltaic power prediction model are weather data, and the output data are photovoltaic power data. Specifically, during model training, the classified historical weather data are respectively input into a photovoltaic prediction power model, then the corresponding historical photovoltaic power data are used as output correction data, and an optimizer and a loss function of the photovoltaic power prediction model compare the output data with the output correction output data and repeatedly update weights until convergence.
Compared with the prior art, in the embodiment of the application, the fact that the turning weather with larger change in weather in one day causes the photovoltaic power to fluctuate greatly is considered, and the influence on the photovoltaic output is larger, so that the weather types are divided into two types of stationary weather and turning weather based on the weather change and the fluctuation condition of the photovoltaic output, and then the photovoltaic power prediction model is trained through the preprocessed historical weather data and the historical photovoltaic power data of the stationary weather day and the turning weather day respectively, so that the sub-photovoltaic power prediction models corresponding to the two weather types are obtained, the corresponding sub-photovoltaic power prediction model is selected according to the weather type of the prediction day to obtain the photovoltaic prediction power, and the accuracy of the photovoltaic power prediction result is improved.
In the embodiment of the application, the turning weather refers to weather in which weather changes and the weather changes can cause the photovoltaic power to fluctuate greatly, and the weather in which weather changes but does not cause the photovoltaic power to fluctuate greatly is excluded.
The history period is generally longer, for example, one year or more, so that more training samples of turning weather can be obtained, which is beneficial to improving prediction accuracy.
In one embodiment, as shown in fig. 2, step 1, based on weather variation and photovoltaic output fluctuation, classifies the daily weather types of the region where the photovoltaic electric field to be predicted is located in the historical period into two types of stationary weather and turning weather, and includes the following steps:
step 11, acquiring power change rate data according to historical photovoltaic power data of the photovoltaic electric field to be predicted in a historical period;
step 12, clustering and dividing the power change rate data into at least two types based on an SOM network, and screening out the type with the largest power fluctuation amplitude as a potential turning weather sample;
step 13, calculating a definition index of the period corresponding to the potential turning weather sample according to the historical solar radiation data;
and 14, identifying the weather type of the day on which the potential turning weather sample with the definition index smaller than the definition threshold value is located as turning weather, and identifying the weather types of other dates in the historical period as stationary weather.
The weather type dividing method is realized based on historical photovoltaic power data and contemporaneous historical solar radiation data, and in the implementation, the fact that the weather conditions with severe changes are usually accompanied by large fluctuation of photovoltaic output is considered, so that the fluctuation identification amplitude is met in value through the power change rate, but the power fluctuation is caused by non-weather factors, especially the photovoltaic power is greatly fluctuated under the influence of a solar altitude angle in sunny sunrise or sunset, so that the characteristic of power fluctuation is required to be focused when the turning weather is identified, and physical quantities capable of reflecting the fluctuation of the illumination radiation quantity caused by the weather change are also required to be introduced, wherein the clarity index can reflect the transparency degree of the atmosphere and is closely related to the weather condition and the solar radiation, and therefore, in the embodiment of the application, the data of the potential turning samples obtained by clustering according to the power change rate are screened out through secondary screening through the clarity index, and only the data of the real turning weather which can cause large power fluctuation are reserved, so that the turning weather is identified. That is, if the photovoltaic output of a certain day can meet the fluctuation range requirement of the power change rate, and the day can meet the corresponding atmospheric condition, the weather type of the day can be identified as turning weather with larger fluctuation range.
Compared with the prior art, in the embodiment of the application, the power change rate is adopted to represent historical photovoltaic power data fluctuation, then clustering primary screening is carried out on the power change rate data, and secondary screening is carried out by combining astronomical meteorological factors-definition indexes, so that turning weather with larger amplitude of power fluctuation is accurately identified, the weather type is effectively divided, and the accuracy of photovoltaic power prediction results is ensured.
In addition, the historical photovoltaic power data and the historical solar radiation data adopted in the embodiment of the application are data obtained from the photovoltaic electric field to be predicted and subjected to data quality inspection.
Preferably, in step 11, the step of obtaining the power change rate data according to the historical photovoltaic power data of the photovoltaic electric field to be predicted includes the following steps:
step 1101, calculating a solar altitude in a region where a photovoltaic electric field to be predicted is located, and taking a time period in which the solar altitude is greater than a preset angle as a photovoltaic output statistic time period;
and step 1102, calculating the power change rate of the photovoltaic output statistic time period according to the historical photovoltaic power data so as to acquire power change rate data.
The solar altitude refers to an included angle between solar rays and a normal line of a ground plane. In implementation, considering that the photovoltaic output has obvious time period characteristics, the initial historical photovoltaic power data is screened by calculating the solar altitude angle of the region where the photovoltaic electric field to be predicted is located, so that the effective data can be better utilized.
The solar altitude is calculated according to the following formula:
ω=(t-12)×15°;
wherein alpha is s Is the solar altitude angle theta z Is a zenith angle, the shape of the zenith angle is a zenith angle,the latitude of the target area is represented by delta, delta is represented by declination angle, omega is represented by hour angle, n is represented by a serial number of a date in one year, and t is represented by hours.
For example, 1 month and 1 day each year, n=1; 12 months 31 days of the year, n=365; 12 months 31 days of leap years, n=366.
The angle of day is positive from point Q on the noon of the sun (from noon of the sun), negative in the clockwise direction, i.e. negative in the morning and positive in the afternoon, and is equal in value to the time from noon (hours) times 15 °.
In step 1101, the preset angle has a value ranging from 5 ° to 15 °, preferably 10 °. That is, a period in which the solar altitude is greater than 10 ° is preferably taken as the photovoltaic output statistic period.
More specifically, the power change rate is the difference between time-by-time powers, and is calculated according to the following formula: Δp=p i+1 -P i The method comprises the steps of carrying out a first treatment on the surface of the Wherein, the delta P is the time-by-time power change rate, P i+1 For the power value at time i+1 daily, P i The power value at time i is the value of power at time i per day.
When the method is implemented, firstly, the historical photovoltaic power data are arranged according to time sequence hour values, and then the power change rate per hour is obtained.
Step 12: and clustering and dividing the power change rate data into at least two types based on an SOM network, and screening the type with the largest power fluctuation range to serve as a potential turning weather sample.
Because the current standard is difficult to define and give a magnitude for the magnitude of the power fluctuation, in order to screen out a type of data sample with large negative fluctuation of the power change rate, in the embodiment of the application, the data with the power change rate is subjected to unsupervised self-organizing clustering through an SOM network (self-organizing map neural network), and is divided into a plurality of types, so that a type of data sample with the largest power fluctuation range is screened out and used as a potential turning weather sample.
The SOM network is a non-teacher learning network, and can adapt to a complex mode of photovoltaic power data by automatically searching internal rules and essential attributes in a data sample, self-organizing and self-adaptively changing network parameters and structures, and accurately and effectively classifying.
Further, in step 12, the class with the largest power negative fluctuation amplitude is screened out and used as a potential turning weather sample. The type with the largest power negative fluctuation amplitude is the type with the largest fluctuation amplitude, wherein the power change rate is a negative value.
The type with the largest power negative fluctuation amplitude is adopted as a potential turning weather sample, most of the cases occur when severe weather changes such as overcast weather or rain and snow weather are changed into sunny weather, and clear weather data can be screened out when turning weather is identified by using a definition index, so that the type with the largest power negative fluctuation amplitude is directly screened out as the potential turning weather sample during clustering screening, and the processing efficiency is improved.
Meanwhile, photovoltaic power reduction caused by instability of meteorological factors in photovoltaic output fluctuation has the greatest influence on stability and scheduling of a power grid, the photovoltaic power has remarkable time periodicity along with solar altitude change in one day, and large-amplitude power positive fluctuation occurs in one day, and large-amplitude power negative fluctuation is accompanied, so that a class with the largest power positive fluctuation amplitude is not screened out and used as a potential turning weather sample in cluster screening, and the identification result of turning weather and the photovoltaic predicted power result are not greatly influenced.
Specifically, the number of clusters of the SOM network is set to 5. In this way, in step 12, the power change rate data is clustered and divided into five types based on the SOM network, wherein the type with the largest power negative fluctuation is separated from the other four types, and the other four types mainly comprise the types of sunny days, rainy days, sunny turning negative with small power fluctuation, and the like, and the type with the largest power negative fluctuation also comprises the types of sunny days, abrupt turning weather, and the like.
Step 13: and calculating the definition index of the period corresponding to the potential turning weather sample according to the contemporaneous historical solar radiation data.
Specifically, the sharpness index of the day of the potentially turning weather sample is calculated according to the following formula:wherein k is T For clarity index, I is total radiation, I 0 Is of the outer levelTotal solar radiation.
The total solar radiation of the ground level is calculated according to the following formula:
wherein E is sc Gamma is the correction value of solar radiation flux in the upper atmosphere caused by the change of the distance between the sun and the earth, omega s Is the time angle in the sunrise to sunset time period.
Step 14: and identifying the weather type of the day on which the potential turning weather sample with the definition index smaller than the definition threshold value is located as turning weather.
In step 14, the weather type of the day on which the potentially turning weather sample is located is identified by a definition index. Wherein the value of the definition threshold is in the range of 0.1 to 0.3, preferably 0.2.
Generally, k T The weather corresponding to less than 0.2 is light rain, gust, small snow, light fog, haze, medium rain and above, medium snow and above, etc.
In one embodiment, in step 2, preprocessing the historical weather data and the historical photovoltaic power data for the stationary weather day to construct a training data set for the stationary weather day, preprocessing the historical weather data and the historical photovoltaic power data for the turning weather day to construct a training data set for the turning weather day includes: performing correlation analysis on historical weather data and historical photovoltaic power data of the stable weather day, and selecting at least two types of weather characteristic data with high correlation from the historical weather data of the stable weather day to construct an input data sequence of the stable weather day; and performing correlation analysis on the historical weather data and the historical photovoltaic power data of the turning weather day, and selecting at least two types of weather characteristic data with high correlation from the historical weather data of the turning weather day to construct an input data sequence of the turning weather day.
Specifically, in an input data sequence of the stationary weather day, five weather characteristic data such as irradiance, humidity, temperature, cloud cover and visibility are sequentially included from high to low according to the correlation;
the input data sequence of the turning weather day sequentially comprises five weather characteristic data of irradiance, humidity, visibility, cloud cover and temperature according to the relativity from high to low.
It should be noted that, the daily historical weather data and the historical photovoltaic power data in the historical period are used as one training sample, that is, the training data set of the stationary weather includes the historical weather data and the historical photovoltaic power data of one or more stationary weather days, and the training data set of the turning weather days includes the historical weather data and the historical photovoltaic power data of one or more turning weather days. In addition, in each training sample, weather data is input data, and photovoltaic power data is output correction data (tag).
In one embodiment, in step 3, the photovoltaic power prediction model is a lightweight convolutional neural network model, and the lightweight convolutional neural network model includes:
a first convolution layer for extracting shallow features of the input data and outputting shallow feature data,
the maximum pooling layer is used for reducing the dimension of the shallow characteristic data;
the plurality of shuffleNet modules are used for extracting deep semantic features from the dimension-reduced shallow feature data in a point-by-point group rolling and channel shuffling mode; and
and the second convolution layer is used for reducing the channel dimension of the deep semantic features and outputting a prediction result.
In the application, in order to improve training efficiency, a lightweight convolutional neural network model is constructed as a photovoltaic power prediction model. Wherein the lightweight convolutional neural network model is a modified ShuffleNet model.
Specifically, the first convolution layer is a one-dimensional convolution layer, the step length is 2, the number of convolution kernels is 24, and the convolution layer is used for extracting shallow layer features of input data, reducing the data dimension and increasing the number of feature channels.
And extracting deep semantic features from the feature data after the dimension reduction through a plurality of ShuffleNet modules. Each module increases the number of feature channels while continuously reducing the feature data dimension, and gradually extracts the deep semantic features of the edge points. The ShuffleNet adopts point-by-point group rolling and channel shuffling, so that the calculation amount of the network can be effectively reduced while the loss of accuracy is not great, and the calculation cost is greatly reduced.
Specifically, to enhance the feature extraction capability of the network, each of the ShuffleNet modules includes a ShuffleNet unit and a channel attention module connected in sequence.
A channel attention module is added after each ShuffleNet cell structure to further extract more accurate features. The channel attention module consists of global average pooling, 2 full connection layers, a ReLU layer and a Sigmoid activation layer, and generates corresponding weights for each channel, so that the network can autonomously select according to the importance of each characteristic channel. Multiplying the characteristics output by the ShuffleNet unit by the weights calculated by the channel attention module yields characteristics of increased attention weights.
The improved SheffeNet model changes the global average pooling and full connection layer at the tail part of the existing SheffeNet model into 1 convolution layer, namely a second convolution layer, wherein the convolution kernel of the convolution layer is 1 multiplied by 1, the number of the convolution layers is 2, and the step length is 1.
Specifically, the ShuffleNet unit includes a convolution layer, a Channel Shuffle layer (Channel Shuffle), a deep convolution layer, a convolution layer, and a fusion layer connected in sequence. In the ShuffleNet unit, both convolution layers are 1×1 convolution layers, and the depth convolution layer is a 3×3 depth convolution layer.
By constructing the lightweight neural network structure, the model can ensure the prediction accuracy, reduce the operation amount and improve the detection efficiency.
After the lightweight convolutional neural network model is built, model training is carried out based on the classified training sample data, the gradient descent method is used for carrying out back propagation updating on parameters in the network training process, and model parameters are optimized, so that two trained sub-photovoltaic prediction models of stationary weather and sub-photovoltaic prediction models of turning weather are obtained.
Specifically, a variance cost function and a cross entropy cost function are adopted to construct a Loss function Loss of the model. And stopping training after the model reaches the required precision or reaches the preset iteration times, and obtaining the trained sub-photovoltaic power prediction model.
The variance cost function is:
the cross entropy cost function is: loss_2= - [ yln (y 0 )+(1-y 0 )ln(1-y 0 )];
The loss function: loss=q 1 loss_1+q 2 loss_2;
Wherein y is the output value of the photovoltaic power prediction model, y 0 Is the measured value (target value) of the photovoltaic power; wherein q is 1 And q 2 And setting the weight coefficient according to actual conditions.
In one embodiment, in step 4, the weather type of the predicted day is determined by a method comprising the steps of:
step 401, establishing a weather identification model;
step 402, training a weather type recognition model through historical weather data of stationary weather and historical weather data of turning weather to obtain a trained weather type recognition model;
step 403, inputting the predicted weather data of the predicted day into a trained weather type recognition model to obtain the weather type of the predicted day.
In the embodiment of the application, the weather type of the predicted day is determined by the trained weather type recognition model, specifically, the weather recognition model is trained by accurately classifying the historical weather data of the stable weather day and the historical weather data of the turning weather day, so that the trained weather recognition model can accurately recognize whether the weather type of the predicted day is the turning weather or the stable weather.
In the embodiment of the application, the weather type identification model takes weather data as input and takes weather type as output. Meanwhile, the weather type recognition model is a deep learning model, such as a kohonen model, a neural network model, and the like.
In one embodiment, the method further comprises: dividing a prediction period into a plurality of prediction days; and superposing the predicted photovoltaic power of the plurality of predicted days according to the time sequence, thereby obtaining the predicted photovoltaic power of the predicted period.
The method of the embodiment of the application further comprises the following steps: after the predicted photovoltaic power of the prediction day is obtained, the accuracy of the prediction result is evaluated by adopting the root mean square error and the absolute value error.
Specifically, root mean square error e RMSE The calculation formula of (2) is as follows:
absolute value error e MAE The calculation formula of (2) is as follows:
wherein: p (P) t,pre The predicted value of the photovoltaic power at the time t; p (P) t The measured value of the photovoltaic power at the time t; n is a predicted period; c (C) ap The rated power of the photovoltaic output of the power station.
The embodiment of the application also provides a photovoltaic power prediction system based on weather typing, which comprises:
the weather classification module classifies the daily weather types of the region where the photovoltaic electric field to be predicted is located in the historical period into two types of stationary weather and turning weather based on weather changes and photovoltaic output fluctuation conditions,
the data processing module is used for preprocessing the historical weather data and the historical photovoltaic power data of the stable weather day to construct a training data set of the stable weather day, and preprocessing the historical weather data and the historical photovoltaic power data of the turning weather day to construct a training data set of the turning weather day;
the model training module is used for training a pre-established photovoltaic power prediction model through a training data set of a stationary weather day and a training data set of a turning weather day respectively to obtain a trained sub-prediction model of the stationary weather day and a trained sub-prediction model of the turning weather day; and
and the power prediction module is used for determining the weather type of the prediction day, and selecting a corresponding sub-photovoltaic power prediction model according to the weather type of the prediction day to obtain the predicted photovoltaic power of the sub-photovoltaic power prediction model.
Examples:
the photovoltaic power prediction is performed below taking a photovoltaic electric field with a certain installed capacity of 1.4MW as an example. And taking weather data and photovoltaic power actual measurement data within a certain period of time as samples, wherein the time resolution is 1h. Wherein the first 80% of the annual data are used as training samples and the last 20% are used as test samples.
Example 1: the predicted period is three days (72 hours), and the first, second and third days are all turning weather. The weather data of the first day, the second day and the third day are input into the sub-photovoltaic power prediction model of the turning weather according to the embodiment of the present application, and the obtained photovoltaic power prediction curve and the photovoltaic power actual measurement curve are shown in fig. 3.
Example 2: the predicted period is three days (72 hours), and the first, second and third days are all stationary weather. The weather data of the first day, the second day and the third day are input into the sub-photovoltaic power prediction model of the stationary weather according to the embodiment of the present application, and the obtained photovoltaic power prediction curve and the photovoltaic power actual measurement curve are shown in fig. 4.
Comparative example: the predicted period was three days (72 hours), and weather type classification was not performed. The weather data of three days are input into a photovoltaic prediction model which is not trained by the data after weather typing, and the obtained photovoltaic power prediction curve and the photovoltaic power actual measurement curve are shown in fig. 5.
From the measured photovoltaic power curves in fig. 5, it can be seen that, in the comparative example, the first and third days belong to the turning weather, and the photovoltaic power has a larger roll-over in a day-and-night period; the next day belongs to stationary weather, and the power trend tends to be consistent with that shown in fig. 4.
Comparing fig. 3 with fig. 5, it can be seen that in embodiment 1, the photovoltaic power prediction curves of the three turning weather days are better in fit with the photovoltaic power actual measurement curves, and the deviation is smaller; compared with example 1, in the comparative example, the fitting degree of the photovoltaic power prediction curve and the photovoltaic power actual measurement curve is reduced in the first and third days, and the deviation is larger. Compared with the prior art, the method has the advantages that when larger weather changes occur in one day, the difference between the photovoltaic power prediction curve obtained through the weather-typed prediction model and the photovoltaic power actual measurement curve is smaller, and the change of data can be found, adapted and learned.
Comparing fig. 4 and fig. 5, it can be seen that the prediction results of the example 1 and the comparative example are not very different in smooth weather, and the photovoltaic power in smooth weather can be accurately predicted.
In conclusion, it can be obviously seen that the power prediction curve after parting is better and more similar to the actual curve, and the prediction result has larger deviation due to the non-uniform photovoltaic power fluctuation characteristics of the whole period. The combined prediction model (sub prediction model of stationary weather and turning weather) provided by the embodiment of the application can effectively improve the prediction precision and the generalization capability of the model.
After the predicted photovoltaic power for the prediction period was obtained, the accuracy of the prediction result was evaluated using the root mean square error and the absolute value error, and the comparison result is shown in table 1.
Table 1 error index for annual photovoltaic power prediction model
Error index Example 2 Example 1 Comparative example
e RMSE (%) 2.23 0.91 2.62
e MAE (%) 1.7 0.68 1.96
As can be seen from table 1, compared with the photovoltaic power prediction method without the weather typing, the photovoltaic power prediction method based on the weather typing provided by the embodiment of the application has the advantages that the prediction precision is improved, and the accuracy of the deep learning model is obviously improved due to more concentrated sample characteristics after the weather typing, outlier rejection and power decomposition. According to the analysis of the prediction error precision, the rationality of the photovoltaic power prediction method based on weather typing is further described.
It can be seen that the sample characteristics after weather typing, outlier rejection and power decomposition are more concentrated, and the accuracy of the deep learning model is obviously improved. The rationality of the combined prediction algorithm proposed by the present report is further illustrated based on analysis of prediction error accuracy.
Those skilled in the art will appreciate that all or part of the flow of the methods of the embodiments described above may be accomplished by way of a computer program to instruct associated hardware, where the program may be stored on a computer readable storage medium. Wherein the computer readable storage medium is a magnetic disk, an optical disk, a read-only memory or a random access memory, etc.
The present application is not limited to the above-mentioned embodiments, and any changes or substitutions that can be easily understood by those skilled in the art within the technical scope of the present application are intended to be included in the scope of the present application.

Claims (10)

1. A photovoltaic power prediction method based on weather typing, the method comprising the steps of:
based on weather changes and photovoltaic output fluctuation conditions, dividing the daily weather types of the region where the photovoltaic electric field to be predicted is located in a historical period into two types of stationary weather and turning weather;
preprocessing the historical weather data and the historical photovoltaic power data of the stationary weather day to construct a training data set of the stationary weather day, and preprocessing the historical weather data and the historical photovoltaic power data of the turning weather day to construct a training data set of the turning weather day;
training a pre-established photovoltaic power prediction model through a training data set of a stationary weather day and a training data set of a turning weather day respectively to obtain a trained sub-prediction model of the stationary weather day and a trained sub-prediction model of the turning weather day;
and determining the weather type of the prediction day, and selecting a corresponding sub-photovoltaic power prediction model according to the weather type of the prediction day to obtain the predicted photovoltaic power.
2. The method of claim 1, wherein classifying the daily weather types in the historical period of the region in which the photovoltaic electric field to be predicted is located into two types of stationary weather and turning weather based on weather changes and photovoltaic output fluctuation conditions comprises:
acquiring power change rate data according to historical photovoltaic power data of the photovoltaic electric field to be predicted in a historical period;
clustering and dividing the power change rate data into at least two types based on an SOM network, and screening the type with the largest power fluctuation range to serve as a potential turning weather sample;
calculating a definition index of the period corresponding to the potential turning weather sample according to the historical solar radiation data;
and identifying the weather type of the day on which the potential turning weather sample is located, the definition index of which is smaller than the definition threshold value, as turning weather, and the weather type of the other days in the historical period as stationary weather.
3. The method according to claim 2, wherein the obtaining power change rate data from historical photovoltaic power data of the photovoltaic electric field to be predicted over a historical period of time comprises the steps of:
calculating a solar altitude angle of a region where a photovoltaic electric field to be predicted is located, and taking a time period when the solar altitude angle is larger than a preset angle as a photovoltaic output statistic time period;
and calculating the power change rate of the photovoltaic output statistic time period according to the historical photovoltaic power data so as to acquire power change rate data.
4. The method of claim 2, wherein the rate of power change is a time-by-time power difference, calculated according to the following equation:
ΔP=P i+1 -P i
wherein, the delta P is the time-by-time power change rate, P i+1 For the power value at time i+1 daily, P i The power value at time i is the value of power at time i per day.
5. The method according to any one of claims 1-4, wherein the weather type of the predicted day is determined by:
establishing a weather identification model;
training the weather type recognition model through the historical weather data of the steady weather and the historical weather data of the turning weather to obtain a trained weather type recognition model;
and inputting the predicted weather data of the predicted day into a trained weather type recognition model to obtain the weather type of the predicted day.
6. The method of any one of claims 1-4, wherein preprocessing the historical weather data and the historical photovoltaic power data for the stationary weather day to construct a training dataset for the stationary weather day, preprocessing the historical weather data and the historical photovoltaic power data for the turning weather day to construct a training dataset for the turning weather day, comprising:
performing correlation analysis on historical weather data and historical photovoltaic power data of the stable weather day, and selecting at least two types of weather characteristic data with high correlation from the historical weather data of the stable weather day to construct an input data sequence of the stable weather day;
and performing correlation analysis on the historical weather data and the historical photovoltaic power data of the turning weather day, and selecting at least two types of weather characteristic data with high correlation from the historical weather data of the turning weather day to construct an input data sequence of the turning weather day.
7. The method of any one of claims 1-4, wherein the photovoltaic power prediction model is a lightweight convolutional neural network model comprising:
the first convolution layer is used for extracting shallow layer characteristics of input data and outputting shallow layer characteristic data;
the maximum pooling layer is used for reducing the dimension of the shallow characteristic data;
the plurality of shuffleNet modules are used for extracting deep semantic features from the dimension-reduced shallow feature data in a point-by-point group rolling and channel shuffling mode;
and the second convolution layer is used for reducing the channel dimension of the deep semantic features and outputting a prediction result.
8. The method according to any one of claims 1-4, wherein the accuracy of the prediction result is evaluated using a root mean square error and an absolute value error after the predicted photovoltaic power of the prediction day is obtained.
9. The method according to any one of claims 1-4, further comprising:
dividing a prediction period into a plurality of prediction days;
and superposing the predicted photovoltaic power of the plurality of predicted days according to the time sequence, thereby obtaining the predicted photovoltaic power of the predicted period.
10. A weather-typing-based photovoltaic power prediction system, the system comprising:
the weather classification module classifies the daily weather types of the region where the photovoltaic electric field to be predicted is located in the historical period into two types of stationary weather and turning weather based on weather changes and photovoltaic output fluctuation conditions,
the data processing module is used for preprocessing the historical weather data and the historical photovoltaic power data of the stable weather day to construct a training data set of the stable weather day, and preprocessing the historical weather data and the historical photovoltaic power data of the turning weather day to construct a training data set of the turning weather day;
the model training module is used for training a pre-established photovoltaic power prediction model through a training data set of a stationary weather day and a training data set of a turning weather day respectively to obtain a trained sub-prediction model of the stationary weather day and a trained sub-prediction model of the turning weather day;
and the power prediction module is used for determining the weather type of the prediction day, and selecting a corresponding sub-photovoltaic power prediction model according to the weather type of the prediction day to obtain the predicted photovoltaic power of the sub-photovoltaic power prediction model.
CN202311141370.2A 2023-09-06 2023-09-06 Photovoltaic power prediction method and system based on weather typing Active CN117200199B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202311141370.2A CN117200199B (en) 2023-09-06 2023-09-06 Photovoltaic power prediction method and system based on weather typing

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202311141370.2A CN117200199B (en) 2023-09-06 2023-09-06 Photovoltaic power prediction method and system based on weather typing

Publications (2)

Publication Number Publication Date
CN117200199A true CN117200199A (en) 2023-12-08
CN117200199B CN117200199B (en) 2024-04-02

Family

ID=88997260

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202311141370.2A Active CN117200199B (en) 2023-09-06 2023-09-06 Photovoltaic power prediction method and system based on weather typing

Country Status (1)

Country Link
CN (1) CN117200199B (en)

Citations (14)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106228274A (en) * 2016-08-03 2016-12-14 河海大学常州校区 Photovoltaic power station power generation amount Forecasting Methodology based on SOM Neural Network Data clustering recognition
US20180046924A1 (en) * 2015-08-31 2018-02-15 Guangzhou Institute Of Energy Conversion, Chinese Academy Of Sciences Whole-life-cycle power output classification prediction system for photovoltaic systems
CN108205717A (en) * 2017-12-30 2018-06-26 国网江苏省电力公司无锡供电公司 A kind of photovoltaic generation power Multiple Time Scales Forecasting Methodology
US10826428B1 (en) * 2019-12-06 2020-11-03 King Abdulaziz University Monitoring and fault detection method and system for photovoltaic plants
CN112070311A (en) * 2020-09-10 2020-12-11 天津大学 Day-ahead light power prediction method based on similar day clustering and meteorological factor weighting
CN112418346A (en) * 2020-12-07 2021-02-26 天津大学 Numerical weather forecast total radiation system error classification calculation method
CN112862630A (en) * 2021-03-08 2021-05-28 海南省电力学校(海南省电力技工学校) Weather type index interval-based photovoltaic power prediction method, terminal and medium
US11070056B1 (en) * 2020-03-13 2021-07-20 Dalian University Of Technology Short-term interval prediction method for photovoltaic power output
CN114169445A (en) * 2021-12-09 2022-03-11 河海大学 Day-ahead photovoltaic power prediction method, device and system based on CAE and GAN hybrid network
CN114399081A (en) * 2021-12-14 2022-04-26 国网浙江省电力有限公司金华供电公司 Photovoltaic power generation power prediction method based on weather classification
US20220373984A1 (en) * 2021-05-19 2022-11-24 Shandong University Hybrid photovoltaic power prediction method and system based on multi-source data fusion
CN115829105A (en) * 2022-11-24 2023-03-21 三峡大学 Photovoltaic power prediction method based on historical data feature search
CN115952906A (en) * 2022-12-29 2023-04-11 特变电工新疆新能源股份有限公司 Short-term photovoltaic power prediction method, system, equipment and medium based on LSGAN-GRU
CN116402203A (en) * 2023-03-23 2023-07-07 中国电力科学研究院有限公司 Method, system and medium for predicting short-time photovoltaic power generation capacity considering weather conditions

Patent Citations (14)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20180046924A1 (en) * 2015-08-31 2018-02-15 Guangzhou Institute Of Energy Conversion, Chinese Academy Of Sciences Whole-life-cycle power output classification prediction system for photovoltaic systems
CN106228274A (en) * 2016-08-03 2016-12-14 河海大学常州校区 Photovoltaic power station power generation amount Forecasting Methodology based on SOM Neural Network Data clustering recognition
CN108205717A (en) * 2017-12-30 2018-06-26 国网江苏省电力公司无锡供电公司 A kind of photovoltaic generation power Multiple Time Scales Forecasting Methodology
US10826428B1 (en) * 2019-12-06 2020-11-03 King Abdulaziz University Monitoring and fault detection method and system for photovoltaic plants
US11070056B1 (en) * 2020-03-13 2021-07-20 Dalian University Of Technology Short-term interval prediction method for photovoltaic power output
CN112070311A (en) * 2020-09-10 2020-12-11 天津大学 Day-ahead light power prediction method based on similar day clustering and meteorological factor weighting
CN112418346A (en) * 2020-12-07 2021-02-26 天津大学 Numerical weather forecast total radiation system error classification calculation method
CN112862630A (en) * 2021-03-08 2021-05-28 海南省电力学校(海南省电力技工学校) Weather type index interval-based photovoltaic power prediction method, terminal and medium
US20220373984A1 (en) * 2021-05-19 2022-11-24 Shandong University Hybrid photovoltaic power prediction method and system based on multi-source data fusion
CN114169445A (en) * 2021-12-09 2022-03-11 河海大学 Day-ahead photovoltaic power prediction method, device and system based on CAE and GAN hybrid network
CN114399081A (en) * 2021-12-14 2022-04-26 国网浙江省电力有限公司金华供电公司 Photovoltaic power generation power prediction method based on weather classification
CN115829105A (en) * 2022-11-24 2023-03-21 三峡大学 Photovoltaic power prediction method based on historical data feature search
CN115952906A (en) * 2022-12-29 2023-04-11 特变电工新疆新能源股份有限公司 Short-term photovoltaic power prediction method, system, equipment and medium based on LSGAN-GRU
CN116402203A (en) * 2023-03-23 2023-07-07 中国电力科学研究院有限公司 Method, system and medium for predicting short-time photovoltaic power generation capacity considering weather conditions

Also Published As

Publication number Publication date
CN117200199B (en) 2024-04-02

Similar Documents

Publication Publication Date Title
US20220373984A1 (en) Hybrid photovoltaic power prediction method and system based on multi-source data fusion
Zhang et al. Forecast of solar energy production-A deep learning approach
CN111079980B (en) Optical power prediction method based on self-adaptive classification strategy and hybrid optimization SVR
CN109165774A (en) A kind of short-term photovoltaic power prediction technique
JP6693330B2 (en) Solar power system operation
CN115049171B (en) Photovoltaic power prediction method and system based on feature migration
CN110766134A (en) Photovoltaic power station short-term power prediction method based on cyclic neural network
CN112418346B (en) Numerical weather forecast total radiation system error classification calculation method
CN116128150B (en) Photovoltaic intelligent output prediction method based on two-stage optimization
CN112070311A (en) Day-ahead light power prediction method based on similar day clustering and meteorological factor weighting
CN111242355A (en) Photovoltaic probability prediction method and system based on Bayesian neural network
CN115759389A (en) Day-ahead photovoltaic power prediction method based on weather type similar day combination strategy
CN116029419A (en) Deep learning-based long-term new energy daily average generation power prediction method and system
CN115912502A (en) Intelligent power grid operation optimization method and device
Kim et al. Solar radiation forecasting based on the hybrid CNN-CatBoost model
Salamalikis et al. Site adaptation of global horizontal irradiance from the Copernicus Atmospheric Monitoring Service for radiation using supervised machine learning techniques
CN113920349A (en) Wind and light typical scene construction method containing meteorological data based on density peak value-FCM
CN117200199B (en) Photovoltaic power prediction method and system based on weather typing
CN117175569B (en) Photovoltaic prediction method and system based on refined weather typing
CN116029440A (en) Ultra-short-term power prediction method and device for photovoltaic power station
CN116881743B (en) Meteorological turning weather identification method and system for photovoltaic power prediction
CN117200200A (en) Training method of photovoltaic power prediction model
CN115238967A (en) Photovoltaic power prediction method and device combining cloud picture and adjacent power station cluster
Aupke et al. Impact of clustering methods on machine learning-based solar power prediction models
Ma et al. Anomaly Detection of Mountain Photovoltaic Power Plant Based on Spectral Clustering

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant