Load prediction method and system, electronic equipment and storage medium
Through the LTSF-Linear model and multi-model fusion Stacking ensemble learning method, combined with linear regression model, the problem of insufficient accuracy and generalization capabilities of load prediction models in the existing technology in complex nonlinear problems is solved, and the accuracy of load prediction is improved .
Patent Information
- Application Number
- CN202411374513.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-29
- Publication Date
- 2024-12-20
- Estimated Expiration
- 2044-09-29
AI Technical Summary
Existing load prediction models are difficult to take into account prediction accuracy and generalization capabilities when dealing with complex nonlinear problems, especially the inverse characteristics of the self-attention mechanism in medium- and long-term predictions, resulting in an increase in prediction error.
The LTSF-Linear model is adopted, including Linear, DLinear and NLinear submodels, and the multi-model fusion Stacking ensemble learning method is used to fusion prediction results by using linear regression models to improve prediction accuracy.
Through multi-model fusion and linear regression methods, the accuracy of load prediction is improved, the ability to capture complex load variation laws is enhanced, and the prediction error is reduced.
Smart Images

Figure CN119171433A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of power forecasting, and in particular to a load forecasting method, system, electronic equipment and storage medium. Background Art
[0002] Load forecasting is a crucial link in the operation and planning of power systems. Accurate load forecasting can not only effectively ensure the safe and stable operation of power systems, but also improve energy efficiency and reduce energy waste. At present, there are many load forecasting methods, mainly including traditional statistical methods, artificial intelligence methods, and hybrid methods.
[0003] Traditional statistical methods, such as time series analysis and linear regression, are widely used because of their simple models and high computational efficiency. However, these methods often show limitations when dealing with complex nonlinear problems and cannot accurately capture the complex laws of load changes. With the development of artificial intelligence technology, methods such as machine learning and deep learning have been increasingly used in load forecasting. These methods are able to process large amounts of data and capture complex nonlinear relationships, improving the accuracy of load forecasting. However, a single model often finds it difficult to balance both prediction accuracy and generalization ability.
[0004] At present, most medium- and long-term prediction models cannot extract temporal relationships from long sequences, that is, the prediction error will not decrease as the size of the lookback window increases. This is mainly due to the existence of the self-attention mechanism. The self-attention mechanism has the characteristics of reverse order and permutation invariance, which is manifested as being insensitive to the arrangement of the input sequence, that is, its output is robust to inputs with different arrangements. This seems to be more in line with human thinking and processing methods in natural language processing tasks, because perhaps distant words are more helpful to the following text, or changing the order of words does not affect the understanding of their semantics. However, for time-sensitive stock or power data, each value of its sequence is a numerical value, and does not have a relatively fixed range of semantic information like a single word. The semantic information of the numerical value is relatively scarce and the meaning is changeable. Time information is their most valuable information. Based on this observation, the self-attention mechanism is theoretically applicable and effective for NLP tasks, but it is fatal for sequence processing tasks that depend on time. Summary of the invention
[0005] The purpose of the embodiments of the present invention is to provide a load forecasting method, system, electronic device and storage medium, which are used to completely or at least partially solve the technical problems existing in the above-mentioned prior art.
[0006] In order to achieve the above object, an embodiment of the present invention provides a load forecasting method, including: Acquire historical load data, and pre-process the historical load data to obtain target historical load data; Inputting the target historical load data into a pre-built LTSF-Linear model for prediction to obtain a prediction result, wherein the pre-built LTSF-Linear model includes a Linear sub-model, a DLinear sub-model and an NLinear sub-model; Use multi-model fusion Stacking ensemble learning to calculate the prediction results output by the LTSF-Linear model based on the linear regression model to obtain the target prediction results.
[0007] Optionally, historical load data is obtained and preprocessed to obtain target historical load data, including: Selecting initial historical load data from the acquired historical load data, and repairing missing values, error values, and noise values in the initial historical load data; The repaired initial historical load data are integrated to obtain the target historical load data.
[0008] Optionally, the target historical load data is input into a pre-built LTSF-Linear model for prediction to obtain prediction results, including: Input the target historical load data into the Linear sub-model and obtain the first prediction result through weighted sum operation; The target historical load data is input into the DLinear sub-model, and the DLinear sub-model performs sequence decomposition on the target historical load data to obtain a trend sequence and a remaining sequence other than the trend sequence, and the trend sequence and the remaining sequence other than the trend sequence are respectively input into the Linear sub-model to obtain the prediction result corresponding to the trend sequence and the prediction result corresponding to the remaining sequence other than the trend sequence, and merge them to obtain a second prediction result; Input the target historical load data into the NLinear sub-model, subtract the last value in the sequence corresponding to the target historical load data from the NLinear sub-model to obtain a simple standard sequence, perform prediction based on the simple standard sequence to obtain a predicted value, and add the subtracted last value to the predicted value to obtain a third prediction result; The first prediction result, the second prediction result and the third prediction result are integrated to obtain a prediction result.
[0009] Optionally, use multi-model fusion Stacking ensemble learning to calculate the prediction results output by the LTSF-Linear model based on the linear regression model to obtain the target prediction results, including: The Linear sub-model, DLinear sub-model, and NLinear sub-model in the LTSF-Linear model are used as the base models for load forecasting, and linear regression is used as the meta-learner. Divide the historical load data into a time series training set and a test set, and calculate the prediction results of the base model in the training set and the test set; Based on the daily cycle characteristics of the load, the forecast results at different time points are regarded as different random variables, and a linear regression model of the forecast results of the base model is constructed for each time point; The weights and biases of the linear regression model are optimized on the training set, and the target prediction results are calculated based on the linear regression model and the prediction results of the base model on the test set.
[0010] Optionally, the linear regression model is as follows: ; ; In the formula, Represents the prediction results of the Stacking ensemble learning model on the test set. , , Represents the weights of the Linear sub-model, DLinear sub-model, and NLinear sub-model at the i-th moment, , , It represents the prediction results of Linear sub-model, DLinear sub-model and NLinear sub-model at the i-th moment. Represents bias, where n is an integer.
[0011] On the other hand, the present invention also provides a load forecasting system, comprising: An acquisition unit, used for acquiring historical load data, and preprocessing the historical load data to obtain target historical load data; A prediction unit, used for inputting the target historical load data into a pre-built LTSF-Linear model for prediction to obtain a prediction result, wherein the pre-built LTSF-Linear model includes a Linear sub-model, a DLinear sub-model and an NLinear sub-model; The fusion unit is used to use multi-model fusion Stacking ensemble learning to calculate the prediction results output by the LTSF-Linear model based on the linear regression model to obtain the target prediction results.
[0012] Optionally, the prediction unit is specifically used for: Input the target historical load data into the Linear sub-model and obtain the first prediction result through weighted sum operation; The target historical load data is input into the DLinear sub-model, and the DLinear sub-model performs sequence decomposition on the target historical load data to obtain a trend sequence and a remaining sequence other than the trend sequence, and the trend sequence and the remaining sequence other than the trend sequence are respectively input into the Linear sub-model to obtain the prediction result corresponding to the trend sequence and the prediction result corresponding to the remaining sequence other than the trend sequence, and merge them to obtain a second prediction result; Input the target historical load data into the NLinear sub-model, subtract the last value in the sequence corresponding to the target historical load data from the NLinear sub-model to obtain a simple standard sequence, perform prediction based on the simple standard sequence to obtain a predicted value, and add the subtracted last value to the predicted value to obtain a third prediction result; The first prediction result, the second prediction result and the third prediction result are integrated to obtain a prediction result.
[0013] Optionally, the fusion unit is specifically used for: The Linear sub-model, DLinear sub-model, and NLinear sub-model in the LTSF-Linear model are used as the base models for load forecasting, and linear regression is used as the meta-learner. Divide the historical load data into a time series training set and a test set, and calculate the prediction results of the base model in the training set and the test set; Based on the daily cycle characteristics of the load, the forecast results at different time points are regarded as different random variables, and a linear regression model of the forecast results of the base model is constructed for each time point; The weights and biases of the linear regression model are optimized on the training set, and the target prediction results are calculated based on the linear regression model and the prediction results of the base model on the test set.
[0014] On the other hand, the present invention also provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the steps of the above-mentioned load forecasting method when executing the program.
[0015] On the other hand, the present invention further provides a non-transitory computer-readable storage medium having a computer program stored thereon, wherein the computer program implements the steps of the above-mentioned load forecasting method when executed by a processor.
[0016] Through the above technical solution, in terms of forecasting model construction, Linear, DLinear, and NLinear in the LTSF-Linear model are used as base models for load forecasting to predict historical load data respectively, and the linear regression model based on the above base model is used as the meta-model, and the final forecasting result is obtained through training through the multi-model fusion Stacking ensemble learning method, which improves the accuracy of the load forecasting results.
[0017] Other features and advantages of the embodiments of the present invention will be described in detail in the subsequent detailed description. BRIEF DESCRIPTION OF THE DRAWINGS
[0018] The accompanying drawings are used to provide a further understanding of the embodiments of the present invention and constitute a part of the specification. Together with the following specific implementations, they are used to explain the embodiments of the present invention, but do not constitute a limitation on the embodiments of the present invention. In the accompanying drawings: Figure 1 is an implementation flow chart of a load forecasting method provided by an embodiment of the present invention; Figure 2 is a schematic diagram of the structure of a Linear sub-model provided by an embodiment of the present invention; Figure 3 is a schematic diagram of the structure of a DLinear sub-model provided by an embodiment of the present invention; Figure 4 It is a flow chart of a multi-model fusion Stacking ensemble learning algorithm provided by an embodiment of the present invention; Figure 5 It is a structural diagram of a load forecasting system provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0019] The specific implementation of the embodiment of the present invention is described in detail below in conjunction with the accompanying drawings. It should be understood that the specific implementation described here is only used to illustrate and explain the embodiment of the present invention, and is not used to limit the embodiment of the present invention.
[0020] See also Figure 1 As shown, it is a flow chart of an implementation of a load forecasting method provided by an embodiment of the present invention, comprising the following execution steps: Step 100: Acquire historical load data, and pre-process the historical load data to obtain target historical load data.
[0021] Specifically, when executing step 100, the following steps may be specifically performed: S1000: Selecting initial historical load data from the acquired historical load data, and repairing missing values, error values, and noise values in the initial historical load data.
[0022] S1001: Integrate the repaired initial historical load data to obtain target historical load data.
[0023] In some embodiments, the data preprocessing process is as follows: Data screening: Select data useful for prediction from the collected data. Data cleaning: Process missing values, error values and noise in the data to ensure data quality. Data fusion: Integrate data from different sources to form a complete data set. Anomaly detection: Identify and process outliers in the data to ensure data accuracy and consistency.
[0024] (5) Data repair: Repair missing data or erroneous data to improve data integrity.
[0025] Step 101: Input the target historical load data into a pre-built LTSF-Linear model for prediction to obtain a prediction result, wherein the pre-built LTSF-Linear model includes a Linear sub-model, a DLinear sub-model and an NLinear sub-model.
[0026] In some embodiments, see Figure 2 As shown in FIG. 1 , a schematic diagram of the structure of a Linear sub-model provided by an embodiment of the present invention is shown. The basic linear model Linear is a direct multi-step prediction model (DMS) of a simple one-layer fully connected time series network. The input is a historical sequence of length L, and the output is a sequence of future T steps. Linear directly regresses the historical time series through a weighted sum operation to perform future predictions, such as Figure 2 As shown. The mathematical expression is, ,in are the weights of the linear layer, and are the input and prediction for the i-th variable. Note that Linear shares weights for different variables, which will not model spatial correlation.
[0027] In some embodiments, see Figure 3 FIG. 1 is a schematic diagram of the structure of a DLinear sub-model provided by an embodiment of the present invention. DLinear is actually a combination of a sequence decomposition mechanism and a Linear sub-model. The structure of the Linear sub-model is shown in FIG. Figure 2 As shown, the input sequence is first decomposed into a trend sequence ( ) and the remaining sequence ( ), input these two sequences into the Linear model respectively, and superimpose the predicted output of the subsequences ( , ) to get the predicted value of the original sequence ( ).
[0028] In some implementations, in order to handle the situation where the distribution of long sequences is biased, NLinear is further proposed. NLinear first subtracts the last value of the sequence from the input sequence, which is called a simple standard sequence. The simple standard sequence is passed through a linear layer to obtain a predicted value, and the subtracted part is added to the predicted value to obtain the final predicted value. The subtraction and addition in NLinear are simple normalization of the input sequence.
[0029] Specifically, when executing step 101, the following steps may be specifically performed: S1010: Input the target historical load data into the Linear sub-model, and obtain a first prediction result through a weighted sum operation.
[0030] S1010: Input the target historical load data into the DLinear sub-model, the DLinear sub-model performs sequence decomposition on the target historical load data to obtain a trend sequence and a remaining sequence other than the trend sequence, and input the trend sequence and the remaining sequence other than the trend sequence into the Linear sub-model respectively to obtain the prediction results corresponding to the trend sequence and the prediction results corresponding to the remaining sequences other than the trend sequence and fuse them to obtain a second prediction result.
[0031] S1010: Input the target historical load data into the NLinear sub-model, subtract the last value in the sequence corresponding to the target historical load data from the NLinear sub-model to obtain a simple standard sequence, and make a prediction based on the simple standard sequence to obtain a predicted value, and add the subtracted last value to the predicted value to obtain a third prediction result.
[0032] S1010: Fusing the first prediction result, the second prediction result, and the third prediction result to obtain a prediction result.
[0033] Step 102: Use multi-model fusion Stacking ensemble learning to calculate the prediction result output by the LTSF-Linear model based on the linear regression model to obtain the target prediction result.
[0034] Specifically, when executing step 102, the following steps may be specifically performed: S1020: The Linear sub-model, DLinear sub-model, and NLinear sub-model in the LTSF-Linear model are used as base models for load forecasting, and linear regression is used as a meta-learner.
[0035] S1021: Divide the historical load data into a time series training set and a test set, and calculate the prediction results of the base model in the training set and the test set.
[0036] S1022: Based on the daily cycle characteristics of the load, the prediction results at different time points are regarded as different random variables, and a linear regression model of the prediction results of the base model is constructed for the different time points.
[0037] S1023: Optimize the weight and bias of the linear regression model on the training set, and calculate the target prediction result based on the linear regression model and the prediction result of the base model on the test set.
[0038] Specifically, the linear regression model is as follows: ; ; In the formula, Represents the prediction results of the Stacking ensemble learning model on the test set. , , Represents the weights of the Linear sub-model, DLinear sub-model, and NLinear sub-model at the i-th moment, , , It represents the prediction results of Linear sub-model, DLinear sub-model and NLinear sub-model at the i-th moment. Represents bias, where n is an integer.
[0039] In some implementations, the multi-model fusion Stacking ensemble learning algorithm used specifically uses Linear, DLinear, and NLinear in the LTSF-Linear model as the base model for load forecasting, and uses linear regression as a meta-learner to achieve model fusion. See the attached flowchart for a specific flow chart. Figure 4 Specifically, for the divided time series training set and test set, firstly, the base model (Linear, DLinear, NLinear) is learned on the training set, and the prediction results of each base model in the training set and test set are calculated. Secondly, the meta-learner is constructed and learned. In view of the daily cycle characteristics of the load, the prediction results at different time points are regarded as different random variables, so there are 96*3 random variables in total. ; ; , where the subscript indicates the time point and the superscript is used to indicate the model. Construct the prediction results of each basic model at different time points , , The linear regression model is as follows:
[0040] The weights and biases of each linear regression model are optimized on the training set, that is, a total of 96*4 parameters are estimated. Finally, the model fusion prediction result is calculated. According to the prediction values of each regression model and each base model on the test set, the prediction result of the stacking comprehensive model on the test set is calculated.
[0041] In a specific embodiment, load data of a certain province is used with a resolution of 15 minutes. Linear, DLinear, and NLinear in the LTSF-Linear model are used as the base models for load forecasting, and the load of 96 points in the next day is predicted based on the historical 192-point load sequence (T+1 prediction). All data are divided into training set, validation set, and test set according to the ratio of 0.7:0.1:0.2. The prediction accuracy results of the model on the test set are displayed, and the test set stage is data from the same time range for more than one year. The evaluation indicators include accuracy and maximum load accuracy, which are defined as shown in Table 1 below.
[0042] Table 1 Evaluation indicator definition
[0043] (1) Accuracy on normal days and holidays Tables 2 and 3 show the accuracy and maximum load accuracy of each model for weekdays and holidays. It can be seen that: ① The model's prediction accuracy for weekdays is generally 0.7-1 percentage points higher than that for holidays; the prediction accuracy for maximum load on weekdays is generally 0.5 percentage points higher than that for holidays. ② The prediction performance (accuracy and maximum load accuracy) of the three base models on weekdays is relatively similar, while the difference in holiday prediction is slightly more obvious. Overall, DLinear's performance is slightly better, but the performance difference of the three base models is small. ③ In terms of the accuracy of holidays and weekdays, the Stacking model fusion method does not show its superiority, and its accuracy is about 0.3% higher than the average accuracy of the base model.
[0044] Table 2 Accuracy of day-based types
[0045] Table 3 Maximum load accuracy of daily types
[0046] (2) Monthly average accuracy Tables 4 and 5 show the monthly statistics of the accuracy of each model and the maximum load accuracy, and the results are still similar: the performance differences of the three base models in each month are small; the Stacking model fusion method does not show its superiority, but only improves by about 0.3% compared with the base model in some months.
[0047] Table 4: Accuracy by month
[0048] Table 5 Maximum load accuracy by month
[0049] Through the above technical solution, in terms of forecasting model construction, Linear, DLinear, and NLinear in the LTSF-Linear model are used as base models for load forecasting to predict historical load data respectively, and the linear regression model based on the above base model is used as the meta-model, and the final forecasting result is obtained through training through the multi-model fusion Stacking ensemble learning method, which improves the accuracy of the load forecasting results.
[0050] See also Figure 5 FIG. 1 is a schematic diagram of a load forecasting system provided by an embodiment of the present invention, comprising: The acquisition unit 50 is used to acquire historical load data and pre-process the historical load data to obtain target historical load data; A prediction unit 51 is used to input the target historical load data into a pre-built LTSF-Linear model for prediction to obtain a prediction result, wherein the pre-built LTSF-Linear model includes a Linear sub-model, a DLinear sub-model and an NLinear sub-model; The fusion unit 52 is used to use multi-model fusion Stacking ensemble learning to calculate the prediction result output by the LTSF-Linear model based on the linear regression model to obtain the target prediction result.
[0051] In some implementations, the prediction unit 51 is specifically configured to: Input the target historical load data into the Linear sub-model and obtain the first prediction result through weighted sum operation; The target historical load data is input into the DLinear sub-model, and the DLinear sub-model performs sequence decomposition on the target historical load data to obtain a trend sequence and a remaining sequence other than the trend sequence, and the trend sequence and the remaining sequence other than the trend sequence are respectively input into the Linear sub-model to obtain the prediction result corresponding to the trend sequence and the prediction result corresponding to the remaining sequence other than the trend sequence, and merge them to obtain a second prediction result; Input the target historical load data into the NLinear sub-model, subtract the last value in the sequence corresponding to the target historical load data from the NLinear sub-model to obtain a simple standard sequence, perform prediction based on the simple standard sequence to obtain a predicted value, and add the subtracted last value to the predicted value to obtain a third prediction result; The first prediction result, the second prediction result and the third prediction result are integrated to obtain a prediction result.
[0052] In some embodiments, the fusion unit 52 is specifically used for: The Linear sub-model, DLinear sub-model, and NLinear sub-model in the LTSF-Linear model are used as the base models for load forecasting, and linear regression is used as the meta-learner. Divide the historical load data into a time series training set and a test set, and calculate the prediction results of the base model in the training set and the test set; Based on the daily cycle characteristics of the load, the forecast results at different time points are regarded as different random variables, and a linear regression model of the forecast results of the base model is constructed for each time point; The weights and biases of the linear regression model are optimized on the training set, and the target prediction results are calculated based on the linear regression model and the prediction results of the base model on the test set.
[0053] On the other hand, the present invention also provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the steps of the load forecasting method described in any one of the above embodiments when executing the program.
[0054] On the other hand, the present invention further provides a non-transitory computer-readable storage medium having a computer program stored thereon, and when the computer program is executed by a processor, the steps of the load forecasting method described in any one of the above embodiments are implemented.
[0055] Those skilled in the art will appreciate that the embodiments of the present application may be provided as methods, systems, or computer program products. Therefore, the present application may adopt the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, the present application may adopt 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 codes.
[0056] The present application is described with reference to the flowcharts and / or block diagrams of the methods, devices (systems), and computer program products according to the embodiments of the present application. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of the processes and / or boxes 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 generate 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.
[0057] 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 1 A function specified in one or more boxes.
[0058] 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.
[0059] In a typical configuration, a computing device includes one or more processors (CPU), input / output interfaces, network interfaces, and memory.
[0060] The memory may include non-permanent memory in a computer-readable medium, random access memory (RAM) and / or non-volatile memory in the form of read-only memory (ROM) or flash RAM. The memory is an example of a computer-readable medium.
[0061] Computer readable media include permanent and non-permanent, removable and non-removable media that can be implemented by any method or technology to store information. Information can be computer readable instructions, data structures, program modules or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technology, compact disk read-only memory (CD-ROM), digital versatile disk (DVD) or other optical storage, magnetic cassettes, magnetic tape magnetic disk storage or other magnetic storage devices or any other non-transmission media that can be used to store information that can be accessed by a computing device. As defined herein, computer readable media does not include temporary computer readable media (transitory media), such as modulated data signals and carrier waves.
[0062] 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.
[0063] The above are only embodiments of the present application and are 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 within the scope of the claims of the present application.
Claims
1. A load forecasting method, characterized in that: include: Acquire historical load data, and pre-process the historical load data to obtain target historical load data; Inputting the target historical load data into a pre-built LTSF-Linear model for prediction to obtain a prediction result, wherein the pre-built LTSF-Linear model includes a Linear sub-model, a DLinear sub-model and an NLinear sub-model; Use multi-model fusion Stacking ensemble learning to calculate the prediction results output by the LTSF-Linear model based on the linear regression model to obtain the target prediction results.
2. The load forecasting method according to claim 1, characterized in that: Obtain historical load data and preprocess the historical load data to obtain target historical load data, including: Selecting initial historical load data from the acquired historical load data, and repairing missing values, error values, and noise values in the initial historical load data; The repaired initial historical load data are integrated to obtain the target historical load data.
3. The load forecasting method according to claim 1, characterized in that: The target historical load data is input into the pre-built LTSF-Linear model for prediction to obtain prediction results, including: Input the target historical load data into the Linear sub-model and obtain the first prediction result through weighted sum operation; The target historical load data is input into the DLinear sub-model, and the DLinear sub-model performs sequence decomposition on the target historical load data to obtain a trend sequence and a remaining sequence other than the trend sequence, and the trend sequence and the remaining sequence other than the trend sequence are respectively input into the Linear sub-model to obtain the prediction result corresponding to the trend sequence and the prediction result corresponding to the remaining sequence other than the trend sequence, and merge them to obtain a second prediction result; Input the target historical load data into the NLinear sub-model, subtract the last value in the sequence corresponding to the target historical load data from the NLinear sub-model to obtain a simple standard sequence, perform prediction based on the simple standard sequence to obtain a predicted value, and add the subtracted last value to the predicted value to obtain a third prediction result; The first prediction result, the second prediction result and the third prediction result are integrated to obtain a prediction result.
4. The load forecasting method according to claim 1, characterized in that: Use multi-model fusion Stacking ensemble learning to calculate the prediction results output by the LTSF-Linear model based on the linear regression model to obtain the target prediction results, including: The Linear sub-model, DLinear sub-model, and NLinear sub-model in the LTSF-Linear model are used as the base models for load forecasting, and linear regression is used as the meta-learner. Divide the historical load data into a time series training set and a test set, and calculate the prediction results of the base model in the training set and the test set; Based on the daily cycle characteristics of the load, the forecast results at different time points are regarded as different random variables, and a linear regression model of the forecast results of the base model is constructed for each time point; The weights and biases of the linear regression model are optimized on the training set, and the target prediction results are calculated based on the linear regression model and the prediction results of the base model on the test set.
5. The load forecasting method according to claim 4, characterized in that: The linear regression model is as follows: ; ; In the formula, Represents the prediction results of the Stacking ensemble learning model on the test set. , , Represents the weights of the Linear sub-model, DLinear sub-model, and NLinear sub-model at the i-th moment, , , It represents the prediction results of Linear sub-model, DLinear sub-model and NLinear sub-model at the i-th moment. Represents bias, where n is an integer.
6. A load forecasting system, characterized in that: include: An acquisition unit, used for acquiring historical load data, and preprocessing the historical load data to obtain target historical load data; A prediction unit, used for inputting the target historical load data into a pre-built LTSF-Linear model for prediction to obtain a prediction result, wherein the pre-built LTSF-Linear model includes a Linear sub-model, a DLinear sub-model and an NLinear sub-model; The fusion unit is used to use multi-model fusion Stacking ensemble learning to calculate the prediction results output by the LTSF-Linear model based on the linear regression model to obtain the target prediction results.
7. The load forecasting system according to claim 6, characterized in that: The prediction unit is specifically used for: Input the target historical load data into the Linear sub-model and obtain the first prediction result through weighted sum operation; The target historical load data is input into the DLinear sub-model, and the DLinear sub-model performs sequence decomposition on the target historical load data to obtain a trend sequence and a remaining sequence other than the trend sequence, and the trend sequence and the remaining sequence other than the trend sequence are respectively input into the Linear sub-model to obtain the prediction result corresponding to the trend sequence and the prediction result corresponding to the remaining sequence other than the trend sequence, and merge them to obtain a second prediction result; Input the target historical load data into the NLinear sub-model, subtract the last value in the sequence corresponding to the target historical load data from the NLinear sub-model to obtain a simple standard sequence, perform prediction based on the simple standard sequence to obtain a predicted value, and add the subtracted last value to the predicted value to obtain a third prediction result; The first prediction result, the second prediction result and the third prediction result are integrated to obtain a prediction result.
8. The load forecasting system according to claim 6, characterized in that: The fusion unit is specifically used for: The Linear sub-model, DLinear sub-model, and NLinear sub-model in the LTSF-Linear model are used as the base models for load forecasting, and linear regression is used as the meta-learner. Divide the historical load data into a time series training set and a test set, and calculate the prediction results of the base model in the training set and the test set; Based on the daily cycle characteristics of the load, the forecast results at different time points are regarded as different random variables, and a linear regression model of the forecast results of the base model is constructed for each time point; The weights and biases of the linear regression model are optimized on the training set, and the target prediction results are calculated based on the linear regression model and the prediction results of the base model on the test set.
9. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the program, the steps of the load forecasting method according to any one of claims 1 to 5 are implemented.
10. A non-transitory computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the load forecasting method according to any one of claims 1 to 5 are implemented.
Citation Information
Patent Citations
Distribution transformer short-term load prediction method and device and electronic equipment
CN116128109A
Load prediction method and device based on LSTM and multi-model integration
CN116865235A
Day-ahead load prediction method and device and load prediction system
CN117895480A
