Power consumption prediction method and device for integrated energy system, electronic equipment and storage medium
By building a double-layer Transformer structure and reinforcement learning model, combining meteorological and photovoltaic facility information, the accuracy of the power consumption prediction of the integrated energy system in the case of abnormal events and scarcity of data is solved, and sensitive capture and high-precision prediction of the power consumption are achieved.
Patent Information
- Application Number
- CN202510440808.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-09
- Publication Date
- 2025-07-25
AI Technical Summary
The existing power consumption prediction methods have low prediction accuracy in abnormal events or scarce data, making it difficult to accurately predict the power consumption of a comprehensive energy system.
By determining the characteristic data of the integrated energy system equipment, a combined model of the double-layer Transformer structure and reinforcement learning structure is constructed, combining meteorological state and photovoltaic facility information, power consumption prediction is carried out, and the model is optimized through error game analysis and RAG technology to improve prediction accuracy.
It realizes sensitive capture and accurate prediction of electricity consumption in the case of abnormal events and scarcity of data, improves the accuracy of electricity consumption prediction and the transparency of the model, reduces artificial intervention, and improves transaction efficiency.
Smart Images

Figure CN120372352A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of power technologies, and in particular, to a power consumption prediction method, device, electronic device, and storage medium for an integrated energy system. Background Art
[0002] Power consumption prediction is a key technology for the safe and economic operation of a power system, which can help the power grid maintain a balance between power generation and power consumption and optimize the dispatching plan.
[0003] The existing power consumption predictions mainly fall into two categories. One is to predict power consumption by using mathematical statistics. However, this type of method requires a large amount of research before prediction, and is easily affected subjectively during the research and prediction processes, resulting in low accuracy of power consumption prediction. The other is to obtain factors related to power consumption and use neural networks to predict power consumption. Although this type of method can obtain high-accuracy power consumption under stable power consumption patterns, the prediction accuracy will significantly decrease under abnormal events or data scarcity conditions. Summary of the Invention
[0004] The present invention provides a power consumption prediction method, device, electronic device, and storage medium for an integrated energy system to solve the problem of inaccurate power consumption prediction under abnormal events and data scarcity.
[0005] According to one aspect of the present invention, there is provided a power consumption prediction method for an integrated energy system, including:
[0006] Determining first feature data; the first feature data is feature data generated from the power consumption of devices within the power supply range of the integrated energy system during a first time interval and device feature information; the device feature information is used to characterize whether there is a photovoltaic facility in the area where the device is located and the meteorological state of the area where the device is located;
[0007] Constructing a first model according to second feature data; the second feature data is feature data generated from the power consumption of devices and device feature information during a second time interval; the second time interval is before the first time interval; the first model is used to predict the power consumption situation of the integrated energy system; the first model is pre-corrected by first data and second data; the first data is used to characterize the error between the power consumption predicted from feature data exceeding a preset threshold and the actual power consumption; the preset threshold is the change range of the feature data corresponding to the actual power consumption situation; the second data is used to characterize the proportion of the error cause of the error between the actual power consumption and the predicted power consumption data;
[0008] Determine the first electricity consumption data based on the first feature data and the first model; the first electricity consumption data is the electricity consumption situation of the equipment within the third time interval; the third time interval is the time interval after the first time interval.
[0009] According to another aspect of the present invention, there is provided a device for predicting electricity consumption for an integrated energy system, including:
[0010] A first feature data determination module, configured to determine first feature data; the first feature data is feature data generated from the electricity consumption of equipment within the first time interval and equipment feature information within the power supply range of the integrated energy system; the equipment feature information is used to characterize whether there is a photovoltaic facility in the area where the equipment is located and the meteorological state of the area where the equipment is located;
[0011] A first model determination module, configured to construct a first model according to second feature data; the second feature data is feature data generated from the electricity consumption of equipment and equipment feature information within the second time interval; the second time interval is before the first time interval; the first model is used to predict the electricity consumption situation of the integrated energy system; the first model is pre-corrected by first data and second data; the first data is used to characterize the error between the electricity consumption predicted from feature data exceeding a preset threshold and the actual electricity consumption; the preset threshold is the change range of the feature data corresponding to the actual electricity consumption situation; the second data is used to characterize the proportion of the error cause of the error between the actual electricity consumption and the predicted electricity consumption data;
[0012] A first electricity consumption data determination module, configured to determine first electricity consumption data based on the first feature data and the first model; the first electricity consumption data is the electricity consumption situation of the equipment within the third time interval; the third time interval is the time interval after the first time interval.
[0013] According to another aspect of the present invention, there is provided an electronic device, the electronic device includes:
[0014] At least one processor; and
[0015] A memory communicatively connected to the at least one processor; wherein,
[0016] The memory stores a computer program executable by the at least one processor, and the computer program is executed by the at least one processor so that the at least one processor can execute the method for predicting electricity consumption for an integrated energy system according to any embodiment of the present invention.
[0017] According to another aspect of the present invention, there is provided a computer-readable storage medium storing computer instructions for causing a processor to implement the power consumption prediction method for an integrated energy system according to any embodiment of the present invention when executed.
[0018] In the technical solution of the embodiment of the present invention, the first feature data is determined, and multi-source data is fused, which improves the quality of the input data of the prediction model and can also provide an accurate data source for subsequent power consumption prediction; the first model is constructed according to the second feature data, and the use of the first model can capture the change law of power consumption more sensitively; the first power consumption data is determined according to the first feature data and the first model. By predicting the power consumption through the first model, the change trend of the power consumption can be captured sensitively, and the accuracy of the power consumption prediction can also be improved.
[0019] It should be understood that the content described in this part is not intended to identify the key or important features of the embodiments of the present invention, nor is it used to limit the scope of the present invention. Other features of the present invention will become easily understood through the following description. BRIEF DESCRIPTION OF THE DRAWINGS
[0020] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the following will briefly introduce the drawings required for the description of the embodiments. Obviously, the drawings in the following description are only some embodiments of the present invention, and those of ordinary skill in the art can obtain other drawings without creative efforts based on these drawings.
[0021] Figure 1 It is a flowchart of a power consumption prediction method for an integrated energy system provided by an embodiment of the present invention;
[0022] Figure 2 It is a flowchart of another power consumption prediction method for an integrated energy system provided by an embodiment of the present invention;
[0023] Figure 3 It is a structural diagram of a power consumption prediction system for an integrated energy system provided by an embodiment of the present invention;
[0024] Figure 4 It is a structural schematic diagram of a power consumption prediction device for an integrated energy system provided by an embodiment of the present invention;
[0025] Figure 5 It is a structural schematic diagram of an electronic device for implementing the power consumption prediction method for an integrated energy system according to an embodiment of the present invention. DETAILED DESCRIPTION OF THE EMBODIMENTS
[0026] To enable those skilled in the art to better understand the solution of the present invention, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only a part of the embodiments of the present invention, rather than all of the embodiments. All other embodiments obtained by those of ordinary skill in the art based on the embodiments of the present invention without creative efforts shall fall within the scope of protection of the present invention.
[0027] It should be noted that the terms "first", "second", etc. in the description and claims of the present invention and the above-mentioned drawings are used to distinguish similar objects, and do not necessarily need to be used to describe a specific order or sequence. It should be understood that such data used in appropriate cases can be interchanged so that the embodiments of the present invention described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "comprising" and "having" and any variations thereof are intended to cover non-exclusive inclusion. For example, a process, method, system, product or device comprising a series of steps or units does not necessarily have to be limited to those steps or units clearly listed, but may include other steps or units not clearly listed or inherent to these processes, methods, products or devices.
[0028] Figure 1 The figure is a flowchart of a power consumption prediction method for an integrated energy system provided by an embodiment of the present invention. This embodiment is applicable to the situation of predicting the power consumption of an integrated energy system. This method can be executed by a power consumption prediction device for an integrated energy system. The power consumption prediction device for an integrated energy system can be implemented in the form of hardware and / or software, and the power consumption prediction device for an integrated energy system can be configured in any electronic device with network communication functions. As Figure 1 shown, the method includes:
[0029] S110. Determine the first feature data.
[0030] Among them, the first feature data is feature data generated from the power consumption of devices within the power supply range of the integrated energy system during the first time interval and the device feature information.
[0031] Among them, the device feature information is used to characterize whether there is a photovoltaic facility in the area where the device is located and the meteorological state of the area where the device is located.
[0032] Among them, the integrated energy system is an energy system that integrates and operates multiple types of energy such as electricity, heat, and gas. The electric energy generated by the integrated energy system can be used by devices on the user side.
[0033] Among them, the device characteristic information may further include: the field where the device is used, the area where the device is located, whether there is distributed photovoltaics in the area where the device is located, the weekday distribution of the objects using the device, and the terrain of the area where the device is located, etc.
[0034] Furthermore, the meteorological status in the device characteristic information is obtained from the China Meteorological Network and Windy.
[0035] Specifically, obtain the electricity consumption of the devices within the power supply range of the integrated energy system during the first time interval to obtain the second electricity consumption data. Preprocess the second electricity consumption data to obtain the third electricity consumption data. Correlate the obtained third electricity consumption data with the device characteristic information in the time dimension to obtain the first characteristic data.
[0036] Furthermore, various current policies regarding electric energy need to be considered when constructing the first characteristic data.
[0037] Among them, the electricity consumption situation during the first time interval is collected at a frequency of once every half hour, so a total of 48 data points are collected in a day.
[0038] Among them, the preprocessing includes: outlier identification and correction, missing value imputation. The preprocessing can be implemented through large models such as ChatGPT, DeepSeek, Grok, etc.
[0039] Furthermore, when preprocessing the second electricity consumption data, it is necessary to first analyze the second electricity consumption data to analyze its variation law under the device characteristic information, and perform outlier identification and correction, missing value imputation on the second electricity consumption data according to the obtained variation law.
[0040] Furthermore, the first characteristic data can be obtained through a data acquisition unit and a data processing unit. Among them, the data acquisition unit is used to automatically obtain the second electricity consumption data from the power trading platform; obtain meteorological data, market electricity price forecasts, policy information and other data from the storage module. Among them, the data processing unit is used to preprocess the obtained second electricity consumption data and correlate the preprocessed data with the device characteristic information in the time dimension to obtain the first characteristic data.
[0041] S120. Construct a first model according to the second characteristic data.
[0042] Among them, the second characteristic data is the characteristic data generated from the device electricity consumption and device characteristic information during the second time interval; the second time interval is before the first time interval.
[0043] Among them, the first model is used to predict the electricity consumption situation of the integrated energy system; the first model is pre-corrected through the first data and the second data.
[0044] Among them, the first data is used to characterize the error between the predicted power consumption obtained from the feature data exceeding the preset threshold and the actual power consumption; the preset threshold is the change range of the feature data corresponding to the actual power consumption situation.
[0045] Among them, the second data is used to characterize the proportion of the error cause of the error between the actual power consumption and the predicted power consumption data.
[0046] Specifically, obtain the second feature data of the equipment within the integrated energy system in the second time interval, input the second feature data into the second model, the second model predicts the second feature data to obtain the fourth power consumption data, determine the first error according to the fourth power consumption data and the power consumption data in the first feature data, and correct the second model according to the first error to obtain the third model. Correct the third model according to the first data to obtain the first model.
[0047] Among them, the first error can be evaluated by the mean absolute percentage error (MAPE) and the root mean square error (RMSE).
[0048] Among them, the first model can be constructed by a model construction unit. The model construction unit is used for constructing, training, and parameter optimization of the first model.
[0049] Furthermore, the first model can be executed by an isolated sandbox environment. Among them, the sandbox environment can be ChatGPT O1, which is used to securely execute the automatically generated first model algorithm code.
[0050] Among them, the second model can adopt a combination of a double-layer Transformer structure and a reinforcement learning structure. The double-layer Transformer structure is used to learn the change trend of power consumption under different conditions; the reinforcement learning structure is used to optimize the double-layer Transformer structure.
[0051] Furthermore, the first layer of the double-layer Transformer structure is used to learn the short-term change trend of power consumption. Among them, the short term can be: hourly, daily. The second layer of the Transformer is used to combine the equipment feature information to learn the long-term change trend of power consumption. Among them, the long term can be: weekly, monthly. Furthermore, the double-layer Transformer structure is optimized by the reinforcement learning structure.
[0052] Further, the training process of the second model is as follows: The second feature data is divided into a training set and a validation set according to 7:3, that is, the first 70% of the data is the training set, and the last 30% of the data is the validation set. The second model can be pre-trained according to the training set. Specifically, the training set is input into the second model, and based on the electricity consumption data output by the second model and the corresponding electricity consumption data of the validation set, the accuracy of the second model is determined, and the second model is iteratively trained until the accuracy of the second model is greater than or equal to the preset accuracy threshold, and the training of the second model is stopped to obtain the third model.
[0053] In the above steps, the construction of the second model can reduce the consumption of computing resources while improving the prediction speed.
[0054] Further, the third model is corrected according to the first data, including: arbitrarily changing the changeable feature data in the second feature data, changing its value to exceed the preset threshold, inputting the changed data into the third model for prediction to obtain the fifth electricity consumption data, determining the first data according to the fifth electricity consumption data and the actual electricity consumption data of the corresponding prediction period in the second feature data, and correcting the third model according to the first data.
[0055] Among them, the first data is the error between the fifth electricity consumption data and the actual electricity consumption data of the corresponding prediction period in the second feature data.
[0056] Among them, the changeable feature data changes with time, such as meteorological data, the weekday distribution of the objects of the application devices, and the terrain of the area where the device is located.
[0057] Among them, some changeable feature data exists in the form of text data, then the text data is quantified, and after quantification, it is changed to exceed the preset threshold.
[0058] Further, for the preset threshold corresponding to the text data, it is set according to actual experience. Exemplarily, assuming that the terrain of the area where the device is located is a plain, it is represented by 0 after quantification, and it can be changed to 3, and 3 represents being around the sea area.
[0059] Further, after correcting the third model according to the first data, it can also be corrected in the following way: randomly generate electricity consumption to obtain random electricity consumption data; perform feature reverse inference on the random electricity consumption data to obtain feature information, correspond the feature information to the random electricity consumption data to obtain the third feature data; input the third feature data into the third model to obtain the sixth electricity consumption data; compare the sixth electricity consumption data with the actual electricity consumption data corresponding to the feature information to obtain the second error, and correct the third model through the second error.
[0060] Among them, the second error can be evaluated by the mean absolute percentage error (MAPE) and the root mean square error (RMSE).
[0061] Among them, backtracking is to reverse-derive the device characteristic information that causes the electricity consumption based on the electricity consumption data.
[0062] In the above steps, random electricity consumption data is used to increase the diversity of the data. Because even if the integrated energy system operates under the same working conditions, the electricity consumption data generated will be different due to the influence of the external environment.
[0063] S130. Determine the first electricity consumption data according to the first characteristic data and the first model.
[0064] Among them, the first electricity consumption data is the electricity consumption situation of the device within the third time interval. The third time interval is the time interval after the first time interval.
[0065] Specifically, input the first characteristic data into the first model, and perform electricity consumption prediction through the first model to obtain the first electricity consumption data.
[0066] Furthermore, the first electricity consumption data can be expressed by the following formula:
[0067] P t =f(T short (H t ),T long (H t ,M t ));
[0068] Among them, P t is the first electricity consumption data; H t is the second electricity consumption data; M t is the market variable; T short is the short-term prediction result; T long is the long-term prediction result.
[0069] Furthermore, after obtaining the first electricity consumption data, save the first electricity consumption data in the storage module. The storage module is used to save the first electricity consumption data, the first characteristic data, the first model, the historical electricity consumption data, and the characteristic data corresponding to the historical electricity consumption data.
[0070] Furthermore, after obtaining the first electricity consumption data, display the first electricity consumption data on the display and interaction terminal. Among them, the display and interaction terminal can also display information such as error analysis and market quotation suggestions.
[0071] Further, after obtaining the first electricity consumption data, determine the electricity purchase strategy for the area where the device is located according to the first electricity consumption data. The area where the device is located purchases electric energy according to the electricity purchase strategy, and obtain the actual electricity consumption data after purchasing the electric energy. Determine the second data according to the actual electricity consumption data and the first electricity consumption data; decompose the error of the second data to obtain the error sources. Through error game analysis, simulate the proportions of different error sources to obtain the proportions of each error source corresponding to the second data, and correct the first model according to the proportions of the error sources.
[0072] Among them, error game analysis is a method for studying the proportion of error sources reaching the second data in the context of mutual influence and interaction.
[0073] Further, after obtaining the first electricity consumption data, it also includes: performing retrospection on the electricity purchase strategy through RAG (Retrieval Augmented Generation) to obtain the historical electricity purchase strategy corresponding to the scenario similar to the electricity consumption scenario of the first electricity consumption data and the characteristic data corresponding to the historical electricity purchase strategy. Obtain the electricity consumption data from the obtained characteristic data; determine the third error according to the obtained electricity consumption data and the first electricity consumption data; generate an error analysis report according to the third error, and correct the first model according to the error analysis report.
[0074] Among them, RAG is mainly composed of a retriever and a generator. The retriever is used to retrieve the electricity purchase strategy in the historical electricity purchase strategy to obtain the historical electricity purchase strategy corresponding to the scenario similar to the electricity consumption scenario of the first electricity consumption data and the characteristic data corresponding to the historical electricity purchase strategy. The generator is used to perform text integration on the obtained historical electricity purchase strategy and the corresponding characteristic data.
[0075] Further, use the characteristic data generated by RAG as the auxiliary characteristics of the first model.
[0076] In the above steps, the use of error game analysis and RAG can improve the interpretability of the first model, and at the same time can automatically analyze the prediction error, improving the transparency of the model. In addition, the use of error game analysis and RAG also combines historical data to analyze the error sources, optimize the next-round prediction, and improve the market adaptability of the first model.
[0077] Exemplarily, such as Figure 2As shown in the figure, first, data is collected to obtain the second electricity consumption data and device feature information. The obtained second electricity consumption data is preprocessed, and the preprocessed data and device feature information are used to construct the first feature data. It is determined whether market trading is required. If so, the first feature data is input into the first model (composed of a double-layer Transformer structure and reinforcement learning) to obtain the first electricity consumption data. A power purchase strategy is generated based on the first electricity consumption data, and the power purchase strategy is optimized according to the error game analysis method. The power purchase strategy is the trading strategy in the figure. Electric energy is purchased according to the optimized power purchase strategy. The actual electricity consumption data after power purchase is obtained, the second data is determined based on the actual electricity consumption data and the first electricity consumption data, error analysis is performed on the second data, and a trading review of the power purchase strategy is carried out through RAG to obtain a correction plan, and the first model is corrected according to the correction plan.
[0078] Optionally, determining the first feature data includes steps A1 - A4:
[0079] Step A1: Determine the second electricity consumption data.
[0080] Specifically, the electricity consumption data of the device in the second time interval is obtained as the second electricity consumption data.
[0081] Step A2: Perform data analysis on the second electricity consumption data to determine the data change rule information.
[0082] Among them, the data change rule information is used to characterize the data change rule of the electricity consumption under the device feature information.
[0083] Specifically, data analysis is performed on the second electricity consumption data to obtain the change rule information of the second electricity consumption data under the device feature information.
[0084] Furthermore, the data analysis is to analyze the coupling relationship between the second electricity consumption data and the device feature information, determine the influence on the second electricity consumption data when at least one of the feature information changes, so as to determine the change rule of the second electricity consumption data.
[0085] Step A3: Perform data cleaning and data filling on the second electricity consumption data according to the data change rule information to obtain the third electricity consumption data.
[0086] Specifically, the second electricity consumption data is screened and traversed according to the data change rule information, the outliers and missing values are screened out, and the filling values of the outliers and missing values are deduced according to the data change rule information, and the outliers and missing values are replaced according to the deduced values to obtain the third electricity consumption data.
[0087] Step A4: Perform time feature association on the third electricity consumption data and the device feature information to obtain the first feature data.
[0088] Specifically, the obtained third electricity consumption data is corresponded with the device feature information in the time dimension, and the corresponded data is sorted out. The sorted-out data is associated with the coupling relationship to obtain the first feature data.
[0089] Furthermore, data sorting is necessary because when collecting data in different dimensions, due to different collection frequencies, the number of data is not corresponding within the same time interval.
[0090] Optionally, constructing the first model according to the second feature data includes steps B1 - B4:
[0091] Step B1: Determine the second feature data.
[0092] Specifically, obtain the electricity consumption of each device within the second time interval, preprocess the obtained electricity consumption data, and correspond the preprocessed data with the device feature information corresponding to the second time interval in the time dimension to obtain the second feature data.
[0093] Step B2: Input the second feature data into the second model to obtain the fourth electricity consumption data.
[0094] Among them, the second model is a model constructed according to the neural network model with time series characteristics.
[0095] Specifically, input the second feature data into the second model for electricity consumption prediction to obtain the fourth electricity consumption data.
[0096] Step B3: Modify the second model according to the fourth electricity consumption data and the second feature data to obtain the third model.
[0097] Specifically, calculate the first error according to the fourth electricity consumption data and the second feature data, modify the parameters of the second model according to the obtained first error, and perform iterative training on the modified second model until the accuracy rate of the second model is greater than or equal to the preset accuracy rate threshold, then stop the training of the second model to obtain the third model.
[0098] Step B4: Modify the third model according to the first data to obtain the first model.
[0099] Specifically, modify the parameters of the third model according to the first data to obtain the first model.
[0100] Furthermore, the acquisition method of the first data is as follows: randomly select the changeable feature data in the second feature data for modification, change its value to exceed the preset threshold to obtain the modified feature data. Input the modified feature data into the third model for prediction to obtain the fifth electricity consumption data, and determine the first data according to the fifth electricity consumption data and the electricity consumption data in the second feature data.
[0101] Optionally, correct the third model according to the first data to obtain the first model, including steps C1 - C4:
[0102] Step C1: Modify the second feature data according to a preset threshold to obtain modified feature data.
[0103] Specifically, arbitrarily select the modifiable feature data in the second feature data, change its value to exceed the preset threshold, and obtain the modified feature data.
[0104] Among them, the modifiable feature data is such that its data characteristics change with time, such as meteorological data, the working day distribution of the objects of the application device, and the terrain of the area where the device is located.
[0105] Among them, some modifiable feature data exists in the form of text data, then quantify the text data, and after quantification, change it to exceed the preset threshold.
[0106] Furthermore, for the preset threshold corresponding to the text data, it is set according to actual experience.
[0107] Step C2: Input the modified feature data into the third model for prediction to obtain the fifth electricity consumption data.
[0108] Specifically, input the modified feature data into the third model for electricity consumption prediction to obtain the fifth electricity consumption data.
[0109] Step C3: Determine the first data according to the fifth electricity consumption data and the second feature data.
[0110] Specifically, perform error evaluation on the electricity consumption data in the fifth electricity consumption data and the second feature data to obtain the first data.
[0111] Step C4: Correct the third model according to the first data.
[0112] Specifically, correct the parameters of the third model according to the first data.
[0113] Optionally, after determining the first electricity consumption data according to the first feature data and the first model, including steps D1 - D3:
[0114] Step D1: Generate a power purchase strategy according to the first electricity consumption data combined with the electricity price.
[0115] Specifically, determine the electricity purchase quantity at different times in the area where the device is located according to the first electricity consumption data and the electricity price at different times, and generate a power purchase strategy from the electricity purchase quantities at different times.
[0116] Step D2: Determine the revenue situation of the integrated energy system according to the power purchase strategy.
[0117] Specifically, determine the electricity purchase quantities for different time periods according to the electricity purchase strategy, and determine the revenue situation of the integrated energy system based on the obtained electricity purchase quantities, electricity prices, and electricity purchase prices.
[0118] Furthermore, the revenue situation can be expressed by the following formula:
[0119] Revenue = (Electricity price - Electricity purchase price) × Electricity purchase quantity.
[0120] Among them, the electricity price is the price at which the integrated energy system sells electricity; the electricity purchase price is the price at which electricity is purchased in the area where the equipment is located.
[0121] Step D3: Modify the electricity purchase strategy according to the revenue situation.
[0122] Specifically, optimize the electricity purchase strategy according to the revenue situation of each time period, and purchase electricity according to the modified electricity purchase strategy, so as to maximize the benefits of the integrated energy system while ensuring that the electricity purchase price in the area where the equipment is located is the most appropriate.
[0123] Furthermore, the optimization of the electricity purchase strategy can be achieved through the following formula:
[0124] V(st) = E at [r t +γV(S t+1 )];
[0125] Among them, V(st) is the value function of the current market state; at is the current quotation strategy; r t is the trading revenue; γ is the discount factor.
[0126] Exemplarily, the above steps can be implemented through the reinforcement learning Actor-Critic structure, that is, use Actor (policy network) to generate the optimal electricity purchase strategy according to the first electricity consumption data; use Critic (value network) to evaluate the market revenue situation of the current electricity purchase strategy and optimize the electricity purchase strategy according to the revenue situation.
[0127] The above steps directly optimize the electricity purchase strategy according to the first electricity consumption data through the reinforcement learning Actor-Critic structure, construct a closed-loop mode between the first electricity consumption data and the electricity purchase strategy, which can not only improve the profitability of the integrated energy system, but also reduce the dependence of the electricity purchase strategy on the experience of traders, and at the same time improve the market competitiveness.
[0128] Furthermore, after optimizing the electricity purchase strategy according to the revenue situation, it also includes: optimizing the quotation strategy.
[0129] Specifically, the optimization of the quotation strategy can be achieved through the following methods: constructing a Stackelberg competition model, generating the electricity quotation strategy by the leader in the Stackelberg competition model; the follower in the Stackelberg competition model responds to the generated electricity quotation strategy to obtain the electricity purchase strategy. Generating a market revenue function according to the quotation strategy and the electricity purchase strategy; optimizing the quotation strategy according to the market revenue function.
[0130] Among them, the Stackelberg competition model is used to simulate the trading game between the integrated energy system and the region where the equipment is located, so as to generate a quotation strategy that maximizes the interests of the integrated energy system.
[0131] Among them, the leader represents the integrated energy system; the follower represents the region where the equipment is located.
[0132] Among them, the market revenue function can be expressed by the following formula:
[0133]
[0134] Among them, P L is the quotation strategy of the integrated energy system; P F is the electricity purchase strategy of the region where the equipment is located; U i is the market revenue function.
[0135] Furthermore, the above steps are implemented through a quotation strategy module. The quotation strategy module is configured in the electricity consumption prediction system for the integrated energy system.
[0136] Furthermore, as Figure 3 shown, the electricity consumption prediction system for the integrated energy system further includes: a first electricity consumption data prediction module, a power purchase strategy optimization module, and an error game module.
[0137] Among them, the first electricity consumption data module is used to generate first feature data and predict the first electricity consumption data according to the first feature data. The first electricity consumption data module further includes: a data collection unit, a data processing unit, a model construction unit, and an isolated sandbox environment.
[0138] Among them, the power purchase strategy optimization module is used to generate a power purchase strategy according to the first electricity consumption data and optimize the power purchase strategy according to the actual electricity consumption data.
[0139] Among them, the error game module is used to analyze the reasons for the electricity consumption data error according to the first electricity consumption data and the actual electricity consumption data, and correct the first model according to the reasons.
[0140] The above steps realize the closed-loop of the first electricity consumption, the power purchase strategy, and the quotation strategy, enabling the prediction result to directly affect the quotation strategy, reducing human intervention, and improving the efficiency of transactions.
[0141] Optionally, correct according to the third model of the first data to obtain the first model, including steps E1 - E4:
[0142] Step E1, determine the actual power consumption data, and determine the error parameter according to the actual power consumption data and the first power consumption data.
[0143] Specifically, after purchasing electric energy according to the power purchase strategy, record the power consumption of the equipment to obtain the actual power consumption data. Subtract the actual power consumption data from the first power consumption data to obtain the error parameter.
[0144] Step E2, perform error decomposition on the error parameter to obtain the error source.
[0145] Specifically, decompose the error parameter according to the type of characteristic information included in the equipment characteristic information through the error decomposition method to obtain the decomposed error, and determine the error source according to the decomposed error.
[0146] Exemplarily, the decomposed error can be: meteorological error, user behavior deviation, market response error, etc.
[0147] Among them, the error decomposition method is a method for analyzing the difference between the actual power consumption data and the first power consumption data. By decomposing the error parameter into different components, it is possible to deeply understand the reasons and mechanisms for the generation of the error parameter.
[0148] Step E3, perform error game analysis on the error source to obtain the second data.
[0149] Specifically, allocate the responsibility for the prediction failure caused by the error source according to the error game analysis to obtain the second data.
[0150] Among them, the error game analysis is a method for studying the proportion of the error source reaching the second data in the context of mutual influence and interaction.
[0151] Furthermore, performing error game analysis on the error source is: setting the participants, strategies, and payoffs of the game. Among them, the participants represent the decision-making subjects in the game, that is, each error source; the strategies represent the solutions generated by each participant during the game, that is, the proportion plan of each error source; the payoffs represent the results obtained by the participants under different strategy combinations, that is, the error parameter generated by the proportion plan of each error source.
[0152] Furthermore, the error parameter generated by each error source proportion plan is continuously compared with the second data, and the error proportion plan corresponding to the error that is the same as the second data is used as the error source of the second data.
[0153] Furthermore, the error parameter can be obtained by the following formula:
[0154] ΔP t = g(E t , H t , M t );
[0155] Wherein, ΔP t is the error parameter generated by the error source proportion scheme; E t is the error source; H t is the second electricity consumption data; M t is the market variable.
[0156] Step E4, correct the first model according to the second data.
[0157] Specifically, adjust the parameters of the first model or adjust the structure of the first model according to the second data.
[0158] The technical solution of this embodiment determines the first feature data, fuses multi-source data, improves the quality of the input data of the prediction model, and can also provide an accurate data source for subsequent electricity consumption prediction; constructs the first model according to the second feature data, and the use of the first model can capture the change law of electricity consumption more sensitively; determines the first electricity consumption data according to the first feature data and the first model. This method can predict the electricity consumption through the first model, can sensitively capture the change trend of electricity consumption, and can also improve the accuracy of electricity consumption prediction.
[0159] Figure 4 This is a schematic structural diagram of an electricity consumption prediction device for an integrated energy system provided by an embodiment of the present invention. This embodiment is applicable to the situation of predicting the electricity consumption of an integrated energy system. The electricity consumption prediction device for an integrated energy system can be implemented in the form of hardware and / or software, and the electricity consumption prediction device for an integrated energy system can be configured in any electronic device with network communication functions. As Figure 4 shown, the device includes: a first feature data determination module 210, a first model determination module 220, and a first electricity consumption data determination module 230, wherein:
[0160] The first feature data determination module 210: is used to determine the first feature data; the first feature data is the feature data generated from the electricity consumption of the equipment within the first time interval and the equipment feature information within the power supply range of the integrated energy system; the equipment feature information is used to characterize whether there is a photovoltaic facility in the area where the equipment is located and the meteorological state of the area where the equipment is located;
[0161] The first model determination module 220: It is used to construct a first model according to the second feature data; the second feature data is the feature data generated from the electricity consumption of the device and the device feature information within the second time interval; the second time interval is before the first time interval; the first model is used to predict the electricity consumption situation of the integrated energy system; the first model is pre-corrected by the first data and the second data; the first data is used to represent the error between the predicted electricity consumption obtained from the feature data exceeding the preset threshold and the actual electricity consumption; the preset threshold is the change range of the feature data corresponding to the actual electricity consumption situation; the second data is used to represent the proportion of the error cause of the error between the actual electricity consumption and the predicted electricity consumption data.
[0162] The first electricity consumption data determination module 230: It is used to determine the first electricity consumption data according to the first feature data and the first model; the first electricity consumption data is the electricity consumption situation of the device within the third time interval; the third time interval is the time interval after the first time interval.
[0163] Optionally, the first feature data determination module 210 includes:
[0164] The second electricity consumption data determination unit: It is used to determine the second electricity consumption data.
[0165] The data change rule information determination unit: It is used to perform data analysis on the second electricity consumption data to determine the data change rule information; the data change rule information is used to represent the data change rule of the electricity consumption under the device feature information.
[0166] The third electricity consumption data determination unit: It is used to perform data cleaning and data filling on the second electricity consumption data according to the data change rule information to obtain the third electricity consumption data.
[0167] The first feature data determination unit: It is used to perform time feature association on the third electricity consumption data and the device feature information to obtain the first feature data.
[0168] Optionally, the first model determination module includes:
[0169] The second data feature determination unit: It is used to determine the second feature data.
[0170] The fourth electricity consumption data determination unit: It is used to input the second feature data into the second model to obtain the fourth electricity consumption data; the second model is a model constructed according to a neural network model with time series features.
[0171] The third model determination unit: It is used to correct the second model according to the fourth electricity consumption data and the second feature data to obtain the third model.
[0172] The first model determination unit: It is used to correct the third model according to the first data to obtain the first model.
[0173] Optionally, the first model determination unit includes:
[0174] The first data determination subunit: configured to perform data modification on the second feature data according to a preset threshold to obtain modified feature data;
[0175] The fifth power consumption data determination subunit: configured to input the modified feature data into a third model for prediction to obtain fifth power consumption data;
[0176] The first data determination subunit: configured to determine first data according to the fifth power consumption data and the second feature data;
[0177] The correction subunit: configured to correct the third model according to the first data.
[0178] Optionally, the power consumption prediction device for an integrated energy system includes:
[0179] The power purchase strategy determination module: configured to generate a power purchase strategy according to the first power consumption data in combination with the electricity price;
[0180] The revenue situation determination module: configured to determine the revenue situation of the integrated energy system according to the power purchase strategy;
[0181] The correction module: configured to correct the power purchase strategy according to the revenue situation.
[0182] Optionally, the power consumption prediction device for an integrated energy system includes:
[0183] The error parameter determination module: configured to determine the actual power consumption data and determine the error parameter according to the actual power consumption data and the first power consumption data;
[0184] The error source module: configured to perform error decomposition on the error parameter to obtain the error source;
[0185] The second data determination module: configured to perform error game analysis on the error source to obtain second data;
[0186] The correction module: configured to correct the first model according to the second data.
[0187] The power consumption prediction device for an integrated energy system provided in the embodiments of the present invention can execute the power consumption prediction method for an integrated energy system provided in any of the above embodiments of the present invention, and has the corresponding functions and beneficial effects of executing the power consumption prediction method for an integrated energy system. For the detailed process, refer to the relevant operations of the power consumption prediction method for an integrated energy system in the foregoing embodiments.
[0188] Figure 5Schematic diagram of the structure of an electronic device for implementing the electricity consumption prediction method for an integrated energy system according to an embodiment of the present invention. The electronic device is intended to represent various forms of digital computers, such as, laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device can also represent various forms of mobile devices, such as, personal digital processors, cellular phones, smart phones, wearable devices (such as helmets, glasses, watches, etc.) and other similar computing devices. The components shown herein, their connections and relationships, and their functions are only examples and are not intended to limit the implementation of the present invention described and / or claimed herein.
[0189] As Figure 5 shown, the electronic device 10 includes at least one processor 11, and a memory communicatively connected to the at least one processor 11, such as read-only memory (ROM) 12, random access memory (RAM) 13, etc. Among them, the memory stores a computer program executable by the at least one processor. The processor 11 can perform various appropriate actions and processes according to the computer program stored in the read-only memory (ROM) 12 or the computer program loaded from the storage unit 18 into the random access memory (RAM) 13. In the RAM 13, various programs and data required for the operation of the electronic device 10 can also be stored. The processor 11, ROM 12, and RAM 13 are connected to each other through a bus 14. The input / output (I / O) interface 15 is also connected to the bus 14.
[0190] A plurality of components in the electronic device 10 are connected to the I / O interface 15, including: an input unit 16, such as a keyboard, a mouse, etc.; an output unit 17, such as various types of displays, speakers, etc.; a storage unit 18, such as a magnetic disk, an optical disk, etc.; and a communication unit 19, such as a network card, a modem, a wireless communication transceiver, etc. The communication unit 19 allows the electronic device 10 to exchange information / data with other devices through a computer network such as the Internet and / or various telecommunication networks.
[0191] The processor 11 can be various general-purpose and / or special-purpose processing components with processing and computing capabilities. Some examples of the processor 11 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various dedicated artificial intelligence (AI) computing chips, various processors running machine learning model algorithms, a digital signal processor (DSP), and any suitable processor, controller, microcontroller, etc. The processor 11 executes the various methods and processes described above, such as the electricity consumption prediction method for an integrated energy system.
[0192] In some embodiments, the power consumption prediction method for an integrated energy system can be implemented as a computer program tangibly embodied in a computer-readable storage medium, such as storage unit 18. In some embodiments, part or all of the computer program can be loaded and / or installed onto the electronic device 10 via the ROM 12 and / or the communication unit 19. When the computer program is loaded into the RAM 13 and executed by the processor 11, one or more steps of the power consumption prediction method for an integrated energy system described above can be performed. Alternatively, in other embodiments, the processor 11 can be configured to execute the power consumption prediction method for an integrated energy system by any other suitable means (e.g., by means of firmware).
[0193] The various embodiments of the systems and techniques described above in this document can be implemented in digital electronic circuitry, integrated circuit systems, field-programmable gate arrays (FPGA), application-specific integrated circuits (ASIC), application-specific standard products (ASSP), systems-on-chip (SOC), complex programmable logic devices (CPLD), computer hardware, firmware, software, and / or combinations thereof. These various embodiments can include: being implemented in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which can be a special-purpose or general-purpose programmable processor that receives data and instructions from a storage system, at least one input device, and at least one output device, and transmits the data and instructions to the storage system, the at least one input device, and the at least one output device.
[0194] The computer program for implementing the method of the present invention can be written in any combination of one or more programming languages. These computer programs can be provided to a processor of a general-purpose computer, a special-purpose computer, or other programmable data processing device, such that when the computer program is executed by the processor, the functions / operations specified in the flowchart and / or block diagram are implemented. The computer program can be executed entirely on the machine, partially on the machine, as a stand-alone software package partially on the machine and partially on a remote machine, or entirely on a remote machine or server.
[0195] In the context of the present invention, a computer-readable storage medium can be a tangible medium that can contain or store a computer program for use by or in connection with an instruction execution system, apparatus, or device. The computer-readable storage medium can include, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination of the foregoing. Alternatively, the computer-readable storage medium can be a machine-readable signal medium. More specific examples of the machine-readable storage medium would include an electrical connection based on one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or Flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
[0196] For providing interaction with a user, the systems and techniques described herein can be implemented on an electronic device having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user; and a keyboard and a pointing device (e.g., a mouse or a trackball) by which the user can provide input to the electronic device. Other kinds of devices can also be used for providing interaction with the user; for example, the feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including acoustic input, voice input, or tactile input).
[0197] The systems and techniques described herein can be implemented in a computing system including backend components (e.g., as a data server), or a computing system including middleware components (e.g., an application server), or a computing system including frontend components (e.g., a user computer having a graphical user interface or a web browser through which the user can interact with an implementation of the systems and techniques described herein), or a computing system including any combination of such backend components, middleware components, or frontend components. The components of the system can be interconnected to each other by any form or medium of digital data communication (e.g., a communication network). Examples of the communication network include: a local area network (LAN), a wide area network (WAN), a blockchain network, and the Internet.
[0198] A computing system may include a client and a server. The client and the server are generally far from each other and usually interact via a communication network. The relationship between the client and the server is generated by computer programs running on respective computers and having a client-server relationship with each other. The server can be a cloud server, also known as a cloud computing server or a cloud host, which is a host product in the cloud computing service system, and solves the defects of difficult management and weak business scalability existing in traditional physical hosts and VPS services.
[0199] It should be understood that various forms of processes shown above can be used, steps can be reordered, added or deleted. For example, the steps recited in the present invention can be executed in parallel, sequentially or in different orders, as long as the desired results of the technical solution of the present invention can be achieved, and no limitation is made herein.
[0200] The above specific embodiments do not constitute a limitation on the protection scope of the present invention. Those skilled in the art should understand that various modifications, combinations, sub-combinations and substitutions can be made according to design requirements and other factors. Any modifications, equivalent substitutions and improvements made within the spirit and principle of the present invention shall be included within the protection scope of the present invention.
Claims
1. A method for predicting electricity consumption for an integrated energy system, characterized in that Including: Determine the first feature data; the first feature data is the feature data generated from the electricity consumption of devices within the power supply range of the integrated energy system during the first time interval and the device feature information; the device feature information is used to characterize whether there is a photovoltaic facility in the area where the device is located and the meteorological state of the area where the device is located; Construct a first model according to the second feature data; the second feature data is the feature data generated from the electricity consumption of devices and the device feature information during the second time interval; the second time interval is before the first time interval; the first model is used to predict the electricity consumption situation of the integrated energy system; The first model is pre-corrected by the first data and the second data; the first data is used to characterize the error between the predicted electricity consumption obtained from the feature data exceeding the preset threshold and the actual electricity consumption; the preset threshold is the change range of the feature data corresponding to the actual electricity consumption situation; the second data is used to characterize the proportion of the error cause of the error between the actual electricity consumption and the predicted electricity consumption data; Determine the first electricity consumption data according to the first feature data and the first model; the first electricity consumption data is the electricity consumption situation of devices during the third time interval; the third time interval is the time interval after the first time interval.
2. The method according to claim 1, wherein The determining the first feature data includes: Determine the second electricity consumption data; Perform data analysis on the second electricity consumption data to determine the data change rule information; the data change rule information is used to characterize the data change rule of the electricity consumption under the device feature information; Perform data cleaning and data filling on the second electricity consumption data according to the data change rule information to obtain the third electricity consumption data; Perform time feature association on the third electricity consumption data and the device feature information to obtain the first feature data.
3. The method according to claim 1, characterized in that, The constructing the first model according to the second feature data includes: Determine the second feature data; Input the second feature data into the second model to obtain the fourth electricity consumption data; the second model is a model constructed according to a neural network model with time series features; Correct the second model according to the fourth electricity consumption data and the second feature data to obtain the third model; Correct the third model according to the first data to obtain the first model.
4. The method according to claim 3, wherein The correcting the third model according to the first data to obtain the first model includes: Perform data modification on the second feature data according to the preset threshold to obtain the modified feature data; Input the modified feature data into the third model for prediction to obtain the fifth electricity consumption data; Determine the first data according to the fifth electricity consumption data and the second feature data; Correct the third model according to the first data.
5. The method according to claim 1, characterized in that, After determining the first electricity consumption data according to the first feature data and the first model, it further includes: Generate a power purchase strategy according to the first electricity consumption data combined with the electricity price; Determine the revenue situation of the integrated energy system according to the power purchase strategy; Correct the power purchase strategy according to the revenue situation.
6. The method according to claim 1, wherein After generating a power purchase strategy according to the first electricity consumption data combined with the electricity price, it further includes: Determine the actual electricity consumption data, and determine the error parameter according to the actual electricity consumption data and the first electricity consumption data; Decompose the error parameters to obtain the error sources; Conduct error game analysis on the error sources to obtain the second data; Correct the first model according to the second data.
7. An electricity consumption prediction device for an integrated energy system, characterized in that It includes: The first feature data determination module is used to determine the first feature data; the first feature data is the feature data generated from the electricity consumption of the equipment within the first time interval and the equipment feature information within the power supply range of the integrated energy system; the equipment feature information is used to characterize whether there is a photovoltaic facility in the area where the equipment is located and the meteorological state of the area where the equipment is located; The first model determination module is used to construct the first model according to the second feature data; the second feature data is the feature data generated from the electricity consumption of the equipment and the equipment feature information within the second time interval; the second time interval is before the first time interval; the first model is used to predict the electricity consumption situation of the integrated energy system; The first model is pre-corrected by the first data and the second data; the first data is used to characterize the error between the predicted electricity consumption obtained from the feature data exceeding the preset threshold and the actual electricity consumption; the preset threshold is the change range of the feature data corresponding to the actual electricity consumption situation; the second data is used to characterize the proportion of the error cause of the error between the actual electricity consumption and the predicted electricity consumption data; The first electricity consumption data determination module is used to determine the first electricity consumption data according to the first feature data and the first model; the first electricity consumption data is the electricity consumption situation of the equipment within the third time interval; the third time interval is the time interval after the first time interval.
8. The device according to claim 7, characterized in that, The first model determination module includes: The second data feature determination unit is used to determine the second feature data; The fourth electricity consumption data determination unit is used to input the second feature data into the second model to obtain the fourth electricity consumption data; the second model is a model constructed according to a neural network model with time series characteristics; The third model determination unit is used to correct the second model according to the fourth electricity consumption data and the second feature data to obtain the third model; The first model determination unit is used to correct the third model according to the first data to obtain the first model.
9. An electronic device, characterized in that, The electronic device includes: At least one processor; and A memory communicatively connected to the at least one processor; wherein, The memory stores a computer program executable by the at least one processor, and when the computer program is executed by the at least one processor, the at least one processor can execute the electricity consumption prediction method for an integrated energy system according to any one of claims 1-6.
10. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer instructions for causing a processor to execute the electricity consumption prediction method for an integrated energy system according to any one of claims 1-6 when executed.