Improved TCN electric quantity prediction method oriented to agent electricity purchasing users

By introducing the random forest method and parallel hybrid activation convolution module in traditional TCN, the PhaCIA-TCNS model is constructed, which solves the problems of redundant convolution and information importance processing, and significantly improves the accuracy and reliability of power prediction.

CN119273388APending Publication Date: 2025-01-07CHINA ELECTRIC POWER RESEARCH INSTITUTE CO LTD +3
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411370474.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-09-29
Publication Date
2025-01-07

AI Technical Summary

Technical Problem

Traditional TCN has redundant convolution operations in power prediction, which increases the learning time cost of the model and evenly processes all input elements, making it impossible to effectively distinguish important information factors, resulting in insufficient prediction accuracy and reliability.

Method used

The random forest method is used to sort the characteristics importance, combine the time domain convolution network and the input attention module, and reduce redundant convolution operations through the parallel hybrid activation convolution module, and build a PhaCIA-TCNS prediction model to improve the accuracy of power prediction.

Benefits of technology

It effectively improves the accuracy and reliability of power forecasts for agent power purchase users, and compares the RMSE and MAPE indicators with other models to show better prediction results.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119273388A_ABST
    Figure CN119273388A_ABST
Patent Text Reader

Abstract

The invention discloses an improved TCN electric quantity prediction method for agency electricity purchasing users, and belongs to the technical field of electricity consumption prediction, and the method comprises the steps: collecting the historical data of the electricity purchasing of each type of users, and the historical data of influence factors; sorting feature importance by adopting a random forest method based on the historical data of the purchased electric quantity and the historical data of the influence factors, and extracting key influence factors; and dividing the screened influence factor data set and the purchased electric quantity historical data set into a training set and a test set, and jointly inputting the training set and the test set into a PhaCIA-TCNS prediction model for prediction to obtain a prediction result. According to the improved TCN electric quantity prediction method oriented to the agent electricity purchasing users, the accuracy and reliability of electric quantity prediction of the agent electricity purchasing users can be effectively improved.
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 consumption prediction, and in particular to an improved TCN electricity consumption prediction method for proxy electricity purchasing users. Background Art

[0002] In the existing technology, power purchasing agents are an important part of the energy market, and the accuracy of their electricity forecasts directly affects the benefits and risk control of market participants. In addition, general forecasting methods have limitations when facing complex market environments. Traditional TCNs have many problems, such as redundant convolution operations. Each layer of TCN consists of two consecutive convolution operations, which improves the learning ability of the model, but also inevitably increases the backpropagation path and the time cost of each learning epoch. The input importance problem, the same number of nonlinearities makes TCN equal to all input elements, however, some elements actually contain more important information than other elements, so there is an urgent need to improve the traditional TCN model. Summary of the invention

[0003] The purpose of the present invention is to provide an improved TCN power forecasting method for proxy power purchasing users, which can effectively improve the accuracy and reliability of power forecasting for proxy power purchasing users.

[0004] To achieve the above object, the present invention provides an improved TCN power forecasting method for proxy power purchasing users, comprising:

[0005] Collect historical data on electricity purchased by various users and historical data on influencing factors;

[0006] Based on the historical data of purchased electricity and historical data of influencing factors, the random forest method is used to sort the importance of features and extract key influencing factors;

[0007] The screened influencing factor data set and the purchased electricity historical data set are divided into a training set and a test set, and are input into the PhaCIA-TCNS prediction model for prediction to obtain the prediction results.

[0008] Preferably, the historical data of influencing factors include meteorological data, electricity price data and event policy data corresponding to the historical data of purchased electricity.

[0009] Preferably, after collecting the historical data of purchased electricity of various users and the historical data of influencing factors, the method further includes: performing abnormality and missing value processing and data standardization on the historical data of purchased electricity and the historical data of influencing factors.

[0010] Preferably, the PhaCIA-TCNS prediction model is constructed through historical data, and prediction is performed after training with a training set to obtain a sequence of prediction results for the day to be predicted.

[0011] Preferably, the PhaCIA-TCNS prediction model comprises:

[0012] The time-domain convolutional network model can learn the sequence characteristics of power data in the time dimension;

[0013] Input attention module, which can give higher weight to important factors in the input sequence;

[0014] The parallel mixed activation convolution module can replace the original residual block in the time domain convolutional network model, reduce the redundant convolution operations in the ordinary time domain convolutional network model, and maintain good learning ability.

[0015] Preferably, the specific process of the PhaCIA-TCNS prediction model includes:

[0016] Define the input sequence as S 0 , first S 0 It is sent to the fully connected linear layer and then processed by the fully connected nonlinear layer to obtain the intermediate attention vector A 0 , the expression is:

[0017] A 0 =ReLU(Linear(S 0 ))

[0018] A is converted into 0 With S 0 Add them together, and further process the summation result through another fully connected nonlinear layer to obtain the complete attention vector A 1 ;

[0019] Through the Softmax operation, A 1 Normalize to obtain the final weighted important vector A 2 ; A 1 , A 2 The expression is:

[0020] A 1 =Tanh(A 0 +S 0 )

[0021] A 2 =Softmax(A 1 )

[0022] The weighted important vector A 2 Applied to the original input load sequence S 0 , using element-wise multiplication to generate the weighted load sequence S 1 :

[0023]

[0024] Define the input sequence of the i-th layer as S i , the PhaC module first processes S using dilated random convolution and denormalization i To obtain the intermediate sequence S i 1 , the expression is:

[0025]

[0026] S i 1 Send to the parallel nonlinear activation operations, multiply their results to get an activation sequence S i 2 :

[0027]

[0028] A skip connection is also added to the PhaC module, where the input sequence S i Processed by a 1×1 convolution block to obtain the residual sequence S i 3 , the expression is:

[0029]

[0030] After the dropout operation, the activation sequence S i 2 With the residual sequence S i 3 Perform element-by-element summation to obtain PhaCS i+1 The output sequence is:

[0031]

[0032] Preferably, the number of neurons in the hidden layer of the PhaCIA-TCNS prediction model is 384 and the kernel size is 5.

[0033] Preferably, the mean absolute percentage error and root mean square error are selected as evaluation indicators of model prediction accuracy, and then compared with the RNN, LSTM, GRU, Bi-RNN, Bi-LSTM, and Bi-GRU prediction models through RMSE and MAPE indicators. The smaller the RMSE and MAPE indicators, the better the prediction effect. The calculation process is as follows:

[0034]

[0035] Where N is the total number of predicted power values, y i is the true value, is the predicted value.

[0036] Preferably, a computer-readable storage medium stores a computer program thereon, which, when executed by a processor, implements the steps of an improved TCN electricity forecasting method for proxy electricity purchasing users as described in any one of claims 1-8.

[0037] Preferably, an electronic device comprises a memory, a processor and a computer program stored in the memory and executable on the processor, wherein when the processor executes the program, the steps of an improved TCN electricity quantity prediction method for proxy electricity purchasing users as described in any one of claims 1 to 8 are implemented.

[0038] Therefore, the present invention adopts the above-mentioned improved TCN power forecasting method for proxy power purchasing users, which can effectively improve the accuracy and reliability of power forecasting for proxy power purchasing users.

[0039] The technical solution of the present invention is further described in detail below through the accompanying drawings and embodiments. BRIEF DESCRIPTION OF THE DRAWINGS

[0040] Figure 1 It is an overall flow chart of an embodiment of an improved TCN power forecasting method for proxy power purchasing users of the present invention;

[0041] Figure 2 It is a schematic diagram of the input attention module flow of an embodiment of an improved TCN power prediction method for proxy power purchasing users of the present invention;

[0042] Figure 3 It is a schematic diagram of the parallel mixed activation convolution module flow of an embodiment of an improved TCN power prediction method for proxy power purchasing users of the present invention. DETAILED DESCRIPTION

[0043] The technical solution of the present invention is further described below through the accompanying drawings and embodiments.

[0044] Unless otherwise defined, the technical terms or scientific terms used in the present invention should be understood by people with ordinary skills in the field to which the present invention belongs. The words "first", "second" and similar words used in the present invention do not indicate any order, quantity or importance, but are only used to distinguish different components. "Include" or "comprise" and similar words mean that the elements or objects appearing before the word include the elements or objects listed after the word and their equivalents, without excluding other elements or objects. "Connect" or "connected" and similar words are not limited to physical or mechanical connections, but may include electrical connections, whether direct or indirect. "Up", "down", "left", "right" and the like are only used to indicate relative positional relationships. When the absolute position of the described object changes, the relative positional relationship may also change accordingly.

[0045] Embodiment 1

[0046] like Figure 1 As shown, the present invention provides an improved TCN power forecasting method for proxy power purchasing users, comprising the following steps:

[0047] S1. Collect historical data on electricity purchased by various users and historical data on influencing factors;

[0048] S2. Based on the collected historical data of purchased electricity and historical data of influencing factors, the random forest method is used to sort the importance of features and extract key influencing factors;

[0049] S3. Divide the filtered influencing factor data set and the purchased electricity historical data set into a training set and a test set, and input them into the PhaCIA-TCNS prediction model for prediction to obtain the prediction results.

[0050] Wherein, in step S1, the historical data of influencing factors include meteorological data, electricity price data and event policy data corresponding to the historical data of purchased electricity.

[0051] The collected data is cleaned, including anomaly and missing value processing and data standardization.

[0052] The execution process in step S2 is specifically as follows: the obtained data is divided into two groups, a training set and a test set, a PhaCIA-TCNS prediction model is constructed through historical data, and prediction is performed after training with the training set to obtain a prediction result sequence for the day to be predicted.

[0053] The PhaCIA-TCNS prediction model includes:

[0054] ① Temporal convolution network (TCN) model, which can learn the sequence characteristics of power data in the time dimension.

[0055] ② Input attention module (IA), the operation process is as follows Figure 2 As shown, it is possible to give higher weights to important factors in the input sequence.

[0056] ③Parallel HybridActivated Convolution (PhaC), the operation process is as follows Figure 3 As shown, it can replace the original residual block in the time domain convolutional network model and reduce the redundant convolution operations in the ordinary time domain convolutional network model while maintaining good learning ability.

[0057] The number of neurons in the hidden layer of the PhaCIA-TCNS prediction model is 384 and the kernel size is 5.

[0058] The specific process of the PhaCIA-TCNS prediction model includes:

[0059] Define the input sequence as S 0 , first S 0 It is sent to the fully connected linear layer, and then processed by the fully connected nonlinear layer (with ReLu as the activation function) to obtain the intermediate attention vector A 0 , the expression is:

[0060] A 0 =ReLU(Linear(S 0 ))

[0061] A is converted into 0 With S 0 Add them together, and further process the summation result by another fully connected nonlinear layer (with Tanh as activation function) to obtain the complete attention vector A 1 ;

[0062] Through the Softmax operation, A 1 Normalize to obtain the final weighted important vector A 2 ; A 1 , A 2 The expression is:

[0063] A 1 =Tanh(A 0 +S 0 )

[0064] A 2 =Softmax(A 1 )

[0065] The weighted important vector A 2 Applied to the original input load sequence S 0 , using element-wise multiplication to generate the weighted load sequence S 1 :

[0066]

[0067] Define the input sequence of the i-th layer as S i , the PhaC module first processes S using dilated random convolution and denormalization i To obtain the intermediate sequence S i 1 , the expression is:

[0068]

[0069] S i 1 Send to the parallel nonlinear activation operations, multiply their results to get an activation sequence S i 2 :

[0070]

[0071] A skip connection is also added to the PhaC module, where the input sequence S i Processed by a 1×1 convolution block to obtain the residual sequence S i 3 , the expression is:

[0072]

[0073] After the dropout operation, the activation sequence S i 2 With the residual sequence S i 3 Perform element-by-element summation to obtain PhaCS i+1 The output sequence is:

[0074]

[0075] The mean absolute percentage error (MAPE) and root mean square error (RMSE) are selected as evaluation indicators of model prediction accuracy, and then compared with the RNN, LSTM, GRU, Bi-RNN, Bi-LSTM, and Bi-GRU prediction models through RMSE and MAPE indicators. The smaller the RMSE and MAPE indicators, the better the prediction effect. The calculation process is as follows:

[0076]

[0077] Where N is the total number of predicted power values, y i is the true value, is the predicted value.

[0078] A computer-readable storage medium stores a computer program, which, when executed by a processor, can implement the steps of the above-mentioned improved TCN electricity quantity prediction method for proxy electricity purchasing users.

[0079] An electronic device includes a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the program, the steps of the above-mentioned improved TCN electricity prediction method for proxy electricity purchasers can be implemented.

[0080] Therefore, the present invention adopts the above-mentioned improved TCN power forecasting method for proxy power purchasing users, which can effectively improve the accuracy and reliability of power forecasting for proxy power purchasing users.

[0081] Finally, it should be noted that the above embodiments are only used to illustrate the technical solution of the present invention rather than to limit it. Although the present invention has been described in detail with reference to the preferred embodiments, those skilled in the art should understand that they can still modify or replace the technical solution of the present invention with equivalents, and these modifications or equivalent replacements cannot cause the modified technical solution to deviate from the spirit and scope of the technical solution of the present invention.

Claims

1. An improved TCN power forecasting method for proxy power purchasers, characterized in that: include: Collect historical data on electricity purchased by various users and historical data on influencing factors; Based on the historical data of purchased electricity and historical data of influencing factors, the random forest method is used to sort the importance of features and extract key influencing factors; The screened influencing factor data set and the purchased electricity historical data set are divided into a training set and a test set, and are input into the PhaCIA-TCNS prediction model for prediction to obtain the prediction results.

2. According to claim 1, an improved TCN power forecasting method for proxy power purchasers is characterized by: The historical data of influencing factors include meteorological data, electricity price data and event policy data corresponding to the historical data of purchased electricity.

3. The improved TCN power forecasting method for proxy power purchasers according to claim 1 is characterized by: After collecting the historical data of purchased electricity of various users and the historical data of influencing factors, the method further includes: performing abnormality and missing value processing and data standardization on the historical data of purchased electricity and the historical data of influencing factors.

4. The improved TCN power forecasting method for proxy power purchasers according to claim 1 is characterized by: The PhaCIA-TCNS prediction model is constructed through historical data, and prediction is performed after training with a training set to obtain a prediction result sequence for the day to be predicted.

5. The improved TCN power forecasting method for proxy power purchasers according to claim 4 is characterized in that: The PhaCIA-TCNS prediction model includes: The time-domain convolutional network model can learn the sequence characteristics of power data in the time dimension; Input attention module, which can give higher weight to important factors in the input sequence; The parallel mixed activation convolution module can replace the original residual block in the time domain convolutional network model, reduce the redundant convolution operations in the ordinary time domain convolutional network model, and maintain good learning ability.

6. The improved TCN power forecasting method for proxy power purchasers according to claim 5 is characterized in that: The specific process of the PhaCIA-TCNS prediction model includes: Define the input sequence as S0, first send S0 to the fully connected linear layer, and then process it by the fully connected nonlinear layer to obtain the intermediate attention vector A0, which is expressed as: A0=ReLU(Linear(S0)) A0 is added to S0 through element-wise summation, and the summation result is further processed by another fully connected nonlinear layer to obtain the complete attention vector A1; A1 is normalized through the Softmax operation to obtain the final weighted important vector A2; the expressions of A1 and A2 are: A1=Tanh(A0+S0) A2=Softmax(A1) Apply the weighted importance vector A2 to the original input payload sequence S0, using element-wise multiplication to generate the weighted payload sequence S1: Define the input sequence of the i-th layer as S i , the PhaC module first processes S using dilated random convolution and denormalization i To obtain the intermediate sequence S i 1 , the expression is: S i 1 Send to the parallel nonlinear activation operations, multiply their results to get an activation sequence S i 2 : A skip connection is also added to the PhaC module, where the input sequence S i Processed by a 1×1 convolution block to obtain the residual sequence S i 3 , the expression is: After the dropout operation, the activation sequence S i 2 With the residual sequence S i 3 Perform element-by-element summation to obtain PhaC S i+1 The output sequence is:

7. The improved TCN power forecasting method for proxy power purchasers according to claim 5 is characterized by: The number of neurons in the hidden layer of the PhaCIA-TCNS prediction model is 384, and the kernel size is 5.

8. The improved TCN power forecasting method for proxy power purchasers according to claim 1 is characterized by: The mean absolute percentage error and root mean square error are selected as evaluation indicators of model prediction accuracy, and then compared with the RNN, LSTM, GRU, Bi-RNN, Bi-LSTM, and Bi-GRU prediction models through RMSE and MAPE indicators. The smaller the RMSE and MAPE indicators, the better the prediction effect. The calculation process is as follows: Where N is the total number of predicted power values, y i is the true value, is the predicted value.

9. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the steps of an improved TCN electricity quantity prediction method for proxy electricity purchasing users as described in any one of claims 1 to 8 are implemented.

10. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein: When the processor executes the program, the steps of an improved TCN electricity quantity prediction method for proxy electricity purchasing users as described in any one of claims 1 to 8 are implemented.