Load prediction method, system, equipment and medium
By integrating the convolutional neural network and LSTM algorithm with attention mechanism in the load prediction model, combined with the exception processing of the DBSCAN algorithm, the problem of poor accuracy and insufficient adaptability of the load prediction model is solved, and higher load prediction accuracy and stability are achieved.
Patent Information
- Application Number
- CN202411538758.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-31
- Publication Date
- 2025-02-25
AI Technical Summary
In the existing load prediction methods, poor model accuracy, insufficient adaptability of nonlinear problems, and abnormal information in the data affects prediction accuracy.
Long-short-term neural network (LSTM) and load prediction model of DBSCAN algorithm using convolutional neural networks with fusion attention mechanism. The abnormal data is detected through the DBSCAN algorithm, data smoothing is performed, and the prediction accuracy is improved by using attention mechanism and LSTM model.
Effectively detect and process abnormal data, improve the accuracy of the load prediction model, reduce the interference of non-important data characteristics on the model, and improve the ability to explore the relationship between historical load data and real-time load prediction.
Smart Images

Figure CN119518713A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of power grid load forecasting, and in particular to a load forecasting method, system, device and medium. Background Art
[0002] At present, there are two mainstream methods for load forecasting data, namely physical method and statistical method. The physical method requires the establishment of a complex parameter model, which has extremely high requirements for the accuracy of parameters and data, and the accuracy of the established model is not good; the statistical method uses artificial intelligence algorithms such as neural networks for prediction, but the current statistical methods are poorly adaptable to nonlinear problems, and when there are errors in the input data, the prediction accuracy of load forecasting data is also insufficient, making it difficult to fully explore the relationship between historical load data and real-time load forecasting. At the same time, since the statistical method requires a large amount of historical data, and some abnormal information exists in the data, it will affect the prediction accuracy of the statistical model. Summary of the invention
[0003] The present application provides a load forecasting method, system, device and medium to solve the problem of poor accuracy of load data forecasting models.
[0004] In one aspect, the present application provides a load forecasting method, the method comprising the following steps:
[0005] Step S1: construct and pre-train a load forecasting model, and input historical load forecasting data into the load forecasting model; wherein the load forecasting model integrates a long short-term neural network and a DBSCAN algorithm of a convolutional neural network with an attention mechanism;
[0006] Step S2: judging whether there is abnormal data in the historical load forecast data based on the DBSCAN algorithm;
[0007] Step S3: If there is abnormal data, the adjacent data of the time section are collected through the load forecasting model and the average value is calculated to perform data smoothing;
[0008] Step S4: training and optimizing the load prediction model based on the data after abnormal processing, inputting the operation data related to the power grid load, and generating the load prediction result.
[0009] In one implementation of the present application, in step S2, the DBSCAN algorithm is defined as follows: define η domain, define core target, define density direct access, define density reachable, and define density connected.
[0010] In one implementation of the present application, the definition of η domain is specifically as follows: for any input load forecasting impact data z di ∈Z d ,Zd ={z d1 ,z d2 ,...,z dn}, with z di The inner area of the circular area with η as the center and η as the radius is called η domain, and the information set of all influencing factors in the domain is: N η (z di )={z dj ∈D|distance(z di ,z dj )≤η}; The core goal is defined as: for any load forecasting impact data z di ∈Z d , the corresponding influencing factor information set N in the corresponding η field η (z di ) is greater than the value of MinPts, then the load forecast impact data is the core target: |N η (z di )|≥MinPts; the density is defined as follows: if there are two load forecasting influencing data z di ,z dj ∈Z d , z dj As the core goal and di In z dj The η domain is called z di With z dj Density reaches, when z di When it is also the core goal, it is also called z di With z dj Density is directly accessible; density is defined as: for multiple load forecasting impact data z d1 ,...z di ,z di+1 ,...,z dn ∈Z d , if z is satisfied di With z di+1 The density is directly proportional to z d1 With z dn Density can be reached; density connection is defined as follows: if the three load forecasts affect data z di ,z dj ,z dk ∈Z d , if z di With z dj All can be achieved through core objectives dk The density can reach, then z di With z dj Density connected.
[0011] In one implementation of the present application, in the attention mechanism part of the load forecasting model, for the measurement information, the historical measurement data from time 1 to time n-1 is set to Z = (z 1 ,z 2 ,…z n-1 )First, use the scoring function s as shown below:
[0012]
[0013] In the formula, H i , B i With B n is the weight for automatic learning update, tanh is the hyperbolic tangent function, which is used to calculate the correlation between each historical measurement data and the measurement data at time n, and the calculation result is normalized using the SoftMax normalized exponential function to obtain z n Attention distribution a in each historical measurement input i , and its calculation formula is:
[0014]
[0015] In the formula, exp is an exponential function. By performing weighted summation on the historical measurement data according to the attention distribution obtained in the formula, the input information that should be paid attention to can be obtained.
[0016] In one implementation of the present application, the convolutional neural network part classifies the connections according to the strength of their association, and assigns corresponding weights of the same convolution kernel to neurons of the same type, as shown in the following formula:
[0017]
[0018] In the formula, is the output matrix of the convolution operation, σ c is the convolutional layer activation function, z i,l-1 is the input information of the i-th window of the l-1 layer, ψ i,l and are the weight parameter matrix and bias parameter matrix of the input information, k j This is the location of the partial data feature tensor obtained at this time.
[0019] In one implementation of the present application, the pooling layer of the convolutional neural network is shown in the following formula:
[0020]
[0021] In the formula, is the output matrix of the pooling layer, p m is the maximum pooling function, z i,l-1is the input information corresponding to the i-th convolution kernel in layer l-1, W p The pooling layer is used to filter the strong and weak features of the data.
[0022] In one implementation of the present application, after the pooling layer features are screened, the fully connected layer is used to perform a fusion operation on each local deep-level data feature after processing, as shown in the following formula:
[0023]
[0024] In the formula, z o is the output of the fully connected layer, σ f is the fully connected layer activation function, z l-1 is the input of the entire l-1 layer, and The weight parameters and bias parameters of the fully connected layer are used to filter the filtered fine-grained features again, and the coarse-grained features are obtained by effectively integrating the fine-grained features. Then, all the input measurement information is efficiently utilized to obtain a reliable load forecasting model.
[0025] The present application also provides a load forecasting system, the system comprising:
[0026] An input unit, used for constructing and pre-training a load forecasting model, and inputting historical load forecasting data into the load forecasting model; wherein the load forecasting model incorporates a long short-term neural network and a DBSCAN algorithm of a convolutional neural network with an attention mechanism;
[0027] An abnormality judgment unit, used for judging whether there is abnormal data in the historical load forecast data based on the DBSCAN algorithm;
[0028] An abnormality processing unit is used to collect adjacent data of the time section through the load forecasting model and calculate the average value thereof to perform data smoothing if abnormal data exists;
[0029] The optimization prediction unit is used to train and optimize the load prediction model based on the data after abnormal processing, input the operation data related to the power grid load, and generate the load prediction result.
[0030] The present application also provides a load forecasting device, the device comprising:
[0031] at least one processor; and,
[0032] a memory communicatively connected to the at least one processor; wherein,
[0033] The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can complete the aforementioned load forecasting method.
[0034] The present application also provides a non-volatile computer storage medium for load forecasting, which stores computer executable instructions. The computer executable instructions are executed by a processor to implement the aforementioned load forecasting method.
[0035] The present application provides a load forecasting method, system, device and medium, which have the following beneficial effects:
[0036] (1) When the training data is abnormal, DBSCAN can effectively detect the outliers and smooth the output to reduce the impact on the load prediction accuracy;
[0037] (2) A time series model based on LSTM of convolutional neural network with attention mechanism is proposed and derived. This model can reduce the interference of non-important data features on the model and solve the shortcoming of traditional time series prediction model that is insensitive to important data features. BRIEF DESCRIPTION OF THE DRAWINGS
[0038] The drawings described herein are used to provide a further understanding of the present application and constitute a part of the present application. The illustrative embodiments of the present application and their descriptions are used to explain the present application and do not constitute an improper limitation on the present application. In the drawings:
[0039] Figure 1 A flow chart of a load forecasting method provided in an embodiment of the present application;
[0040] Figure 2 The overall algorithm flow chart provided for the embodiment of the present application;
[0041] Figure 3 A schematic diagram of the DBCSAN algorithm provided in the embodiment of the present application;
[0042] Figure 4 A schematic diagram of the CNN structure provided in the embodiment of the present application;
[0043] Figure 5 A diagram of the maximum pooling layer structure provided in an embodiment of the present application;
[0044] Figure 6 The average error diagram of the active power prediction value of the 118 system under different sequence lengths provided in the embodiment of the present application;
[0045] Figure 7 A graph showing average error of reactive power prediction values of 118 systems under different sequence lengths provided in an embodiment of the present application;
[0046] Figure 8 A composition diagram of a load forecasting system provided in an embodiment of the present application;
[0047] Fig. 9 A schematic diagram of a load forecasting device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0048] In order to make the purpose, technical solution and advantages of the present application clearer, the technical solution of the present application will be clearly and completely described below in combination with the specific embodiments of the present application and the corresponding drawings. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of the present application.
[0049] The embodiments of the present application provide a load forecasting method, system, device and medium. The technical solutions proposed in the embodiments of the present application are described in detail below with reference to the accompanying drawings.
[0050] Figure 1 A flow chart of a load forecasting method provided in an embodiment of the present application. Figure 1 As shown, the method mainly includes the following steps:
[0051] Step S1: construct and pre-train a load forecasting model, and input historical load forecasting data into the load forecasting model; wherein the load forecasting model integrates a long short-term neural network and a DBSCAN algorithm of a convolutional neural network with an attention mechanism;
[0052] Step S2: judging whether there is abnormal data in the historical load forecast data based on the DBSCAN algorithm;
[0053] Step S3: If there is abnormal data, the adjacent data of the time section are collected through the load forecasting model and the average value is calculated to perform data smoothing;
[0054] Step S4: training and optimizing the load prediction model based on the data after abnormal processing, inputting the operation data related to the power grid load, and generating the load prediction result.
[0055] In the embodiment of the present application, a load forecasting model of a long-term and short-term neural network based on a convolutional neural network with an attention mechanism and a DBSCAN algorithm is provided. The overall algorithm flow chart is as follows: Figure 2 The specific contents of the embodiments of the present application are described in detail below.
[0056] In the embodiment of the present application, determining whether the current input data contains bad information is the primary step in abnormal data processing. Considering that the scale of historical load forecasting influencing data is large, the traditional residual identification search method is inefficient. Therefore, a density-based spatial clustering algorithm is used to classify the error data and missing data in the load forecasting influencing data. To use the clustering algorithm, the following definition is first given:
[0057] (1) η domain: For any input load prediction impact data z di ∈Z d ,Z d ={z d1 ,z d2 ,...,z dn}, with z di The inner area of the circular area with η as the center and η as the radius is called η domain, and the information set of all influencing factors in the domain is:
[0058] N η (z di )={z dj ∈D|distance(z di ,z dj )≤η}
[0059] (2) Core goal: to predict the impact of any load on data z di ∈Z d , the corresponding influencing factor information set N in the corresponding η field η (z di ) is greater than the value of MinPts, then the load forecast impact data is the core target:
[0060] |N η (z di )|≥MinPts
[0061] (3) Density direct access: If there are two load forecasting influencing data z di ,z dj ∈Z d , z dj As the core goal and di In z dj The η domain is called z di With z dj Density reaches, when z di When it is also the core goal, it is also called z di With z dj Density direct.
[0062] (4) Density achievable: For multiple load forecasting impact data z d1 ,...z di ,zdi+1 ,...,z dn ∈Z d , if z is satisfied di With z di+1 The density is directly proportional to z d1 With z dn Density can reach.
[0063] (5) Density connection: If the three load forecasts affect the data z di ,z dj ,z dk ∈Z d , if z di With z dj All can be achieved through core objectives dk The density can reach, then z di With z dj Density connected.
[0064] To further explain the principle of DBSCAN in detail, the schematic diagram of the clustering algorithm is shown in Figure 3, which depicts the clustering results of three types of load forecasting influencing data. At this time, MinPts is 5, and the dotted circle is the η area. d1 There are six influencing factors in the η field (including z d1 ), so z d1 As the core goal, the influencing factor information d2 With z d1 Density direct, z d3 With z d1 The density can reach z d4 With z d3 Density connected. When the load forecast influencing data is input into DBSCAN, the clustering algorithm will mark multiple core targets in the load forecast influencing data used and establish a core target set according to the set domain radius η and the minimum number of included points MinPts of the core target within the domain radius. When the number of load forecast influencing data near the core target is less than the parameter MinPts, it is temporarily marked as bad data. After traversing all load forecast influencing data, the detection process of bad data is completed.
[0065] Load forecast data is affected by many factors such as user usage habits and time. Therefore, load data has a chronological change pattern. The time series data prediction algorithm can be used to mine the time series characteristics of historical load forecast data and construct reliable pseudo-measurement data. This application proposes a measurement data prediction method based on a convolutional neural network with an attention mechanism combined with a long short-term memory neural network.
[0066] The purpose of studying the attention mechanism is to intelligently assign weights to data. By calculating the influence weights of individual input data separately, the weight information of historical time series data is abstracted, and all information weight factors are weighted averaged to achieve adaptive weight allocation.
[0067] Taking measurement information as an example, suppose the historical measurement data from time 1 to time n-1 is Z = (z 1 ,z 2 ,…z n-1 )First, use the scoring function s as follows:
[0068]
[0069] In the formula, H i , B i With B n is the weight for automatic learning update, tanh is the hyperbolic tangent function, which is used to calculate the correlation between each historical measurement data and the measurement data at time n, and the calculation result is normalized using the SoftMax normalized exponential function to obtain z n Attention distribution a in each historical measurement input i , and its calculation formula is:
[0070]
[0071] In the formula, exp is an exponential function. By weighted summing the historical measurement data based on the attention distribution obtained above, the input information that should be paid attention to can be obtained.
[0072]
[0073] Considering the large capacity of historical data for load forecasting, the scale of model parameters will also increase with the increase of data scale, causing overfitting or training difficulties of neural networks, resulting in parameter explosion problems in predicting measurement information. Convolutional neural networks can use pooling and convolution to process data, locally connect data features and share weights to avoid problems such as parameter explosion. Its structure diagram is shown in the figure below. Figure 4 shown.
[0074] Compared with the fully connected mode of traditional neural networks, CNN uses partial connection when connecting upper-layer neurons to the convolutional layer to extract some features of the input information. At the same time, for all neurons in the same layer, CNN classifies them according to the strength of the connection correlation, and assigns corresponding weights to the same convolution kernel for neurons of the same type. The expression is shown in the following formula:
[0075]
[0076] In the formula, is the output matrix of the convolution operation, σ c is the convolutional layer activation function, z i,l-1 is the input information of the i-th window of the l-1 layer, ψ i,l and are the weight parameter matrix and bias parameter matrix of the input information, k j This is the location of the partial data feature tensor obtained at this time.
[0077] In order to further reduce the data size and network parameters, CNN sets a pooling layer after the convolution layer. Its expression is:
[0078]
[0079] In the formula, is the output matrix of the pooling layer, p m is the maximum pooling function, z i,l-1 is the input information corresponding to the i-th convolution kernel in layer l-1, W p The pooling layer selects strong and weak features of data features. This application uses the maximum pooling operation to divide all data features into multi-dimensional matrices, which can reduce the model size and increase the operation speed, while improving the robustness of the filtered features. Figure 5 shown.
[0080] After the original data information is refined by the convolution layer and filtered by the pooling layer, the fully connected layer performs a fusion operation on each local deep-level data feature after processing. The principle is shown in the following formula:
[0081]
[0082] In the formula, z o is the output of the fully connected layer, σ f is the fully connected layer activation function, z l-1 is the input of the entire l-1 layer, and are the weight parameters and bias parameters of the fully connected layer. In this section, the LSTM neural network is used to filter the fine-grained features after ATT and CNN, and the fine-grained features are effectively integrated to obtain coarse-grained features, and then all the input measurement information is efficiently utilized to obtain a reliable load forecasting data model.
[0083] In the embodiment of the present application, the IEEE 118 node node system is used for simulation testing. The power grid load data comes from the actual load data set of the 2020 Global Energy Forecasting Competition, and the model is trained using PYTHON software. The computer configuration is Win10 system, the processor is Intel Core i7-8700k series, the main frequency is 3.0GHz, the graphics card is GTX-1660TI, and the memory is 16G. The TensorFlow and Keras toolboxes are selected for training the load forecasting model. In the IEEE 118 node test system, the load data of 2017 is selected to generate 8760 measurement state sets, and 4000 groups of data are randomly selected as training sets. 8760 data are generated as test sets using the load data of 2018, and the data are normalized using the mapminmax function in Matlab. The number of LSTM neurons is selected as shown in Table 1 below.
[0084] Table 1 LSTM neuron number selection table
[0085]
[0086] The algorithm performance corresponding to different sample capture numbers and iteration times is shown in Table 2.
[0087] Table 2 Algorithm table corresponding to different sample capture numbers and iteration times
[0088]
[0089] It can be seen from Tables 1 and 2 that the model has the best performance when the number of LSTM neurons is 64 and 64 respectively, and the number of sample captures and the number of iterations are 32 and 8 respectively. In the embodiment of the present application, the CNN parameter selection is shown in Table 3 below.
[0090] Table 3 CNN parameter selection table
[0091]
[0092] In the examples of the present application, the accuracy comparison of different models was tested, as shown in Table 4 below.
[0093] Table 4 Comparison of prediction accuracy of different models
[0094]
[0095] As shown in Table 4, the LSTM using neural network and ATT-CNN-LSTM (long short-term neural network of convolutional neural network with attention mechanism) are both better than the unscented Kalman prediction algorithm in performance. The LSTM algorithm before and after the improvement is modeled by historical data, and no prior assumptions are required for the model. When the internal rules of the data are unknown, the neurons in the network can be called to learn and train the data, explore the hidden functional relationship between the data, and collect more accurate data features. As a result, the MAE is reduced by nearly 3 times on average, and the prediction accuracy is higher; the RMSE is maintained at the order of 10–4, and the prediction data fluctuates less. The comparison results of the predicted value and the true value of the ATT-CNN-LSTM model performance and the traditional LSTM model are shown in Table 5.
[0096] Table 5 Comparison of prediction accuracy under two models
[0097]
[0098] As can be seen from Table 5, in terms of prediction accuracy, compared with the traditional LSTM, the ATT-CNN-LSTM method proposed in this application has a prediction accuracy of nearly 2 times in the three consecutive node sequences listed, and the RMSE is maintained at the order of 10-4. This shows that the method of this application is superior to the traditional LSTM method in both prediction accuracy and prediction error stability.
[0099] In order to further verify that the method of this application still has superior prediction performance on long time series, this application predicts the voltage and phase angle of the sampling points with a sampling length of 1-1500 and a step size of 500. The MAE and RMSE between the predicted value of the whole system state and the true value are shown in Table 6.
[0100] Table 6 Prediction accuracy results of the whole system
[0101]
[0102] As can be seen from Table 6, the attention mechanism used extracts high-weight features from the data set and optimizes the input data, making the RMSE and MAE both stable at 10 –4 with 10 –3 This further verifies that the proposed method has the advantages of strong prediction stability and high accuracy. In order to intuitively analyze the model prediction performance and error fluctuation range, Figure 6 Figure 7 The MAE trend over time is plotted. The RMSE of the model in this application is stable at 10 –4 This indicates that this method has good accuracy and prediction stability.
[0103] The above is a load forecasting method provided by an embodiment of the present application. Based on the same inventive concept, an embodiment of the present application also provides a load forecasting system. Figure 8 A load forecasting system composition diagram provided in an embodiment of the present application, such as Figure 8 As shown, the system mainly includes: an input unit 801, which is used to construct and pre-train a load forecasting model, and input historical load forecasting data into the load forecasting model; wherein the load forecasting model integrates a long-term and short-term neural network of a convolutional neural network with an attention mechanism and a DBSCAN algorithm; an abnormality judgment unit 802, which is used to judge whether there is abnormal data in the historical load forecasting data based on the DBSCAN algorithm; an abnormality processing unit 803, which is used to collect adjacent data of the time section through the load forecasting model and calculate the average value thereof, and perform data smoothing processing if abnormal data exists; an optimization prediction unit 804, which is used to train and optimize the load forecasting model based on the data after abnormality processing, input the operation data related to the power grid load, and generate a load forecasting result.
[0104] The above is a load forecasting system provided by an embodiment of the present application. Based on the same inventive concept, an embodiment of the present application also provides a load forecasting device. Fig. 9 A schematic diagram of a load forecasting device provided in an embodiment of the present application is shown in FIG. Fig. 9 As shown, the device mainly includes: at least one processor 901; and a memory 902 communicatively connected to the at least one processor; wherein the memory 902 stores instructions executable by the at least one processor 901, and the instructions are executed by the at least one processor 901 so that the at least one processor 901 can complete the aforementioned load forecasting method.
[0105] In addition, an embodiment of the present application further provides a non-volatile computer storage medium for load forecasting, which stores computer executable instructions, and the computer executable instructions are executed by a processor to implement the aforementioned load forecasting method.
[0106] 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.
[0107] 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 including 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.
[0108] 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 in the computer or other programmable device. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.
[0109] In a typical configuration, a computing device includes one or more processors (CPU), input / output interfaces, network interfaces, and memory.
[0110] Each embodiment in this application is described in a progressive manner, and the same or similar parts between the embodiments can be referred to each other, and each embodiment focuses on the differences from other embodiments. In particular, for the device embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the partial description of the method embodiment.
[0111] It should also be noted that the terms "include", "comprises" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, commodity or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, commodity or device. In the absence of more restrictions, the elements defined by the sentence "comprises a ..." do not exclude the existence of other identical elements in the process, method, commodity or device including the elements.
[0112] The above is only an embodiment of the present application and is not intended to limit the present application. For those skilled in the art, the present application may have various changes and variations. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present application should be included in the scope of the claims of the present application.
Claims
1. A load forecasting method, characterized in that: The method comprises the following steps: Step S1: construct and pre-train a load forecasting model, and input historical load forecasting data into the load forecasting model; wherein the load forecasting model integrates a long short-term neural network and a DBSCAN algorithm of a convolutional neural network with an attention mechanism; Step S2: judging whether there is abnormal data in the historical load forecast data based on the DBSCAN algorithm; Step S3: If there is abnormal data, the adjacent data of the time section are collected through the load forecasting model and the average value is calculated to perform data smoothing; Step S4: training and optimizing the load prediction model based on the data after abnormal processing, inputting the operation data related to the power grid load, and generating the load prediction result.
2. A load forecasting method according to claim 1, characterized in that: In step S2, the definition of the DBSCAN algorithm is as follows: define η domain, define core target, define density direct, define density reachable, and define density connected.
3. A load forecasting method according to claim 2, characterized in that: The definition of η domain is as follows: for any input load forecast impact data z di ∈Z d ,Z d ={z d1 ,z d2 ,...,z dn }, with z di The inner area of the circular area with η as the center and η as the radius is called η domain, and the information set of all influencing factors in the domain is: N η (z di )={z dj ∈D|distance(z di ,z dj )≤η}; The core goal is defined as: for any load forecasting impact data z di ∈Z d , the corresponding influencing factor information set N in the corresponding η field η (z di ) is greater than the value of MinPts, then the load forecast impact data is the core target: |N η (z di )|≥MinPts; the density is defined as follows: if there are two load forecasting influencing data z di ,z dj ∈Z d , z dj As the core goal and di In z dj The η domain is called z di With z dj Density reaches, when z di When it is also the core goal, it is also called z di With z dj Density is directly accessible; density is defined as: for multiple load forecasting impact data z d1 ,...z di ,z di+1 ,...,z dn ∈Z d , if z is satisfied di With z di+1 The density is directly proportional to z d1 With z dn Density can be reached; density connection is defined as follows: if the three load forecasts affect data z di ,z dj ,z dk ∈Z d , if z di With z dj All can be achieved through core objectives dk The density can reach, then z di With z dj Density connected.
4. A load forecasting method according to claim 1, characterized in that: In the attention mechanism part of the load forecasting model, for the measurement information, the historical measurement data from time 1 to time n-1 is assumed to be Z = (z1, z2, … z n-1 )First, use the scoring function s as shown below: In the formula, H i , B i With B n is the weight for automatic learning update, tanh is the hyperbolic tangent function, which is used to calculate the correlation between each historical measurement data and the measurement data at time n, and the calculation result is normalized using the SoftMax normalized exponential function to obtain z n Attention distribution a in each historical measurement input i , and its calculation formula is: In the formula, exp is an exponential function. By performing weighted summation on the historical measurement data according to the attention distribution obtained in the formula, the input information that should be paid attention to can be obtained.
5. A load forecasting method according to claim 1, characterized in that: The convolutional neural network classifies the connections according to their strength, and assigns the same convolution kernel to neurons of the same type. The expression is as follows: In the formula, is the output matrix of the convolution operation, σ c is the convolutional layer activation function, z i,l-1 is the input information of the i-th window of the l-1 layer, ψ i,l With l are the weight parameter matrix and bias parameter matrix of the input information, k j This is the location of the partial data feature tensor obtained at this time.
6. A load forecasting method according to claim 1, characterized in that: The pooling layer of the convolutional neural network is shown in the following formula: In the formula, is the output matrix of the pooling layer, p m is the maximum pooling function, z i,l-1 is the input information corresponding to the i-th convolution kernel in layer l-1, W p The pooling layer is used to filter the strong and weak features of the data.
7. A load forecasting method according to claim 6, characterized in that: After the pooling layer features are filtered, the fully connected layer is used to fuse the deep data features of each local area after processing, as shown in the following formula: In the formula, z o is the output of the fully connected layer, σ f is the fully connected layer activation function, z l-1 is the input of the entire l-1 layer, and The weight parameters and bias parameters of the fully connected layer are used to filter the filtered fine-grained features again, and the coarse-grained features are obtained by effectively integrating the fine-grained features. Then, all the input measurement information is efficiently utilized to obtain a reliable load forecasting model.
8. A load forecasting system, characterized in that: The system comprises: An input unit, used for constructing and pre-training a load forecasting model, and inputting historical load forecasting data into the load forecasting model; wherein the load forecasting model incorporates a long short-term neural network and a DBSCAN algorithm of a convolutional neural network with an attention mechanism; An abnormality judgment unit, used for judging whether there is abnormal data in the historical load forecast data based on the DBSCAN algorithm; An abnormality processing unit is used to collect adjacent data of the time section through the load forecasting model and calculate the average value thereof to perform data smoothing if abnormal data exists; The optimization prediction unit is used to train and optimize the load prediction model based on the data after abnormal processing, input the operation data related to the power grid load, and generate the load prediction result.
9. A load forecasting device, characterized in that: The device comprises: at least one processor; and, a memory communicatively connected to the at least one processor; wherein, The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can complete a load forecasting method as described in any one of claims 1-7.
10. A non-volatile computer storage medium for load forecasting, storing computer executable instructions, characterized in that: The computer executable instructions are executed by a processor to implement a load forecasting method as described in any one of claims 1-7.