Day-ahead electricity price probability prediction method and device based on deep learning
Through deep learning-based methods, using meteorological states and generator data to predict electricity prices, the problems of difficult prediction of electricity prices in the existing technology are solved, and more accurate and transparent electricity price prediction is achieved, which is a participant in the power market. Provides better decision support.
Patent Information
- Application Number
- CN202411532595.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-30
- Publication Date
- 2025-02-14
AI Technical Summary
The prior art is difficult to accurately predict the fluctuation range and uncertainty of electricity prices, resulting in a lack of sufficient information for power market participants in decision-making.
Using a deep learning-based method, we can build predictive parameters by obtaining meteorological state data and generator power generation data, and train using deep neural network (DDNN), and add hyperparameter optimization to improve the performance of the prediction model, and finally obtain the electricity price recently. Probability prediction results.
Improved the accuracy and transparency of electricity price forecasts, providing electricity market participants with more comprehensive forecast information, helping them better manage risks and formulate strategies.
Smart Images

Figure CN119444281A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of day-ahead electricity price prediction, and in particular relates to a method and device for predicting day-ahead electricity price probability based on deep learning. Background Art
[0002] In order to promote the liberalization and competition of the electricity market, more and more countries and regions around the world have begun to implement electricity market reforms, gradually introduce market mechanisms and competition mechanisms, and encourage the development of new energy and private investment. These reform measures are aimed at promoting the efficient allocation of resources, improving the quality and reliability of electricity supply, and providing consumers with better choices and services.
[0003] Internationally, the power markets of many countries have undergone a transformation from planned markets to competitive markets and introduced power financial derivatives, which have increased the flexibility and efficiency of the market. In these countries, power market transactions have become an active area, and various power market participants can conduct operations such as power purchase, sale and hedging through trading platforms.
[0004] Electricity prices are a concentrated reflection of the supply and demand relationship in the electricity market. At the same time, electricity prices, as an important basis for market supervision and electricity trading decisions, have become a key information indicator in the electricity market.
[0005] Generally speaking, transactions and relationships in the electricity market are based on electricity prices. Accurate prediction of electricity prices is crucial to every market participant, and in-depth research on electricity price prediction is particularly critical. Summary of the invention
[0006] In order to solve the problems existing in the prior art, the purpose of the present invention is to provide a method and device for predicting the probability of day-ahead electricity prices based on deep learning. This method can not only provide the possible fluctuation range of the predicted value, but also reflect the uncertainty level of the predicted results, thereby improving the prediction accuracy.
[0007] To achieve the above objectives, the present invention provides a first objective of a method for predicting the probability of day-ahead electricity prices based on deep learning, comprising: Obtain the meteorological status data and generator power generation data of the area to be predicted, and construct prediction parameters; The prediction parameters are input into a pre-trained day-ahead electricity price probability prediction model for prediction to obtain the day-ahead electricity price probability; wherein the training method of the pre-trained day-ahead electricity price probability prediction model comprises: Collect regional meteorological data and generator power generation data to build a historical data set; Performing visual analysis and data preprocessing on the historical data set to obtain a prediction feature parameter set; Based on the prediction feature parameter set as input, the deep neural network DDNN is used as the basic model for training. Hyperparameter optimization is added during the training process, and the output probability distribution parameters are used to perform probability prediction of the day-ahead electricity price; a pre-trained day-ahead electricity price probability prediction model is obtained.
[0008] As a further improvement of the present invention, the meteorological status data of the region and the power generation data of the generator are collected to construct a historical data set; specifically, the following includes: A dataset of regional hourly day-ahead electricity prices, day-ahead load forecasts, day-ahead renewable energy forecasts, emission quota prices, and various fuel prices; 70% of the data is used as a training set, 20% of the data is used as a validation set, and the rest of the data is used as a test set.
[0009] As a further improvement of the present invention, the method for performing visual analysis and data preprocessing on the historical data set is: Hurst analysis method, DFA analysis method or Porter-Hudak method.
[0010] As a further improvement of the present invention, the deep neural network DDNN has The probability output layer in the deep neural network DDNN is composed of probability distributions. If it is a discrete problem, use binomial or Poisson distribution. If it is a continuous problem, the output variables are all positive, and use gamma or beta distribution. If the output variables are both positive and negative, use normal distribution, distribution or JSU distribution.
[0011] As a further improvement of the present invention, hyperparameter optimization is added during the training process, and the output probability distribution parameters are used to perform probability prediction on the day-ahead electricity price; a pre-trained day-ahead electricity price probability prediction model is obtained, including: Based on the prediction characteristic parameters, the best hyperparameter combination is selected according to the performance index, and the results of the search process are analyzed to understand the impact of different hyperparameters on the model performance; the model is retrained on the complete training data using the selected hyperparameter combination, and its performance is evaluated on the test set; and the final pre-trained day-ahead electricity price probability prediction model is obtained.
[0012] As a further improvement of the present invention, the prediction feature parameter set is used as input and the deep neural network DDNN is used as the basic model for training, including: In the Predict the day-ahead price for the next day, ; Includes the following input features: The day-ahead price three days ago and one week ago, ; No. The day-ahead forecast of the total load for the day, , as well as historical values from the previous day and week ago, and ; No. Day-ahead forecast of renewable energy RES, , and the historical value of the previous day, ; The latest closing price of EUA emission allowances, ; The latest closing price of fuel, and ; Weekday dummy variable .
[0013] As a further improvement of the present invention, hyperparameter optimization is added to the training process, including: In hyperparameter optimization, the groups of input variables are subjected to feature selection; the following inputs are considered in total: corresponding to each group inputs, corresponding to a single variable , , , and , perform hyperparameter optimization on the neural network model, including: Select input features. Since there are many input variables, the input variables with greater impact on electricity prices are determined through hyperparameter optimization; Determine whether to use the dropout layer after the input layer. If used, the ratio parameter is extracted from the interval [0,1]. If there is no dropout layer in the model, the ratio is not optimized. There are at most two hyperparameters per layer. The number of neurons in the hidden layer, whose value is selected from integers in the interval [16, 1024], with 1 hyperparameter per layer; The activation function used in each hidden layer, 1 hyperparameter per layer; L1 regularization of hidden layers, determines whether to use L1 regularization on hidden layers and their weights. If used, the ratio is in logarithmic scale. Extraction within the interval, with a maximum of 2 hyperparameters per layer; L1 regularization of the distribution layer, used for P distribution parameters, where P=2 is suitable for normal distribution and P=4 is suitable for JSU distribution. Whether to use L1 regularization, if used, determine the ratio, a total of 2P hyperparameters; The learning rate of the Adam algorithm is scaled from Select within the interval and add 1 hyperparameter.
[0014] As a further improvement of the present invention, the method of hyperparameter optimization includes: grid search, random search, genetic algorithm or Bayesian optimization.
[0015] As a further improvement of the present invention, after obtaining the pre-trained day-ahead electricity price probability prediction model, it also includes comparing it with the existing prediction methods, and the comparison methods include: mean absolute error, mean square error, root mean square error, quantile prediction, clarity method or continuous sorting probability score method.
[0016] In a second aspect, the present invention provides a device for predicting the probability of a day-ahead electricity price based on deep learning, comprising: The acquisition module is used to obtain the meteorological status data and the power generation data of the generator in the area to be predicted and construct the prediction parameters; The prediction module is used to input the prediction parameters into the pre-trained day-ahead electricity price probability prediction model for prediction to obtain the day-ahead electricity price probability; wherein the training method of the pre-trained day-ahead electricity price probability prediction model includes: Collect regional meteorological data and generator power generation data to build a historical data set; Performing visual analysis and data preprocessing on the historical data set to obtain a prediction feature parameter set; Based on the prediction feature parameter set as input, the deep neural network DDNN is used as the basic model for training. Hyperparameter optimization is added during the training process, and the output probability distribution parameters are used to perform probability prediction of the day-ahead electricity price; a pre-trained day-ahead electricity price probability prediction model is obtained.
[0017] The beneficial effects of the present invention are: The prediction framework developed by the present invention has the ability to generate traditional deterministic prediction results and can additionally provide innovative probabilistic prediction information. The combination of these two prediction results provides a comprehensive prediction information system for the field of day-ahead electricity price prediction, greatly enhancing the flexibility of choice when facing diverse decision-making problems. Compared with the deterministic prediction method that can only output a single-point prediction result, the proposed probabilistic prediction method can output a prediction interval, depicting a richer and more detailed future scenario for decision makers. Such an interval prediction can not only provide the possible fluctuation range of the predicted value, but also reflect the uncertainty level of the prediction result, thereby providing a more solid foundation for risk assessment and management. In addition, through the probabilistic prediction method, decision makers can more accurately identify and quantify potential risks, so as to make more information-based and risk-controlled decisions when planning resource allocation and formulating strategies. Furthermore, the introduction of probabilistic prediction also promotes the transparency of the power market and provides market participants with more information to formulate pricing strategies and hedge risks. BRIEF DESCRIPTION OF THE DRAWINGS
[0018] Figure 1 It is a schematic diagram of the process of the method for predicting the probability of day-ahead electricity prices based on deep learning according to the present invention; Figure 2 The network structures and differences between DNN and DDNN; (a) is the DNN network structure; (b) is the DDNN network structure; Figure 3 The probability density prediction results of electricity prices; (a) is the curve at 3 o'clock; (b) is the curve at 12 o'clock; Figure 4 The probability prediction results with different confidence intervals for four hyperparameter optimizations are averaged; Figure 5 The results of some existing prediction methods Figure 6 The present invention provides a device for predicting the probability of day-ahead electricity prices based on deep learning.
[0019] The present invention is further described in detail below in conjunction with the accompanying drawings. DETAILED DESCRIPTION
[0020] In order to enable those skilled in the art to better understand the technical solutions in the present invention, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of the present invention.
[0021] like Figure 1 As shown, the present invention provides a method for predicting the probability of day-ahead electricity prices based on deep learning, comprising the following steps: S1, obtain the meteorological status data and generator power generation data of the area to be predicted, and construct the prediction parameters; S2, inputting the prediction parameters into a pre-trained day-ahead electricity price probability prediction model for prediction to obtain the day-ahead electricity price probability; wherein the training method of the pre-trained day-ahead electricity price probability prediction model comprises: S3, collects regional meteorological data and generator power generation data to build a historical data set; S4, performing visual analysis and data preprocessing on the historical data set to obtain a prediction feature parameter set; S5, based on the prediction feature parameter set as input, the deep neural network DDNN is used as the basic model for training, hyperparameter optimization is added during the training process, and the output probability distribution parameters are used to perform probability prediction of the day-ahead electricity price; a pre-trained day-ahead electricity price probability prediction model is obtained.
[0022] The present invention constructs a historical data set by collecting regional meteorological status data and generator power generation data; preprocesses and visualizes the collected data to improve the quality and reliability of the data; uses the DDNN deep neural network to perform probabilistic prediction of the day-ahead electricity price; compares it with the existing prediction methods, and evaluates and compares the advantages and disadvantages of the newly proposed probabilistic prediction method.
[0023] The method for predicting the day-ahead electricity price probability based on deep learning proposed in the present invention aims to improve the accuracy of electricity price prediction and provide users with valuable electricity price prediction information through a series of carefully designed steps. The method first collects meteorological status data and generator power generation data of the area to be predicted, which are crucial for electricity price prediction. Meteorological status (such as temperature, humidity, wind speed, etc.) directly affects electricity demand, while generator power generation reflects the power supply situation. By comprehensively considering these factors, the prediction model can capture the law of electricity price fluctuations more comprehensively. The method adopts deep neural network (DDNN) as the basis of the prediction model. Deep learning has significant advantages in processing complex and nonlinear relationships and can more effectively mine potential information in data. By training the DDNN model, accurate prediction of day-ahead electricity prices can be achieved, and the reliability and accuracy of the prediction can be improved. Compared with traditional point prediction, this method provides a probabilistic prediction of electricity prices. Probabilistic prediction can reflect the uncertainty of electricity prices and provide users with richer information. This helps users to better manage risks, such as reducing electricity consumption when electricity prices are high or increasing electricity storage when electricity prices are low.
[0024] During the training process, the method adds a hyperparameter optimization step. Hyperparameter optimization can automatically adjust model parameters to improve the model's predictive performance. This not only reduces the workload of manual parameter adjustment, but also improves the generalization ability and stability of the model. Before building the prediction feature parameter set, the method performs visual analysis and data preprocessing on the historical data set. Visual analysis helps to find outliers and trends in the data, while data preprocessing ensures the quality and consistency of the input data. These steps are crucial to improving the accuracy and reliability of the prediction model.
[0025] The day-ahead electricity price probability prediction method based on deep learning proposed in the present invention has the advantages of data-driven, deep learning, probability prediction, hyperparameter optimization, visualization analysis and data preprocessing, adaptability and scalability, etc. These advantages make this method have broad application prospects and important practical value in the field of electricity price prediction.
[0026] The following will be combined with the attached Figure 1 The present invention is further described. However, the content of the present invention is not limited to this.
[0027] Step 1: When applying the model proposed in the present invention, it is first necessary to collect regional meteorological status data and generator power generation data.
[0028] Construct a dataset containing hourly regional day-ahead (DA) electricity prices, day-ahead load forecasts, day-ahead renewable energy (RES) forecasts, EU emission quota prices, and prices of various fuels (coal, oil, and natural gas). Seventy percent of the data is used as a training set, twenty percent as a validation set, and the rest as a test set. Common data are used for input features and prediction targets.
[0029] The electricity market consists of derivatives, spot, and balancing parts [2]. The most important of these is the spot market, especially the day-ahead auction. It is held once a day at noon, and all products for the next day are traded in a uniform price auction, usually S=24. Since all times of the next day are traded simultaneously, all times are based on the same set of information. In this project study, all prices are modeled using exactly the same input features.
[0030] Step 2: Preprocess and visualize the collected data to improve the quality and reliability of the data.
[0031] The key result of the Hurst analysis is the Hurst index H, which is a measure of the long-term memory of a time series. The Hurst index can indicate whether a time series tends to strongly regress to the mean (anti-persistence), follow a trend (persistence), or follow a random walk (no clear long-term trend). If , the sequence exhibits anti-persistence, so it exhibits stronger fluctuations than pure randomness; if , the sequence behaves like a random walk. In physics, this is called Brownian motion; if , the sequence exhibits long memory, and future values will tend to follow the trends set by past values.
[0032] Hurst analysis is mainly done by using the rescaled range (R / S) method to calculate the Hurst exponent. The following are the general steps for performing Hurst analysis: Choosing time series and subsequence length: First, you need to have a time series dataset, and then decide how long to divide the sequence into subsequences. Usually, this length starts from a smaller value and gradually increases.
[0033] Split time series: Split the entire time series into multiple non-overlapping subsequences of length n. If the length N of the time series is not divisible by n, then the last subsequence may be shorter than the previous subsequence.
[0034] Calculate the mean and standard deviation of each subsequence: For each subsequence , calculate its mean and standard deviation .
[0035] Normalize the data and create a cumulative deviation sequence: For each subsequence Each data point in , calculate the normalized value ,Right now , then create a cumulative deviation series .
[0036] Calculation range: For each subsequence , calculate the range of its cumulative deviation sequence ,Right now
[0037] Calculate the rescaled range: For each subsequence , calculate the rescaled range, that is .
[0038] Repeat the above steps for subsequences of different lengths: Repeat steps 1 to 6 for a range of different subsequence lengths.
[0039] Calculate the Hurst index: For each subsequence length, calculate and The slope of the Hurst index If it is close to 0.5, it indicates that the time series is a random walk; if If it is greater than 0.5, it indicates that the time series is persistent; Less than 0.5 indicates that the time series has anti-persistence.
[0040] DFA (Detrended Fluctuation Analysis) is a statistical method for detecting long-range correlation in time series data. Long-range correlation refers to the correlation between data points that are far apart in the time series. DFA can help determine whether a time series has fractal properties and can be used to distinguish different types of non-stationarity. The steps for performing DFA analysis on data are as follows: Divide the time series into subsequences: Given a length of time series, dividing it into subsequences, each of which has a length of ,in (For simplicity, assume Can be divisible by integer).
[0041] Create cumulative time series: For each subseries , creating a cumulative time series by adding the returns in the subsequences to each point.
[0042] Fit Least Squares Line: For each cumulative time series, fit a least squares line To data point .
[0043] Calculate the RMS volatility: For each subsequence , calculates the root mean square fluctuation (RMSF) of the integrated and detrended time series, i.e. the standard deviation of the residuals of the fitted line.
[0044] Calculate the average of the RMS fluctuations: Finally, calculate all the lengths of The average RMSF of the subsequences.
[0045] The Porter-Hudak (GPH) method is a method for estimating the autocorrelation coefficient in long memory processes. Long memory processes, such as fractionally differencing noise processes, are important in time series analysis because they exhibit long-range dependencies. The GPH method is particularly suitable for estimating the fractional difference parameters in the fractional difference autoregressive moving average (ARFIMA) model.
[0046] In the Geweke and Porter-Hudak (GPH) method, the estimation process begins by computing the periodogram, which is the sample counterpart of the spectral density. , the periodogram is defined as: (1) In the formula , Indicates less than or equal to The largest integer of ; is at frequency The complex exponential part of the Fourier transform at is the time series Observations, is the length of the time series. Periodogram is the frequency The power estimate at , which represents the intensity of the frequency component in the time series.
[0047] Bandwidth parameters It is crucial in GPH regression because it determines the number of low-frequency components used in the estimation process. The choice of affects the trade-off between the bias and variance of the estimator. This may lead to a larger variance in the estimator (i.e., more unstable), while a larger Bias may be introduced, especially if high-frequency components do not fit the assumed model.
[0048] symbol Indicates that The result is rounded to the nearest integer, where is the length of the time series. Geweke and Porter-Hudak and some other researchers recommend choosing Proportional to the square root of the length of the time series, a rule of thumb that balances the bias-variance tradeoff for many practical situations. However, There is no fixed best choice. Some researchers suggest using different values, such as Or a range in arrive Choose between Depends on the specific characteristics of the data and the goals of the analysis.
[0049] Next, the last step is to Perform a simple linear regression at: (2) Here, is the slope in the regression equation, which is the difference parameter The estimated value of .
[0050] In this regression equation, is the frequency The function of The GPH method assumes that at low frequencies, the spectral density of the time series exhibits a power law form, that is, the spectral density function is negative twice the frequency near zero frequency. By estimating this slope, the application can estimate the differential parameter , and then the Hurst index can be calculated .
[0051] Step 3: Use the DDNN deep neural network to make a probabilistic prediction of the day-ahead electricity price.
[0052] A deep neural network (DNN) is an artificial neural network composed of multiple layers of neurons. These neurons are computational units that process information by simulating the way the human brain works. DDNN can be considered a form of DNN, specifically referring to networks that use distributed computing resources or output probability distributions. In any case, DDNN is built on the basic principles of DNN and uses the architecture and technology of deep learning to achieve its specific application goals. The model used in this invention has This setting is used in subsequent DNN and DDNN models.
[0053] In the model of the present invention, multivariate outputs consisting of multiple features and possible probability distributions are discussed. For DNN, the output is the electricity price for the next day; for DDNN, the output is the parameter values of different distributions. This is feasible for electricity price prediction because all next-day electricity prices are announced at one time, so they can share the input set, but this is usually not the case in other applications. The probability output layer can be composed of almost any realized probability distribution. If you are dealing with a discrete problem, you can choose a binomial or Poisson distribution; if you are dealing with a continuous problem, the output variables are all positive, and you can choose a gamma or beta distribution; if the output variables are both positive and negative, you can choose a normal distribution, Distribution or JSU distribution. Since electricity prices can be positive or negative, a two-parameter normal distribution and a four-parameter JSU distribution are used in this project.
[0054] In the The day-ahead price forecast for the next day is For all considered models, the following 221 input features are available: The day-ahead price three days ago and one week ago, i.e. .
[0055] No. The day-ahead forecast of the total load for the day is , as well as the historical values from the previous day and week ago, i.e. and .
[0056] No. The day-ahead forecast of renewable energy (RES) is , and the historical value of the previous day, that is, .
[0057] The latest closing price of EUA, i.e. .
[0058] The latest closing price of the fuel, i.e. and .
[0059] Weekday dummy variable .
[0060] Both neural network and models automatically select relevant input features. For neural network models, feature selection is performed for groups of input variables during the hyperparameter optimization step. A total of 14 groups of inputs were considered: 9 corresponding to each group inputs, and the remaining 5 groups correspond to single variables , , , and .
[0061] The best hyperparameter combination is selected based on the performance indicators, and the results of the search process are analyzed to understand the impact of different hyperparameters on model performance. Finally, the model is retrained on the complete training data using the selected hyperparameter combination, and its performance is evaluated on the test set to ensure the generalization ability of the model.
[0062] Hyperparameter optimization is a computationally intensive process, especially when the model is complex, the dataset is large, or the hyperparameter space is extensive. Considering the time and computational costs, this project performs hyperparameter optimization on the following hyperparameters and their potential values for neural network models (both point-like and distributed): First, the input features are selected. Since there are many input variables, the input variables that have a greater impact on electricity prices can be determined through hyperparameter optimization. There are a total of 14 hyperparameters.
[0063] Whether to use a dropout layer after the input layer, and if so, what is its ratio. The ratio parameter is drawn from the interval [0,1]. If there is no dropout layer in the model, the ratio is not optimized. There are at most two hyperparameters per layer.
[0064] The number of neurons in the hidden layer, whose value is selected from integers in the interval [16, 1024], with 1 hyperparameter per layer.
[0065] The activation function used by each hidden layer. Possible functions are: elu, relu, sigmoid, softmax, softplus and tanh, with 1 hyperparameter per layer.
[0066] L1 regularization of hidden layers, whether to use L1 regularization on hidden layers and their weights, if so, what is the ratio, and the ratio is in logarithmic scale Extraction within the interval, with a maximum of 2 hyperparameters per layer.
[0067] The L1 regularization of the distribution layer is used for P distribution parameters, where P=2 is suitable for normal distribution and P=4 is suitable for JSU distribution. Whether to use L1 regularization and, if so, what is its ratio? There are a total of 2P hyperparameters.
[0068] The learning rate of the Adam algorithm is scaled from Select within the interval and add 1 hyperparameter.
[0069] After determining the network structure in the optimization process, it is necessary to determine the method for hyperparameter optimization. Currently, the commonly used hyperparameter optimization methods include grid search, random search, genetic algorithm, and Bayesian optimization.
[0070] Step 4: Compare with existing prediction methods to evaluate and compare the advantages and disadvantages of the newly proposed probability prediction method.
[0071] The mean absolute error (MAE) is the average of the absolute values of the differences between the actual observed values and the predicted values. It provides an average measure of the size of the prediction errors.
[0072] (3) As a metric for evaluating the performance of a forecasting model, the mean absolute error (MAE) is always non-negative and can intuitively quantify the size of the forecast error. When MAE is 0, it means that the model's prediction is perfect. A notable feature of MAE is that it weights errors of all sizes equally and does not change with the size of the error. This feature makes MAE an easy-to-interpret and understand metric. At the same time, MAE shows relatively low sensitivity when dealing with outliers. This is because it does not give heavier penalties to larger errors like the mean square error (MSE), thus providing a more robust error assessment when outliers are present in the data.
[0073] The mean squared error (MSE) is the average of the squares of the differences between the actual observed values and the predicted values. It penalizes large errors and therefore pays more attention to outliers in the data.
[0074] (4) The mean squared error (MSE) is another measure of forecast accuracy that is also non-negative, and when the MSE drops to 0, it indicates that the forecast has achieved perfect accuracy. MSE is calculated by squaring the forecast error, which results in amplifying the weight of larger errors, making the model more sensitive to these large forecast deviations. Because of this, MSE is particularly sensitive to outliers when processing data, as these values will have a significant impact on the MSE due to squaring. However, since the dimension of MSE is the square of the dimension of the original data, it may not be as intuitive as MAE, because the dimension of MAE is consistent with the original data and is easier to understand and interpret.
[0075] The root mean square error (RMSE) is the square root of the MSE. It is the square root of the average of the squares of the differences between the actual observed values and the predicted values, providing the error magnitude on the same dimension as the original data.
[0076] (5) The root mean square error (RMSE) is a common indicator for measuring the accuracy of predictions. Its value will never be negative, and when RMSE is equal to 0, it means that the prediction is completely accurate. In the calculation process, RMSE first squares the error, then calculates the average, and finally takes the square root, so it also has a higher weight for larger errors, but because the square root is finally taken, its dimension is the same as that of the original data, making the result easier to understand. Compared with MSE, RMSE has a reduced penalty for large errors, but compared with MAE, this penalty is still larger. Because RMSE can provide an average standard for errors, it is widely used in the performance evaluation of various forecasting models.
[0077] Quantile Forecast Aims to determine a threshold value so that the true value of the random variable has Assessing the reliability of these forecasts involves comparing forecasts to actual observations, performing calibrations to ensure matching of long-term frequencies, testing the kurtosis of the forecast distribution to assess its concentration, using the probability integral transform (PIT) to verify the correctness of the forecast distribution, calculating the continuous rank probability score (CRPS) to comprehensively evaluate the quality of the forecast, and visually demonstrating the agreement between the forecast and observations through graphical analysis such as quantile-quantile (QQ) plots.
[0078] Although statistical tests indicate the reliability of the forecasts, the accuracy of each individual forecast remains uncertain because probabilistic forecasts inherently incorporate uncertainty.
[0079] Sharpness is an important concept in probabilistic forecast evaluation, which describes the degree of concentration of the forecast distribution. A forecast with high sharpness indicates that the uncertainty of the forecast result is small and the forecast values are concentrated in a narrow range. This is beneficial for decision makers because it reduces the range of uncertainty that needs to be considered when making decisions.
[0080] In probabilistic forecasting, assessing the clarity of a forecast involves a variety of methods, including: observing the width of the forecast interval, where a narrower interval means higher clarity; calculating the variance or standard deviation of the distribution, where a smaller value indicates a more concentrated distribution and higher clarity; analyzing the cumulative probability around the median of the distribution, where a higher concentration indicates higher clarity; examining the kurtosis of the probability density function, where a sharp peak indicates a high forecast concentration; and using graphical methods, such as drawing PDF or CDF graphs, to intuitively display the degree of concentration of the forecast distribution. Together, these methods help assess the certainty of forecast results and provide a clearer basis for decision making.
[0081] In real applications, there may be a trade-off between clarity and reliability. For example, a forecaster may provide a very narrow prediction interval (high clarity), but if this interval does not frequently contain the true value, then the forecast is unreliable.
[0082] The Continuous Ranked Probability Score (CRPS) is a metric used to evaluate the quality of probabilistic forecasts. It is essentially a generalization of the mean absolute error of probabilistic forecasts, taking into account the entire probability distribution rather than just a single point estimate. Its specific definition is as follows: (6) (7) in represents the quantile prediction result with nominal probability q, Represents the real power of renewable energy generation. Similar to RMSE, the lower the quantile score QS, the higher the quality of probability prediction.
[0083] Application Examples The data used in the embodiment is a public data set, which contains hourly observations of electricity prices in a certain area for six years from January 1, 2015 to December 31, 2020. The data from January 1, 2015 to January 1, 2018 is the training set, the data from January 1, 2018 to January 1, 2019 is the validation set, and the rest is the test set.
[0084] See also Figure 2 For the test object, the model used is The number of neurons in the hidden layer is arbitrary, but in order to highlight the difference between point networks and probabilistic networks, the number of neurons in the hidden layer of the two DNNs is the same. For both DNNs, the input layer and hidden layer are the same, and only the output part is different.
[0085] After determining the structure, the hyperparameters of the dataset were optimized, which included 2048 iterations of the optimization algorithm, which were performed in a hybrid batch rolling manner. The dataset has 1456 days of data. This project divides the first 1092 days into training data and the last 364 days into validation data.
[0086] After determining the model input and network parameters, we can get the output parameters gamma, delta, loc, and scale at 2019-01-11-03:00, which are 0.566, 3.314, 40.864, and 9.431 respectively. The gamma parameter affects the skewness of the distribution; the delta parameter is related to the peak degree of the distribution; the location parameter loc determines the center or location of the distribution; and the scale parameter scale affects the degree of diffusion of the distribution or the standard deviation of the distribution. After determining the parameters, we can get the probability density function of the day-ahead electricity price, see Figure 3 , the two vertical dashed lines in the figure draw the 90% prediction interval.
[0087] Finally, the probability density prediction results are converted into interval prediction results with different confidence levels, where the confidence intervals are 10%~90%, see Figure 4 This approach not only depicts the possible range of electricity price fluctuations, but also quantifies the characteristics of its random fluctuations. Such forecasts can provide valuable information to grid operators, allowing them to foresee and prepare in advance for significant fluctuations in electricity prices that may occur on the day before, thereby enhancing the stability and reliability of the grid.
[0088] DNN point prediction results are compared with seasonal naive prediction methods, exponential smoothing state space models, and autoregressive models. Figure 5 By comparing with the point prediction method of DNN, we can see that there is a large difference between several basic prediction methods and the true value. This is because these existing methods only use electricity price data, do not introduce exogenous variables, and the model is not complex enough.
[0089] Therefore, a method for predicting the probability of day-ahead electricity prices based on deep learning of the present invention includes collecting regional meteorological status data and generator power generation data to construct a historical data set; performing visual analysis and data preprocessing on the historical data set to understand the trend, periodicity and seasonality of the data, identify the noise, missing values and outliers in the data, and improve the quality and reliability of the data; after adding hyperparameter optimization, a deep neural network (DDNN) with output probability distribution parameters is used to predict the day-ahead electricity price probabilistically. Compared with the existing prediction methods, the advantages and disadvantages of the newly proposed probability prediction methods are evaluated and compared. The present invention can provide a possible fluctuation range of the predicted value, reflecting the uncertainty level of the prediction result, and providing more sufficient information and basis for the planning, prediction, operation and other decisions of the power system.
[0090] In a second aspect, the present invention provides a device for predicting the probability of a day-ahead electricity price based on deep learning, comprising: The acquisition module is used to obtain the meteorological status data and the power generation data of the generator in the area to be predicted and construct the prediction parameters; The prediction module is used to input the prediction parameters into the pre-trained day-ahead electricity price probability prediction model for prediction to obtain the day-ahead electricity price probability; wherein the training method of the pre-trained day-ahead electricity price probability prediction model includes: Collect regional meteorological data and generator power generation data to build a historical data set; Performing visual analysis and data preprocessing on the historical data set to obtain a prediction feature parameter set; Based on the prediction feature parameter set as input, the deep neural network DDNN is used as the basic model for training. Hyperparameter optimization is added during the training process, and the output probability distribution parameters are used to perform probability prediction of the day-ahead electricity price; a pre-trained day-ahead electricity price probability prediction model is obtained.
[0091] Specifically, Figure 6 As shown, including: The data collection module collects regional meteorological data and generator power generation data to build a historical data set; Data preprocessing module, which performs preprocessing and visual analysis on the collected data to improve the quality and reliability of the data; Hyperparameter optimization and probability prediction module, using DDNN deep neural network to make probability prediction of day-ahead electricity price; The prediction method evaluation module compares the existing prediction methods and evaluates and compares the advantages and disadvantages of the newly proposed probability prediction method.
[0092] The third aspect of the present invention is to provide an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements a method for generating a new energy power generation scenario that takes into account temporal and spatial correlation when executing the computer program.
[0093] A fourth aspect of the present invention is to provide a computer-readable storage medium, which stores a computer program. When the computer program is executed by a processor, a method for generating a new energy power generation scenario that takes into account time and space correlation is implemented.
[0094] The above contents are only for explaining the technical idea of the present invention and cannot be used to limit the protection scope of the present invention. Any changes made on the basis of the technical solution in accordance with the technical idea proposed by the present invention shall fall within the protection scope of the claims of the present invention.
[0095] It will be appreciated by those skilled in the art that embodiments of the present invention may be provided as methods, systems, or computer program products. Therefore, the present invention may take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Furthermore, the present invention may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0096] The present invention is described with reference to flowcharts and / or block diagrams of methods, devices (systems), and computer program products according to embodiments of the present invention. It should be understood that each process and / or block in the flowchart and / or block diagram, as well as the combination of processes and / or blocks in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0097] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.
[0098] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.
[0099] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention rather than to limit it. Although the present invention has been described in detail with reference to the above embodiments, ordinary technicians in the relevant field should understand that the specific implementation methods of the present invention can still be modified or replaced by equivalents. Any modification or equivalent replacement that does not depart from the spirit and scope of the present invention should be covered within the scope of protection of the claims of the present invention.
Claims
1. A method for predicting the probability of day-ahead electricity prices based on deep learning, characterized in that: include: Obtain the meteorological status data and generator power generation data of the area to be predicted, and construct prediction parameters; The prediction parameters are input into a pre-trained day-ahead electricity price probability prediction model for prediction to obtain the day-ahead electricity price probability; wherein the training method of the pre-trained day-ahead electricity price probability prediction model comprises: Collect regional meteorological data and generator power generation data to build a historical data set; Performing visual analysis and data preprocessing on the historical data set to obtain a prediction feature parameter set; Based on the prediction feature parameter set as input, the deep neural network DDNN is used as the basic model for training. Hyperparameter optimization is added during the training process, and the output probability distribution parameters are used to perform probability prediction of the day-ahead electricity price; a pre-trained day-ahead electricity price probability prediction model is obtained.
2. The method for predicting the day-ahead electricity price probability based on deep learning according to claim 1, characterized in that: Collect regional meteorological data and generator power generation data to build a historical data set; specifically include: A dataset of regional hourly day-ahead electricity prices, day-ahead load forecasts, day-ahead renewable energy forecasts, emission quota prices, and various fuel prices; 70% of the data is used as a training set, 20% of the data is used as a validation set, and the rest of the data is used as a test set.
3. The method for predicting the day-ahead electricity price probability based on deep learning according to claim 1, characterized in that: The method for performing visual analysis and data preprocessing on the historical data set is: Hurst analysis method, DFA analysis method or Porter-Hudak method.
4. The method for predicting the day-ahead electricity price probability based on deep learning according to claim 1, characterized in that: The deep neural network DDNN has The probability output layer in the deep neural network DDNN is composed of probability distributions. If it is a discrete problem, use binomial or Poisson distribution. If it is a continuous problem, the output variables are all positive, and use gamma or beta distribution. If the output variables are both positive and negative, use normal distribution, distribution or JSU distribution.
5. The method for predicting the day-ahead electricity price probability based on deep learning according to claim 1, characterized in that: Hyperparameter optimization is added during the training process, and the output probability distribution parameters are used to make probability predictions for day-ahead electricity prices; Get the pre-trained day-ahead electricity price probability prediction model, including: Based on the predicted feature parameters, select the best hyperparameter combination according to the performance index, and analyze the results of the search process to understand the impact of different hyperparameters on model performance; retrain the model on the complete training data using the selected hyperparameter combination, and evaluate its performance on the test set; The final pre-trained day-ahead electricity price probability prediction model is obtained.
6. The method for predicting the day-ahead electricity price probability based on deep learning according to claim 1, characterized in that: The method of training a deep neural network DDNN as a basic model based on a prediction feature parameter set as input includes: In the Predict the day-ahead price for the next day, ; Includes the following input features: The day-ahead price three days ago and one week ago, ; No. The day-ahead forecast of the total load for the day, , as well as historical values from the previous day and week ago, and ; No. Day-ahead forecast of renewable energy RES, , and the historical value of the previous day, ; The latest closing price of EUA emission allowances, ; The latest closing price of fuel, and ; Weekday dummy variable .
7. The method for predicting the day-ahead electricity price probability based on deep learning according to claim 1, characterized in that: Hyperparameter optimization is added during the training process, including: In hyperparameter optimization, the groups of input variables are subjected to feature selection; the following inputs are considered in total: corresponding to each group inputs, corresponding to a single variable , , , and , perform hyperparameter optimization on the neural network model, including: Select input features. Since there are many input variables, the input variables with greater impact on electricity prices are determined through hyperparameter optimization; Determine whether to use the dropout layer after the input layer. If used, the ratio parameter is extracted from the interval [0,1]. If there is no dropout layer in the model, the ratio is not optimized. There are at most two hyperparameters per layer. The number of neurons in the hidden layer, whose value is selected from integers in the interval [16, 1024], with 1 hyperparameter per layer; The activation function used in each hidden layer, 1 hyperparameter per layer; L1 regularization of hidden layers, determines whether to use L1 regularization on hidden layers and their weights. If used, the ratio is in logarithmic scale. Extraction within the interval, with a maximum of 2 hyperparameters per layer; L1 regularization of the distribution layer, used for P distribution parameters, where P=2 is suitable for normal distribution and P=4 is suitable for JSU distribution. Whether to use L1 regularization, if used, determine the ratio, a total of 2P hyperparameters; The learning rate of the Adam algorithm is scaled from Select within the interval and add 1 hyperparameter.
8. The method for predicting the day-ahead electricity price probability based on deep learning according to claim 1, characterized in that: Methods for hyperparameter optimization include: grid search, random search, genetic algorithms, or Bayesian optimization.
9. The method for predicting the day-ahead electricity price probability based on deep learning according to claim 1, characterized in that: After obtaining the pre-trained day-ahead electricity price probability prediction model, the method further includes: comparing with existing prediction methods, and the comparison methods include: mean absolute error, mean square error, root mean square error, quantile prediction, clarity method or continuous sorting probability score method.
10. A device for predicting the probability of day-ahead electricity prices based on deep learning, characterized in that: include: The acquisition module is used to obtain the meteorological status data and the power generation data of the generator in the area to be predicted and construct the prediction parameters; The prediction module is used to input the prediction parameters into the pre-trained day-ahead electricity price probability prediction model for prediction to obtain the day-ahead electricity price probability; wherein the training method of the pre-trained day-ahead electricity price probability prediction model includes: Collect regional meteorological data and generator power generation data to build a historical data set; Performing visual analysis and data preprocessing on the historical data set to obtain a prediction feature parameter set; Based on the prediction feature parameter set as input, the deep neural network DDNN is used as the basic model for training. Hyperparameter optimization is added during the training process, and the output probability distribution parameters are used to perform probability prediction of the day-ahead electricity price; a pre-trained day-ahead electricity price probability prediction model is obtained.
Citation Information
Cited By
Power grid electricity price intelligent prediction method based on multi-model fusion algorithm
CN120069937A