Energy demand prediction method and device, electronic equipment and storage medium

By STL decomposition and correction of residual terms on historical energy consumption data, the problem that traditional models cannot capture sudden changes is solved, and the accuracy and reliability of energy demand prediction are improved.

CN120124808APending Publication Date: 2025-06-10GUANGDONG POWER GRID CO LTD
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202510302237.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-03-14
Publication Date
2025-06-10

AI Technical Summary

Technical Problem

Traditional energy demand forecasting models lack sufficient flexibility and adaptability to effectively capture sudden changes, resulting in bias in prediction results.

Method used

By STL decomposing the historical energy consumption data of each sub-region in the target area, the trend term, season term and residual term are obtained, and the periodic part related to temperature is eliminated from the season term to obtain the predicted temperature-controlled consumption. Correct the residual term based on the degree of mutation, and make predictions based on the trend term, season term and adjustment residual term.

Benefits of technology

Improve the accuracy and reliability of energy demand forecasts, and can more effectively capture the impact of sudden changes and extreme weather on energy demand, reducing forecast deviations.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120124808A_ABST
    Figure CN120124808A_ABST
Patent Text Reader

Abstract

The invention discloses an energy demand prediction method and device, electronic equipment and a storage medium, and the method comprises the steps: carrying out the STL decomposition of historical energy consumption data of each sub-region in a target region, and obtaining a trend term, a season term and a residual term of each sub-region; removing periodic parts related to the air temperature from the seasonal items to obtain corresponding basic seasonal items; acquiring air temperature forecast data corresponding to a future time node, and calculating predicted temperature control consumption in each sub-region; predicting to obtain a corresponding prediction trend item, a prediction basic season item and a prediction residual item, and obtaining a corresponding prediction season item according to the prediction basic season item and the prediction temperature control consumption; and determining a correction factor of each data point in the residual item corresponding to each sub-region, correcting the corresponding prediction residual item, and taking the sum of the prediction trend item, the prediction season item and the adjustment residual item as energy demand prediction data of the corresponding sub-region. According to the invention, the precision of energy demand prediction can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of data processing, and particularly to an energy demand prediction method, device, electronic device and storage medium. Background Art

[0002] Energy demand prediction is crucial for ensuring the stability and sustainability of energy supply. Accurate prediction results can provide strong evidence for governments and enterprises, facilitating the rational planning of energy production, reserves and distribution by governments and enterprises, thereby effectively reducing the risks of energy shortage or surplus and ensuring the normal operation of social life. In commercial and administrative electricity consumption areas, such as subways, shopping malls, administrative office buildings, etc., their energy demands have obvious regularities, and the reliability and reference value of energy prediction results are relatively high. Currently, the energy demand prediction for these two types of areas is the most widely applied. Moreover, in these two types of electricity consumption areas, temperature control devices are generally required to maintain a constant indoor temperature. Temperature regulation is an important factor in energy consumption in these two types of electricity consumption areas, and their energy demands are highly correlated with air temperature.

[0003] However, traditional prediction algorithms, such as the ARIMA model, SARIMA model and exponential smoothing method based on time series analysis, assume that the demand pattern is relatively stable and follows certain regularities, and they all rely on the trend and seasonal changes of historical data for prediction. However, these algorithms have obvious deficiencies in coping with the drastic fluctuations in energy demand caused by emergencies. For example, in the above two types of areas, their energy demand predictions rely on the regular changes of historical data of relevant factors such as air temperature for prediction. However, when an emergency occurs, such as in extreme weather or climate change, the air temperature will change sharply in a short time that does not conform to historical laws. Traditional models usually lack sufficient flexibility and adaptability to capture such sudden changes, thus affecting the accuracy and reliability of the prediction and resulting in deviations in the prediction results. Summary of the Invention

[0004] The present invention provides an energy demand prediction method, device, electronic device and storage medium to solve the technical problem that traditional models lack sufficient flexibility and adaptability to capture sudden changes, thus affecting the accuracy and reliability of the prediction and resulting in deviations in the prediction results.

[0005] To solve the above technical problem, an embodiment of the present invention provides an energy demand prediction method, including:

[0006] Obtain the historical energy consumption data and historical air temperature data of each sub-region in the target region, and perform STL decomposition on the historical energy consumption data to obtain the corresponding trend term, seasonal term and residual term for each sub-region;

[0007] Based on the historical temperature data, remove the periodic part related to temperature in the season item to obtain the corresponding basic season item;

[0008] Obtain the temperature forecast data corresponding to the future time node, and based on the difference between the temperature forecast data and the preset constant temperature within the sub-region, the power of each temperature control device, the efficiency of each temperature control device, and the heat capacity coefficient of the sub-region, obtain the predicted temperature control consumption within each sub-region;

[0009] Predict the trend item for the future time node according to the trend item to obtain the corresponding predicted trend item; predict the basic season item for the future time node according to the basic season item to obtain the corresponding predicted basic season item, and obtain the corresponding predicted season item according to the predicted basic season item and the predicted temperature control consumption; predict the residual item for the future time node according to the residual item to obtain the corresponding predicted residual item;

[0010] Cluster each sub-region according to the historical energy consumption data, divide all sub-regions into several categories, and then determine the mutation degree of each data point in the residual item corresponding to each sub-region according to the category corresponding to each sub-region and the value of each data point in the residual item corresponding to each sub-region;

[0011] Determine the correction factor of each data point in the residual item corresponding to each sub-region according to the mutation degree, and correct the corresponding predicted residual item according to the correction factor to obtain the corrected adjusted residual item. Then, take the sum of the predicted trend item, the predicted season item, and the adjusted residual item as the energy demand prediction data corresponding to the sub-region.

[0012] As a preferred solution, calculate the predicted temperature control consumption within each sub-region according to the following formula:

[0013]

[0014] △T=|T future -T set ;

[0015] where, ΔS temp,i is the predicted temperature control consumption within sub-region i, N is the total number of temperature control devices within the sub-region, ΔT is the difference between the temperature forecast data and the preset constant temperature within the sub-region, T future is the temperature forecast data, T set is the preset constant temperature within the sub-region, P device,i is the power of the temperature control device of sub-region i, C thermal,i is the heat capacity coefficient of sub-region i, and η i is the efficiency of the temperature control device of sub-region i.

[0016] As a preferred solution, decomposing the historical energy consumption data to obtain a trend term, a seasonal term, and a residual term corresponding to each sub-region includes:

[0017] Preprocessing the historical energy consumption data; wherein, the preprocessing includes: missing value filling, dimension unification, and outlier processing;

[0018] Calculating the coefficient of variation and the standard deviation of the preprocessed historical energy consumption data, and performing normalization processing on the coefficient of variation and the standard deviation;

[0019] Taking the product of the normalized coefficient of variation and a first preset coefficient as a first product, taking the product of the normalized standard deviation and a second preset coefficient as a second product, and taking the sum of the first product and the second product as the fluctuation degree of the historical energy consumption data; wherein, the sum of the first preset coefficient and the second preset coefficient is 1;

[0020] Determining the STL decomposition parameters corresponding to the historical energy consumption data according to the fluctuation degree; wherein, the STL decomposition parameters include: seasonal period and trend smoothing window;

[0021] Decomposing the historical energy consumption data according to the decomposition parameters and a preset STL decomposition algorithm to obtain a trend term, a seasonal term, and a residual term corresponding to each sub-region.

[0022] As a preferred solution, determining the mutation degree of each data point in the residual term corresponding to each sub-region according to the category corresponding to each sub-region and the value of each data point in the residual term corresponding to each sub-region includes:

[0023] For each sub-region, according to the category corresponding to the sub-region and the value of each data point in the residual term corresponding to the sub-region, determining the difference in the residual terms between the current sub-region and other sub-regions of the same category, and the difference in the residual terms between the current sub-region and other sub-regions of different categories at the same time node;

[0024] Determining the mutation degree of each data point in the residual term corresponding to the current sub-region according to the difference in the residual terms between the current sub-region and other sub-regions of the same category, and the difference in the residual terms between the current sub-region and other sub-regions of different categories at the same time node.

[0025] As a preferred solution, determining the trend smoothing window corresponding to the historical energy consumption data according to the following formula:

[0026] H n =H min +[(H max -H min )×(1-ln )];

[0027] Among them, H n is the trend smoothing window of the historical energy consumption data of the nth sub-region, H min is the preset window minimum value, H max is the preset window maximum value, H max is greater than H min , l n is the degree of fluctuation of the historical energy consumption data of the nth sub-region.

[0028] As an optimal solution, the mutation degree of each data point in the residual term corresponding to each sub-region is determined according to the following formula:

[0029]

[0030] Among them, τ ni is the mutation degree of the i-th data point in the residual term of the historical energy consumption data of the nth sub-region, μ ni is the value of the i-th data point in the residual term of the historical energy consumption data of the nth sub-region, μ ki is the value of the i-th data point in the residual term of the historical energy consumption data of the k-th sub-region other than the nth sub-region, M is the number of sub-regions, α ki is the category coefficient of the i-th data point in the residual term of the historical energy consumption data of the k-th sub-region other than the nth sub-region;

[0031] The correction factor of each data point in the residual term is determined according to the following formula:

[0032]

[0033] Among them, is the correction factor of the i-th data point in the residual term of the historical energy consumption data of the nth sub-region, t ni is the time node corresponding to the i-th data point in the residual term of the historical energy consumption data of the nth sub-region, c is the time node of the predicted residual term, τ ni is the mutation degree of the i-th data point in the residual term of the historical energy consumption data of the nth sub-region.

[0034] As an optimal solution, the predicted residual term is corrected according to the following formula to obtain the corrected adjusted residual term:

[0035]

[0036] Among them, ζ n is the adjusted residual term of the nth sub-region, is the predicted residual term of the nth sub-region, is the correction factor of the ith data point in the residual term of the historical energy consumption data of the nth sub-region, N i is the number of data points in the residual term of the historical energy consumption data of the nth sub-region, μ ni is the value of the ith data point in the residual term of the historical energy consumption data of the nth sub-region.

[0037] Based on the above embodiment, another embodiment of the present invention provides an energy demand forecasting device, including: a historical energy consumption data decomposition module, a basic seasonal item processing module, a temperature control consumption forecasting module, an initial forecasting module, a mutation degree determination module and an energy demand forecasting module;

[0038] The historical energy consumption data decomposition module is used to obtain the historical energy consumption data and historical temperature data of each sub-region in the target area, and perform STL decomposition on the historical energy consumption data to obtain the trend term, seasonal term and residual term corresponding to each sub-region;

[0039] The basic seasonal term processing module is used to remove the periodic part related to the temperature from the seasonal term according to the historical temperature data to obtain the corresponding basic seasonal term;

[0040] The temperature control consumption prediction module is used to obtain the temperature forecast data corresponding to the future time node, and obtain the predicted temperature control consumption in each sub-area according to the difference between the temperature forecast data and the preset constant temperature in the sub-area, the power of each temperature control device, the efficiency of each temperature control device and the heat capacity coefficient of the sub-area;

[0041] The initial prediction module is used to predict the trend item of the future time node according to the trend item to obtain the corresponding predicted trend item; predict the basic seasonal item of the future time node according to the basic seasonal item to obtain the corresponding predicted basic seasonal item, and obtain the corresponding predicted seasonal item according to the predicted basic seasonal item and the predicted temperature control consumption; predict the residual item of the future time node according to the residual item to obtain the corresponding predicted residual item;

[0042] The mutation degree determination module is used to cluster each sub-region according to the historical energy consumption data, divide all sub-regions into several categories, and then determine the mutation degree of each data point in the residual item corresponding to each sub-region according to the category corresponding to each sub-region and the value of each data point in the residual item corresponding to each sub-region;

[0043] The energy demand prediction module is used to determine the correction factors of each data point in the residual term corresponding to each sub-region according to the mutation degree, correct the corresponding prediction residual term according to the correction factors to obtain the corrected adjusted residual term, and then use the sum of the prediction trend term, prediction season term and adjusted residual term as the energy demand prediction data of the corresponding sub-region.

[0044] Based on the above embodiments, another embodiment of the present invention provides an electronic device, which includes a processor, a memory, and a computer program stored in the memory and configured to be executed by the processor. When the processor executes the computer program, it implements the energy demand prediction method described in the above embodiments of the present invention.

[0045] Based on the above embodiments, another embodiment of the present invention provides a storage medium, which includes a stored computer program. When the computer program runs, it controls the device where the storage medium is located to execute the energy demand prediction method described in the above embodiments of the present invention.

[0046] Compared with the prior art, the embodiments of the present invention have the following beneficial effects:

[0047] The present invention provides an energy demand prediction method. Compared with the prior art that only predicts based on the trend and seasonal changes in historical energy consumption data, the present invention first performs STL decomposition on the historical energy consumption data of each sub-region in the target area, and can obtain the corresponding trend term, season term and residual term. Among them, the residual term can represent the impact of sudden change factors such as emergencies, abnormal fluctuations, and unconventional seasonal changes on energy demand. Since temperature is one of the main driving factors for seasonal fluctuations, according to the historical temperature data, the periodic part related to temperature is removed from the season term to obtain the corresponding basic season term, and the influence of temperature fluctuations is excluded from the basic season term. Predictions are made based on the trend term, basic season term and residual term to obtain the corresponding predicted trend term, predicted basic season term and predicted residual term.

[0048] Furthermore, according to the difference between the temperature forecast data at future time nodes and the preset constant temperature within the sub-region, the power of each temperature control device, the efficiency of each temperature control device, and the heat capacity coefficient of the sub-region, the predicted temperature control consumption within each sub-region is obtained. The predicted temperature control consumption is the predicted consumption of the temperature factor independently separated from the season term. The total predicted season term can be obtained based on the predicted basic season term and the predicted temperature control consumption.

[0049] And since the mutation factors affecting the data points in the residual term may still continuously affect the predicted residual term, it is necessary to correct the predicted residual term based on the values of the data points in the residual term. Determine the mutation degree of each data point in the residual term corresponding to each sub-region according to the category corresponding to each sub-region and the values of each data point in the residual term corresponding to each sub-region; determine the correction factor of each data point in the residual term corresponding to each sub-region according to the mutation degree, and correct the corresponding predicted residual term according to the correction factor to obtain the adjusted residual term after correction. Finally, take the sum of the predicted trend term, the predicted seasonal term, and the adjusted residual term as the energy demand prediction data for the corresponding sub-region.

[0050] In the present invention, by removing the periodic part related to temperature in the seasonal term, instead of predicting the energy demand related to temperature according to the historical regularity of the seasonal term, the energy demand related to temperature is separately solved according to the temperature forecast data corresponding to the future time node. The predicted temperature control consumption obtained by the solution can reflect the impact of the temperature-related fluctuations on the energy demand. The corrected residual term can represent the impact of other sudden change factors on the energy demand except for the temperature mutation. Combining the predicted trend term, the predicted seasonal term, and the adjusted residual term can more accurately capture the fluctuations of the energy demand, solve the problem that the traditional prediction model cannot effectively cope with the impact of emergencies, improve the accuracy and reliability of the energy demand prediction, and ensure the reasonable allocation of energy resources. BRIEF DESCRIPTION OF THE DRAWINGS

[0051] Figure 1 is a schematic flowchart of an energy demand prediction method provided by an embodiment of the present invention;

[0052] Figure 2 is a schematic structural diagram of an energy demand prediction device provided by an embodiment of the present invention. DETAILED DESCRIPTION OF THE EMBODIMENTS

[0053] To make the objectives, technical solutions, and advantages of the present application clearer, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present application. Apparently, the described embodiments are some, but not all, of the embodiments of the present application. All other embodiments obtained by those of ordinary skill in the art without creative efforts based on the embodiments of the present application belong to the scope of protection of the present application.

[0054] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the technical field to which this application belongs; the terms used herein are for the purpose of describing specific embodiments only and are not intended to limit this application; the terms "including" and "having" and any variations thereof in the specification and claims of this application and the above description of the drawings are intended to cover non-exclusive inclusion.

[0055] In the description of the embodiments of this application, technical terms such as "first" and "second" are only used to distinguish different objects and cannot be understood as indicating or implying relative importance or implicitly specifying the quantity, specific order or primary-secondary relationship of the indicated technical features. In the description of the embodiments of this application, the meaning of "a plurality" is more than two, unless otherwise specifically defined.

[0056] Referring to "embodiments" herein means that the specific features, structures or characteristics described in connection with the embodiments may be included in at least one embodiment of this application. The phrase appears in various places in the specification does not necessarily refer to the same embodiment, nor is it an independent or alternative embodiment mutually exclusive with other embodiments. Those skilled in the art explicitly and implicitly understand that the embodiments described herein may be combined with other embodiments.

[0057] In the description of the embodiments of this application, the term "and / or" is only a description of the association relationship of associated objects, indicating that there can be three relationships. For example, A and / or B can represent: A exists alone, A and B exist simultaneously, and B exists alone. In addition, the character " / " in this article generally represents an "or" relationship between the associated objects before and after.

[0058] In the description of the embodiments of this application, the term "a plurality" refers to more than two (including two). Similarly, "multiple groups" refers to more than two groups (including two groups), and "multiple pieces" refers to more than two pieces (including two pieces).

[0059] In the description of the embodiments of this application, unless otherwise clearly specified and limited, technical terms such as "installation", "connection", "connection", "fixation" should be understood in a broad sense. For example, it can be a fixed connection, a detachable connection, or integrated; it can also be a mechanical connection or an electrical connection; it can be directly connected or indirectly connected through an intermediate medium, and it can be the communication inside two elements or the interaction relationship between two elements. For those of ordinary skill in the art, the specific meanings of the above terms in the embodiments of this application can be understood according to specific circumstances.

[0060] Embodiment 1

[0061] Please refer to Figure 1, is a schematic flowchart of an energy demand prediction method provided by an embodiment of the present invention, including the following specific steps:

[0062] S1. Obtain the historical energy consumption data and historical temperature data of each sub-region in the target region, and perform STL decomposition on the historical energy consumption data to obtain the corresponding trend term, seasonal term, and residual term for each sub-region;

[0063] Preferably, the step of decomposing the historical energy consumption data to obtain the corresponding trend term, seasonal term, and residual term for each sub-region includes: preprocessing the historical energy consumption data; wherein, the preprocessing includes: missing value filling, dimension unification, and outlier processing; calculating the coefficient of variation and standard deviation of the preprocessed historical energy consumption data, and normalizing the coefficient of variation and standard deviation; taking the product of the normalized coefficient of variation and the first preset coefficient as the first product, taking the product of the normalized standard deviation and the second preset coefficient as the second product, and taking the sum of the first product and the second product as the fluctuation degree of the historical energy consumption data; wherein, the sum of the first preset coefficient and the second preset coefficient is 1; determining the STL decomposition parameters corresponding to the historical energy consumption data according to the fluctuation degree; wherein, the STL decomposition parameters include: seasonal period and trend smoothing window; decomposing the historical energy consumption data according to the decomposition parameters and a preset STL decomposition algorithm to obtain the corresponding trend term, seasonal term, and residual term for each sub-region.

[0064] Preferably, the trend smoothing window corresponding to the historical energy consumption data is determined according to the following formula:

[0065] H n =H min +[(H max -H min )×(1-l n )];

[0066] wherein, H n is the trend smoothing window of the historical energy consumption data of the nth sub-region, H min is the preset window minimum value, H max is the preset window maximum value, H max is greater than H min , and l n is the fluctuation degree of the historical energy consumption data of the nth sub-region.

[0067] Specifically, the present invention provides an energy demand prediction method, which specifically includes the following steps:

[0068] Step 1. STL decomposition:

[0069] First, obtain the historical energy consumption data and historical temperature data of each sub-region in the target area, and decompose each of the historical energy consumption data using the STL decomposition algorithm to obtain the trend term, seasonal term, and residual term of each of the historical energy consumption data.

[0070] Among them, the STL (Seasonal-Trend decomposition using Loess) algorithm is a time series decomposition method that can decompose time series data into a trend term (Trend), a seasonal term (Seasonal), and a residual term (Remainder). Using the STL decomposition algorithm to decompose the historical energy consumption data, the obtained trend term can reflect the long-term change trend of historical energy consumption, that is, the overall change trend of historical energy demand; the seasonal term can reflect the periodic change of historical energy consumption, such as the impact of winter heating, summer air conditioning, etc. on energy demand; the residual term refers to the part remaining after removing the trend term and seasonal term from the historical energy consumption data, which is usually caused by factors such as emergencies, abnormal fluctuations, and unconventional seasonal changes.

[0071] It can be understood that traditional prediction algorithms usually ignore the impact of emergencies on energy demand, resulting in problems with the prediction results being deviated. Therefore, in this embodiment, the STL decomposition algorithm is first used to decompose the historical energy consumption data to obtain the residual term generated by the impact of emergencies on energy demand, and then the residual term is further processed and analyzed.

[0072] It should be noted that the energy consumption data of a large area is usually affected by the same mutation factors. Therefore, the target area is divided into several sub-regions, and the energy consumption data between each sub-region in the target area can be mutually referred to. For example, in terms of electric energy, the area covered by the power grid usually includes multiple small areas, and the power demands of these small areas may be affected by similar emergencies or external factors. By analyzing the energy consumption data of these sub-regions, the impact of mutation factors on the entire area can be captured more effectively, thereby improving the accuracy of overall prediction.

[0073] In the specific implementation process, first obtain the historical energy consumption data of each sub-region in the target area with a preset time length in the energy monitoring system. The target area is the area to be predicted by the implementer. For example, the target area can be a certain city, and at this time each sub-region is each residential area and each industrial and production park in the city; the target area can also be a specific building complex or business park, and each sub-region represents different buildings or different functional areas within the area.

[0074] Further, data cleaning is performed on the historical energy consumption data of each sub-region. The data cleaning includes at least: filling in missing values in the historical energy consumption data, standardizing the dimensions of the historical energy consumption data, and detecting outliers in the historical energy consumption data.

[0075] In step one, the STL decomposition algorithm is used to decompose each of the historical energy consumption data to obtain the trend term, seasonal term, and residual term of each of the historical energy consumption data. Specifically, it may include:

[0076] S11. Calculate the degree of fluctuation of each of the historical energy consumption data;

[0077] S12. Determine the decomposition parameters of each of the historical energy consumption data based on the degree of fluctuation;

[0078] S13. Based on each of the decomposition parameters, use the STL decomposition algorithm to decompose each of the historical energy consumption data respectively to obtain the trend term, seasonal term, and residual term of each of the historical energy consumption data.

[0079] Among them, the degree of fluctuation represents the magnitude of the numerical fluctuation of each historical energy consumption data, and the decomposition parameters of each historical energy consumption data are the various parameters set when using the STL decomposition algorithm to decompose each historical energy consumption data.

[0080] It should be noted that when using the STL decomposition algorithm, it is necessary to preset the various parameters of the STL decomposition algorithm. The various parameters of the STL decomposition algorithm mainly include: seasonal period (season), that is, the period length of seasonal changes in the time series; trend smoothing window (trend.window), which can control the smoothness of the trend term. A larger trend smoothing window can make the trend term more stable, while a smaller trend smoothing window can retain more data fluctuations.

[0081] It can be understood that in this embodiment, the decomposition parameters include the seasonal period and the trend smoothing window, and the other parameters of the STL decomposition algorithm can be artificially defined by the operator.

[0082] In this embodiment, since all the historical energy consumption data comes from the same target region, it can be considered that they are affected by the same seasonal period. When using the STL decomposition algorithm to decompose each historical energy consumption data, the seasonal periods in the decomposition parameters of each historical energy consumption data are the same. Exemplarily, when the historical energy consumption data in this embodiment is in units of months, the seasonal period can be set to 12.

[0083] For the setting of the trend smoothing window in the decomposition parameters, since there are differences in the data fluctuation situations of different historical energy consumption data, the trend smoothing window of each historical energy consumption data should be adjusted separately according to its fluctuation degree. Therefore, the seasonal periods of all historical energy consumption data can be set to the same value; and since the numerical fluctuations of different historical energy consumption data are different, the values of the trend smoothing windows set for different historical energy consumption data are different. Furthermore, determining the decomposition parameters of each historical energy consumption data based on the fluctuation degree is essentially: determining the trend smoothing window of each historical energy consumption data based on the fluctuation degree.

[0084] It can be understood that if the fluctuation degree of a certain historical energy consumption data is large, a smaller trend smoothing window can be selected to make the trend item fit the original data as much as possible, and if the fluctuation degree of a certain historical energy consumption data is small, a larger trend smoothing window can be selected to make the trend item more stable.

[0085] In the specific implementation process, calculate the coefficient of variation and standard deviation of each historical energy consumption data, and perform linear normalization processing on the coefficient of variation and standard deviation of all historical energy consumption data, that is, map each coefficient of variation and each standard deviation to the range of 0 to 1, and add the product of the first preset coefficient and the coefficient of variation and the product of the second preset coefficient and the standard deviation to obtain the fluctuation degree of each historical energy consumption data. It should be noted that the coefficient of variation is the ratio of the standard deviation to the mean of the historical energy consumption data. The higher the coefficient of variation, the greater the numerical fluctuation of the historical energy consumption data. The sum of the first preset coefficient and the second preset coefficient is 1.

[0086] Furthermore, determine the trend smoothing window of each historical energy consumption data based on the fluctuation degree of each historical energy consumption data.

[0087] Specifically, taking the historical energy consumption data of the nth sub-region as an example, the following formula can be used to calculate and determine the trend smoothing window of the historical energy consumption data of the nth sub-region:

[0088] H n = H min + [(H max - H min ) × (1 - l n )];

[0089] In the formula, H n represents the trend smoothing window of the historical energy consumption number of the nth sub-region, H min represents the preset window minimum value, H max represents the preset window maximum value, l n represents the fluctuation degree of the historical energy consumption number of the nth sub-region. Among them, H max is greater than Hmin is represented and in this embodiment, H min is set to 3, and H max is set to 13.

[0090] It should be noted that if the fluctuation degree of the nth sub-region is large, the trend smoothing window calculated by using the above formula is small, and thus the trend term decomposed by using this trend smoothing window can fit the original data as much as possible; on the contrary, if the fluctuation degree of the nth sub-region is small, the trend smoothing window calculated by using the above formula is large, and thus the trend term decomposed by using this trend smoothing window is relatively stable and can reflect the long-term change trend of the data.

[0091] Furthermore, based on the decomposition parameters corresponding to each historical energy consumption data and using the STL decomposition algorithm, each of the historical energy consumption data is decomposed to obtain the trend term, seasonal term, and residual term of each of the historical energy consumption data.

[0092] S2. According to the historical temperature data, remove the periodic part related to the temperature in the seasonal term to obtain the corresponding basic seasonal term;

[0093] Step 2: Extract the basic seasonal term:

[0094] According to the historical temperature data, remove the periodic part related to the temperature in the seasonal term to obtain the corresponding basic seasonal term.

[0095] Because in commercial electricity consumption areas and administrative electricity consumption areas, such as subways, shopping malls, administrative office buildings, etc., it is generally necessary to use temperature control equipment to maintain a constant indoor temperature, and temperature regulation is an important factor in energy consumption in these two types of electricity consumption areas, and their energy demand has a great correlation with the temperature.

[0096] The temperature belongs to a part of the seasonal term, but the seasonal term obtained by the above decomposition can only reflect the periodic changes in historical energy consumption, such as the impact of winter heating and summer air conditioning on energy demand. When there is a sharp change in temperature that does not conform to the historical law in a short time due to extreme weather or climate change, the seasonal term cannot capture this situation of temperature mutation that does not conform to the historical law.

[0097] To address the above problems, the present invention eliminates the periodic components affected by temperature from the original seasonal terms decomposed by STL to obtain the corresponding basic seasonal terms. Subsequently, when conducting energy demand forecasting, by forecasting the basic seasonal terms, the predicted basic seasonal terms unaffected by temperature are obtained. Then, the energy consumption related to temperature regulation at future time points is predicted separately to obtain the corresponding predicted temperature control consumption. Adding the predicted basic seasonal terms and the predicted temperature control consumption can yield a total predicted seasonal term. By this means, the periodic part related to temperature is eliminated from the seasonal terms, enabling the separate prediction of the energy consumption related to temperature regulation in the event of extreme weather or sudden climate changes that cause a sharp change in temperature inconsistent with historical patterns in a short period, capturing the impact of temperature mutations on energy demand forecasting and significantly improving the accuracy of energy demand forecasting.

[0098] Specifically, the original seasonal term S decomposed by the above historical decomposition i,t , which reflects fixed cycle patterns (such as weekend effects, non-temperature-controlled seasonal fluctuations), performs a regression analysis on the seasonal term S i,t and the historical temperature data T t to extract the periodic part S related to temperature control in the seasonal term temp,i,t and eliminate it from the seasonal term S i,t to obtain the corresponding basic seasonal term S base,i,t for describing the periodic energy consumption patterns unrelated to temperature control in the target area (such as holidays, production cycles, fixed-time lighting, etc.).

[0099] Basic seasonal term: Reflects the energy consumption fluctuations of non-temperature-controlled equipment within a fixed time cycle (such as factory shift schedules, business activities, natural light changes);

[0100] Temperature control drive term: Dynamically responds to the impact of temperature changes on the energy consumption of equipment such as air conditioners and heating systems;

[0101] The original seasonal term S i,t : Includes all periodic fluctuations (temperature-control related and non-temperature-control related).

[0102] In a specific embodiment,

[0103] A temperature control energy consumption regression model such as a polynomial regression model can be established to capture the non-linear temperature control relationship:

[0104]

[0105] If there is a lag effect between temperature control energy consumption and temperature (such as the delay in turning on the air conditioner), a lag term T t-1 , T t-2 .

[0106] Calculate the basic seasonal term:

[0107] S base,i,t = S i,t - S temp,i,t ;

[0108] Result: S base,i,t Indicates the remaining periodic fluctuations after removing the influence of temperature control.

[0109] S3. Obtain the temperature forecast data corresponding to future time nodes, and based on the difference between the temperature forecast data and the preset constant temperature within the sub-region, the power of each temperature control device, the efficiency of each temperature control device, and the heat capacity coefficient of the sub-region, obtain the predicted temperature control consumption in each sub-region;

[0110] Preferably, calculate the predicted temperature control consumption in each sub-region according to the following formula:

[0111]

[0112] ΔT = |T future - T set |;

[0113] where, ΔS temp,i is the predicted temperature control consumption in sub-region i, N is the total number of temperature control devices in the sub-region, ΔT is the difference between the temperature forecast data and the preset constant temperature within the sub-region, T future is the temperature forecast data, T set is the preset constant temperature within the sub-region, P device,i is the power of the temperature control device in sub-region i, C thermal,i is the heat capacity coefficient of sub-region i, η i is the efficiency of the temperature control device in sub-region i.

[0114] Step 3. Calculate the thermostat drive term:

[0115] Obtain the temperature forecast data corresponding to future time nodes, and based on the difference between the temperature forecast data and the preset constant temperature within the sub-region, the power of each temperature control device, the efficiency of each temperature control device, and the heat capacity coefficient of the sub-region, calculate the predicted temperature control consumption in each sub-region according to the following formula:

[0116]

[0117] ΔT = |T future - T set |;

[0118] where, ΔS temp,iis the predicted temperature control consumption in sub-region i, N is the total number of temperature control devices in the sub-region, ΔT is the difference between the temperature forecast data and the preset constant temperature in the sub-region, T future is the temperature forecast data, T set is the preset constant temperature in the sub-region, P device,i is the power of the temperature control device in sub-region i (such as air conditioner COP), C thermal,i is the heat capacity coefficient of sub-region i (related to building structure and area), η i is the efficiency of the temperature control device in sub-region i.

[0119] S4. Predict the trend term for the future time node according to the said trend term to obtain the corresponding predicted trend term; predict the basic season term for the future time node according to the said basic season term to obtain the corresponding predicted basic season term, and obtain the corresponding predicted season term according to the said predicted basic season term and the predicted temperature control consumption; predict the residual term for the future time node according to the said residual term to obtain the corresponding predicted residual term;

[0120] Step Four: Component Prediction (Fusing Temperature Control Consumption into Seasonal Term):

[0121] 1. Trend Term Prediction: Independent of the air temperature, use a time series model (ARIMA, Prophet) to predict the trend term for the future time node according to the said trend term to obtain the corresponding predicted trend term In a specific embodiment, when using the SARIMA model to predict the trend term of historical energy consumption data, the input of the model is the trend term of the historical energy consumption data, that is, the set of trend terms of all data points in the historical energy consumption data, and the output of the model is the predicted trend term of the historical energy consumption data.

[0122] 2. Seasonal Term Prediction (Fusing Predicted Temperature Control Consumption):

[0123] Predict the basic season term for the future time node according to the said basic season term to obtain the corresponding predicted basic season term S base,i 。In a specific embodiment, use the SARIMA model to predict the basic season term of historical energy consumption data. The input of the model is the basic season term of the historical energy consumption data, that is, the set of basic season terms of all data points in the historical energy consumption data, and the output of the model is the predicted basic season term of the historical energy consumption data.

[0124] Synthesize the predicted season term:

[0125]

[0126] S base,i: Forecast the basic seasonal term (historical mean or periodic extrapolation).

[0127] ΔS temp,i : Forecast the temperature control consumption (dynamically respond to temperature changes).

[0128] 3. Residual term prediction:

[0129] Predict the residual term at future time nodes based on the residual term to obtain the corresponding predicted residual term In a specific embodiment, when using the exponential smoothing algorithm to predict the residual term of historical energy consumption data, the input of the algorithm is the residual term of the historical energy consumption data, that is, the set of residual terms of all data points in the historical energy consumption data, and the output of the algorithm is the predicted residual term of the historical energy consumption data.

[0130] It can be understood that by independently predicting the trend term, seasonal term and residual term, the short-term fluctuations caused by emergencies can be accurately identified and adjusted, thereby improving the prediction accuracy and avoiding prediction deviations caused by ignoring emergencies.

[0131] S5. Cluster each sub-region according to the historical energy consumption data, divide all sub-regions into several categories, and then determine the mutation degree of each data point in the residual term corresponding to each sub-region according to the category corresponding to each sub-region and the value of each data point in the residual term corresponding to each sub-region;

[0132] Preferably, the determining the mutation degree of each data point in the residual term corresponding to each sub-region according to the category corresponding to each sub-region and the value of each data point in the residual term corresponding to each sub-region includes: for each sub-region, according to the category corresponding to the sub-region and the value of each data point in the residual term corresponding to the sub-region, determine the difference in the residual term between the current sub-region and other sub-regions of the same category at the same time node, and the difference in the residual term between the current sub-region and other sub-regions of different categories; determine the mutation degree of each data point in the residual term corresponding to the current sub-region according to the difference in the residual term between the current sub-region and other sub-regions of the same category at the same time node, and the difference in the residual term between the current sub-region and other sub-regions of different categories.

[0133] S6. Determine the correction factor of each data point in the residual term corresponding to each sub-region according to the mutation degree, and correct the corresponding predicted residual term according to the correction factor to obtain the corrected adjusted residual term, and then use the sum of the predicted trend term, predicted seasonal term and adjusted residual term as the energy demand prediction data for the corresponding sub-region.

[0134] Preferably, determine the mutation degree of each data point in the residual term corresponding to each sub-region according to the following formula:

[0135]

[0136] Among them, τ ni is the mutation degree of the i-th data point in the residual term of the historical energy consumption data of the n-th sub-region, and μ ni is the value of the i-th data point in the residual term of the historical energy consumption data of the n-th sub-region, and μ ki is the value of the i-th data point in the residual term of the historical energy consumption data of the k-th sub-region other than the n-th sub-region. M is the number of sub-regions, and α ki is the category coefficient of the i-th data point in the residual term of the historical energy consumption data of the k-th sub-region other than the n-th sub-region;

[0137] Determine the correction factor of each data point in the residual term according to the following formula:

[0138]

[0139] Among them, is the correction factor of the i-th data point in the residual term of the historical energy consumption data of the n-th sub-region, and t ni is the time node corresponding to the i-th data point in the residual term of the historical energy consumption data of the n-th sub-region, c is the time node of the predicted residual term, and τ ni is the mutation degree of the i-th data point in the residual term of the historical energy consumption data of the n-th sub-region.

[0140] Preferably, correct the predicted residual term according to the following formula to obtain the corrected adjusted residual term:

[0141]

[0142] Among them, ζ n is the adjusted residual term of the n-th sub-region, is the predicted residual term of the n-th sub-region, is the correction factor of the i-th data point in the residual term of the historical energy consumption data of the n-th sub-region, and N i is the number of data points in the residual term of the historical energy consumption data of the n-th sub-region, and μ ni is the value of the i-th data point in the residual term of the historical energy consumption data of the n-th sub-region.

[0143] Step Five: Correct the predicted residual term:

[0144] For any historical energy consumption data, calculate the mutation degree of each data point in the residual term and correct the predicted residual term of the historical energy consumption data based on the mutation degree to obtain the adjusted residual term;

[0145] Among them, the mutation degree represents the degree to which each data point is affected by sudden factors or abnormal events. Using the mutation degree to correct the prediction residual term can improve the prediction accuracy.

[0146] In one embodiment, calculating the mutation degree of each data point in the residual term may specifically include:

[0147] (1) Based on the historical energy consumption data of each sub-region and using a clustering algorithm, all sub-regions are divided into at least one category;

[0148] (2) Based on the category of each sub-region and the value of each data point in the residual term, determine the mutation degree of each data point in the residual term.

[0149] It should be noted that when extreme weather or emergencies such as power supply interruptions occur, the energy consumption data of each small region in the target region will be affected; when specific industrial production fluctuations and production stoppages occur, each sub-region belonging to the industrial area in the target region will be affected, while other regions such as residential areas will be less affected; when large-scale events or traffic changes occur, each sub-region belonging to the residential area in the target region will be affected, while other regions will be less affected.

[0150] It can be understood that if the absolute value of a certain data point in the residual term of the historical energy consumption data of a certain sub-region is large, that is, the degree of deviation of the residual from 0 is high, it cannot directly indicate that this data point is caused by the influence of emergencies. In other words, if the absolute values of the residual values of other sub-regions at the time point corresponding to this data point are also large, it can be explained that this data point may be affected by extreme weather or emergencies; if the absolute values of the residual values of the sub-regions belonging to the same category as this data point are small at the time point corresponding to this data point, this data point may be only a noise point at this time.

[0151] Based on this, in this embodiment, first, based on the similarity of the historical energy consumption data of each sub-region, all sub-regions are divided into at least one category by using a clustering algorithm, and the historical energy consumption situations of the sub-regions in each category are similar. Then, according to the differences in the residual values between each sub-region and other sub-regions belonging to the same category and the differences in the residual values between each sub-region and other sub-regions belonging to different categories at the same time node, determine the mutation degree of each data point in the residual term.

[0152] In the specific implementation process, based on the historical energy consumption data of each sub-region and using a clustering algorithm, all sub-regions are divided into at least one category. Among them, the clustering algorithm can be the K-means clustering algorithm or the hierarchical clustering algorithm. If the K-means clustering algorithm is used, it is necessary to preset that the value of K is greater than or equal to 3.

[0153] Further, the mutation degree of each data point in the residual term is determined based on the category of each sub-region and the value of each data point in the residual term.

[0154] Specifically, taking the i-th data point in the residual term of the historical energy consumption data of the n-th sub-region as an example, the mutation degree of the i-th data point in the residual term can be determined using the following formula:

[0155]

[0156] where τ ni is the mutation degree of the i-th data point in the residual term of the historical energy consumption data of the n-th sub-region, μ ni is the value of the i-th data point in the residual term of the historical energy consumption data of the n-th sub-region, μ ki is the value of the i-th data point in the residual term of the historical energy consumption data of the k-th sub-region other than the n-th sub-region, M is the number of sub-regions, and α ki is the category coefficient of the i-th data point in the residual term of the historical energy consumption data of the k-th sub-region other than the n-th sub-region.

[0157] Among them, if the k-th sub-region other than the n-th sub-region is of the same category as the n-th sub-region, then α ki is 1, and if the k-th sub-region other than the n-th sub-region is of a different category from the n-th sub-region, then α ki is 0.

[0158] In one embodiment, correcting the prediction residual term of the energy consumption data based on the mutation degree to obtain an adjusted residual term may specifically include:

[0159] (1) Determining a correction factor for each data point in the residual term based on the mutation degree;

[0160] (2) Correcting the prediction residual term of the historical energy consumption data based on the correction factor of each data point to obtain an adjusted residual term.

[0161] Among them, in this embodiment, each data point in the residual term is used to correct the prediction residual term, and the correction factor is the magnitude of the correction degree of each data point to the prediction residual term.

[0162] It should be noted that if the mutation degree of a certain data point in the residual term is large and this data point is close to the prediction residual term, it indicates that the mutation factor affecting this data point may still continuously affect the prediction residual term. At this time, the prediction residual term needs to be corrected based on the value of this data point; while if the mutation degree of a certain data point in the residual term is large but this data point is far from the prediction residual term, it indicates that the mutation factor affecting this data point may have subsided and no longer affects the prediction residual term.

[0163] Based on this, in this embodiment, the correction factor of each data point in the residual term is determined based on the mutation degree of each data point and the distance between each data point and the predicted residual term.

[0164] Specifically, taking the i-th data point in the residual term of the historical energy consumption data of the n-th sub-region as an example, the correction factor of the i-th data point in the residual term of the historical energy consumption data of the n-th sub-region can be determined using the following formula:

[0165]

[0166] Where, is the correction factor of the i-th data point in the residual term of the historical energy consumption data of the n-th sub-region, t ni is the time node corresponding to the i-th data point in the residual term of the historical energy consumption data of the n-th sub-region, c is the time node of the predicted residual term, τ ni is the mutation degree of the i-th data point in the residual term of the historical energy consumption data of the n-th sub-region.

[0167] Furthermore, the predicted residual term of the energy consumption data is corrected based on the correction factor of each data point to obtain an adjusted residual term.

[0168] Specifically, taking the historical energy consumption data of the n-th sub-region as an example, the following formula can be used to correct the predicted residual term of the energy consumption data of the n-th sub-region to obtain an adjusted residual term:

[0169]

[0170] Where, ζ n is the adjusted residual term of the n-th sub-region, is the predicted residual term of the n-th sub-region, is the correction factor of the i-th data point in the residual term of the historical energy consumption data of the n-th sub-region, N i is the number of data points in the residual term of the historical energy consumption data of the n-th sub-region, μ ni is the value of the i-th data point in the residual term of the historical energy consumption data of the n-th sub-region.

[0171] Taking the ratio of the mutation degree to the difference in time nodes as the correction factor can make the data points that are closer to the predicted residual term and have a larger mutation degree have a higher degree of correction to the predicted residual term, while for the data points that are farther from the predicted residual term and have a smaller mutation degree, the degree of correction to the predicted residual term is lower. It can be regarded as normalizing the correction factor. If the correction factor corresponding to the ith data point in the residual term of the energy consumption data of the nth sub-region is large, it means that the data point has a greater impact on the predicted data point, that is, the degree to which the predicted residual term needs to be corrected according to the data point is also large. Therefore, in this example, the correction factor of each data point is multiplied by the value of the data point. The correction factor can be regarded as the correction weight of the data point, and then the multiplication result is added to the predicted residual term, so that the summed result, that is, the adjusted residual term, is closer to the actual situation, with higher accuracy and reliability.

[0172] Step 6: Determine energy demand forecast data for each sub-region based on the forecast trend items, forecast season items and adjustment residual items, and complete energy demand forecast for the target region based on the energy demand forecast data.

[0173] In the specific implementation process, the forecast trend item, the forecast season item and the adjustment residual item are added together to obtain the energy demand forecast data of the corresponding sub-region. Furthermore, the energy demand forecast of the target region can be completed based on the energy demand forecast data.

[0174] Embodiment 2

[0175] Please refer to Figure 2 , is a schematic diagram of the structure of an energy demand forecasting device provided by an embodiment of the present invention, the device comprising: a historical energy consumption data decomposition module, a basic seasonal item processing module, a temperature control consumption forecasting module, an initial forecasting module, a mutation degree determination module and an energy demand forecasting module;

[0176] The historical energy consumption data decomposition module is used to obtain the historical energy consumption data and historical temperature data of each sub-region in the target area, and perform STL decomposition on the historical energy consumption data to obtain the trend term, seasonal term and residual term corresponding to each sub-region;

[0177] The basic seasonal term processing module is used to remove the periodic part related to the temperature from the seasonal term according to the historical temperature data to obtain the corresponding basic seasonal term;

[0178] The temperature control consumption prediction module is used to obtain the temperature forecast data corresponding to the future time node, and obtain the predicted temperature control consumption in each sub-area according to the difference between the temperature forecast data and the preset constant temperature in the sub-area, the power of each temperature control device, the efficiency of each temperature control device and the heat capacity coefficient of the sub-area;

[0179] The initial prediction module is used to predict the trend term at a future time node according to the trend term to obtain the corresponding predicted trend term; predict the basic seasonal term at a future time node according to the basic seasonal term to obtain the corresponding predicted basic seasonal term, and obtain the corresponding predicted seasonal term according to the predicted basic seasonal term and the predicted temperature control consumption; predict the residual term at a future time node according to the residual term to obtain the corresponding predicted residual term.

[0180] The mutation degree determination module is used to cluster each sub-region according to the historical energy consumption data, divide all sub-regions into several categories, and then determine the mutation degree of each data point in the residual term corresponding to each sub-region according to the category corresponding to each sub-region and the numerical values of each data point in the residual term corresponding to each sub-region.

[0181] The energy demand prediction module is used to determine the correction factor of each data point in the residual term corresponding to each sub-region according to the mutation degree, correct the corresponding predicted residual term according to the correction factor to obtain the corrected adjusted residual term, and then use the sum of the predicted trend term, the predicted seasonal term and the adjusted residual term as the energy demand prediction data of the corresponding sub-region.

[0182] It should be noted that the device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed to multiple network units. Some or all of the modules can be selected according to actual needs to achieve the purpose of the solution of this embodiment. In addition, in the attached drawings of the device embodiments provided by the present invention, the connection relationship between modules indicates that they have a communication connection, which can be specifically implemented as one or more communication buses or signal lines. Those of ordinary skill in the art can understand and implement without creative efforts.

[0183] Those skilled in the art can clearly understand that for the convenience and simplicity, the specific working process of the device described above can refer to the corresponding process in the foregoing method embodiment, and will not be elaborated here.

[0184] Embodiment III

[0185] Correspondingly, an embodiment of the present invention provides an electronic device, which includes a processor, a memory, and a computer program stored in the memory and configured to be executed by the processor. When the processor executes the computer program, it implements the energy demand prediction method described in the foregoing embodiment of the present invention.

[0186] The electronic device may be a computing device such as a desktop computer, a notebook, a palm computer, and a cloud server. The device may include, but is not limited to, a processor and a memory.

[0187] The so-called processor may be a central processing unit (CPU), or may also be other general-purpose processors, digital signal processors (DSPs), application specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor may be a microprocessor or the processor may also be any conventional processor, etc. The processor is the control center of the device and connects various parts of the entire device through various interfaces and lines.

[0188] Embodiment 4

[0189] Correspondingly, an embodiment of the present invention provides a storage medium, which includes a stored computer program. When the computer program runs, it controls the device where the storage medium is located to execute the energy demand prediction method described in the above-mentioned embodiment of the present invention.

[0190] The memory can be used to store the computer program. The processor realizes various functions of the device by running or executing the computer program stored in the memory and calling the data stored in the memory. The memory mainly includes a program storage area and a data storage area. Among them, the program storage area can store an operating system, application programs required for at least one function, etc.; the data storage area can store data created according to the use of the mobile phone, etc. In addition, the memory may include high-speed random access memory, and may also include non-volatile memory, such as a hard disk, a memory, a plug-in hard disk, a smart media card (SMC), a secure digital (SD) card, a flash card, at least one magnetic disk storage device, a flash memory device, or other volatile solid-state storage devices.

[0191] The storage medium is a computer-readable storage medium, and the computer program is stored in the computer-readable storage medium. When the computer program is executed by a processor, the steps of the above-mentioned various method embodiments can be implemented. Among them, the computer program includes computer program code, and the computer program code can be in the form of source code, object code, executable file or some intermediate form, etc. The computer-readable medium may include: any entity or device capable of carrying the computer program code, recording medium, USB flash drive, mobile hard disk, magnetic disk, optical disk, computer memory, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), electrical carrier signal, telecommunication signal, and software distribution medium, etc. It should be noted that the content included in the computer-readable medium can be appropriately increased or decreased according to the requirements of legislation and patent practice within the jurisdiction. For example, in some jurisdictions, according to legislation and patent practice, the computer-readable medium does not include electrical carrier signals and telecommunication signals.

[0192] The above is the preferred embodiment of the present invention. It should be pointed out that for those of ordinary skill in the art of the present technology, without departing from the principle of the present invention, several improvements and modifications can be made, and these improvements and modifications are also regarded as the protection scope of the present invention.

Claims

1. A method for predicting energy demand, characterized in that: include: Obtain historical energy consumption data and historical temperature data of each sub-region in the target region, and perform STL decomposition on the historical energy consumption data to obtain trend items, seasonal items, and residual items corresponding to each sub-region; According to the historical temperature data, the periodic part related to the temperature is eliminated from the seasonal item to obtain the corresponding basic seasonal item; Obtain temperature forecast data corresponding to future time nodes, and obtain predicted temperature control consumption in each sub-area based on the difference between the temperature forecast data and the preset constant temperature in the sub-area, the power of each temperature control device, the efficiency of each temperature control device, and the heat capacity coefficient of the sub-area; Predicting the trend item of the future time node according to the trend item to obtain the corresponding predicted trend item; predicting the basic seasonal item of the future time node according to the basic seasonal item to obtain the corresponding predicted basic seasonal item, and obtaining the corresponding predicted seasonal item according to the predicted basic seasonal item and the predicted temperature control consumption; predicting the residual item of the future time node according to the residual item to obtain the corresponding predicted residual item; Clustering each sub-region according to the historical energy consumption data, dividing all sub-regions into several categories, and then determining the mutation degree of each data point in the residual item corresponding to each sub-region according to the category corresponding to each sub-region and the value of each data point in the residual item corresponding to each sub-region; The correction factor of each data point in the residual item corresponding to each sub-region is determined according to the mutation degree, and the corresponding prediction residual item is corrected according to the correction factor to obtain the corrected adjusted residual item, and then the sum of the prediction trend item, the prediction season item and the adjusted residual item is used as the energy demand forecast data of the corresponding sub-region.

2. The energy demand forecasting method according to claim 1, characterized in that: The predicted temperature control consumption in each sub-area is calculated according to the following formula: Among them, ΔS temp,i is the predicted temperature control consumption in sub-area i, N is the total number of temperature control devices in the sub-area, ΔT is the difference between the temperature forecast data and the preset constant temperature in the sub-area, T future is the temperature forecast data, T set is the preset constant temperature in the sub-area, P device,i is the power of the temperature control device in sub-area i, C thermal,i is the heat capacity coefficient of sub-region i, η i is the efficiency of the temperature control device in sub-area i.

3. The energy demand forecasting method according to claim 1, characterized in that: Decomposing the historical energy consumption data to obtain trend items, seasonal items and residual items corresponding to each sub-region includes: Preprocessing the historical energy consumption data; wherein the preprocessing includes: missing value filling, dimension unification and outlier processing; Calculating the coefficient of variation and standard deviation of the preprocessed historical energy consumption data, and normalizing the coefficient of variation and standard deviation; The product of the normalized coefficient of variation and the first preset coefficient is used as the first product, the product of the normalized standard deviation and the second preset coefficient is used as the second product, and the sum of the first product and the second product is used as the fluctuation degree of the historical energy consumption data; wherein the sum of the first preset coefficient and the second preset coefficient is 1; Determine the STL decomposition parameters corresponding to the historical energy consumption data according to the degree of fluctuation; wherein the STL decomposition parameters include: seasonal cycle and trend smoothing window; According to the decomposition parameters and the preset STL decomposition algorithm, the historical energy consumption data is decomposed to obtain trend items, seasonal items and residual items corresponding to each sub-region.

4. The energy demand forecasting method according to claim 1, characterized in that: Determining the mutation degree of each data point in the residual term corresponding to each sub-region according to the category corresponding to each sub-region and the value of each data point in the residual term corresponding to each sub-region includes: For each sub-region, according to the category corresponding to the sub-region and the value of each data point in the residual item corresponding to the sub-region, determine the difference in residual items between the current sub-region and other sub-regions of the same category, and the difference in residual items between the current sub-region and other sub-regions of different categories at the same time node; According to the difference in residual terms between the current sub-region and other sub-regions of the same category at the same time node, and the difference in residual terms between the current sub-region and other sub-regions of different categories, the mutation degree of each data point in the residual term corresponding to the current sub-region is determined.

5. The energy demand forecasting method according to claim 2, characterized in that: The trend smoothing window corresponding to the historical energy consumption data is determined according to the following formula: H n =H min +[(H max -H min )×(1-l n )]; (4) Among them, H n is the trend smoothing window of the historical energy consumption data of the nth sub-region, H min is the preset window minimum value, H max is the preset window maximum value, H max Greater than H min , l n is the fluctuation degree of historical energy consumption data of the nth sub-region.

6. The energy demand forecasting method according to claim 4, characterized in that: The mutation degree of each data point in the residual term corresponding to each sub-region is determined according to the following formula: Among them, τ ni is the mutation degree of the ith data point in the residual term of the historical energy consumption data of the nth sub-region, μ ni is the value of the ith data point in the residual term of the historical energy consumption data of the nth sub-region, μ ki is the value of the i-th data point in the residual term of the historical energy consumption data of the k-th sub-region except the n-th sub-region, M is the number of sub-regions, α ki is the category coefficient of the i-th data point in the residual term of the historical energy consumption data of the k-th sub-region except the n-th sub-region; Determine the correction factor for each data point in the residual term according to the following formula: in, is the correction factor of the ith data point in the residual term of the historical energy consumption data of the nth sub-region, t ni is the time node corresponding to the i-th data point in the residual term of the historical energy consumption data of the n-th sub-region, c is the time node of the predicted residual term, τ ni is the mutation degree of the ith data point in the residual term of the historical energy consumption data of the nth sub-region.

7. The energy demand forecasting method according to claim 6, characterized in that: The prediction residual term is corrected according to the following formula to obtain a corrected adjusted residual term: Among them, n is the adjusted residual term of the nth sub-region, is the prediction residual term of the nth sub-region, is the correction factor of the ith data point in the residual term of the historical energy consumption data of the nth sub-region, N i is the number of data points in the residual term of the historical energy consumption data of the nth sub-region, μ ni is the value of the ith data point in the residual term of the historical energy consumption data of the nth sub-region.

8. An energy demand forecasting device, characterized in that: include: Historical energy consumption data decomposition module, basic seasonal item processing module, temperature control consumption prediction module, initial prediction module, mutation degree determination module and energy demand prediction module; The historical energy consumption data decomposition module is used to obtain the historical energy consumption data and historical temperature data of each sub-region in the target area, and perform STL decomposition on the historical energy consumption data to obtain the trend term, seasonal term and residual term corresponding to each sub-region; The basic seasonal term processing module is used to remove the periodic part related to the temperature from the seasonal term according to the historical temperature data to obtain the corresponding basic seasonal term; The temperature control consumption prediction module is used to obtain the temperature forecast data corresponding to the future time node, and obtain the predicted temperature control consumption in each sub-area according to the difference between the temperature forecast data and the preset constant temperature in the sub-area, the power of each temperature control device, the efficiency of each temperature control device and the heat capacity coefficient of the sub-area; The initial prediction module is used to predict the trend item of the future time node according to the trend item to obtain the corresponding predicted trend item; predict the basic seasonal item of the future time node according to the basic seasonal item to obtain the corresponding predicted basic seasonal item, and obtain the corresponding predicted seasonal item according to the predicted basic seasonal item and the predicted temperature control consumption; predict the residual item of the future time node according to the residual item to obtain the corresponding predicted residual item; The mutation degree determination module is used to cluster each sub-region according to the historical energy consumption data, divide all sub-regions into several categories, and then determine the mutation degree of each data point in the residual item corresponding to each sub-region according to the category corresponding to each sub-region and the value of each data point in the residual item corresponding to each sub-region; The energy demand forecasting module is used to determine the correction factor of each data point in the residual item corresponding to each sub-region according to the mutation degree, and to correct the corresponding prediction residual item according to the correction factor to obtain the corrected adjusted residual item, and then use the sum of the prediction trend item, the prediction season item and the adjusted residual item as the energy demand forecast data for the corresponding sub-region.

9. An electronic device, characterized in that: The method comprises a processor, a memory, and a computer program stored in the memory and configured to be executed by the processor, wherein the processor implements the energy demand forecasting method according to any one of claims 1 to 7 when executing the computer program.

10. A storage medium, characterized in that: The storage medium includes a stored computer program, wherein when the computer program is executed, the device where the storage medium is located is controlled to execute the energy demand forecasting method according to any one of claims 1 to 7.

Citation Information

Cited By

  • Coal consumption prediction method and device, equipment, storage medium and product

    CN121010049A