A method, medium and application for preprocessing missing data for short-term load forecasting
Through the classification of historical data and the fitting of multiple mathematical functions, the data is completed according to the slope of the missing points, which solves the problem of missing data in short-term power load forecasting and improves the prediction accuracy and reliability.
Patent Information
- Application Number
- CN202110597836.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-05-31
- Publication Date
- 2024-09-06
- Estimated Expiration
- 2041-05-31
AI Technical Summary
Existing technology is difficult to effectively handle data missing in short-term power load forecasting, especially in the case of continuous data loss and mutation, resulting in low forecasting accuracy and large errors.
By classifying historical data, finding the average load on similar days, fitting multiple mathematical functional expressions, and using different calculation methods to fill in the missing data according to the slope of the missing points, including using polyfit fitting methods and characteristic coefficient calculations .
It improves the accuracy and reliability of short-term power load forecasting, overcomes the problem of large errors in existing technology when dealing with continuous data loss, and achieves higher-quality data completion.
Smart Images

Figure CN113378102B
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of electric power data mining, and relates to a method for processing electric power load data, and in particular to a method, medium and application for preprocessing missing data for short-term load forecasting. Background Art
[0002] Power load forecasting is one of the important tasks of power system dispatching, electricity consumption, planning, and other management departments. Accurate short-term load forecasting can economically and reasonably arrange the start and stop of power generation units within the power grid, maintain the safety and stability of power grid operation, reduce unnecessary rotating reserve capacity, reasonably arrange unit maintenance plans, ensure the normal production and life of society, effectively reduce power generation costs, and improve economic and social benefits. Accurate medium- and long-term load forecasting is conducive to determining the installed capacity, location and time of new power generation units in the future, and determining the capacity increase, reconstruction, construction and development of the power grid. Therefore, high-precision load forecasting is very necessary.
[0003] The power load forecasting work depends to a large extent on the historical data collected. The completeness and accuracy of the historical data will have a serious impact on the quality of the load forecast. Especially in the medium and long-term load forecasting, due to historical reasons, mainly the negligence of the data collection or storage department, some archival data may be left unrecorded or lost, which results in data gaps. The collected historical data often has data gaps. This part of the data gap is data gap and data distortion.
[0004] If these missing data are not effectively supplemented, extrapolated and corrected, they will be provided to the load forecast as a reference in the form of false information and false change rules, which will inevitably mislead the establishment of the load forecast model, affect the accuracy and reliability of the forecast results, and directly affect the forecast results.
[0005] The existing methods for filling in the gaps in the intermediate data are mainly divided into the non-adjacent mean generation method and the recursive non-adjacent mean generation method. Among them, the non-adjacent mean generation method is the averaging method, and the recursive non-adjacent mean generation method is a method that uses the data at both ends of the missing data to obtain the missing data in the middle by using the non-adjacent mean generation method, and then uses the data at both ends and the obtained missing data one by one by using the non-adjacent mean generation method to finally fill in the missing data.
[0006] The biggest drawback of these methods is that they cannot handle the situation of continuous data loss and continuous data mutation. When correcting the first abnormal data, the next load data must be used. If the next data is still abnormal data, it will seriously affect the correction effect. In summary, the relative errors generated by the prediction are large, and the overall prediction accuracy is not high. Summary of the invention
[0007] The purpose of the present invention is to overcome the defects of the above-mentioned prior art and provide a highly reliable preprocessing method, medium and application for short-term load forecasting data missing.
[0008] The purpose of the present invention can be achieved by the following technical solutions:
[0009] A method for preprocessing missing data for short-term load forecasting, comprising:
[0010] A classification step, obtaining historical data, and classifying the time collection points of the historical data according to set indicators;
[0011] In the averaging step, based on the local missing area, the load average of the same type of similar daily collection points is obtained to obtain a series of time collection point-load relationship pairs;
[0012] The relationship fitting step is to select a number of time acquisition point-load relationship pairs in the neighborhood of the local missing area and fit them to obtain a multinomial mathematical function formula;
[0013] The filling step is to calculate the derivative of the missing point in the multi-functional mathematical expression as the slope at the missing point, and fill the load value at the missing point using different calculation methods according to the size of the slope.
[0014] Furthermore, the set indexes include the type of collection day and external climate conditions at the collection point.
[0015] Furthermore, the polynomial mathematical function formula is obtained by using a polyfit fitting method.
[0016] Furthermore, different calculation methods are used to fill in the load value at the missing point according to the size of the slope:
[0017] If the slope at the missing point is less than 0, the load value at the missing point is calculated using formula (1):
[0018]
[0019] If the slope at the missing point is greater than 0, the load value at the missing point is calculated using formula (2):
[0020]
[0021] If the slope at the missing point is equal to 0, the load value at the missing point is calculated using formula (3):
[0022]
[0023] Among them, P i represents the load value at the missing point, Psta Indicates that there is a recorded load value before the missing point, P end Indicates that there is a recorded load value after the missing point, g imax is the maximum slope value in the historical data of the i-missing point, k i is the characteristic coefficient, and R is a random number.
[0024] Furthermore, the characteristic coefficient k in the formula (1) is i It is calculated using the following formula:
[0025]
[0026] Among them, α1 and α2 are correction coefficients.
[0027] Furthermore, the characteristic coefficient k in the formula (2) is i It is calculated using the following formula:
[0028]
[0029] Among them, α1 and α2 are correction coefficients.
[0030] Furthermore, the correction coefficient α1 has a value range of 0.90-0.99, and the correction coefficient α2 has a value range of 0.97-0.99.
[0031] Furthermore, the random number R has a value range of 0.4-0.6.
[0032] The present invention also provides a computer-readable storage medium, comprising one or more programs for execution by one or more processors of an electronic device, wherein the one or more programs include instructions for executing the method for preprocessing missing data for short-term load forecasting as described above.
[0033] The present invention also provides an application of the method for preprocessing missing data for short-term load forecasting as described above, which realizes short-term load forecasting of the power system based on historical data after the load values at the missing points are supplemented.
[0034] Compared with the prior art, the present invention has the following beneficial effects:
[0035] 1. The present invention classifies the time collection points of historical data according to set indicators, and fills in the missing data based on similar days of the same type in the local missing area. It can effectively fill in the missing sample data with high quality, and can improve the short-term power load forecasting accuracy to a certain extent, which is beneficial to the stable operation of the power grid.
[0036] 2. The present invention adopts different calculation methods to obtain the load value at the missing point according to the different slopes of the missing point, which has higher reliability.
[0037] 3. The method of the present invention can overcome the shortcoming of large error in processing continuous data loss by the non-adjacent mean generation method. BRIEF DESCRIPTION OF THE DRAWINGS
[0038] Figure 1 It is a schematic diagram of the process of the present invention;
[0039] Figure 2 It is the T1-T12 polynomial function fitting graph corresponding to curve A;
[0040] Figure 3 Comparison between the actual load curve of T1-T12 on a certain day and the two supplementary load curves;
[0041] Figure 4 It is the T31-T46 polynomial function fitting diagram corresponding to curve B;
[0042] Figure 5 Comparison between the actual load curve of T31-T46 on a certain day and the two supplementary load curves;
[0043] Figure 6 It is the T54-T66 polynomial function fitting diagram corresponding to curve C;
[0044] Figure 7 Comparison between the actual load curve of T54-T66 on a certain day and the two supplementary load curves. DETAILED DESCRIPTION
[0045] The present invention is described in detail below in conjunction with the accompanying drawings and specific embodiments. This embodiment is implemented based on the technical solution of the present invention, and provides a detailed implementation method and specific operation process, but the protection scope of the present invention is not limited to the following embodiments.
[0046] refer to Figure 1 As shown, the present invention provides a method for preprocessing missing data for short-term load forecasting, comprising:
[0047] S101, a classification step, obtaining historical data, and classifying the time collection points of the historical data according to set indicators;
[0048] S102, averaging step, according to the local missing area, calculate the load average value of the same type of similar daily collection points to obtain a series of time collection point-load relationship pairs;
[0049] S103, a relationship fitting step, selecting a number of time acquisition point-load relationship pairs in the neighborhood of the local missing area, and fitting to obtain a multinomial mathematical function;
[0050] S104, a filling step, calculating the derivative of the missing point in the multinomial mathematical function as the slope at the missing point, and using different calculation methods to fill the load value at the missing point according to the size of the slope.
[0051] The set index includes the type of collection day and the external climate conditions of the collection point. Specifically, the method of the present invention classifies all the 96 or 288 historical data points collected daily into working days, rest days and holidays, as well as corresponding external climate conditions, such as temperature, humidity, wind speed, cloud cover, sunshine hours, sunshine intensity and other indicators.
[0052] In the averaging step, missing points are not included in the average calculation.
[0053] In the present invention, a polyfit fitting method can be used to obtain a polynomial mathematical function, and the obtained polynomial mathematical function can be expressed as:
[0054] P(x)=A+Bx+Cx 2 +Dx 3 +......
[0055] Where A, B, C and D are unknown constants; P(x) represents the load at time point x, where x is the time point of load operation, ranging from 0 to 24 hours.
[0056] Using the multinomial mathematical function P(x), the derivatives are calculated for a number of time points at the missing points (generally no more than 5 points) to determine the size of the slope at that point. Let the slope be g, then the size of the slope is divided into three types:
[0057] P′(x)=g<0
[0058] P′(x)=g>0
[0059] P′(x)=g=0
[0060] According to the size of the slope, different calculation methods are used to fill in the load value at the missing point:
[0061] If the slope at the missing point is less than 0, the load value at the missing point is calculated using formula (1):
[0062]
[0063] If the slope at the missing point is greater than 0, the load value at the missing point is calculated using formula (2):
[0064]
[0065] If the slope at the missing point is equal to 0, the load value at the missing point is calculated using formula (3):
[0066]
[0067] Among them, P irepresents the load value at the missing point, P sta Indicates that there is a recorded load value before the missing point, P end Indicates that there is a recorded load value after the missing point, g imax is the maximum slope value in the historical data of the i-missing point, k i is the characteristic coefficient, R is a random number, and its value range is 0.4-0.6.
[0068] The characteristic coefficient k in formula (1) i It is calculated using the following formula:
[0069]
[0070] Among them, α1 and α2 are correction coefficients, the value range of α1 is 0.90-0.99, and the value range of α2 is 0.97-0.99.
[0071] The characteristic coefficient k in formula (2) i It is calculated using the following formula:
[0072]
[0073] Among them, α1 and α2 are correction coefficients, the value range of α1 is 0.90-0.99, and the value range of α2 is 0.97-0.99.
[0074] If the functions are implemented in the form of software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, or the part that contributes to the prior art or the part of the technical solution, can be embodied in the form of a software product. The computer software product is stored in a storage medium, including several instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the methods described in each embodiment of the present invention. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk, etc., which can store program codes.
[0075] The load data of 10kV power main equipment in a regional power grid for three years and 1095 days were collected, with a total of 2372865 load curves. Each load curve records 96 points throughout the day, with a total of 227795040 data points. Partial missing data was artificially created for one of the curves.
[0076] The data set S is a set of all 2372865 load curves, which is divided into two load curve sets S1 and S2; S1 is a set of three curves with missing values, namely curve A, curve B and curve C, and S2 is a set of other curves without missing values.
[0077] Example 1
[0078] The artificially created curve A has two missing values, missing at T=6,7, as shown in Table 1.
[0079] Table 1 Loading data of artificially created curve A with 2 missing values
[0080]
[0081] Note: Data in brackets are missing data
[0082] Dataset S2 is classified according to working days, rest days and holidays, as well as corresponding external climate conditions, such as temperature, humidity, wind speed, cloud cover, sunshine hours, sunshine intensity and other indicators. Curve A belongs to the working day. Dataset S2 takes the average value of each collection point on similar days of the same type (points with missing data are not included in the average value calculation). In this way, a series of time collection point-load value relationship pairs are obtained. Then, at about 6 points before and after T=6,7, T1-T12 is selected in this embodiment, and a polynomial mathematical function is fitted by polyfit from these time collection point-load value relationship pairs so that it can represent the time-load relationship at any time point in this section. The fitting result of the polynomial function is as follows Figure 2 shown.
[0083] According to the polynomial function obtained by polyfit, the derivatives are calculated for the time points where T6 and T7 are missing, and the slopes at these points are determined. The slopes of T6 and T7 are P′(6)=g6<0 and P′(7)=g7<0, and then substituted into the formula:
[0084]
[0085] in,
[0086]
[0087] in,
[0088] In the above formula, g 6max and g 7max They are the maximum slope values in the historical data of points T6 and T7 respectively. If the correction coefficient is selected by machine learning based on the historical data, α1 is 0.975 and α2 is 0.980, thus P6 is calculated to be 4591.5. Similarly, the load value of point T7 on a certain day can be calculated.
[0089] For comparison, we use the existing non-neighboring mean filling methods, such as Figure 3 As shown in the figure, the dotted line represents the filling of missing values of the data of a certain day (T=6,7) of the 10kV power main equipment of a certain regional power grid by the method of the present invention in this embodiment, and the thick solid line represents the filling of non-adjacent mean values. Obviously, for these two discrete missing values, the filling effect of the present invention is significantly better than that of the non-adjacent mean filling method.
[0090] Example 2
[0091] The artificially created curve B has 4 consecutive missing values, and the data are missing at T=37-40, as shown in Table 2.
[0092] Table 2 Loading data of artificially created curve B with 4 consecutive missing values
[0093]
[0094] Note: Data in brackets are missing data
[0095] Curve B is a working day. The average value of each collection point of the data set S2 on similar days is taken (points with missing data are not included in the average value calculation). In this way, a series of time collection point-load value relationship pairs are obtained. Then, at about 6 points before and after T=37-40, T31-T46 is selected in this embodiment, and a polynomial mathematical function is fitted by polyfit from these time collection point-load value relationship pairs, so that it can represent the time-load relationship at any time point in this section. The polynomial function fitting result is as follows Figure 4 shown.
[0096] According to the polynomial function obtained by polyfit, the derivatives are calculated for the time points at each missing point T = 37-40 to determine the size of the slope at that point. The slope of T37-T40 is P′(37) = g 37 >0, P′(38)=g 38 >0 until P′(40)=g 40 >0, and then substitute into the formula:
[0097]
[0098] in,
[0099]
[0100] in,
[0101] In the above formula (P 38 With P 39 Similarly, omitted), g 37max , g 38max, g 39max and g 40max They are the maximum slope values in the historical data of points T37, T38, T39, and T40. If the correction coefficient is selected by machine learning from historical data, α1 is 0.90 and α2 is 0.97, then P is calculated. 37 It is 6433.6. Similarly, the load values of the other three points T38, T39 and T40 on a certain day can be calculated.
[0102] For comparison, we use the existing recursive non-neighboring mean filling method, such as Figure 5 As shown, the dotted line represents the filling of missing data (T=37-40) of a certain day of 10kV power main equipment in a certain regional power grid in this embodiment by the method of the present invention, and the thick solid line represents the filling of the recursive non-adjacent mean. Obviously, for 4 consecutive discrete missing values, the filling effect of the present invention is significantly better than the recursive non-adjacent mean filling method.
[0103] Example 3
[0104] The artificially created curve C has one missing value, which is missing at T=59, as shown in Table 3.
[0105] Table 3 Loading data of artificially created curve C with 1 missing value
[0106]
[0107] Note: Data in brackets are missing data
[0108] Curve C is a working day. The average value of each collection point of the data set S2 on similar days is taken (points with missing data are not included in the average value calculation). In this way, a series of time collection point-load value relationship pairs are obtained. Then, at about 6 points before and after T=59, T54-T65 is selected in this embodiment, and a polynomial mathematical function is fitted by polyfit from these time collection point-load value relationship pairs, so that it can represent the time-load relationship at any time point in this section. The polynomial function fitting result is as follows Figure 6 shown.
[0109] According to the polynomial function obtained by polyfit, the derivative is calculated for the time point where T = 59 is missing, and the size of the slope at this point is determined, P'(59) = g 59 = 0 and the slope of T58 and T60 P′(58) = g 58 >0 and P′(60)=g 60 <0, then substitute into the formula:
[0110]
[0111] In the above formula, R is a random number between 0.4 and 0.6, and 0.5 is selected here. It can be calculated that the load value of point T59 on a certain day is 6346.3.
[0112] For comparison, we use the existing non-neighboring mean filling methods, such as Figure 7 As shown in the figure, the dotted line represents the filling of missing values of the data of a certain day (T=59) of a 10kV power main equipment in a certain regional power grid by the method of the present invention in this embodiment, and the thick solid line represents the filling of non-adjacent mean values. Obviously, for this discrete missing value, the filling effect of the present invention is significantly better than that of the non-adjacent mean value filling method.
[0113] After obtaining the completed historical data using the above method, more accurate and reliable short-term load forecasting of the power system can be carried out.
[0114] The preferred specific embodiments of the present invention are described in detail above. It should be understood that a person skilled in the art can make many modifications and changes based on the concept of the present invention without creative work. Therefore, any technical solution that can be obtained by a person skilled in the art through logical analysis, reasoning or limited experiments based on the concept of the present invention on the basis of the prior art should be within the scope of protection determined by the claims.
Claims
1. A method for preprocessing missing data for short-term load forecasting, characterized in that: include: A classification step, obtaining historical data, and classifying the time collection points of the historical data according to set indicators; In the averaging step, based on the local missing area, the load average of the same type of similar daily collection points is obtained to obtain a series of time collection point-load relationship pairs; The relationship fitting step is to select a number of time acquisition point-load relationship pairs in the neighborhood of the local missing area and fit them to obtain a multinomial mathematical function formula; A filling step, calculating the derivative of the missing point in the multi-functional mathematical expression as the slope at the missing point, and filling the load value at the missing point using different calculation methods according to the size of the slope; According to the size of the slope, different calculation methods are used to fill in the load value at the missing point: If the slope at the missing point is less than 0, the load value at the missing point is calculated using formula (1): If the slope at the missing point is greater than 0, the load value at the missing point is calculated using formula (2): If the slope at the missing point is equal to 0, the load value at the missing point is calculated using formula (3): Among them, P i represents the load value at the missing point, P sta Indicates that there is a recorded load value before the missing point, P end Indicates that there is a recorded load value after the missing point, g imax is the maximum slope value in the historical data of the i-missing point, k i is the characteristic coefficient, R is a random number, g i is the slope at the missing point i; The characteristic coefficient k in the formula (1) is i It is calculated using the following formula: Among them, α1 and α2 are correction coefficients; The characteristic coefficient k in the formula (2) is i It is calculated using the following formula: Among them, α1 and α2 are correction coefficients.
2. The method for preprocessing missing data for short-term load forecasting according to claim 1, characterized in that: The set indicators include the type of collection day and the external climate conditions of the collection point.
3. The method for preprocessing missing data for short-term load forecasting according to claim 1, characterized in that: The polynomial mathematical function formula is obtained by using the polyfit fitting method.
4. The method for preprocessing missing data for short-term load forecasting according to claim 1, characterized in that: The correction coefficient α1 has a value range of 0.90-0.99, and the correction coefficient α2 has a value range of 0.97-0.
99.
5. The method for preprocessing missing data for short-term load forecasting according to claim 1, characterized in that: The value range of the random number R is 0.4-0.
6.
6. A computer-readable storage medium, characterized in that: It comprises one or more programs for execution by one or more processors of an electronic device, wherein the one or more programs comprise instructions for executing the method for preprocessing missing data for short-term load forecasting as claimed in any one of claims 1-5.
7. An application of the method for preprocessing missing data for short-term load forecasting according to any one of claims 1 to 5, characterized in that: The short-term load forecast of the power system is realized based on the historical data after the load values at the missing points are supplemented.
