Power load prediction method and prediction system based on mRMR-EABILSTM-TCN
The maximum correlation minimum redundancy algorithm is used to filter the features and build the mRMR-EABiLSTM-TCN model, which solves the problem of feature redundancy and low efficiency of deep learning models in user load prediction, and achieves efficient and accurate load prediction.
Patent Information
- Application Number
- CN202411151287.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-21
- Publication Date
- 2024-12-13
AI Technical Summary
The existing technology has problems such as feature redundancy problems in user load prediction and feature information loss and gradient explosion in deep learning models during long-distance learning. It is difficult to effectively process high-dimensional inputs and massive data, resulting in low prediction efficiency and low accuracy. .
Feature screening is performed using the maximum correlation minimum redundancy algorithm (mRMR) to build an mRMR-EABiLSTM-TCN model that combines self-attention, bidirectional long and short-term memory neural network (BiLSTM) and time convolutional network (TCN), through forward selection The algorithm evaluates the effectiveness of input features, determines the optimal input feature set, and optimizes the power load prediction model.
It effectively avoids feature redundancy, improves load prediction accuracy, improves the operating efficiency and prediction timeliness of the model, and has certain engineering value.
Smart Images

Figure CN119129813A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of power systems, and more specifically, relates to a power load forecasting method and a forecasting system based on mRMR-EABiLSTM-TCN. Background Art
[0002] Different from system-level load, user load is highly random, has a small base number, and is strongly affected by factors such as meteorological conditions and production plans, making it difficult to obtain good prediction results for user load forecasting. If micro-meteorological data such as temperature and humidity are monitored and analyzed in a small area, and these micro-meteorological data are included in the load influencing factors when establishing a refined user load forecasting model, the accuracy of user load forecasting can be improved to a certain extent.
[0003] When establishing a prediction model for user load time series, the load values of the previous several time periods and the micro-meteorological conditions at the time of prediction will have different degrees of influence on the load value at the time of prediction, and general linear equations are difficult to describe the nonlinear law of load changes. To this end, it is necessary to use machine learning algorithms to fully explore the correlation between the data before and after the sequence. However, traditional machine learning algorithms such as artificial neural networks or support vector machines have defects such as low operating efficiency when training model parameters and network structures, and shallow perceptrons are difficult to represent high-dimensional data features, which makes traditional algorithms unsuitable for applications with high input dimensions and large load data volumes. Therefore, it is necessary to study prediction algorithms with high computational efficiency, small memory usage, and the ability to process high-dimensional features to ensure the timeliness and efficiency of load prediction. As an extension of machine learning algorithms, deep learning uses a layer-by-layer training method to search and solve model parameters, so that a network structure with multiple hidden layers can be constructed, and feature extraction of high-dimensional input data can be realized autonomously, avoiding the problem of dimensionality disaster. At the same time, deep learning algorithms use batch processing to decompose the original massive data into several sub-sample sets for model training, which improves the efficiency of model training. A large number of research results and applications have shown that compared with machine learning algorithms, deep learning is more suitable for processing high-dimensional input and massive data tasks. Therefore, a user load forecasting model is urgently needed to obtain scientific and reasonable forecast values and guide power sales companies to carry out power purchase and sales business.
[0004] Compared with traditional classification and recognition algorithms, deep learning algorithms avoid the impact of improper feature extraction on classification accuracy and also have good noise resistance. Models such as deep autoencoder networks, convolutional neural networks, and classification deep learning neural networks were used in the research on power transformer fault diagnosis, verifying the advantages of deep learning feature processing and classification accuracy. In the field of user power consumption pattern classification, based on the clustering algorithm, a large number of user load curves were classified and fused into four typical power consumption patterns according to cluster centers, namely bimodal, trimodal, stable, and peak-avoiding. Then, the sparse autoencoder deep learning model was used to classify the clustering results to achieve the goal of identifying user power consumption behavior patterns.
[0005] In existing studies, when micro-meteorological data is used as an external feature input into the model, there may be a problem of feature redundancy, that is, some micro-meteorological data has little effect on load changes, and the introduction of this feature will bring a lot of redundant information, which will have a negative impact on the learning of the model and increase the risk of overfitting. In addition, deep learning models such as recurrent neural networks are prone to problems such as feature information loss and gradient explosion when learning over long distances. Convolutional neural networks use local connections and parameter sharing to effectively improve the operating efficiency of the model, but there are also shortcomings such as translation invariance and parameter loss in the pooling process. Other single deep learning models also have their own limitations. Summary of the invention
[0006] In order to solve the deficiencies in the prior art, the present invention provides a user short-term load forecasting method based on mRMR-EABiLSTM-TCN to obtain accurate and reliable user power load forecasting results.
[0007] The present invention adopts the following technical solution. A first aspect of the present invention provides a method for power load forecasting based on mRMR-EABiLSTM-TCN, comprising the following steps:
[0008] Step 1: Collect load data and characteristic factors that affect user power load, and perform data cleaning and normalization preprocessing;
[0009] Step 2: Based on the processed data, the maximum relevance minimum redundancy algorithm (mRMR) is used to sort the importance of the feature factors, and the top N relevant features are selected to form a rough feature set;
[0010] Step 3, construct the mRMR-EABiLSTM-TCN short-term user load forecasting model that combines the self-attention EA, the bidirectional long short-term memory neural network BiLSTM and the temporal convolutional network TCN, and use the coarsely selected feature set as the feature input of the model;
[0011] Step 4: Make predictions based on the constructed model, evaluate the effectiveness of different input features through the forward selection algorithm, determine the optimal input feature set, and optimize the power prediction model.
[0012] Preferably, in step 1, the data cleaning used is divided into two processes: outlier screening and missing value supplementation. Outliers and missing values in the original data are screened out based on the box plot, and the mean of adjacent moments is used to correct outliers and supplement missing values:
[0013] IQR=Q3-Q1
[0014] ul=Q3+1.5·IQR
[0015] dl=Q1-1.5·IQR
[0016] in:
[0017] ul is the upper limit, dl is the lower limit, Q3 is the upper quartile, Q1 is the lower quartile, and IQR is the interquartile range;
[0018] Values greater than ul or less than dl are considered outliers or missing values, and the mean of adjacent moments is used to correct outliers or supplement missing values.
[0019] Preferably, in step 1, the normalization uses a maximum-minimum normalization method to scale the data to between [0, 1]:
[0020]
[0021] in:
[0022] y i ′ represents the normalized load value, y min Indicates the minimum load value in the load sequence, y max Indicates the maximum load value in the load sequence.
[0023] Preferably, in step 2, the amount of information commonly contained in multiple linear or nonlinear variables is calculated, requiring that the correlation between the feature set and the category is maximized and the redundancy between the features is minimized, and the formula is as follows:
[0024]
[0025] in:
[0026] S represents the selected input variable set, |S| represents the number of input variables, and c represents the output target value;
[0027] D describes each input variable x in the input variable set S i The mean mutual information between the input variable set and the output target c reflects the correlation between the input variable set and the output target;
[0028] R represents the size of the mutual information between variables in the input variable set S, describing the redundancy between the input variables.
[0029] Preferably, in step 2, the initial input variable set is represented as X and contains N features, S represents the selected feature set, and F represents the feature set to be selected. Applying mRMR to select the input variable set includes the following steps:
[0030] Step 2.1, initialize the selected feature set S to be an empty set, and the feature set to be selected is X, that is, X→F,
[0031] Step 2.2, Calculate x i The correlation with the target class c I(x i ; c); record x * To satisfy max[I(x i ; c)] The characteristics of the condition, let F-{x *}→F1, {x *}→S1;
[0032] Step 2.3, let x i ∈F m-1 , x j ∈S m-1 (m=2,3,…,N), from F m-1 Find the idiom The maximum feature that holds true is denoted by x ** , let F m-1 -{x **}→F m , S m-1 +{x **}→S m ;
[0033] Step 2.4, repeat step 2.3 until F is Then we get the candidate feature set S, and sort the features in S according to The values are sorted in descending order.
[0034] Preferably, in step 3, the weights of each feature are adaptively allocated beyond the self-attention EA, including:
[0035]
[0036] F out =AM V
[0037] in:
[0038] A represents the attention matrix, Norm represents the normalization process, F represents each feature, and F out represents the attention vector;
[0039] M∈R s×d Represents an introduced external spatial memory unit with a dimension of s×d.
[0040] Preferably, in step 3, the bidirectional long short-term memory neural network BiLSTM closely links the current state with the past and future states, including:
[0041] I t =σ(X t ω xi +H t-1 ω hi +b i )
[0042] F t =σ(X t ω xf +H t-1 ω hf +b f )
[0043] O t =σ(X t ω xo +H t-1 ω ho +b o )
[0044]
[0045] H t =O t ⊙tanh(C t )
[0046] in:
[0047] F t , I t , O t are the forget gate, input gate and output gate at time t, respectively. t represents the state of the memory cell at time t, is the candidate memory cell state, H t is a hidden state in the forward propagation process, ω xi ,ω xf ,ω xo and xc is the weight between the corresponding gate and the input, ω hi ,ω hf ,ω ho and ω hcis the weight between the corresponding gates, b i 、b f 、b o and b c is the bias of the corresponding gate.
[0048] Preferably, in step 3, the temporal convolutional network TCN consists of three parts: causal convolution, dilated convolution and residual connection. The dilated convolution operation F(m) of a certain element m is expressed as follows:
[0049]
[0050] in:
[0051] x is the input time series, k is the convolution kernel size, i is the number of dilated convolution operations, x m-di is the position of the input layer corresponding to the element m, d is the dilated convolution coefficient, f is the convolution kernel, Represents a convolution operation.
[0052] Preferably, in step 4, the forward selection algorithm has the following process: the feature subset starts from an empty set, and one feature is selected each time to be added to the feature subset so that the feature function is optimal;
[0053] The collected original user load data is used as the input of the BiLSTM model improved by EA. After the time series features are initially extracted by EA, the extracted features are input into BiLSTM for further feature learning.
[0054] The encapsulator working mode is adopted, and the initial value of the optimal input variable set is set to an empty set. The forward selection algorithm is used to add the input variables with the highest mutual information value to the selected input variable set one by one. After extracting features through the fully connected layer, the load features extracted by EABiLSTM and the key factor features extracted by the fully connected layer are concatenated and fused based on the concatenation function Concatenate in Python. The concatenated results are input into the TCN model to mine the coupling relationship between load and key factors. The optimal input variable set is determined based on the principle of minimum prediction error to optimize the user's short-term load forecasting accuracy.
[0055] The second aspect of the present invention provides an mRMR-EABiLSTM-TCN-based power load forecasting system, comprising: a data processing module, a feature selection module, a model building module, and a prediction and evaluation module; an mRMR-EABiLSTM-TCN-based power load forecasting system according to any one of claims 1 to 9 is characterized in that:
[0056] The data processing module is used to collect power load data and characteristic factors that affect user power load, clean the collected data, process abnormal values and missing values, and perform normalization operations;
[0057] The feature selection module is used to sort the importance of feature factors according to the maximum relevance and minimum redundancy algorithm, select the top N relevant features, and form a coarse feature set to focus on relevant features;
[0058] The model building module is used to build a prediction model that comprehensively surpasses self-attention EA, bidirectional long short-term memory neural network BiLSTM and temporal convolutional network TCN. EA is used for adaptive weight allocation, BiLSTM is used to process time series features, and TCN is used to extract long-term dependencies to fully capture the characteristics of load data.
[0059] The prediction and evaluation module is used to construct the mRMR-EABiLSTM-TCN model for short-term prediction of power load, evaluate the effectiveness of different input features, determine the optimal input feature set, and optimize the performance of the model.
[0060] A third aspect of the present invention provides a terminal, including a processor and a storage medium; characterized in that:
[0061] The storage medium is used to store instructions;
[0062] The processor is used to operate according to the instruction to execute the steps of the power load forecasting method based on mRMR-EABiLSTM-TCN.
[0063] A fourth aspect of the present invention provides a computer-readable storage medium having a computer program stored thereon, characterized in that the program is executed by a processor to perform the steps of a power load forecasting method based on mRMR-EABiLSTM-TCN.
[0064] Compared with the prior art, the beneficial effects of the present invention at least include: the present invention performs feature screening based on mRMR, preliminarily screens out key factors that have a greater impact on the load degree, and uses this to form a coarse feature set, effectively avoiding the problem of feature redundancy; the present invention constructs an EABiLSTM-TCN model, preliminarily extracts the time series characteristics of user load based on EA, inputs the extracted time series characteristics into BiLSTM for further feature learning, and inputs them into TCN together with key factors to capture the dependency relationship between the load and the key factors; the present invention adopts mRMR-EABiLSTM-TCN for load forecasting, and adopts a forward selection algorithm to evaluate the effectiveness of different input features, and determines the optimal input feature set, which is conducive to improving the final load forecasting accuracy and has certain engineering value. BRIEF DESCRIPTION OF THE DRAWINGS
[0065] Figure 1 is a prediction flow chart of the present invention;
[0066] Figure 2 The specific structure of the EA;
[0067] Figure 3 This is the BiLSTM network structure diagram;
[0068] Figure 4 This is the causal convolution structure diagram;
[0069] Figure 5 Forward selection test diagram for load influence factors;
[0070] Figure 6 Prediction curves for different models. DETAILED DESCRIPTION
[0071] In order to make the purpose, technical scheme and advantages of the present invention clearer, the technical scheme of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. The embodiments described in this application are only part of the embodiments of the present invention, not all of them. Based on the spirit of the present invention, other embodiments obtained by ordinary technicians in this field without creative work are all within the scope of protection of the present invention.
[0072] like Figure 1 As shown, the present invention relates to a user short-term load forecasting method based on mRMR-EABiLSTM-TCN, comprising the following steps:
[0073] Step 1: Collect load data and characteristic factors that affect user power load, such as temperature and electricity price, and perform data preprocessing operations such as data cleaning and normalization;
[0074] Preferably, the data cleaning is divided into two processes: outlier screening and missing value supplementation. Outliers and missing values in the original data are screened out based on the box plot, and the average of adjacent moments is used to correct outliers and supplement missing values. The principle of the box plot algorithm is as follows:
[0075] IQR=Q3-Q1
[0076] ul=Q3+1.5·IQR
[0077] dl=Q1-1.5·IQR
[0078] In the formula: ul is the upper limit, dl is the lower limit, Q3 is the upper quartile, Q1 is the lower quartile, IQR is the interquartile range, and values greater than ul or less than dl are judged as outliers or missing values, and the mean of adjacent moments is used to correct outliers or supplement missing values.
[0079] Preferably, the normalization adopts the maximum and minimum normalization method to scale the data to [0, 1] to eliminate the influence of dimension. The normalization formula is:
[0080]
[0081] Where: y i ′ is the normalized load value, y min is the minimum load value in the load sequence, y max is the maximum load value in the load sequence.
[0082] Step 2: Based on the processed data, the maximum relevance minimum redundancy algorithm (mRMR) is used to sort the importance of the feature factors, and the top N relevant features are selected to form a rough feature set;
[0083] Preferably, the mRMR is based on the mutual information theory, which calculates the amount of information contained in multiple linear or nonlinear variables, and is widely used in variable selection. Its goal is to maximize the correlation between feature sets and categories and minimize redundancy between features, that is,
[0084]
[0085] Where: S is the selected input variable set, |S| is the number of input variables, and c is the output target value. D describes the input variables x in the input variable set S. i The mean mutual information between the input variable set and the output target c reflects the correlation between the input variable set and the output target. R represents the size of the mutual information between the variables in the input variable set S, describing the redundancy between the input variables.
[0086] Preferably, in step 2, the initial input variable set is represented as X and contains N features; S represents the selected feature set, and F represents the feature set to be selected. The steps of applying mRMR to select the input variable set are:
[0087] Step 2.1, initialize the selected feature set S to be an empty set, and the feature set to be selected is X, that is, X→F,
[0088] Step 2.2, Calculate x i The correlation with the target class c I(x i ; c); record x * To satisfy max[I(x i ; c)] The characteristics of the condition, let F-{x *}→F1, {x *}→S1;
[0089] Step 2.3, let x i ∈F m-1 , x j ∈S m-1 (m=2,3,…,N), from F m-1 Find the idiom The maximum feature that holds true is denoted by x ** , let F m-1 -{x **}→F m , S m-1 +{x **}→S m ;
[0090] Step 2.4, repeat step 2.3 until F is Then we get the candidate feature set S, and sort the features in S according to The values are sorted in descending order.
[0091] Step 3, construct the mRMR-EABiLSTM-TCN short-term user load forecasting model which combines the self-attention EA, the bidirectional long short-term memory neural network BiLSTM and the temporal convolutional network TCN, and use the coarsely selected feature set as the feature input of the model;
[0092] Preferably, the self-attention EA is an external attention mechanism, and its specific structure is as follows: Figure 2 As shown, the weight adaptive allocation function of each feature can be realized. The principle is as follows:
[0093]
[0094] F out =AM V
[0095] Where: A is the attention matrix, Norm represents the normalization process, F represents each feature, M∈R s×d is an external spatial memory unit introduced, whose dimension is s×d, F out is the attention vector.
[0096] Preferably, the bidirectional long short-term memory neural network (BiLSTM) is an improved model of LSTM, which enriches feature information by closely linking the current state with the past and future states. Its network structure is as follows: Figure 3 As shown, the LSTM algorithm principle is as follows:
[0097] I t =σ(X t ω xi +H t-1 ω hi +b i )
[0098] F t =σ(X t ω xf +H t-1 ω hf +b f )
[0099] O t =σ(X t ω xo +H t-1 ω ho +b o )
[0100]
[0101] H t =O t ⊙tanh(C t )
[0102] Where: F t , I t , O t are the forget gate, input gate and output gate at time t, respectively. t represents the state of the memory cell at time t, is the candidate memory cell state, H t is a hidden state in the forward propagation process, ω xi ,ω xf ,ω xo and xc is the weight between the corresponding gate and the input, ω hi ,ω hf ,ω ho and ω hc is the weight between the corresponding gates, b i 、b f 、b o and b c is the bias of the corresponding gate.
[0103] Preferably, the temporal convolutional network (TCN) consists of three parts: causal convolution, dilated convolution and residual connection. The larger receptive field enhances the ability of the model to extract features. The structure of the causal convolution is as follows: Figure 4 As shown, the expansion convolution operation F(m) of an element m is expressed as follows:
[0104]
[0105] Where: x is the input time series, k is the convolution kernel size, i is the number of dilated convolution operations, x mdi is the position of the input layer corresponding to the element m, d is the dilated convolution coefficient, f is the convolution kernel, Represents a convolution operation.
[0106] Step 4: Make predictions based on the constructed model, evaluate the effectiveness of different input features through the forward selection algorithm, determine the optimal input feature set, and optimize the power prediction model.
[0107] Preferably, the forward selection algorithm is a greedy algorithm, and its general process is: the feature subset starts from an empty set, and one feature is selected each time to be added to the feature subset so that the feature function is optimal (that is, the prediction error is minimized in the present invention).
[0108] Preferably, the collected original user load data is used as the input of the BiLSTM model improved based on EA. After using EA to preliminarily extract time series features, the extracted features are input into BiLSTM for further feature learning. The encapsulator working mode is adopted, and the initial value of the optimal input variable set is set to an empty set. The forward selection algorithm is used to add the input variables with the highest mutual information value to the selected input variable set one by one. After extracting features through the fully connected layer, the load features extracted by EABiLSTM and the key factor features extracted by the fully connected layer are concatenated and fused based on the concatenation function Concatenate in Python, and the concatenated results are input into the TCN model to mine the coupling relationship between load and key factors. Finally, the optimal input variable set is determined based on the principle of minimizing the prediction error, so as to optimize the accuracy of user short-term load forecasting.
[0109] The following describes in detail the implementation process of the prediction method of the present invention for user short-term load prediction in combination with specific examples.
[0110] A total of 5808 load data (sampling time interval is 1h) from a user in Wuxi City, Jiangsu Province from 1:00 on September 1, 2020 to 24:00 on April 30, 2021, and the corresponding resolution (sampling time interval is 1h) of external features that can affect the user load were selected; the training set and the test set were divided into 8:2 ratios. Based on the selected input variables, user load prediction models based on CNN, LSTM and EABiLSTM-TCN were established respectively. After training each model with the training set, the prediction accuracy of different models was compared based on the prediction results of the test set.
[0111] In order to verify the feasibility of the method proposed in this invention for user short-term load forecasting, the root mean square error (RMSE) and mean absolute percentage error (MAPE) are selected as error indicators. The specific calculation formula is as follows:
[0112]
[0113] Where: n is the sample length, y t and are the actual and predicted values at time t.
[0114] In order to verify the comprehensive performance of the proposed model, the case test is compared and analyzed from the following two perspectives.
[0115] Example 1: Verification of the effectiveness of feature screening
[0116] In order to illustrate the effectiveness of the proposed feature screening method, the key factors after the initial screening of mRMR are used as the rough selection feature set, and the forward selection algorithm is used to determine the optimal input variables. Figure 5 It can be seen that the features after preliminary screening by mRMR still contain some redundant information. If all key factors are input into the model, it will cause the problem of feature redundancy. Therefore, the present invention uses the forward selection algorithm to further determine the optimal variables based on the mRMR rough selection. It can be seen that when the variable dimension is 8, the prediction error MAPE is the smallest.
[0117] Example 2: EABiLSTM-TCN model effectiveness verification
[0118] In order to further illustrate the beneficial effect of the proposed model on user short-term load forecasting, the prediction results of the proposed EABiLSTM-TCN model are compared with those of CNN and LSTM models on the basis of determining the optimal input variables using mRMR and forward search algorithms respectively. The specific prediction results are shown in Table 1.
[0119] Table 1 Comparison of prediction performance of different models
[0120]
[0121] Figure 6 The prediction results of each model after combining the feature screening technology are shown. It can be seen that compared with the CNN and LSTM models, the proposed EABiLSTM-TCN has achieved the best prediction results overall by extracting time series features well and paying close attention to important features. In addition, when the load fluctuates greatly ( Figure 6 The proposed model can better track the rapid fluctuation of the original load and capture the complex characteristics of user load data, and has good application prospects.
[0122] In summary, the method of the present invention has good prediction performance, can effectively screen out key factors that contribute more to the prediction, deeply capture the timing characteristics of the load itself and the coupling characteristics between the load and the key factors, and provide more effective reference information for power system dispatchers to perform dispatching control.
[0123] The embodiments of the present invention are described in detail above with reference to the accompanying drawings, but the present invention is not limited to the above embodiments, and various changes can be made within the knowledge scope of ordinary technicians in this field without departing from the purpose of the present invention.
[0124] The beneficial effects of the present invention at least include: the present invention performs feature screening based on mRMR, preliminarily screens out key factors that have a greater impact on the load degree, and uses this to form a coarse feature set, effectively avoiding the problem of feature redundancy; the present invention constructs an EABiLSTM-TCN model, preliminarily extracts the time series characteristics of user load based on EA, inputs the extracted time series characteristics into BiLSTM for further feature learning, and inputs them into TCN together with key factors to capture the dependency relationship between the load and the key factors; the present invention adopts mRMR-EABiLSTM-TCN for load forecasting, and adopts a forward selection algorithm to evaluate the effectiveness of different input features, and determines the optimal input feature set, which is conducive to improving the final load forecasting accuracy and has certain engineering value.
[0125] The present disclosure may be a system, a method and / or a computer program product. The computer program product may include a computer-readable storage medium carrying computer-readable program instructions for causing a processor to implement various aspects of the present disclosure.
[0126] A computer-readable storage medium may be a tangible device that can hold and store instructions used by an instruction execution device. A computer-readable storage medium may be, for example, but not limited to, an electrical storage device, a magnetic storage device, an optical storage device, an electromagnetic storage device, a semiconductor storage device, or any suitable combination of the foregoing. More specific examples of computer-readable storage media (a non-exhaustive list) include: a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), a static random access memory (SRAM), a portable compact disk read-only memory (CD-ROM), a digital versatile disk (DVD), a memory stick, a floppy disk, a mechanical encoding device, such as a punch card or a raised structure in a groove on which instructions are stored, and any suitable combination of the foregoing. As used herein, a computer-readable storage medium is not to be interpreted as a transient signal per se, such as a radio wave or other freely propagating electromagnetic wave, an electromagnetic wave propagating through a waveguide or other transmission medium (e.g., a light pulse through a fiber optic cable), or an electrical signal transmitted through a wire.
[0127] The computer-readable program instructions described herein can be downloaded from a computer-readable storage medium to each computing / processing device, or downloaded to an external computer or external storage device via a network, such as the Internet, a local area network, a wide area network, and / or a wireless network. The network can include copper transmission cables, optical fiber transmissions, wireless transmissions, routers, firewalls, switches, gateway computers, and / or edge servers. The network adapter card or network interface in each computing / processing device receives the computer-readable program instructions from the network and forwards the computer-readable program instructions for storage in the computer-readable storage medium in each computing / processing device.
[0128] The computer program instructions for performing the operation of the present disclosure may be assembly instructions, instruction set architecture (ISA) instructions, machine instructions, machine-related instructions, microcode, firmware instructions, state setting data, or source code or object code written in any combination of one or more programming languages, including object-oriented programming languages, such as Smalltalk, C++, etc., and conventional procedural programming languages, such as "C" language or similar programming languages. Computer-readable program instructions may be executed completely on a user's computer, partially on a user's computer, as an independent software package, partially on a user's computer, partially on a remote computer, or completely on a remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer via any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., using an Internet service provider to connect via the Internet). In some embodiments, an electronic circuit, such as a programmable logic circuit, a field programmable gate array (FPGA), or a programmable logic array (PLA), may be customized by utilizing the state information of the computer-readable program instructions, and the electronic circuit may execute the computer-readable program instructions, thereby realizing various aspects of the present disclosure.
[0129] 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, and any modifications or equivalent replacements that do 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 power load forecasting method based on mRMR-EABiLSTM-TCN, It is characterized in that The following steps are involved: Step 1: Collect load data and characteristic factors that affect user power load, and perform data cleaning and normalization preprocessing; Step 2: Based on the processed data, the maximum relevance minimum redundancy algorithm (mRMR) is used to sort the importance of the feature factors, and the top N relevant features are selected to form a rough feature set; Step 3, construct the mRMR-EABiLSTM-TCN short-term user load forecasting model that combines the self-attention EA, the bidirectional long short-term memory neural network BiLSTM and the temporal convolutional network TCN, and use the coarsely selected feature set as the feature input of the model; Step 4: Make predictions based on the constructed model, evaluate the effectiveness of different input features through the forward selection algorithm, determine the optimal input feature set, and optimize the power prediction model.
2. According to the mRMR-EABiLSTM-TCN-based power load forecasting method of claim 1, Features: In step 1, the data cleaning used is divided into two processes: outlier screening and missing value supplementation. The outliers and missing values in the original data are screened out based on the box plot, and the mean of adjacent moments is used to correct outliers and supplement missing values: IQR / Q 3 -Q 1 ul6Q 3 +1.5·IQR dl6Q 1 -1.5·IQR in: ul is the upper limit, dl is the lower limit, Q 3 is the upper quartile, Q 1 is the lower quartile, and IQR is the interquartile range; Values greater than ul or less than dl are considered outliers or missing values, and the mean of adjacent moments is used to correct outliers or supplement missing values.
3. According to the power load forecasting method based on mRMR-EABiLSTM-TCN in claim 1, Features: In step 1, the normalization uses the maximum and minimum normalization method to scale the data to between [0, 1]: in: y′ i represents the normalized load value, y min Indicates the minimum load value in the load sequence, y max Indicates the maximum load value in the load sequence.
4. According to the mRMR-EABiLSTM-TCN-based power load forecasting method of claim 1, Features: In step 2, the amount of information contained in multiple linear or nonlinear variables is calculated, requiring the feature set to have the maximum correlation with the category and the minimum redundancy between features. The formula is as follows: in: S represents the selected input variable set, |S| represents the number of input variables, and c represents the output target value; D describes each input variable x in the input variable set S i The mean mutual information between the input variable set and the output target c reflects the correlation between the input variable set and the output target; R represents the size of the mutual information between variables in the input variable set S, describing the redundancy between the input variables.
5. According to the mRMR-EABiLSTM-TCN-based power load forecasting method of claim 4, Features: In step 2, the initial input variable set is represented as X and contains N features, S represents the selected feature set, and F represents the feature set to be selected. Applying mRMR to select the input variable set includes the following steps: Step 2.1, initialize the selected feature set S to be an empty set, and the feature set to be selected is X, that is, X→F, Step 2.2, Calculate x i The correlation with the target class c I(x i ; c); record x * To satisfy max[I(x i ; c)] The characteristics of the condition, let F-{x * }→F 1 ,{x * }→S 1 ; Step 2.3, let x i ∈F m-1 , x j ∈S m-1 (m=2,3,…,N), from F m-1 Find the idiom The maximum feature that holds true is denoted by x ** , let F m-1 -{x ** }→F m , S m-1 +{x ** }→S m ; Step 2.4, repeat step 2.3 until F is Then we get the candidate feature set S, and sort the features in S according to The values are sorted in descending order.
6. The power load forecasting method based on mRMR-EABiLSTM-TCN according to claim 1, Features: In step 3, the weights of each feature are adaptively allocated beyond the self-attention EA, including: F out =AM V in: A represents the attention matrix, Norm represents the normalization process, F represents each feature, and F out represents the attention vector; M∈R s×d Represents an introduced external spatial memory unit with a dimension of s×d.
7. The power load forecasting method based on mRMR-EABiLSTM-TCN according to claim 1, Features: In step 3, the bidirectional long short-term memory neural network BiLSTM closely links the current state with the past and future states, including: I t =σ(X t oh xi +H t-1 oh hi +b i ) F t =σ(x t oh xf +H t-1 oh hf +b f ) The t =σ(X t oh x0 +H t-1 oh ho +b o ) H t =O t ⊙tanh(C t ) in: F t , I t , O t Respectively represent the forget gate, input gate and output gate at time t; C t represents the state of the memory cell at time t, Represents the candidate memory cell state; H t Represents a hidden state in the forward propagation process; ω xi ,ω xf ,ω xo and xc represents the weight between the corresponding gate and the input, ω hi ,ω hf ,ω ho and ω hc represents the weight between the corresponding gates, b i 、b f 、b o and b c It represents the bias of the corresponding gate.
8. The power load forecasting method based on mRMR-EABiLSTM-TCN according to claim 1, Features: In step 3, the temporal convolutional network TCN consists of three parts: causal convolution, dilated convolution and residual connection. The dilated convolution operation F(m) of an element m is expressed as follows: in: x represents the input time series, k represents the convolution kernel size, i represents the number of dilated convolution operations, and x mdi represents the position of the input layer corresponding to the element m, d represents the dilated convolution coefficient, and f represents the convolution kernel. Represents a convolution operation.
9. The power load forecasting method based on mRMR-EABiLSTM-TCN according to claim 1, Features: In step 4, the forward selection algorithm has the following process: the feature subset starts from an empty set, and one feature is selected each time to be added to the feature subset so that the feature function is optimal; The collected original user load data is used as the input of the BiLSTM model improved by EA. After the time series features are initially extracted by EA, the extracted features are input into BiLSTM for further feature learning. The encapsulator working mode is adopted, and the initial value of the optimal input variable set is set to an empty set. The forward selection algorithm is used to add the input variables with the highest mutual information value to the selected input variable set one by one. After extracting features through the fully connected layer, the load features extracted by EABiLSTM and the key factor features extracted by the fully connected layer are concatenated and fused based on the concatenation function Concatenate in Python. The concatenated results are input into the TCN model to mine the coupling relationship between load and key factors. The optimal input variable set is determined based on the principle of minimum prediction error to optimize the user's short-term load forecasting accuracy.
10. A power load forecasting system based on mRMR-EABiLSTM-TCN, include: Data processing module, feature selection module, model building module, and prediction and evaluation module; The power load forecasting system based on mRMR-EABiLSTM-TCN according to any one of claims 1 to 9 is operated, characterized in that: The data processing module is used to collect power load data and characteristic factors that affect user power load, clean the collected data, process abnormal values and missing values, and perform normalization operations; The feature selection module is used to sort the importance of feature factors according to the maximum relevance and minimum redundancy algorithm, select the top N relevant features, and form a coarse feature set to focus on relevant features; The model building module is used to build a prediction model that comprehensively surpasses self-attention EA, bidirectional long short-term memory neural network BiLSTM and temporal convolutional network TCN. EA is used for adaptive weight allocation, BiLSTM is used to process time series features, and TCN is used to extract long-term dependencies to fully capture the characteristics of load data. The prediction and evaluation module is used to construct the mRMR-EABiLSTM-TCN model for short-term prediction of power load, evaluate the effectiveness of different input features, determine the optimal input feature set, and optimize the performance of the model.
11. A terminal comprising a processor and a storage medium; Features: The storage medium is used to store instructions; The processor is configured to operate according to the instructions to execute the steps of the method according to any one of claims 1-9.
12. A computer-readable storage medium having a computer program stored thereon, It is characterized in that When the program is executed by a processor, the steps of the method according to any one of claims 1 to 9 are implemented.
Citation Information
Cited By
Charging demand prediction method for highway new energy vehicle charging station
CN120952421A
