Summer load prediction model construction method, prediction method, equipment and medium

By combining whale optimization algorithm based on historical data and long-term memory network model, the problem of load prediction results in the prior art is solved, and more accurate summer load prediction is achieved.

CN119624162APending Publication Date: 2025-03-14CHINA ELECTRIC POWER RESEARCH INSTITUTE CO LTD +3
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411502366.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-10-25
Publication Date
2025-03-14

AI Technical Summary

Technical Problem

In the prior art, the year is directly used as a parameter to predict summer loads, making it difficult to track the load transformation trend in real time, resulting in the prediction results far below the actual value.

Method used

Based on historical summer load data and historical load influencing factor data during the same period, the annual load correction coefficient is optimized through the whale optimization algorithm, the historical load data is corrected, and the long-term and short-term memory network model is used for training to improve prediction accuracy.

Benefits of technology

Effectively tracking the transformation trend of summer loads enhances the availability of load data and improves the accuracy of prediction results.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119624162A_ABST
    Figure CN119624162A_ABST
Patent Text Reader

Abstract

The invention provides a summer load prediction model construction method, a summer load prediction method, equipment and a medium, and relates to the technical field of power consumption management. In the summer load prediction model provided by the invention, based on the historical summer load data and the historical load influence factor data of the same period, the whale optimization algorithm is utilized to obtain the optimized load annual correction coefficient, and then the trained long-short-term memory network model is utilized to verify the optimized load annual correction coefficient. Obtaining an optimal load annual correction coefficient and a trained long short-term memory network model, taking the optimal load annual correction coefficient and the trained long short-term memory network model as a trained summer load prediction model, and correcting historical load data of different years in time by using the optimal load annual correction coefficient. According to the method, the transformation trend of the summer load is effectively tracked, the availability of summer load data is enhanced, and the accuracy of predicting the generated summer load is improved through the trained long-short-term memory network model.
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 management, and in particular to a summer load forecasting model construction method, a forecasting method, a device and a medium. Background Art

[0002] With the frequent occurrence of extreme high temperatures during the summer, the uncertainty in the amplitude of both the source and load sides of the new power system has gradually increased. It is urgent to normalize the flexible adjustment role of demand-side resources. Accurate prediction of summer load plays an important supporting role in ensuring power supply.

[0003] The load forecasting method disclosed in the prior art uses the load data of continuous time in historical records. When processing the load data of different years, the year is directly input as a parameter into the summer load forecasting model to obtain the predicted value of the summer load.

[0004] The load forecasting method disclosed in the prior art directly uses the year as a parameter to forecast the summer load, which makes it difficult to track the change trend of the summer load in real time, resulting in the generated forecast result being far lower than the actual value. Summary of the invention

[0005] In order to solve the problem that the existing technology uses the year as a parameter to directly predict the summer load, resulting in the generated prediction result being far lower than the actual value, the present invention proposes a summer load prediction model construction method, prediction method, device and medium. In the summer load prediction method provided by the present invention, based on the historical summer load data and the historical load influencing factor data of the same period, the historical summer load data is corrected by using the summer load prediction model, and the historical load data of different years are corrected in time, which effectively realizes the tracking of the change trend of the summer load and enhances the availability of the summer load data; by predicting the summer load using the constructed summer load prediction model, the accuracy of the generated prediction result is improved.

[0006] In one aspect, the present invention provides a method for constructing a summer load forecasting model, comprising:

[0007] Comprehensively obtain the historical summer load data recorded in previous years and the historical load influencing factor data of the same period to obtain the historical load data;

[0008] Dividing the historical load data into a training set and a validation set;

[0009] The initial load year correction coefficient is optimized by the whale optimization algorithm to obtain the optimized load year correction coefficient; the training set and the validation set are respectively corrected by using the optimized load year correction coefficient, and the long short-term memory network model is trained based on the corrected training set; based on the corrected validation set, the trained long short-term memory network model is used to perform prediction to obtain the prediction result; the prediction result is evaluated to obtain the optimal load year correction coefficient;

[0010] Based on the optimal load annual correction coefficient and the trained long short-term memory network model, a final summer load forecasting model is obtained.

[0011] Optionally, the initial load annual correction coefficient is optimized by the whale optimization algorithm to obtain an optimized load annual correction coefficient; the training set and the validation set are respectively corrected by using the optimized load annual correction coefficient, and the long short-term memory network model is trained based on the corrected training set; based on the corrected validation set, prediction is performed using the trained long short-term memory network model to obtain a prediction result; the prediction result is evaluated to obtain the optimal load annual correction coefficient, including:

[0012] The initial load annual correction coefficient is optimized by the whale optimization algorithm to obtain multiple optimized load annual correction coefficients;

[0013] Using each optimized load year correction coefficient to correct the training set respectively, to obtain a plurality of corrected training sets, and using each corrected training set to train the long short-term memory network model respectively, to obtain a plurality of trained long short-term memory network models;

[0014] The validation set is corrected using each optimized load year correction coefficient to obtain multiple corrected validation sets, and each corrected validation set is used to perform predictions through the corresponding long short-term memory network model to obtain multiple prediction results and the prediction error of each prediction result;

[0015] Select the optimized load annual correction factor corresponding to the minimum forecast error among the forecast errors;

[0016] If the iteration termination condition is met, the optimized annual load correction factor corresponding to the minimum prediction error is used as the optimal annual load correction factor;

[0017] If the iteration termination condition is not met, the whale optimization algorithm is used to continue optimizing the optimized load annual correction coefficient corresponding to the minimum prediction error to obtain multiple next-generation optimized load annual correction coefficients.

[0018] Optionally, the initial load annual correction coefficient is optimized by the whale optimization algorithm to obtain multiple optimized load annual correction coefficients, including:

[0019] Initialize the whale population, maximum number of iterations and search space of the whale optimization algorithm, and use the current average annual load growth rate as the initial position of each individual whale in the whale population, and the initial position of each individual whale in the whale population corresponds to the initial load annual correction coefficient;

[0020] Based on the search space, the position of each individual whale is optimized using the whale optimization algorithm to obtain the optimized position of each individual whale, and the optimized position of each individual whale is used as the annual correction coefficient of each optimized load.

[0021] Optionally, the validation set is corrected using each optimized load year correction coefficient to obtain multiple corrected validation sets, and each corrected validation set is used to perform predictions through a corresponding long short-term memory network model to obtain multiple prediction results and a prediction error of each prediction result, including:

[0022] For each individual whale after each optimization, the position of each individual whale after optimization is used as a load year correction coefficient to correct the verification set, so as to obtain a plurality of corrected verification sets;

[0023] Each corrected validation set is predicted by the corresponding long short-term memory network model to obtain multiple prediction results;

[0024] Based on the actual value in each corrected validation set and each predicted result, the prediction error of each predicted result is calculated.

[0025] Optionally, the prediction error of each prediction result includes:

[0026] The average absolute error between the predicted value and each actual value corresponding to each prediction result.

[0027] Optionally, the mean absolute error satisfies the following expression:

[0028]

[0029] Where η s is the mean absolute error of the prediction result after correction using the position of the sth whale individual as the annual correction coefficient for the optimized load; δ is the δth data in the validation set corrected using the position of the sth whale individual, δ = 1, ..., m val ;m val The amount of data in the validation set corrected to use the position of the sth whale individual; The predicted value of the δth data in the prediction result obtained by using the long short-term memory network model to predict the position of the sth whale individual after the correction of the validation set; is the actual value of the δth data in the validation set corrected using the position of the sth whale individual.

[0030] Optionally, the historical load influencing factor data includes: meteorological data and day type;

[0031] The meteorological data include: daily minimum temperature, daily average temperature, daily maximum temperature and humidity; the day types include: working days and holidays.

[0032] Optionally, the trained long short-term memory network model is expressed as follows:

[0033] LSTM(x,c t-1 ,h t-1 )=(c,h),

[0034] c t =f t ⊙c t-1 +i t ⊙g t ,

[0035]

[0036] f t =σ(W fx x+W fh h t-1 +b f ),

[0037] i t =σ(W ix x+W ih h t-1 +b i ),

[0038] g t =σ(W gx x+W gh h t-1 +b g ),

[0039] o t =σ(W ox x+W oh h t-1 +b o ),

[0040] Where, LSTM() is the trained long short-term memory network model; x is the current value of the historical load influencing factor data; c t-1is the historical state information corresponding to time t-1. If the forget gate is fully closed and takes a value of 0, it corresponds to that the historical load influencing factor data has no effect on the current state; if the forget gate is fully opened and takes a value of 1, the historical load influencing factor data is completely transmitted to time t; if the value is between 0 and 1, it represents partial transmission of the historical load influencing factor data; h t-1 represents the output value of the hidden layer node of the long short-term memory network model at the last time t-1; c is the state value update function of the long short-term memory network model; c t is the historical state information corresponding to time t; h is the output value function of the hidden layer node of the long short-term memory network model; o is the current output value of the output gate; is the tanh function; f t is the forget gate, which is used to control the historical load influencing factor data allowed to enter at time t; i t is the input gate, which is used to represent the historical load influencing factor data in the revised training set; g t It is an input node, which is used to indicate the amount of data allowed to enter in the control input amount; t is the output gate, which is used to indicate the load forecast result at time t obtained based on the load influencing factor data in the modified training set; W fx W is the weight matrix of the forget gate multiplied by the current input value x; fh is the forget gate and the output value h of the previous moment t-1 The multiplied weight matrix; W ix For the input gate and the current input value x t The multiplied weight matrix; W ih is the input gate and the output value h at the previous moment t-1 The multiplied weight matrix; W gx W is the weight matrix of the input node multiplied by the current input value x; gh is the input node and the output value h at the previous moment t-1 The multiplied weight matrix; W ox W is the weight matrix that multiplies the output gate by the current input value x; oh is the output gate and the output value h at the previous moment t-1 The multiplied weight matrix; b f is the bias matrix of the forget gate; b i is the bias matrix of the input gate; b g is the bias matrix of the input node; b o is the bias matrix of the output gate; ⊙ is the vector multiplication symbol; σ is the sigmoid function.

[0041] Optionally, after determining the final summer load forecasting model based on the optimal load annual correction coefficient and the trained long short-term memory network model, the method further includes:

[0042] Based on a pre-constructed test set, the test set is corrected using the optimal load annual correction coefficient, and prediction is performed based on the corrected test set using the trained long short-term memory network model to obtain a predicted value;

[0043] Determine the index value of the performance evaluation index of the summer load forecasting model according to the predicted value and the true value in the corrected test set, wherein the performance evaluation index includes the mean absolute percentage error, the mean absolute error or the determination coefficient;

[0044] The performance of the summer load forecasting model is evaluated using the index value of the performance evaluation index.

[0045] Optionally, if the performance evaluation index includes a mean absolute percentage error, the process of determining the index value of the performance evaluation index of the summer load forecasting model according to the predicted value and the true value in the corrected test set satisfies the following expression:

[0046]

[0047] Where M APE is the average absolute percentage error of the summer load forecasting model; δ1 is the δ1th data in the test set corrected by the optimal load year correction coefficient, δ1 = 1, ..., m test ;m test is the number of data in the corrected test set; is the true value corresponding to the δ1th data in the corrected test set; is the predicted value corresponding to the δ1th data in the corrected test set.

[0048] Optionally, if the performance evaluation index includes a mean absolute error, the process of determining the index value of the performance evaluation index of the summer load forecasting model according to the predicted value and the true value in the corrected test set satisfies the following expression:

[0049]

[0050] Where M AE is the average absolute error of the summer load forecasting model; δ1 is the δ1th data in the test set corrected by the optimal load annual correction coefficient, δ1 = 1, ..., m test ;m test is the number of data in the corrected test set; is the true value corresponding to the δ1th data in the corrected test set; is the predicted value corresponding to the δ1th data in the corrected test set.

[0051] Optionally, if the performance evaluation index includes a determination coefficient, the process of determining the index value of the performance evaluation index of the summer load forecasting model according to the predicted value and the true value in the corrected test set satisfies the following formula:

[0052]

[0053] In the formula, R 2 is the determination coefficient of the summer load forecasting model; δ1 is the δ1th data in the test set corrected by the optimal load year correction coefficient, δ1 = 1, ..., m test ;m test is the number of data in the corrected test set; is the true value corresponding to the δ1th data in the corrected test set; is the predicted value corresponding to the δ1th data in the corrected test set; is the sample expectation of the δ1th sample in the corrected test set.

[0054] On the other hand, the present invention also proposes a summer load forecasting model construction system, comprising:

[0055] A data acquisition unit is used to comprehensively acquire historical summer load data recorded in previous years and historical load influencing factor data of the same period to obtain historical load data;

[0056] A data partitioning unit, connected to the data acquisition unit for partitioning the historical load data into a training set and a validation set;

[0057] A correction coefficient acquisition unit is used to optimize the initial load year correction coefficient by using a whale optimization algorithm to obtain an optimized load year correction coefficient; use the optimized load year correction coefficient to respectively correct the training set and the verification set, and train the long short-term memory network model based on the corrected training set; based on the corrected verification set, use the trained long short-term memory network model to perform prediction to obtain a prediction result; evaluate the prediction result to obtain an optimal load year correction coefficient;

[0058] The prediction model output unit is used to obtain the final summer load prediction model based on the optimal load annual correction coefficient and the trained long short-term memory network model.

[0059] Optionally, the correction coefficient acquisition unit includes:

[0060] The optimization coefficient acquisition module is used to optimize the initial load annual correction coefficient through the whale optimization algorithm to obtain multiple optimized load annual correction coefficients;

[0061] A memory network model building module is used to respectively use each optimized load year correction coefficient to correct the training set to obtain multiple corrected training sets, and use each corrected training set to respectively train the long short-term memory network model to obtain multiple trained long short-term memory network models;

[0062] The prediction result output module is used to correct the verification set using each optimized load year correction coefficient to obtain multiple corrected verification sets, and use each corrected verification set to perform predictions through the corresponding long short-term memory network model to obtain multiple prediction results and the prediction error of each prediction result;

[0063] A correction coefficient output module is used to select the optimized load annual correction coefficient corresponding to the minimum prediction error among the prediction errors;

[0064] If the iteration termination condition is met, the optimized annual load correction factor corresponding to the minimum prediction error is used as the optimal annual load correction factor;

[0065] If the iteration termination condition is not met, the whale optimization algorithm is used to continue optimizing the optimized load annual correction coefficient corresponding to the minimum prediction error to obtain multiple next-generation optimized load annual correction coefficients.

[0066] Optionally, the optimization coefficient acquisition module is specifically used for:

[0067] Initialize the whale population, maximum number of iterations and search space of the whale optimization algorithm, and use the current average annual load growth rate as the initial position of each individual whale in the whale population, and the initial position of each individual whale in the whale population corresponds to the initial load annual correction coefficient;

[0068] Based on the search space, the position of each individual whale is optimized using the whale optimization algorithm to obtain the optimized position of each individual whale, and the optimized position of each individual whale is used as the annual correction coefficient of each optimized load.

[0069] Optionally, the prediction result output module is specifically used for:

[0070] For each individual whale after each optimization, the position of each individual whale after optimization is used as a load year correction coefficient to correct the verification set, so as to obtain a plurality of corrected verification sets;

[0071] Each corrected validation set is predicted by the corresponding long short-term memory network model to obtain multiple prediction results;

[0072] Based on the actual value in each corrected validation set and each predicted result, the prediction error of each predicted result is calculated.

[0073] In another aspect, the present invention further proposes a summer load forecasting method, the method comprising:

[0074] Obtain the current summer load data and the current historical load influencing factor data to obtain the load data to be predicted;

[0075] Based on the load data to be predicted, a summer load prediction model is used to perform prediction to obtain a summer load prediction value;

[0076] The summer load forecasting model is constructed using the summer load forecasting model construction method described in the above technical solution.

[0077] Optionally, before performing prediction based on the load data to be predicted using a summer load prediction model to obtain a summer load prediction value, the method further includes:

[0078] The load data to be predicted is normalized.

[0079] In another aspect, the present invention further provides a summer load forecasting system, the system comprising:

[0080] The to-be-predicted data acquisition unit is used to acquire the current summer load data and the current load influencing factor data to obtain the to-be-predicted load data;

[0081] A summer load data prediction unit, used to perform prediction based on the load data to be predicted using a summer load prediction model to obtain a summer load prediction value;

[0082] The summer load forecasting model is constructed using the summer load forecasting model construction method described in the above technical solution.

[0083] Optionally, also include:

[0084] A data processing unit is used to normalize the load data to be predicted.

[0085] In another aspect, the present invention further provides a computer device, comprising: at least one processor and a memory; the memory and the processor are connected via a bus;

[0086] The memory is used to store one or more programs;

[0087] When the one or more programs are executed by the at least one processor, the summer load forecasting model construction method or the summer load forecasting method as described in the above technical solution is implemented.

[0088] On the other hand, the present invention further proposes a readable storage medium having an execution program stored thereon, and when the execution program is executed, the summer load forecasting model construction method or the summer load forecasting method as described in the above technical solution is implemented.

[0089] Compared with the prior art, the present invention has the following beneficial effects:

[0090] The present invention provides a method for constructing a summer load prediction model. Based on historical summer load data and historical load influencing factor data of the same period, an optimized load annual correction coefficient is obtained by using a whale optimization algorithm, and then the optimized load annual correction coefficient is verified by using a trained long short-term memory network model to obtain an optimal load annual correction coefficient and a trained long short-term memory network model. The optimal load annual correction coefficient and the trained long short-term memory network model are used as a trained summer load prediction model, and the historical load data of different years are corrected in time using the optimal load annual correction coefficient, so as to effectively track the change trend of the summer load, enhance the availability of the summer load data, and improve the accuracy of the predicted summer load by using the trained long short-term memory network model.

[0091] The present invention provides a summer load forecasting method. Based on historical summer load data and historical load influencing factor data of the same period, a summer load forecasting model is used to correct the historical summer load data, and the historical load data of different years are corrected in time, so as to effectively track the changing trend of the summer load and enhance the availability of the summer load data. The summer load is predicted by using the constructed summer load forecasting model, so as to improve the accuracy of the generated prediction results. BRIEF DESCRIPTION OF THE DRAWINGS

[0092] Figure 1 A flow chart of a method for constructing a summer load forecasting model proposed by the present invention;

[0093] Figure 2 A flow chart of obtaining the optimal annual load correction coefficient in a summer load forecasting model construction method proposed by the present invention;

[0094] Figure 3 A flow chart of predicting summer load in a summer load prediction method proposed by the present invention;

[0095] Figure 4 This is a schematic diagram of the structure of the electronic device proposed by the present invention. DETAILED DESCRIPTION

[0096] Embodiment 1:

[0097] Reference Figure 1 The present invention provides a method for constructing a summer load forecasting model, comprising:

[0098] S1, comprehensively obtain the historical summer load data recorded in previous years and the historical load influencing factor data of the same period to obtain the historical load data;

[0099] S2, dividing the historical load data into a training set and a validation set;

[0100] S3, optimizing the initial load annual correction coefficient by the whale optimization algorithm to obtain the optimized load annual correction coefficient; using the optimized load annual correction coefficient to respectively correct the training set and the validation set, and training the long short-term memory network model based on the corrected training set; based on the corrected validation set, using the trained long short-term memory network model to perform prediction to obtain a prediction result; evaluating the prediction result to obtain the optimal load annual correction coefficient;

[0101] S4, obtaining a final summer load forecasting model based on the optimal load annual correction coefficient and the trained long short-term memory network model.

[0102] Exemplarily, the historical load influencing factor data for the same period as the historical summer load data include: meteorological data and day type; the meteorological data include: daily minimum temperature, daily average temperature, daily maximum temperature and humidity; the day type includes: working days and holidays. The day type uses 1 to represent working days and 0 to represent holidays.

[0103] According to the historical summer load data recorded in previous years and the historical load influencing factor data of the same period, a two-dimensional matrix is ​​comprehensively established. The two-dimensional matrix is ​​used as the historical load data. The historical load data is divided according to the proportion to obtain the training set, verification set and test set respectively.

[0104] For example, the historical load data is divided into training set data and tra,s , validation set data pre,s And test set data test,s .

[0105] Among them, the training set data tra,s Used for long short-term memory network model training, validation set data pre,s It is used to optimize the annual load correction factor, and the test set data test,s Used to evaluate the performance of the obtained summer load forecasting model.

[0106] In some embodiments, in order to facilitate the management of the acquired historical load data, the present invention can also normalize the acquired historical load data. The normalized data can reduce the differences in the historical load data, thereby facilitating the training of the long short-term memory network model and improving the training speed and accuracy of the long short-term memory network model.

[0107] For example, the Long Short-Term Memory (LSTM) network model adds a forget gate, an input gate, and an output gate on the basis of a recurrent neural network (RNN), which can achieve long-term storage of information. Among them, the forget gate is used to control how much information in the historical state c(t-1) is allowed to enter at time t; the input gate is used to control how much information in the input g(t) is allowed to enter and exit; the output gate is used to control how much information in the state value c(t) at time t is displayed to the outside, and the information displayed to the outside is the predicted summer load value at time t.

[0108] By training with the long short-term memory network model, it is possible to establish a connection between the summer load data in the historical load data and the historical load influencing factor data, and to improve the influence of the main factors in the historical load influencing factor data on the historical summer load data according to time, while avoiding dependence on the main factors in the historical load influencing factor data, thereby achieving the accuracy of the summer load prediction results.

[0109] In order to obtain the optimal annual load correction coefficient for correcting historical summer load data, the present invention obtains the next generation of optimized load annual correction coefficient by utilizing the whale optimization algorithm. During the iteration process, the next generation of optimized load annual correction is used as the base value, and the hunting behavior of the whale optimization algorithm is used to iterate and obtain the optimal annual load correction coefficient.

[0110] The whale optimization algorithm (WOA) is a new group intelligence optimization search method proposed by Mirjalili and Lewis in 2001. The algorithm is derived from the simulation of the hunting behavior of humpback whale groups in nature. The optimization process using the whale optimization algorithm includes at least two stages: hunting and searching.

[0111] During the hunting phase, individual whales randomly perform contraction or spiral movements to get closer to their prey. When a whale performs contraction, it moves closer to the whale closest to the target prey. The position update formula is:

[0112]

[0113] Where X(n+1) is the updated position vector of the current whale; X(n) is the position vector of the current whale; X * (n) is the best whale position vector at present; D h is the distance between the individual whale and the current best whale position; n is the current iteration number; A and C are coefficients.

[0114] In the hunting phase of the whale optimization algorithm, by reducing the value of a, the fluctuation range of A can be reduced, thereby simulating the whale's shrinking and surrounding behavior. The calculation formulas for coefficients A and C are:

[0115]

[0116] Where r1 and r2 are random numbers in [0,1]; the value of a decreases linearly from 2 to 0 with the number of iterations; n is the current number of iterations; N max is the maximum number of iterations.

[0117] The mathematical model for a humpback whale swimming toward its prey in a spiral motion is:

[0118]

[0119] Where X(n+1) is the updated position vector of the current whale position; X * (n) is the best whale position vector at present; D p is the distance between the individual whale and the current best whale position; b is a constant used to define the spiral shape; l is a random number in [-1,1]; X(n) is the current whale position vector.

[0120] Assuming that each individual whale has a probability of Pi to choose the shrinking and encircling mechanism, and a probability of 1-Pi to choose the spiral model to update the whale's position vector, the probability model of whale hunting behavior is:

[0121]

[0122] Where X(n+1) is the updated position vector of the current whale position; X * (n) is the best whale position vector at present; D is the current whale shrinking movement step; A is the coefficient; p is a random number in [0,1]; P i The probability of choosing a shrinking encirclement for each individual whale; D p is the distance between the individual whale and the current best whale position; b is a constant used to define the shape of the spiral; l is a random number in [-1,1].

[0123] During the iteration process, when the value of A is within [-1,1], the next position of the whale can be any position between its current position and the position of the prey. Therefore, when A<1, the whale attacks the prey.

[0124] In the search phase, the algorithm sets a random whale position to update the positions of other whales when A ≥ 1, forcing the whales to deviate from their prey and strengthening the global search capability of the whale optimization algorithm.

[0125] In the search phase, individual whales conduct a large-scale random search based on the current positions of other whales. The expression of the whale optimization algorithm search phase is:

[0126]

[0127] Where X(n+1) is the updated position vector of the current whale position; X rand is the position vector of a randomly selected individual whale; A and C are coefficients; D s is the distance between the current whale individual and the randomly selected whale individual; X(n) is the position vector of the current whale.

[0128] The location of the whale should be constrained by a preset search space:

[0129] l b ≤X(n+1)≤u b ,

[0130] In the formula, l b and u b They represent the lower and upper limits of the set search space respectively; X(n+1) is the position vector after the current whale position is updated.

[0131] After that, the optimized load annual correction factor with the smallest prediction error is selected and the optimized load annual correction factor k* with the smallest prediction error is used as the new optimal whale position vector X * (n+1):

[0132]

[0133] In the formula, X * (n+1) is the position vector of the new optimal whale individual; k * is the annual correction factor of the optimized load with the smallest forecast error; η(k * ) is the forecast error of the optimized load annual correction factor with the smallest forecast error; is the minimum value of the prediction error corresponding to the current optimized load annual correction coefficient; s is the whale individual number; S N The size of the whale population.

[0134] The present invention obtains an optimized load annual correction coefficient based on historical summer load data and historical load influencing factor data of the same period by using a whale optimization algorithm, and then verifies the optimized load annual correction coefficient by using a trained long short-term memory network model to obtain an optimal load annual correction coefficient and a trained long short-term memory network model, and uses the optimal load annual correction coefficient and the trained long short-term memory network model as a trained summer load prediction model; the optimal load annual correction coefficient is used to timely correct historical load data of different years, effectively tracking the changing trend of the summer load, enhancing the availability of the summer load data, and improving the accuracy of the predicted summer load through the trained long short-term memory network model.

[0135] Reference Figure 2 and Figure 3 In some embodiments, the initial load year correction coefficient is optimized by the whale optimization algorithm to obtain an optimized load year correction coefficient; the training set and the validation set are respectively corrected by using the optimized load year correction coefficient, and the long short-term memory network model is trained based on the corrected training set; based on the corrected validation set, the trained long short-term memory network model is used to perform prediction to obtain a prediction result; the prediction result is evaluated to obtain the optimal load year correction coefficient, including:

[0136] S301, optimizing the initial load annual correction coefficient by using a whale optimization algorithm to obtain multiple optimized load annual correction coefficients;

[0137] S302, respectively using each optimized load year correction coefficient to correct the training set to obtain multiple corrected training sets, and using each corrected training set to respectively train the long short-term memory network model to obtain multiple trained long short-term memory network models;

[0138] S303, respectively using each optimized load year correction coefficient to correct the validation set to obtain multiple corrected validation sets, and using each corrected validation set to perform predictions through a corresponding long short-term memory network model to obtain multiple prediction results and a prediction error of each prediction result;

[0139] S304, selecting an optimized load annual correction coefficient corresponding to a minimum prediction error among the prediction errors;

[0140] If the iteration termination condition is met, the optimized annual load correction factor corresponding to the minimum prediction error is used as the optimal annual load correction factor;

[0141] If the iteration termination condition is not met, the whale optimization algorithm is used to continue optimizing the optimized load annual correction coefficient corresponding to the minimum prediction error to obtain multiple next-generation optimized load annual correction coefficients.

[0142] In the summer load model construction method provided by the present invention, iterative optimization is performed based on the initial load year correction coefficient by using the whale optimization algorithm, and the optimized load year correction coefficient corresponding to the minimum prediction error when the iteration termination condition is reached is used as the optimal load year correction coefficient. The historical load data of different years are corrected in time using the optimal load year correction coefficient, which effectively tracks the changing trend of the summer load, enhances the availability of the summer load data, and improves the accuracy of the prediction results obtained by using the corrected summer load data for prediction.

[0143] In some embodiments, the initial load annual correction factor is optimized by the whale optimization algorithm to obtain multiple optimized load annual correction factors, including:

[0144] S3011, initializing the whale population, maximum number of iterations and search space of the whale optimization algorithm, and taking the current average annual load growth rate as the initial position of each individual whale in the whale population, and the initial position of each individual whale in the whale population corresponds to the initial load annual correction coefficient;

[0145] S3012: Based on the search space, the position of each individual whale is optimized using the whale optimization algorithm to obtain the optimized position of each individual whale, and the optimized position of each individual whale is used as the annual correction coefficient of each optimized load.

[0146] For example, the whale population, maximum number of iterations and search space of the whale optimization algorithm are initialized, and the size of the whale population is set to S N , maximum number of iterations N max And the search space [l b ,u b ].

[0147] The historical summer load in the training set was corrected by calculating the optimized load annual correction coefficient corresponding to each whale, and the corrected training set was used to train the long short-term memory network model.

[0148] According to the modified parameter vector k corresponding to the position of the sth whale individual S , the corrected training set data s , satisfying the following expression:

[0149]

[0150] Among them, data s is the training set after training with the optimized load year correction factor; P his,1 , P his,2 , ..., P his,y-1 , P his,y are the historical load data of different years; I1, I2, ..., Iy-1 , I y They are the load influencing factor data corresponding to different years; are the correction parameters corresponding to different years; y is the selected historical load years; s is the individual whale number, S N The size of the whale population.

[0151] In some embodiments, the validation set is corrected using each optimized load year correction coefficient to obtain multiple corrected validation sets, and each corrected validation set is used to perform predictions through a corresponding long short-term memory network model to obtain multiple prediction results and a prediction error of each prediction result, including:

[0152] S3031, for each individual whale after each optimization, using the position of each individual whale after optimization as a load year correction coefficient to correct the verification set, to obtain multiple corrected verification sets;

[0153] S3032, predicting each corrected validation set through a corresponding long short-term memory network model to obtain multiple prediction results;

[0154] S3033, based on the actual value in each corrected validation set and each prediction result, calculate the prediction error of each prediction result.

[0155] Exemplarily, the prediction error of each prediction result includes:

[0156] The average absolute error between the predicted value and each actual value corresponding to each prediction result.

[0157] Exemplarily, the mean absolute error satisfies the following expression:

[0158]

[0159] Where η s is the mean absolute error of the prediction result after correction using the position of the sth whale individual as the annual correction coefficient for the optimized load; δ is the δth data in the validation set corrected using the position of the sth whale individual, δ = 1, ..., m val ;m val The amount of data in the validation set corrected to use the position of the sth whale individual; The predicted value of the δth data in the prediction result obtained by using the long short-term memory network model to predict the position of the sth whale individual after the correction of the validation set; is the actual value of the δth data in the validation set corrected using the position of the sth whale individual.

[0160] In some embodiments, the trained long short-term memory network model in the summer load forecasting model construction method proposed by the present invention is expressed as follows:

[0161] LSTM(x,c t-1 ,h t-1 )=(c,h),

[0162] c t =f t ⊙c t-1 +i t ⊙g t ,

[0163]

[0164] f t =σ(W fx x+W fh h t-1 +b f ),

[0165] i t =σ(W ix x+W ih h t-1 +b i ),

[0166] g t =σ(W gx x+W gh h t-1 +b g ),

[0167] o t =σ(W ox x+W oh h t-1 +b o ),

[0168] Where, LSTM() is the trained long short-term memory network model; x is the current value of the historical load influencing factor data; c t-1 is the historical state information corresponding to time t-1. If the forget gate is fully closed and takes a value of 0, it corresponds to that the historical load influencing factor data has no effect on the current state; if the forget gate is fully opened and takes a value of 1, the historical load influencing factor data is completely transmitted to time t; if the value is between 0 and 1, it represents partial transmission of the historical load influencing factor data; h t-1 represents the output value of the hidden layer node of the long short-term memory network model at the last time t-1; c is the state value update function of the long short-term memory network model; c t is the historical state information corresponding to time t; h is the output value function of the hidden layer node of the long short-term memory network model; o is the current output value of the output gate; is the tanh function; f t is the forget gate, which is used to control the historical load influencing factor data allowed to enter at time t; i t is the input gate, which is used to represent the historical load influencing factor data in the revised training set; g t It is an input node, which is used to indicate the amount of data allowed to enter in the control input amount; t is the output gate, which is used to indicate the load forecast result at time t obtained based on the load influencing factor data in the modified training set; W fx W is the weight matrix of the forget gate multiplied by the current input value c; f h is the forget gate and the output value h at the previous moment t-1 The multiplied weight matrix; W ix For the input gate and the current input value x t The multiplied weight matrix; W ih is the input gate and the output value h at the previous moment t-1 The multiplied weight matrix; W gx W is the weight matrix of the input node multiplied by the current input value x; gh is the input node and the output value h at the previous moment t-1 The multiplied weight matrix; W ox W is the weight matrix that multiplies the output gate by the current input value x; o h is the output gate and the output value h at the previous moment t-1 The multiplied weight matrix; b f is the bias matrix of the forget gate; b i is the bias matrix of the input gate; b g is the bias matrix of the input node; b o is the bias matrix of the output gate; ⊙ is the vector multiplication symbol; σ is the sigmoid function.

[0169] In some embodiments, in order to facilitate the evaluation of the prediction results of the summer load prediction model, after determining the final summer load prediction model based on the optimal load annual correction coefficient and the trained long short-term memory network model, the summer load prediction model construction method proposed by the present invention further includes:

[0170] Based on a pre-constructed test set, the test set is corrected using the optimal load annual correction coefficient, and prediction is performed based on the corrected test set using the trained long short-term memory network model to obtain a predicted value;

[0171] Determine the index value of the performance evaluation index of the summer load forecasting model according to the predicted value and the true value in the corrected test set, wherein the performance evaluation index includes the mean absolute percentage error, the mean absolute error or the determination coefficient;

[0172] The performance of the summer load forecasting model is evaluated using the index value of the performance evaluation index.

[0173] In some embodiments, if the performance evaluation index includes a mean absolute percentage error, the process of determining the index value of the performance evaluation index of the summer load forecasting model according to the predicted value and the true value in the corrected test set satisfies the following expression:

[0174]

[0175] Where M APE is the average absolute percentage error of the summer load forecasting model; δ1 is the δ1th data in the test set corrected by the optimal load year correction coefficient, δ1 = 1, ..., m test ;m test is the number of data in the corrected test set; is the true value corresponding to the δ1th data in the corrected test set; is the predicted value corresponding to the δ1th data in the corrected test set.

[0176] In some embodiments, if the performance evaluation index includes a mean absolute error, the process of determining the index value of the performance evaluation index of the summer load forecasting model according to the predicted value and the true value in the corrected test set satisfies the following expression:

[0177]

[0178] Where M AE is the average absolute error of the summer load forecasting model; δ1 is the δ1th data in the test set corrected by the optimal load annual correction coefficient, δ1 = 1, ..., m test ;m test is the number of data in the corrected test set; is the true value corresponding to the δ1th data in the corrected test set; is the predicted value corresponding to the δ1th data in the corrected test set.

[0179] In some embodiments, if the performance evaluation index includes a determination coefficient, the process of determining the index value of the performance evaluation index of the summer load forecasting model according to the predicted value and the true value in the corrected test set satisfies the following formula:

[0180]

[0181] In the formula, R 2is the determination coefficient of the summer load forecasting model; δ1 is the δ1th data in the test set corrected by the optimal load year correction coefficient, δ1 = 1, ..., m test ;m test is the number of data in the corrected test set; is the true value corresponding to the δ1th data in the corrected test set; is the predicted value corresponding to the δ1th data in the corrected test set; is the sample expectation of the δ1th sample in the corrected test set.

[0182] Embodiment 2:

[0183] Based on the same inventive concept, the present invention also provides a summer load forecasting model construction system, comprising:

[0184] A data acquisition unit is used to comprehensively acquire historical summer load data recorded in previous years and historical load influencing factor data of the same period to obtain historical load data;

[0185] A data partitioning unit, used for partitioning the historical load data into a training set and a validation set;

[0186] A correction coefficient acquisition unit is used to optimize the initial load year correction coefficient by using a whale optimization algorithm to obtain an optimized load year correction coefficient; use the optimized load year correction coefficient to respectively correct the training set and the verification set, and train the long short-term memory network model based on the corrected training set; based on the corrected verification set, use the trained long short-term memory network model to perform prediction to obtain a prediction result; evaluate the prediction result to obtain an optimal load year correction coefficient;

[0187] The prediction model output unit is used to obtain the final summer load prediction model based on the optimal load annual correction coefficient and the trained long short-term memory network model.

[0188] In some embodiments, the correction coefficient acquisition unit includes:

[0189] The optimization coefficient acquisition module is used to optimize the initial load annual correction coefficient through the whale optimization algorithm to obtain multiple optimized load annual correction coefficients;

[0190] A memory network model building module is used to respectively use each optimized load year correction coefficient to correct the training set to obtain multiple corrected training sets, and use each corrected training set to respectively train the long short-term memory network model to obtain multiple trained long short-term memory network models;

[0191] The prediction result output module is used to correct the verification set using each optimized load year correction coefficient to obtain multiple corrected verification sets, and use each corrected verification set to perform predictions through the corresponding long short-term memory network model to obtain multiple prediction results and the prediction error of each prediction result;

[0192] A correction coefficient output module is used to select the optimized load annual correction coefficient corresponding to the minimum prediction error among the prediction errors;

[0193] If the iteration termination condition is met, the optimized annual load correction factor corresponding to the minimum prediction error is used as the optimal annual load correction factor;

[0194] If the iteration termination condition is not met, the whale optimization algorithm is used to continue optimizing the optimized load annual correction coefficient corresponding to the minimum prediction error to obtain multiple next-generation optimized load annual correction coefficients.

[0195] In some embodiments, the optimization coefficient acquisition module provided by the present invention is specifically used for:

[0196] Initialize the whale population, maximum number of iterations and search space of the whale optimization algorithm, and use the current average annual load growth rate as the initial position of each individual whale in the whale population, and the initial position of each individual whale in the whale population corresponds to the initial load annual correction coefficient;

[0197] Based on the search space, the position of each individual whale is optimized using the whale optimization algorithm to obtain the optimized position of each individual whale, and the optimized position of each individual whale is used as the annual correction coefficient of each optimized load.

[0198] In some embodiments, the prediction result output module is specifically used to:

[0199] For each individual whale after each optimization, the position of each individual whale after optimization is used as a load year correction coefficient to correct the verification set, so as to obtain a plurality of corrected verification sets;

[0200] Each corrected validation set is predicted by the corresponding long short-term memory network model to obtain multiple prediction results;

[0201] Based on the actual value in each corrected validation set and each predicted result, the prediction error of each predicted result is calculated.

[0202] In some embodiments, the prediction error of each prediction result output by the prediction result output module includes:

[0203] The average absolute error between the predicted value and each actual value corresponding to each prediction result.

[0204] Exemplarily, the mean absolute error satisfies the following expression:

[0205]

[0206] Where η s is the mean absolute error of the prediction result after correction using the position of the sth whale individual as the annual correction coefficient for the optimized load; δ is the δth data in the validation set corrected using the position of the sth whale individual, δ = 1, ..., m val ;m val The amount of data in the validation set corrected to use the position of the sth whale individual; The predicted value of the δth data in the prediction result obtained by using the long short-term memory network model to predict the position of the sth whale individual after the correction of the validation set; is the actual value of the δth data in the validation set corrected using the position of the sth whale individual.

[0207] Exemplarily, the historical load influencing factor data includes: meteorological data and day type;

[0208] The meteorological data include: daily minimum temperature, daily average temperature, daily maximum temperature and humidity; the day types include: working days and holidays.

[0209] In some embodiments, the long short-term memory network model trained by the memory network model building module is expressed as follows:

[0210] LSTM(x,c t-1 ,h t-1 )=(c,h),

[0211] c t =f t ⊙c t-1 +i t ⊙g t ,

[0212]

[0213] f t =σ(W fx x+W fh h t-1 +b f ),

[0214] i t =σ(W ix x+W ih h t-1 +b i ),

[0215] g t =σ(Wgx x+W gh h t-1 +b g ),

[0216] o t =σ(W ox x+W oh h t-1 +b o ),

[0217] Where, LSTM() is the trained long short-term memory network model; x is the current value of the historical load influencing factor data; c t-1 is the historical state information corresponding to time t-1. If the forget gate is fully closed and takes a value of 0, it corresponds to that the historical load influencing factor data has no effect on the current state; if the forget gate is fully opened and takes a value of 1, the historical load influencing factor data is completely transmitted to time t; if the value is between 0 and 1, it represents partial transmission of the historical load influencing factor data; h t-1 represents the output value of the hidden layer node of the long short-term memory network model at the last time t-1; c is the state value update function of the long short-term memory network model; c t is the historical state information corresponding to time t; h is the output value function of the hidden layer node of the long short-term memory network model; o is the current output value of the output gate; is the tanh function; f t is the forget gate, which is used to control the historical load influencing factor data allowed to enter at time t; i t is the input gate, which is used to represent the historical load influencing factor data in the revised training set; g t It is an input node, which is used to indicate the amount of data allowed to enter in the control input amount; t is the output gate, which is used to indicate the load forecast result at time t obtained based on the load influencing factor data in the modified training set; W fx W is the weight matrix of the forget gate multiplied by the current input value x; f h is the forget gate and the output value h at the previous moment t-1 The multiplied weight matrix; W ix For the input gate and the current input value x t The multiplied weight matrix; W ih is the input gate and the output value h at the previous moment t-1 The multiplied weight matrix; W gx W is the weight matrix of the input node multiplied by the current input value x; gh is the input node and the output value h at the previous moment t-1 The multiplied weight matrix; W ox W is the weight matrix that multiplies the output gate by the current input value x; oh is the output gate and the output value h at the previous moment t-1 The multiplied weight matrix; b f is the bias matrix of the forget gate; b i is the bias matrix of the input gate; b g is the bias matrix of the input node; b o is the bias matrix of the output gate; ⊙ is the vector multiplication symbol; σ is the sigmoid function.

[0218] In some embodiments, the summer load forecasting model construction system provided by the present invention further includes a result evaluation unit, which is used to:

[0219] Based on a pre-constructed test set, the test set is corrected using the optimal load annual correction coefficient, and prediction is performed based on the corrected test set using the trained long short-term memory network model to obtain a predicted value;

[0220] Determine the index value of the performance evaluation index of the summer load forecasting model according to the predicted value and the true value in the corrected test set, wherein the performance evaluation index includes the mean absolute percentage error, the mean absolute error or the determination coefficient;

[0221] The performance of the summer load forecasting model is evaluated using the index value of the performance evaluation index.

[0222] Exemplarily, if the performance evaluation index includes a mean absolute percentage error, the process of determining the index value of the performance evaluation index of the summer load forecasting model according to the predicted value and the true value in the corrected test set satisfies the following expression:

[0223]

[0224] Where M APE is the average absolute percentage error of the summer load forecasting model; δ1 is the δ1th data in the test set corrected by the optimal load year correction coefficient, δ1 = 1, ..., m test ;m test is the number of data in the corrected test set; is the true value corresponding to the δ1th data in the corrected test set; is the predicted value corresponding to the δ1th data in the corrected test set.

[0225] Exemplarily, if the performance evaluation index includes a mean absolute error, the process of determining the index value of the performance evaluation index of the summer load forecasting model according to the predicted value and the true value in the corrected test set satisfies the following expression:

[0226]

[0227] Where M AE is the average absolute error of the summer load forecasting model; δ1 is the δ1th data in the test set corrected by the optimal load annual correction coefficient, η1=1,…,m test ;m test is the number of data in the corrected test set; is the true value corresponding to the η1th data in the corrected test set; is the predicted value corresponding to the η1th data in the corrected test set.

[0228] Exemplarily, if the performance evaluation index includes a determination coefficient, the process of determining the index value of the performance evaluation index of the summer load forecasting model according to the predicted value and the true value in the corrected test set satisfies the following formula:

[0229]

[0230] In the formula, R 2 is the determination coefficient of the summer load forecasting model; η1 is the η1th data in the test set corrected by the optimal load year correction coefficient, η1 = 1, ..., m test ;m test is the number of data in the corrected test set; is the true value corresponding to the δ1th data in the corrected test set; is the predicted value corresponding to the δ1th data in the corrected test set; is the sample expectation of the η1th sample in the corrected test set.

[0231] Embodiment 3:

[0232] Based on the inventive concept of the above-mentioned summer load forecasting model construction method, the present invention also proposes a summer load forecasting method, the method comprising:

[0233] Obtain the current summer load data and the current load influencing factor data to obtain the load data to be predicted;

[0234] Based on the load data to be predicted, a summer load prediction model is used to perform prediction to obtain a summer load prediction value;

[0235] The summer load forecasting model is constructed using the summer load forecasting model construction method described in the above technical solution.

[0236] In some embodiments, before performing prediction based on the load data to be predicted using a summer load prediction model to obtain a summer load prediction value, the method further includes:

[0237] The load data to be predicted is normalized.

[0238] Exemplarily, the load data to be predicted is normalized, and the load data to be predicted P is normalized. his Multiplying by the correction parameter k, the load data set matrix data to be predicted can be expressed as:

[0239]

[0240] Among them, P his,1 , P his,2 …P his,y are the historical load data of different years in the load data to be predicted; I is the corresponding load influencing factor data; k 1 , k 2 ,...k y-1 are the correction parameters corresponding to different years; y is the year of the historical load data selected for different years.

[0241] Embodiment 4:

[0242] Based on the same inventive concept, the present invention also proposes a summer load forecasting system, the system comprising:

[0243] The to-be-predicted data acquisition unit is used to acquire the current summer load data and the current load influencing factor data to obtain the to-be-predicted load data;

[0244] A summer load data prediction unit, used to perform prediction based on the load data to be predicted using a summer load prediction model to obtain a summer load prediction value;

[0245] The summer load forecasting model is constructed using the summer load forecasting model construction method described in the above technical solution.

[0246] In some embodiments, the summer load forecasting system proposed by the present invention further includes:

[0247] A data processing unit is used to normalize the load data to be predicted.

[0248] Exemplarily, the load data to be predicted is normalized, and the load data to be predicted P is normalized. his Multiplying by the correction parameter k, the load data set matrix data to be predicted can be expressed as:

[0249]

[0250] Among them, P his,1 , P his,2 …P his,yare the historical load data of different years in the load data to be predicted; I is the corresponding load influencing factor data; k 1 , k 2 ,...k y-1 are the correction parameters corresponding to different years; y is the year of the historical load data selected for different years.

[0251] Embodiment 5:

[0252] Reference Figure 4 Based on the same inventive concept, the present invention also provides an electronic device, which may be a computer device, a single-chip device, an intelligent mobile device, etc. The electronic device in this embodiment may include a processor, a memory, a transceiver component, etc. The memory, the processor, and the transceiver component are connected via a bus; the memory may be used to store an execution program, and an exemplary execution program may include instructions; the processor is used to execute the instructions stored in the memory. The memory may also be used to store data, which may be called and / or modified when executing instructions.

[0253] The processor may be a central processing unit (CPU), or other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components, etc. It is the computing core and control core of the terminal, which is suitable for implementing one or more instructions, specifically suitable for loading and executing one or more instructions in a storage medium to implement corresponding method flows or corresponding functions, so as to implement a summer load forecasting model construction method or steps of a summer load forecasting method in the above-mentioned embodiment.

[0254] Embodiment 6:

[0255] Based on the same inventive concept, the present invention also provides a readable storage medium, specifically an electronic device readable storage medium (Memory), which is a memory device in the electronic device for storing programs and data. It can be understood that the storage medium here can include both the built-in storage medium in the electronic device and the extended storage medium supported by the electronic device. The storage medium provides a storage space, which stores the operating system of the terminal. In addition, one or more instructions suitable for being loaded and executed by the processor are also stored in the storage space, and these instructions can be one or more execution programs (including program codes). It should be noted that the storage medium here can be a high-speed RAM memory or a non-volatile memory, such as at least one disk memory. The processor loads and executes one or more instructions stored in the storage medium, which can implement the steps of a summer load forecasting model construction method or a summer load forecasting method in the above-mentioned embodiment.

[0256] Those skilled in the art will appreciate that embodiments of the present invention may be provided as methods, systems, or computer program products. Therefore, the present invention may take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, the present invention may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0257] 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.

[0258] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1A function specified in one or more boxes.

[0259] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.

[0260] The above are merely embodiments of the present invention and are not intended to limit the present invention. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present invention are included in the scope of the claims of the present invention to be approved.

Claims

1. A method for constructing a summer load forecasting model, characterized in that: include: Comprehensively obtain the historical summer load data recorded in previous years and the historical load influencing factor data of the same period to obtain the historical load data; Dividing the historical load data into a training set and a validation set; The initial load annual correction factor is optimized by the whale optimization algorithm to obtain the optimized load annual correction factor; The training set and the validation set are respectively corrected using the optimized load year correction coefficient, and the long short-term memory network model is trained based on the corrected training set; Based on the corrected validation set, the trained long short-term memory network model is used to make predictions and obtain the prediction results; Evaluate the forecast results and obtain the optimal load annual correction factor; Based on the optimal load annual correction coefficient and the trained long short-term memory network model, a final summer load forecasting model is obtained.

2. The method according to claim 1, characterized in that The initial load annual correction coefficient is optimized by the whale optimization algorithm to obtain the optimized load annual correction coefficient; The training set and the validation set are respectively corrected using the optimized load year correction coefficient, and the long short-term memory network model is trained based on the corrected training set; Based on the corrected validation set, the trained long short-term memory network model is used to make predictions and obtain the prediction results; Evaluate the forecast results and obtain the optimal load annual correction factor, including: The initial load annual correction coefficient is optimized by the whale optimization algorithm to obtain multiple optimized load annual correction coefficients; Using each optimized load year correction coefficient to correct the training set respectively, to obtain a plurality of corrected training sets, and using each corrected training set to train the long short-term memory network model respectively, to obtain a plurality of trained long short-term memory network models; The validation set is corrected using each optimized load year correction coefficient to obtain multiple corrected validation sets, and each corrected validation set is used to perform predictions through the corresponding long short-term memory network model to obtain multiple prediction results and the prediction error of each prediction result; Select the optimized load annual correction factor corresponding to the minimum forecast error among the forecast errors; If the iteration termination condition is met, the optimized annual load correction factor corresponding to the minimum prediction error is used as the optimal annual load correction factor; If the iteration termination condition is not met, the whale optimization algorithm is used to continue optimizing the optimized load annual correction coefficient corresponding to the minimum prediction error to obtain multiple next-generation optimized load annual correction coefficients.

3. The method according to claim 2, characterized in that The initial load annual correction coefficient is optimized by the whale optimization algorithm to obtain multiple optimized load annual correction coefficients, including: Initialize the whale population, maximum number of iterations and search space of the whale optimization algorithm, and use the current average annual load growth rate as the initial position of each individual whale in the whale population, and the initial position of each individual whale in the whale population corresponds to the initial load annual correction coefficient; Based on the search space, the position of each individual whale is optimized using the whale optimization algorithm to obtain the optimized position of each individual whale, and the optimized position of each individual whale is used as the annual correction coefficient of each optimized load.

4. The method according to claim 3, characterized in that The verification set is corrected using each optimized load year correction coefficient to obtain multiple corrected verification sets, and each corrected verification set is used to perform predictions through a corresponding long short-term memory network model to obtain multiple prediction results and a prediction error of each prediction result, including: For each individual whale after each optimization, the position of each individual whale after optimization is used as a load year correction coefficient to correct the verification set, so as to obtain a plurality of corrected verification sets; Each corrected validation set is predicted by the corresponding long short-term memory network model to obtain multiple prediction results; Based on the actual value in each corrected validation set and each predicted result, the prediction error of each predicted result is calculated.

5. The method according to claim 4, characterized in that The prediction error of each prediction result includes: The average absolute error between the predicted value and the actual value corresponding to each prediction result.

6. The method according to claim 5, characterized in that The mean absolute error satisfies the following expression: Where η s is the mean absolute error of the prediction results after correction using the position of the sth whale individual as the optimized load year correction factor; δ is the δth data in the validation set corrected using the position of the sth whale individual, δ = 1, ..., m val ;m val The amount of data in the validation set corrected to use the position of the sth whale individual; The predicted value of the δth data in the prediction result obtained by using the long short-term memory network model to predict the position of the sth whale individual after the correction of the validation set; is the actual value of the δth data in the validation set corrected using the position of the sth whale individual.

7. The method according to claim 1, characterized in that The historical load influencing factor data include: meteorological data and day type; The meteorological data include: daily minimum temperature, daily average temperature, daily maximum temperature and humidity; the day types include: working days and holidays.

8. The method according to claim 6, characterized in that The trained long short-term memory network model is expressed as follows: LSTM(x,c t-1 ,h t-1 )=(c,h), c t =f t ⊙c t-1 +i t ⊙g t , f t =σ(W fx x+W fh h t-1 +b f ), i t =σ(W ix x+W ih h t-1 +b i ), g t =σ(W gx x+W gh h t-1 +b g ), o t =σ(W ox x+W oh h t-1 +b o ), Where, LSTM() is the trained long short-term memory network model; x is the current value of the historical load influencing factor data; c t-1 is the historical state information corresponding to time t-1. If the forget gate is fully closed and takes a value of 0, it corresponds to that the historical load influencing factor data has no effect on the current state; if the forget gate is fully opened and takes a value of 1, the historical load influencing factor data is completely transmitted to time t; if the value is between 0 and 1, it represents partial transmission of the historical load influencing factor data; h t-1 represents the output value of the hidden layer node of the long short-term memory network model at the last time t-1; c is the state value update function of the long short-term memory network model; c t is the historical state information corresponding to time t; h is the output value function of the hidden layer node of the long short-term memory network model; o is the current output value of the output gate; is the tanh function; f t is the forget gate, which is used to control the historical load influencing factor data allowed to enter at time t; i t is the input gate, which is used to represent the historical load influencing factor data in the revised training set; g t It is an input node, which is used to indicate the amount of data allowed to enter in the control input amount; t is the output gate, which is used to indicate the load forecast result at time t obtained based on the load influencing factor data in the modified training set; W fx W is the weight matrix of the forget gate multiplied by the current input value x; f h is the forget gate and the output value h at the previous moment t-1 The multiplied weight matrix; W ix For the input gate and the current input value x t The multiplied weight matrix; W ih is the input gate and the output value h at the previous moment t-1 The multiplied weight matrix; W gx W is the weight matrix of the input node multiplied by the current input value x; gh is the input node and the output value h at the previous moment t-1 The multiplied weight matrix; W ox W is the weight matrix that multiplies the output gate by the current input value x; o h is the output gate and the output value h at the previous moment t-1 The multiplied weight matrix; b f is the bias matrix of the forget gate; b i is the bias matrix of the input gate; b g is the bias matrix of the input node; b o is the bias matrix of the output gate; ⊙ is the vector multiplication symbol; σ is the sigmoid function.

9. The method according to claim 1, characterized in that After determining the final summer load forecasting model based on the optimal load annual correction coefficient and the trained long short-term memory network model, the method further includes: Based on the pre-constructed test set, the test set is corrected using the optimal load year correction coefficient, and the trained long short-term memory network model is used to perform prediction based on the corrected test set to obtain a predicted value; Determine the index value of the performance evaluation index of the summer load forecasting model according to the predicted value and the true value in the corrected test set, wherein the performance evaluation index includes the mean absolute percentage error, the mean absolute error or the determination coefficient; The performance of the summer load forecasting model is evaluated using the index value of the performance evaluation index.

10. The method according to claim 9, characterized in that If the performance evaluation index includes the mean absolute percentage error, the process of determining the index value of the performance evaluation index of the summer load forecasting model according to the predicted value and the true value in the corrected test set satisfies the following expression: Where M APE is the average absolute percentage error of the summer load forecasting model; δ1 is the δ1th data in the test set corrected by the optimal load year correction coefficient, δ1 = 1, ..., m test ;m test is the number of data in the corrected test set; is the true value corresponding to the δ1th data in the corrected test set; is the predicted value corresponding to the δ1th data in the corrected test set.

11. The method according to claim 9, characterized in that If the performance evaluation index includes the mean absolute error, the process of determining the index value of the performance evaluation index of the summer load forecasting model according to the predicted value and the true value in the corrected test set satisfies the following expression: Where M AE is the average absolute error of the summer load forecasting model; δ1 is the δ1th data in the test set corrected by the optimal load annual correction coefficient, δ1 = 1, ..., m test ;m test is the number of data in the corrected test set; is the true value corresponding to the δ1th data in the corrected test set; is the predicted value corresponding to the δ1th data in the corrected test set.

12. The method according to claim 9, characterized in that If the performance evaluation index includes a determination coefficient, the process of determining the index value of the performance evaluation index of the summer load forecasting model according to the predicted value and the true value in the corrected test set satisfies the following formula: In the formula, R 2 is the determination coefficient of the summer load forecasting model; δ1 is the δ1th data in the test set corrected by the optimal load year correction coefficient, δ1 = 1, ..., m test ;m test is the number of data in the corrected test set; is the true value corresponding to the δ1th data in the corrected test set; is the predicted value corresponding to the δ1th data in the corrected test set; is the sample expectation of the δ1th sample in the corrected test set.

13. A summer load forecasting model construction system, characterized in that: include: A data acquisition unit is used to comprehensively acquire historical summer load data recorded in previous years and historical load influencing factor data of the same period to obtain historical load data; A data partitioning unit, connected to the data acquisition unit for partitioning the historical load data into a training set and a validation set; A correction coefficient acquisition unit is used to optimize the initial load annual correction coefficient through a whale optimization algorithm to obtain an optimized load annual correction coefficient; The training set and the validation set are respectively corrected using the optimized load year correction coefficient, and the long short-term memory network model is trained based on the corrected training set; Based on the corrected validation set, the trained long short-term memory network model is used to make predictions and obtain the prediction results; Evaluate the forecast results and obtain the optimal load annual correction factor; The prediction model output unit is used to obtain the final summer load prediction model based on the optimal load annual correction coefficient and the trained long short-term memory network model.

14. The system of claim 13, wherein: The correction coefficient acquisition unit comprises: The optimization coefficient acquisition module is used to optimize the initial load annual correction coefficient through the whale optimization algorithm to obtain multiple optimized load annual correction coefficients; A memory network model building module is used to respectively use each optimized load year correction coefficient to correct the training set to obtain multiple corrected training sets, and use each corrected training set to respectively train the long short-term memory network model to obtain multiple trained long short-term memory network models; The prediction result output module is used to correct the verification set using each optimized load year correction coefficient to obtain multiple corrected verification sets, and use each corrected verification set to perform predictions through the corresponding long short-term memory network model to obtain multiple prediction results and the prediction error of each prediction result; The correction coefficient output module is used to select the optimized load annual correction coefficient corresponding to the minimum prediction error in the prediction error; if the iteration termination condition is met, the optimized load annual correction coefficient corresponding to the minimum prediction error is used as the optimal annual load correction coefficient; if the iteration termination condition is not met, the whale optimization algorithm is continued to be used to optimize the optimized load annual correction coefficient corresponding to the minimum prediction error to obtain multiple next-generation optimized load annual correction coefficients.

15. The system of claim 14, wherein: The optimization coefficient acquisition module is specifically used for: Initialize the whale population, maximum number of iterations and search space of the whale optimization algorithm, and use the current average annual load growth rate as the initial position of each individual whale in the whale population, and the initial position of each individual whale in the whale population corresponds to the initial load annual correction coefficient; Based on the search space, the position of each individual whale is optimized using the whale optimization algorithm to obtain the optimized position of each individual whale, and the optimized position of each individual whale is used as the annual correction coefficient of each optimized load.

16. The system of claim 14, wherein: The prediction result output module is specifically used for: For each individual whale after each optimization, the position of each individual whale after optimization is used as a load year correction coefficient to correct the verification set, so as to obtain a plurality of corrected verification sets; Each corrected validation set is predicted by the corresponding long short-term memory network model to obtain multiple prediction results; Based on the actual value in each corrected validation set and each predicted result, the prediction error of each predicted result is calculated.

17. A summer load forecasting method, characterized in that: The method comprises: Obtain the current summer load data and the current historical load influencing factor data to obtain the load data to be predicted; Based on the load data to be predicted, a summer load prediction model is used to perform prediction to obtain a summer load prediction value; The summer load forecasting model is constructed using the summer load forecasting model construction method according to any one of claims 1 to 12.

18. The method according to claim 17, characterized in that Before performing prediction based on the load data to be predicted using a summer load prediction model to obtain a summer load prediction value, the method further includes: The load data to be predicted is normalized.

19. A summer load forecasting system, characterized in that: The system comprises: The to-be-predicted data acquisition unit is used to acquire the current summer load data and the current load influencing factor data to obtain the to-be-predicted load data; A summer load data prediction unit, used to perform prediction based on the load data to be predicted using a summer load prediction model to obtain a summer load prediction value; The summer load forecasting model is constructed using the summer load forecasting model construction method according to any one of claims 1 to 12.

20. The system of claim 19, wherein: Also includes: A data processing unit is used to normalize the load data to be predicted.

21. A computer device, characterized in that: include: at least one processor and memory; The memory and the processor are connected via a bus; The memory is used to store one or more programs; When the one or more programs are executed by the at least one processor, the summer load forecasting model construction method described in any one of claims 1 to 12 or the summer load forecasting method described in claim 17 or 18 is implemented.

22. A readable storage medium, characterized in that: An execution program is stored thereon, and when the execution program is executed, the summer load forecasting model construction method described in any one of claims 1-12 or the summer load forecasting method described in claim 17 or 18 is implemented.