Electricity price prediction method

By constructing timing and non -time -order neural network models, the fusion output for electrical price prediction, solving the problem of poor adaptability and not high predictive accuracy in the electricity market's electricity price forecast in the power market, and achieved higher accuracy of electricity prices.

CN119379322AInactive Publication Date: 2025-01-28BEIJING MW CLOUD DATA TECH CO LTD
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202411338553.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-09-25
Publication Date
2025-01-28
Estimated Expiration
Not applicable · inactive patent

AI Technical Summary

Technical Problem

Existing machine learning models are not adaptable to electricity price prediction in the power market, have low prediction accuracy, and are difficult to deal with complex nonlinear relationships.

Method used

By obtaining historical data that affects electricity prices, the key historical data is screened and divided into time series data and non -time sequence data. The circulating neural network and full connection neural network are constructed, and the electricity price prediction is fixed.

Benefits of technology

The timing relationship and complicated laws of capturing electricity data data more accurately have improved the accuracy and practical application capabilities of electricity prices.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119379322A_ABST
    Figure CN119379322A_ABST
Patent Text Reader

Abstract

The invention discloses an electricity price prediction method, which comprises the steps of obtaining historical data influencing the electricity price, performing data preprocessing, screening key historical data influencing the electricity price, and dividing the key historical data into a training set, a verification set and a test set; establishing a time sequence recurrent neural network, introducing time sequence data in the key historical data, training the time sequence data to obtain a time sequence output tensor, establishing a non-time sequence full-connection neural network, introducing non-time sequence data in the key historical data to train a model, and obtaining a non-time sequence output tensor; a fused full-connection neural network is established, and a time sequence output tensor and a non-time sequence output tensor are introduced and trained; and performing electricity price prediction by using the fused full-connection neural network. According to the method, the time sequence factors and the non-time sequence factors can be combined, the time sequence relation and the complex rule of the data can be better captured, and the electricity price can be predicted more comprehensively and accurately.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of electricity price prediction, and more specifically, to an electricity price prediction method. Background Art

[0002] The stable operation of the electricity market is crucial to the normal operation of the economy and life. The accuracy and real-time performance of electricity price forecasts are helpful for the operation and management of the electricity market. Traditional electricity price forecasting methods mainly include time series analysis and statistical models. However, the electricity market has complex interactions and influencing factors, and does not have the ability to handle complex nonlinear relationships. Machine learning can automatically extract high-order features from data through multi-layer neural networks, thereby more accurately reflecting the laws of electricity price changes. Therefore, machine learning is feasible for electricity price forecasting in the electricity market. How to overcome the defects of the existing machine learning models, such as low adaptability and low prediction accuracy, is the main technical problem studied in this application. Summary of the invention

[0003] The present invention provides an electricity price prediction method, which can combine time series factors and non-time series factors to better capture the time series relationship and complex laws of data and predict electricity prices more comprehensively and accurately.

[0004] In order to achieve these purposes and other advantages according to the present invention, a method for predicting electricity prices is provided, comprising: Obtain historical data that affects electricity prices and perform data preprocessing. By analyzing the correlation coefficient between historical data and historical electricity prices, screen key historical data that affects electricity prices and divide the key historical data into training sets, validation sets, and test sets. Establish a time-series recurrent neural network, input the time-series data in the key historical data and train it, obtain the time-series output tensor, establish a non-time-series fully connected neural network, input the non-time-series data in the key historical data to train the model, and obtain the non-time-series output tensor; Establish a fused fully connected neural network, input the time series output tensor and the non-time series output tensor for training, calculate the error between the predicted electricity price and the actual electricity price, obtain the model loss, use the back propagation algorithm to continuously optimize the model, and update the node weights of the time series recurrent neural network and the non-time series fully connected neural network; Electricity price forecasting using fused fully connected neural networks.

[0005] Preferably, data preprocessing includes processing of duplicate values, missing values, outliers, as well as normalization and vectorization.

[0006] Preferably, the time series data in the key historical data include power load, power generation, carbon emissions, and historical electricity prices, and the non-time series data in the key historical data include temperature, humidity, and weather type.

[0007] Preferably, the number of hidden layer nodes of the time series recurrent neural network is 3 layers, each layer has 50 nodes, the weight decay coefficient is 0.2, and the minimum error threshold is set to 0.01; The number of hidden layer nodes of the non-temporal fully connected neural network is 2 layers, each layer has 30 nodes, the weight decay coefficient is 0.2, and the minimum error threshold is set to 0.01; The number of hidden layer nodes of the fused fully connected neural network is 1 layer, with 1 node, the weight decay coefficient is 0.2, and the minimum error threshold is set to 0.01.

[0008] An electronic device comprises: at least one processor, and a memory communicatively connected to the at least one processor, wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor executes the described method.

[0009] A storage medium stores a computer program, which, when executed by a processor, implements the method described.

[0010] A computer program product comprises a computer program, wherein when the program is executed by a processor, the method described is implemented.

[0011] The present invention has at least the following beneficial effects: The present invention obtains historical data that affects electricity prices, screens out key historical data that affects electricity prices, divides time series data from non-time series data, and respectively constructs a time series recurrent neural network and a non-time series fully connected neural network to extract time series variables and non-time series variables, so that the fused fully connected neural network can identify the impact of time series variables and non-time series variables on pricing, and has higher prediction accuracy and better practical application capabilities.

[0012] Other advantages, objectives and features of the present invention will be embodied in part through the following description, and in part will be understood by those skilled in the art through study and practice of the present invention. BRIEF DESCRIPTION OF THE DRAWINGS

[0013] Figure 1 It is a structural schematic diagram of a technical solution of the present invention. DETAILED DESCRIPTION

[0014] The present invention is further described in detail below in conjunction with the accompanying drawings so that those skilled in the art can implement the invention with reference to the description.

[0015] It should be understood that the terms such as “having”, “including” and “comprising” used herein do not exclude the existence or addition of one or more other elements or combinations thereof.

[0016] It should be noted that the experimental methods described in the following embodiments are conventional methods unless otherwise specified, and the reagents and materials can be obtained from commercial sources unless otherwise specified; in the description of the present invention, it should be noted that, unless otherwise clearly specified and limited, the terms "installed", "connected", and "set" should be understood in a broad sense, for example, they can be fixedly connected, set, or detachably connected, set, or connected and set in one piece. For ordinary technicians in this field, the specific meanings of the above terms in the present invention can be understood in specific circumstances. The orientation or position relationship indicated by the terms "lateral", "longitudinal", "upper", "lower", "front", "back", "left", "right", "vertical", "horizontal", "top", "bottom", "inside", "outside", etc. is based on the orientation or position relationship shown in the accompanying drawings, which is only for the convenience of describing the present invention and simplifying the description, and does not indicate or imply that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation, and therefore cannot be understood as a limitation of the present invention.

[0017] like Figure 1 As shown, the present invention provides an electricity price prediction method, comprising: Obtain historical data that affects electricity prices and perform data preprocessing. The purpose of data preprocessing is to facilitate the establishment of correlation analysis on historical data. Data preprocessing includes processing of duplicate values, missing values, and abnormal values, as well as normalization and vectorization. Duplicate values ​​are processed by deletion, missing values ​​are processed by filling missing information according to the logical relationship between the previous and next data, abnormal values ​​are processed by outlier detection, and normalization is processed as follows: x’ represents the normalized parameter value, x Indicates the original value of the parameter. x min Indicates the minimum value of the parameter. x max Indicates the maximum value of the parameter. Special data such as weather type can be encoded, for example, sunny, rainy, and snowy days are encoded as 1, 2, and 3 respectively.

[0018] By analyzing the correlation coefficient between historical data and historical electricity prices, we screened the key historical data that affect electricity prices and divided the key historical data into training set, validation set and test set. We used the Pearson coefficient to analyze whether the impact of various factors (historical data) on historical electricity prices exceeded the threshold. The larger the absolute value, the stronger the correlation, and the more obvious the impact on historical electricity prices. If it exceeds the threshold, the factor (historical data) is the key historical data that affects electricity prices. The training set, validation set and test set are divided into 75%, 15% and 10% respectively, which are used for parameter update, hyperparameter adjustment and model performance evaluation.

[0019] Establish a time-series recurrent neural network, pass the time series data in the key historical data into and train it. The number of hidden layer nodes of the time-series recurrent neural network is 3 layers, each layer has 50 nodes, and the weight decay coefficient is 0.2. The time series data in the key historical data include power load, power generation, carbon emissions, and historical electricity prices. Obtain the output tensor of the time series. Establish a non-time-series fully connected neural network, pass the non-time series data in the key historical data into and train it. The number of hidden layer nodes of the non-time-series fully connected neural network is 2 layers, each layer has 30 nodes, and the weight decay coefficient is 0.2. The non-time series data in the key historical data include temperature, humidity, and weather type. Obtain the non-time series output tensor; In a sequential recurrent neural network, at any time t∈(0,1,…,T), the input is x t , the output is y t , the hidden layer h at time t t Based on the input x at time t t And the hidden layer h at time t-1 t-1 The output y at time T is obtained T Based on the hidden layer h at time T T Mapping obtained.

[0020] h t = σ( w 输入-隐藏 x t + w 隐藏-隐藏 h t-1 + v 1) y T = σ( w 隐藏-输出 h T + v 2) in, v 1. v 2 are the fitting errors, w 输入-隐藏 , w 隐藏-隐藏 ,w 隐藏-输出 is the weight and σ(x) is the activation function.

[0021] In a non-sequential fully connected neural network, the input is independent of the time sequence. The input is x and the output is y. in, is the fitting error, is the weight, f (x) is the activation function.

[0022] Establish a fused fully connected neural network, pass the time series output tensor M and the non-time series output tensor N into the training model, that is, the last layer has M and N nodes, and the fused tensor dimension is M+N. The number of hidden layer nodes of the fused fully connected neural network is 1 layer, each layer has 1 node, the weight decay coefficient is 0.2, and the minimum error threshold is set to 0.01. Calculate the error between the predicted electricity price and the actual electricity price to obtain the model loss, and use the back propagation algorithm to continuously optimize the model, update the node weights of the time series recurrent neural network and the non-time series fully connected neural network; use gradient descent to update the weights and biases, back propagate the gradient, and use the optimization algorithm (such as stochastic gradient descent) to update the weights to minimize the loss function. Repeat until the iterative training reaches a predefined number of times and the fused fully connected neural network reaches a satisfactory performance level.

[0023] Electricity price forecasting using fused fully connected neural networks.

[0024] For the method of the present application, root mean square error (RMSE) and mean absolute error (MAE) are used as evaluation indicators.

[0025] In order to verify the method of this application, the electricity price data of a certain region in 2018 was used for research, of which 1023 data samples were used, 767 data were used as training sets, 153 data were used as validation sets, and 103 data were used as test sets. The model was trained using the method of this application to learn the rules of historical data. The test set was used for testing, and the predicted results were compared with the actual results to evaluate the prediction effect. The results are shown in Table 1.

[0026] Table 1 RMSE MAE RNN 3.3 4.6 FCNN 4.5 6.8 This application 2.7 3.1 Traditional RNN and FCNN ignore time series factors and non-time series factors, and the prediction effect is not as good as this application. This application considers using RNN to process time series factors and FCNN to process non-time series factors, and can better learn the relationship between each factor and electricity price. The root mean square error (RMSE) and mean absolute error (MAE) are both at a small level, and the model stability is good.

[0027] The present invention also provides an electronic device, comprising: at least one processor, and a memory connected to the at least one processor in communication, wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor executes the method. The electronic device can be any terminal device including a mobile phone, a laptop computer, a desktop computer, a tablet computer, a PDA (Personal Digital Assistant), a POS (Point of Sales), a vehicle-mounted computer, etc.

[0028] The present invention also provides a storage medium on which a computer program is stored, and when the program is executed by a processor, the method described is implemented. Through the description of the above implementation methods, the technicians in the relevant field can clearly understand that the present invention can be implemented by means of software plus necessary general hardware, and of course it can also be implemented by special hardware including special integrated circuits, special CPUs, special memories, special components, etc. In general, all functions completed by computer programs can be easily implemented by corresponding hardware, and the specific hardware structure used to implement the same function can also be various, such as analog circuits, digital circuits or special circuits. However, for the present invention, software program implementation is a better implementation method in more cases. Based on such an understanding, the technical solution of the present invention is essentially or the part that contributes to the prior art can be embodied in the form of a software product, and the computer software product is stored in a readable storage medium, such as a computer floppy disk, a U disk, a mobile hard disk, a read-only memory (ROM, Read-Only Memory), a random access memory (RAM, RandomAccess Memory), a disk or an optical disk, etc., including a number of instructions to enable a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment of the present invention.

[0029] The present invention also provides a computer program product, which includes a computer program, which, when executed by a processor, implements the method described. The computer program (which may also be referred to or described as a program, software, software application, module, software module, script or code) can be written in any form of programming language, including a compiled language or an interpreted language or a declarative language or a procedural language, and the computer program can be expanded in any form, including as an independent program or as a module, component, subroutine or other unit suitable for use in a computing environment. The computer program may but does not necessarily correspond to a file in a file system. The program may be stored in a part of a file that stores other programs or data, for example, one or more scripts stored in the following: in a markup language document; in a single file dedicated to a related program; or in multiple collaborative files, for example, files storing one or more modules, subroutines or code portions. The computer program can be expanded to execute on one or more computers, the computers being located in one place, or distributed to multiple locations and interconnected through a communication network. The processing and logic flow described in this specification can be performed by one or more programmable computers, which execute one or more computer programs by operating input data and generating output to run functions.

[0030] The number of devices and processing scales described here are used to simplify the description of the present invention. Applications, modifications and variations of the present invention will be obvious to those skilled in the art.

[0031] Although the embodiments of the present invention have been disclosed as above, they are not limited to the applications listed in the specification and the implementation modes, and they can be fully applied to various fields suitable for the present invention. For those familiar with the art, additional modifications can be easily implemented. Therefore, without departing from the general concept defined by the claims and the scope of equivalents, the present invention is not limited to the specific details and the illustrations shown and described herein.

Claims

1. A method for predicting electricity prices, characterized in that: include: Obtain historical data that affects electricity prices and perform data preprocessing. By analyzing the correlation coefficient between historical data and historical electricity prices, screen key historical data that affects electricity prices and divide the key historical data into training sets, validation sets, and test sets. Establish a time-series recurrent neural network, input the time-series data in the key historical data and train it, obtain the time-series output tensor, establish a non-time-series fully connected neural network, input the non-time-series data in the key historical data to train the model, and obtain the non-time-series output tensor; Establish a fused fully connected neural network, input the time series output tensor and the non-time series output tensor for training, calculate the error between the predicted electricity price and the actual electricity price, obtain the model loss, use the back propagation algorithm to continuously optimize the model, and update the node weights of the time series recurrent neural network and the non-time series fully connected neural network; Electricity price forecasting using fused fully connected neural networks.

2. The electricity price prediction method according to claim 1, characterized in that: Data preprocessing includes handling of duplicate values, missing values, outliers, as well as normalization and vectorization.

3. The electricity price prediction method according to claim 1, characterized in that: The time series data in the key historical data include electricity load, power generation, carbon emissions, and historical electricity prices. The non-time series data in the key historical data include temperature, humidity, and weather type.

4. The electricity price prediction method according to claim 1, characterized in that: The number of hidden layer nodes of the time series recurrent neural network is 3 layers, each layer has 50 nodes, the weight decay coefficient is 0.2, and the minimum error threshold is set to 0.01; The number of hidden layer nodes of the non-temporal fully connected neural network is 2 layers, each layer has 30 nodes, the weight decay coefficient is 0.2, and the minimum error threshold is set to 0.01; The number of hidden layer nodes of the fused fully connected neural network is 1 layer, with 1 node, the weight decay coefficient is 0.2, and the minimum error threshold is set to 0.

01.

5. An electronic device, characterized in that include: At least one processor, and a memory communicatively connected to the at least one processor, wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor performs the method described in any one of claims 1 to 4.

6. A storage medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the method described in any one of claims 1 to 4 is implemented.

7. A computer program product comprising a computer program, characterized in that When the program is executed by a processor, the method described in any one of claims 1 to 4 is implemented.

Citation Information

Cited By

  • Day-ahead electricity price prediction method and system, computer equipment and medium

    CN121073528A