Optimization method, device, equipment and program product of heat supply pipe network model
By acquiring and utilizing predicted load data and actual load data and adjusting the hyperparameters of the heating pipeline model, the problem of poor monitoring reliability of the heating pipeline network is solved, and the prediction accuracy and monitoring effect are improved.
Patent Information
- Application Number
- CN202411327310.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Priority Date
- 2023-10-24
- Filing Date
- 2024-09-23
- Publication Date
- 2025-01-03
- Estimated Expiration
- 2044-09-23
AI Technical Summary
The existing heating pipeline monitoring model is difficult to adjust according to actual operation, resulting in poor monitoring reliability.
By obtaining predicted load data and actual load data, the model hyperparameter terms are adjusted using optimization algorithms to improve prediction accuracy and monitoring reliability.
The accuracy and reliability of heating pipeline monitoring are improved to ensure that the model can be adjusted and optimized according to actual operation.
Smart Images

Figure CN119249662A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of heating pipe networks, and specifically, to an optimization method, device, equipment and program product for a heating pipe network model. Background Art
[0002] The heating network refers to the network of pipes formed by heating pipes in the heating system. During the heating process, the heating network is responsible for transporting the heat carrier from the heating end to the heat demand end, and then transporting the carrier from the heat demand end back to the heating end, forming a circulating heating flow path. Among them, the heat end is for example a heating room, and the heat demand end is for example a user's home.
[0003] During the heating process, the load of the heating network needs to be monitored to predict the trend of the load. The load conditions include the temperature difference between the carrier temperature output from the heating end and the temperature of the recovered carrier, and the carrier flow rate entering each user's home. By monitoring the load conditions, it is convenient to modify the subsequent operation data of the heating network so that the load conditions can be improved.
[0004] The current method of monitoring the heating network includes using pre-trained models to implement monitoring, but the currently used models are difficult to adjust according to the actual operation of the heating network, resulting in poor monitoring reliability of the heating network. Summary of the invention
[0005] The embodiments of the present application provide a method, device, equipment and program product for optimizing a heating network model, so as to at least solve the technical problem of poor monitoring reliability of the heating network.
[0006] According to a first aspect of an embodiment of the present application, a method for optimizing a heating network model is provided, the method comprising:
[0007] During the use phase of the heating network model, the predicted load data output by the heating network model based on the load condition of the heating network in the target time period is obtained;
[0008] Acquire actual load data of the heating network in the target time period;
[0009] According to the predicted load data, the actual load data and a preset optimization algorithm, at least one hyperparameter item of the heating network model is optimized to obtain an optimized hyperparameter value corresponding to the hyperparameter item.
[0010] By adopting this embodiment, the heating network model can predict the load conditions of the heating network and obtain predicted load data, which is convenient for regulating the heating network according to the predicted load data, improving the load conditions in the target time period, and realizing the monitoring of the heating network. At the same time, during the use stage of the heating network model, the actual load data and optimization algorithm will be used to optimize the hyperparameter items of the heating network model in combination with the predicted load data, so that the heating network model can be adjusted according to the actual operation of the heating network, thereby improving the accuracy of the subsequent predicted load data and improving the reliability of the monitoring of the heating network.
[0011] In combination with the first aspect, in an optional implementation of the embodiment of the present application, optimizing at least one hyperparameter item of the heating network model according to the predicted load data and the actual load data and a preset optimization algorithm to obtain an optimized hyperparameter value corresponding to the hyperparameter item includes:
[0012] Calculating a first performance evaluation value according to the predicted load data and the actual load data, wherein the first performance evaluation value is used to characterize the accuracy of the prediction performed by the heating network model;
[0013] Determining an objective function according to the first performance evaluation value;
[0014] The objective function is processed using the optimization algorithm to obtain the optimized hyperparameter value corresponding to at least one hyperparameter item of the heating network model.
[0015] With this implementation, since the actual load data is the real load data of the heating network, the first performance evaluation value can reflect the degree of difference between the predicted load data and the actual load data, thereby being able to characterize the prediction accuracy of the heating network model. That is, a larger degree of difference characterizes a lower prediction accuracy, and a smaller degree of difference characterizes a higher prediction accuracy. After determining the objective function based on the first performance evaluation value, the objective function is processed using an optimization algorithm, which is conducive to finding the minimum value in the first performance evaluation value, so that the hyperparameter value corresponding to the minimum value in the first performance evaluation value can be used as the optimized hyperparameter value to achieve the optimization of the heating network model. Since the actual load data is used in the optimization process, the optimization of the heating network model can make the prediction more accurate, improve the prediction accuracy, and thus improve the monitoring reliability of the heating network.
[0016] In combination with the first aspect, in an optional implementation manner of the embodiment of the present application, the first performance evaluation value includes at least one of a mean square error value, a mean absolute error value, and a Pearson correlation coefficient value.
[0017] By adopting this implementation method, the mean square error value, the mean absolute error value and the Pearson correlation coefficient value can all reflect the degree of difference between the predicted load data and the actual load data, so that the objective function generated according to the mean square error value, the mean absolute error value and / or the Pearson correlation coefficient value can easily improve the optimization effect, thereby improving the prediction accuracy and further improving the monitoring reliability of the heating network.
[0018] In combination with the first aspect, in an optional implementation of the embodiment of the present application, after optimizing at least one hyperparameter item of the heating network model according to the predicted load data and the actual load data and a preset optimization algorithm to obtain an optimized hyperparameter value corresponding to the hyperparameter item, the method further includes:
[0019] Acquire first historical data of the heating network, wherein the first historical data includes historical operation data and historical load data corresponding to the historical operation data;
[0020] Processing the historical operation data using the optimized heating network model to obtain target predicted load data;
[0021] Calculating a second performance evaluation value based on the target predicted load data and the corresponding historical load data;
[0022] An optimization result is determined according to the first performance evaluation value and the second performance evaluation value, wherein the optimization result is used to characterize the effect of the optimization.
[0023] With this implementation, after optimizing the heating network model, historical operation data will be used for testing to obtain optimization results. Through the optimization results, the effect of the optimization can be known. If there is an effect or the effect is good, it proves that the optimization has played a certain role. Otherwise, the optimization results can be used to remind relevant personnel to manually optimize the heating network model to avoid the difficulty in timely discovery when the optimization algorithm does not produce an optimization effect.
[0024] In combination with the first aspect, in an optional implementation manner of the embodiment of the present application, determining the optimization result according to the first performance evaluation value and the second performance evaluation value includes:
[0025] calculating a difference between the first performance evaluation value and the second performance evaluation value;
[0026] The optimization result is determined according to the size of the difference value, wherein the larger the difference value is, the worse the optimization effect represented by the determined optimization result is.
[0027] By adopting this implementation method, the difference value is easy to calculate, which is conducive to saving computing resources.
[0028] In combination with the first aspect, in an optional implementation of the embodiment of the present application, the optimization algorithm includes a Bayesian optimization algorithm.
[0029] By adopting this implementation method, the Bayesian optimization algorithm helps to reduce the amount of calculation, save computing resources, and thus reduce the optimization cost.
[0030] In combination with the first aspect, in an optional implementation of an embodiment of the present application, the heating network model includes a random forest regression model.
[0031] According to a second aspect of an embodiment of the present application, a method for load prediction of a heating network is provided, the method comprising:
[0032] Obtaining operation data of the heating network;
[0033] Processing the operating data using a preset heating network model to obtain predicted load data, wherein the predicted load data is used to characterize the load condition of the heating network in a target time period;
[0034] At least one hyper-parameter item of the heating network model is optimized according to the predicted load data and the actual load data of the heating network in the target time period.
[0035] By adopting this embodiment, in the process of load forecasting for the heating network, the heating network model will be optimized to facilitate the heating network model to change according to changes in operating data, so that the matching degree between the heating network model and the operating data is higher, thereby predicting more accurate load data and improving the monitoring effect and reliability of the heating network.
[0036] In conjunction with the second aspect, in an optional implementation of the embodiment of the present application, the operating data includes operating data of different types and / or operating data obtained in different acquisition methods;
[0037] Before the operation data is processed by using a preset heating network model to obtain predicted load data, the method further includes:
[0038] The operation data is pre-processed using the same or different data processing methods according to the type and / or acquisition method of the operation data.
[0039] With this implementation, the operating data has different types and / or different acquisition methods, so that the load forecasting process of the heating network needs to use multi-label, that is, multi-dimensional operating data, which will cause the prediction accuracy of the heating network model to decrease when the dimension increases, decreases or changes. However, since this application optimizes the heating network model according to the predicted load data and the actual load data after the heating network model outputs the predicted load data, the optimized heating network model can be applied to the operating data with increased, decreased or changed dimensions, thereby improving the accuracy of the prediction, that is, improving the monitoring reliability of the heating network.
[0040] In addition, preprocessing the operation data helps to improve the difficulty of the heating network model to process the operation data and improve the data processing efficiency. At the same time, when preprocessing, the same or different preprocessing will be used according to the type and / or acquisition method of the operation data, which helps to improve the preprocessing effect.
[0041] In conjunction with the second aspect, in an optional implementation of the embodiment of the present application, the operating data includes temperature and pressure; the preprocessing includes feature engineering;
[0042] The method further comprises:
[0043] The temperature and pressure are processed by the feature engineering to obtain a temperature-pressure ratio, and the temperature-pressure ratio is used as the operating data to obtain the processing of the heating network model.
[0044] By adopting this implementation method, temperature and pressure are replaced by temperature-pressure ratio, which helps to reduce the data processing amount of the heating network model and improve the processing efficiency of the heating network model.
[0045] According to a third aspect of an embodiment of the present application, a method for load prediction of a heating network is provided, the method comprising:
[0046] Obtaining operation data of the heating network;
[0047] Processing the operating data using a preset heating network model to obtain predicted load data, wherein the predicted load data is used to characterize the load condition of the heating network in a target time period;
[0048] According to the predicted load data and the actual load data of the heating network in the target time period, at least one hyper-parameter item of the heating network model is optimized using the above-mentioned heating network model optimization method.
[0049] According to a fourth aspect of an embodiment of the present application, there is provided a device for optimizing a heating network model, the device comprising:
[0050] A first acquisition module is used to acquire, during the use phase of the heating network model, predicted load data output by the heating network model for predicting the load condition of the heating network in a target time period;
[0051] A second acquisition module is used to acquire actual load data of the heating network during the target time period;
[0052] The first optimization module is used to optimize at least one hyperparameter item of the heating network model according to the predicted load data, the actual load data and a preset optimization algorithm to obtain an optimized hyperparameter value corresponding to the hyperparameter item.
[0053] According to a fifth aspect of an embodiment of the present application, there is provided a device for optimizing a heating network model, the device comprising:
[0054] A third acquisition module is used to acquire the operation data of the heating network;
[0055] A prediction module, used to process the operation data using a preset heating network model to obtain predicted load data, wherein the predicted load data is used to characterize the load condition of the heating network in a target time period;
[0056] The second optimization module is used to optimize at least one hyper-parameter item of the heating network model according to the predicted load data and the actual load data of the heating network in the target time period.
[0057] According to a sixth aspect of an embodiment of the present application, there is provided an electronic device, the electronic device comprising a memory and a processor;
[0058] The memory is used to store computer programs;
[0059] The processor is used to execute the computer program to implement the steps of the method described above.
[0060] According to a seventh aspect of an embodiment of the present application, a computer-readable storage medium is provided, wherein the computer-readable storage medium stores a computer program, and when the computer program runs on a computer or a processor, the computer or the processor executes the steps of the method described above.
[0061] According to an eighth aspect of an embodiment of the present application, a computer program product is provided, wherein the computer program product comprises computer instructions. When the computer instructions are executed by a computer or a processor, the steps of the method described above are executed.
[0062] The technical effects obtained in the above-mentioned third to eighth aspects are similar to the technical effects obtained by the corresponding technical means in the first and second aspects, and will not be repeated here. BRIEF DESCRIPTION OF THE DRAWINGS
[0063] Figure 1 It is a flow chart of a method for optimizing a heating network model provided in an embodiment of the present application;
[0064] Figure 2 It is a flow chart of obtaining optimized hyper-parameter values in an optimization method for a heating network model provided in an embodiment of the present application;
[0065] Figure 3 It is a flow chart of a load prediction method for a heating network provided in an embodiment of the present application;
[0066] Figure 4 It is a schematic diagram of hyper-parameter optimization of a load prediction method for a heating network in a specific implementation provided in an embodiment of the present application;
[0067] Figure 5 It is a schematic diagram before optimization of a load prediction method for a heating network in a specific implementation provided in an embodiment of the present application;
[0068] Figure 6 It is a schematic diagram of an optimized load prediction method for a heating network in a specific implementation provided in an embodiment of the present application;
[0069] Figure 7 It is a structural block diagram of an optimization device for a heating network model provided in an embodiment of the present application;
[0070] Figure 8 It is a structural block diagram of a load prediction device for a heating network provided in an embodiment of the present application;
[0071] Fig. 9 It is a structural schematic diagram of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0072] In order to enable those skilled in the art to better understand the solution of the present application, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of the present application.
[0073] It should be understood that the "plurality" mentioned in this article refers to two or more. In the description of the embodiments of the present application, unless otherwise specified, " / " means or, for example, A / B can mean A or B; "and / or" in this article 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 mean: A exists alone, A and B exist at the same time, and B exists alone. In addition, in order to facilitate the clear description of the technical solutions of the embodiments of the present application, in the embodiments of the present application, the words "first", "second" and so on are used to distinguish between the same items or similar items with basically the same functions and effects. Those skilled in the art can understand that the words "first", "second" and so on do not limit the quantity and execution order, and the words "first", "second" and so on do not limit certain different
[0074] In addition, the terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover non-exclusive inclusions. For example, a process, method, system, product, or apparatus that includes a series of steps or elements is not necessarily limited to those steps or elements explicitly listed, but may include other steps or elements not explicitly listed or inherent to such process, method, product, or apparatus.
[0075] First, the terms involved in the embodiments of the present application are introduced.
[0076] Heating network: a complex interconnected pipeline system consisting of numerous series and parallel pipelines and various heat users.
[0077] The load of the heating network: also known as the load of the thermal network system, refers to the amount of heat or energy that the thermal network needs to transport within a certain period of time to meet the user's thermal needs. This load is usually expressed in terms of thermal power (energy consumption per unit time) in kilowatts (kW) or megawatts (MW). The load of the thermal network system is a key parameter for the design and operation of the thermal network, because it directly affects the scale of the network, the selection of equipment, the consumption of energy, and the economy and efficiency of the system. Among them, the load data mentioned in this application may include the flow rate of hot water in the thermal network and the supply and return water temperature difference. The supply and return water temperature difference refers to the difference between the hot water temperature provided by the energy station of the thermal network and the recovered hot water temperature.
[0078] Load supply and demand: supply refers to the heat delivered by the energy station of the thermal network, and demand refers to the heat required by the end of the thermal network (or the user).
[0079] Load supply and demand balance: The heat delivered to the energy station of the thermal network and the heat required by the terminal of the thermal network (or the user) can be roughly regarded as the same in the same order of magnitude. If an imbalance occurs, such as the heat delivered by the energy station of the thermal network is less than the heat required by the terminal of the thermal network (or the user), the temperature in the user's home will not meet the standard, affecting the comfort level, triggering a large number of customer complaints, and causing livelihood problems; if the heat delivered by the energy station of the thermal network is greater than the heat required by the terminal of the thermal network (or the user), the user's home will overheat, and the user will usually open the windows to dissipate heat, resulting in energy waste and increased costs for the source enterprise.
[0080] Load forecasting: refers to predicting the load of the heating network in a certain period of time in the future. For example, predicting the supply and return water temperature difference of the heating network in a certain period of time in the future. According to the predicted supply and return water temperature difference, the hot water temperature in the heating network can be adjusted to save energy while meeting user needs.
[0081] Hydraulic imbalance: refers to the situation where the flow distribution of hot water in the heating network does not conform to the design requirements of each user. The inconsistency between the actual flow and the required flow of each heat user is called hydraulic imbalance of the heat user.
[0082] Although my country's centralized heating industry has experienced a period of rapid development, it still has many shortcomings. High heating energy consumption and poor heating quality are two basic characteristics of my country's centralized heating industry. When the heating system is abnormal, due to the lack of stable monitoring devices, on-site operators cannot find and solve the fault in time, which poses a safety hazard. The core control parameter of the heating system is the water supply temperature. Whether the secondary side water supply temperature can be stabilized near the set value directly affects the heating quality. The traditional control strategy is to use manual experience or simple PID algorithm to adjust the heating station, heat source, pipe network and heating terminal. These adjustment methods cannot adapt well to the complex system of centralized heating with nonlinearity and hysteresis. It is difficult to accurately control the water supply temperature. There is a certain hysteresis. Overheating of the water supply temperature will cause the user's indoor temperature to be greater than the design temperature. Users often consume excessive heat by opening windows for ventilation, which will cause energy waste. Insufficient water supply temperature makes it difficult to ensure that the user's indoor temperature reaches a comfortable temperature, affecting the user experience.
[0083] The main reasons for the low energy efficiency of centralized heating come from two aspects: one is the balance of supply and demand of pipe network load; the other is the hydraulic imbalance of pipe network. For a large heating system, to achieve the balance of supply and demand, it is necessary to have a scientific and relatively accurate prediction of the load demand of the day, and try to balance the supply and demand. Otherwise, if the supply exceeds the demand, energy will be wasted; the hydraulic imbalance of the pipe network has always been a problem in large heating pipe networks. How to solve this problem? From the perspective of pipe network structure, the two-level pipe network structure has solved some problems, but due to the large scale of the pipe network, and the current secondary pipe network is a dynamic flow variable system, which increases the difficulty of hydraulic balance of the primary pipe network. Using appropriate methods to establish a stable and reliable pipe network model and provide high-quality and feasible logic for the intelligent control system is the key to solving this problem.
[0084] Based on this, the present application embodiment provides a method for optimizing a heating network model, referring to Figure 1 The flowchart of the optimization method of the heating network model shown is as follows.
[0085] S100. During the use phase of the heating network model, the predicted load data output by the heating network model based on the load condition of the heating network in a target time period is obtained.
[0086] It should be noted that the heating network model refers to a model that can predict the load of the heating network, which can be a neural network model or other models that can predict the load, and this embodiment does not specifically limit this. Before the heating network model is officially used, it is necessary to train the heating network model. Therefore, the heating network model in the use stage is a model after training.
[0087] Since this embodiment does not limit the specific structure or specific situation of the heating network model, it also does not specifically limit how the heating network model predicts the load situation to obtain predicted load data. This is because different heating network models require different data and different prediction processes. Specifically, the required data can be input according to the needs of the actual heating network model to obtain the predicted load data.
[0088] For ease of understanding, the heating network model is used as a neural network model as an example. During training, the historical temperature data and historical pressure data of the heating network are used for training, so that the heating network model can predict the load situation based on the historical temperature data and historical pressure data. In the use stage, the temperature and pressure of the heating network are used as the input of the heating network model to obtain the predicted load data.
[0089] The predicted load data refers to the predicted load of the heating network within the target time period, and the predicted load data may include the supply and return water temperature difference and / or hot water flow of the heating network within the target time period.
[0090] Since the load situation in the target time period is predicted, the number of predicted load data can be multiple, for example, there is one predicted load data corresponding to each minute in the target time period.
[0091] S102: Obtain actual load data of the heating network in a target time period.
[0092] The actual load data refers to the real load data of the heating network during the target time period. That is to say, after the time in real life reaches the target time period, the load data of the heating network at that time is obtained as the actual load data.
[0093] In one embodiment, the number of actual load data should correspond to the number of predicted load data. That is, if there is predicted load data corresponding to each minute of the target time period, then after the actual time reaches the target time period, one actual load data is obtained every minute, so that the predicted load data and the actual load data can correspond one to one in time.
[0094] S104. Optimize at least one hyperparameter item of the heating network model according to the predicted load data, the actual load data and a preset optimization algorithm to obtain an optimized hyperparameter value corresponding to the hyperparameter item.
[0095] It should be noted that the hyperparameter items of the heating network model need to be able to be modified in real time so that after the optimization algorithm calculates the optimized hyperparameter values, the optimized hyperparameter values can be directly updated to the heating network model without the need to re-build or train the heating network model based on the optimized hyperparameter values.
[0096] By adopting this embodiment, the heating network model can predict the load conditions of the heating network and obtain predicted load data, which is convenient for regulating the heating network according to the predicted load data, improving the load conditions in the target time period, and realizing the monitoring of the heating network. At the same time, during the use stage of the heating network model, the actual load data and optimization algorithm will be used to optimize the hyperparameter items of the heating network model in combination with the predicted load data, so that the heating network model can be adjusted according to the actual operation of the heating network, thereby improving the accuracy of the subsequent predicted load data and improving the reliability of the monitoring of the heating network.
[0097] In a possible embodiment of the present application, Figure 2 As shown, according to the predicted load data and the actual load data and the preset optimization algorithm, at least one hyperparameter item of the heating network model is optimized to obtain the optimized hyperparameter value corresponding to the hyperparameter item, including:
[0098] S200: Calculate a first performance evaluation value according to the predicted load data and the actual load data.
[0099] The first performance evaluation value is used to characterize the accuracy of the prediction of the heating network model. Specifically, the first performance evaluation value can be the value of the mean square error MSE, the value of the mean absolute error MAE and / or the value of the Pearson correlation coefficient PCC, that is, any value that can directly or indirectly characterize the prediction accuracy can be used as the first performance evaluation value.
[0100] S202: Determine an objective function according to the first performance evaluation value.
[0101] It should be noted that, since the load situation of the target time period is predicted, there are at least two predicted load data, so the objective function can be obtained according to at least two predicted load data and the corresponding time. In one embodiment, the objective function is expressed as a curve composed of the first performance evaluation value and time. For example, the target time period is from 1:00 on A year B month C day to 1:10 on A year B month C day, and there is a predicted load data corresponding to every 2 minutes, then there are 6 predicted load data corresponding to 0 minutes, 2 minutes, 4 minutes, 6 minutes, 8 minutes and 10 minutes. When the actual time reaches 1:00 on A year B month C day, the actual load data is obtained, and it is obtained once every 2 minutes, and a total of 6 actual load data are obtained. A first performance evaluation value is calculated using the predicted load data corresponding to 0 minutes and the actual load data, and so on, a total of 6 first performance evaluation values corresponding to 0 minutes, 2 minutes, 4 minutes, 6 minutes, 8 minutes and 10 minutes are obtained, respectively. In this way, a curve with the first performance evaluation value as the ordinate and time as the abscissa can be obtained, and the curve is used as the objective function.
[0102] S204. Process the objective function using an optimization algorithm to obtain an optimized hyperparameter value corresponding to at least one hyperparameter item of the heating network model.
[0103] Specifically, any algorithm that can obtain optimized hyperparameter values according to the objective function can be used as an optimization algorithm. More specifically, the optimization algorithm in this embodiment is a Bayesian optimization algorithm, and in the specific scenario of the embodiment of the present application, its optimization process generally includes the following contents.
[0104] The Bayesian optimization input parameter values are:
[0105] objective_function: the objective function to be optimized, bounds: the boundaries of the parameter search space, n_iter: the number of iterations, init_points: the number of initial sampling points, acq_func: the selected posterior probability function, kappa: a parameter that controls the trade-off between exploration and exploitation.
[0106] S1: In this embodiment, the objective function to be optimized is the performance index of the model on the validation set, that is, the several function formulas mentioned below for evaluating the model effect after the model is established. These objective functions are collectively referred to as f(x). In addition to the objective function f(x) itself, the boundary of the parameter search space also needs to be defined. The boundary here is the boundary of the hyperparameter space X, which limits the value range of the hyperparameter x. This embodiment is for a hot water pipe network system, and the boundary here is usually set according to the requirements of different pipe network systems for the temperature and flow of the primary network or the secondary network.
[0107] S2: As a complex system, the hot water pipe network system will show non-steady-state under actual working conditions, which means that the state of the system changes over time, and this change may be irregular or random. Gaussian process is a powerful non-parametric Bayesian modeling tool that can handle nonlinear relationships and provide uncertainty estimates for predictions. Therefore, in this embodiment, Gaussian process is selected as the probability proxy model.
[0108] The Gaussian process defines a prior distribution p(f) on the function space, where f =
[0109] [f(x1),f(x2),…,f(x n )] T is the value of the target function at n observation points. The Gaussian process assumes that these function values follow a multivariate normal distribution: f~N(m,K), where m is the mean vector and K is the covariance matrix, whose elements K ij = k(x i ,y i ) is calculated by the covariance function, also known as the kernel function. Considering the periodicity of the hot water network, a periodic kernel should be selected here. The general form of the periodic kernel is:
[0110]
[0111] Among them, σ 2 is the signal variance, L is the length scale, and p is the cycle length. The length scale and cycle length here should be selected considering the actual application scenario of the hot water network (the changes in real data). In the periodic kernel, the length scale affects the smoothness of changes within the cycle. A smaller length scale will lead to faster changes within the cycle, while a larger length scale will lead to smoother changes within the cycle. The cycle length should be selected based on the periodic characteristics of the actual data. Due to the stability of the terminal demand, the data at the same time point every day in the hot water network system within a certain period is similar, that is, repeated. At this time, the cycle length should be set to 24.
[0112] S3: Initialize the Gaussian process through a set of initial hyperparameter settings and corresponding objective function values. Suppose the initial data set is where y i =f(x i )+ε i , where ε i is the observation noise, which is assumed to obey a zero-mean Gaussian distribution, i.e., ε i ~N(0,σ 2 ). Enter the number of initial sampling points here, that is, the number of hyperparameter settings and corresponding objective function values selected before starting Bayesian optimization.
[0113] After selecting the initial sampling points, the objective function f(x i ), and get the objective function value y i , and then combine the initial hyperparameter settings and the corresponding objective function values into the initial data set The initial data set D is then used to initialize the mean vector m and covariance matrix K of the Gaussian process. In this embodiment, the mean vector is a linear mean function fitted from real data, and its formula is as follows:
[0114] m(x)=w T x+b
[0115] Where w is the weight vector and b is the bias term. The size of the weight vector represents the importance of the corresponding objective in the multi-objective optimization problem and is calculated from the matrix. In the matrix, first calculate the sum a of each row and the sum a of all the numbers in the matrix i , The bias term b controls the distance that the function deviates from the origin, determines the position of the neural network model in space, and is adjusted by the algorithm itself during the training process.
[0116] S4: Construct the posterior distribution. Using the initial data set D and the Gaussian process, construct the posterior distribution of the target function. For a new point X * , the posterior distribution gives the predicted mean μ(X * ) and the prediction variance σ 2 (X * ), whose formula is as follows:
[0117]
[0118] In the formula, μ(X * ) is the Gaussian process at the new input point X * The predicted mean at k* is the new input point X * and the covariance vector between the training data points, K is the covariance matrix between the training data points, σ 2is the variance of the observation noise, I is the identity matrix, and y is the target value vector of the training data.
[0119]
[0120] In the formula, σ 2 (X * ) is the Gaussian process at the new input point X * The prediction variance at k(X * ,X * ) is the new input point X * The covariance between the kernel function and itself, that is, the kernel function in X * The value at k* is the new input point X * and the covariance vector between the training data points, K is the covariance matrix between the training data points, σ 2 is the variance of the observation noise and I is the identity matrix.
[0121] S5: Use the acquisition function to select the next evaluation point. The expected upper limit acquisition function is defined as:
[0122] EI(x)=E[max(0,f(x)-f(x + )]
[0123] In the formula, f(x + ) is the best objective function value currently observed, then the above formula can be:
[0124]
[0125] In the formula, Φ and φ are the cumulative distribution function and probability density function of the standard normal distribution, respectively. is an exploration parameter, which is the parameter that controls the trade-off between exploration and exploitation. It determines the balance between exploration and exploitation. The bigger it is, the more exploratory it is; The smaller the value, the stronger the utilization. In this embodiment, considering the stability of the hot water pipe network system, the value is set by the algorithm to modify it automatically, and the ratio of 1 out of 10 behaviors is maintained.
[0126] The upper confidence limit acquisition function is defined as:
[0127] UCB(x)=μ(x)+βσ(x)
[0128] Where μ(x) is the predicted mean of the Gaussian process at point x, σ(x) is the predicted standard deviation of the Gaussian process at point x, and β is a hyperparameter that controls the balance between exploration and exploitation. Its exploration ratio is consistent with the exploration parameter in the expected upper bound acquisition function.
[0129] S6: Update the probabilistic proxy model. Evaluate the objective function f(x) at the new point x and add the result to the observed data set. Then, use the new data set to update the posterior distribution of the Gaussian process.
[0130] S7: Iterative optimization. Repeat steps 4 to 6 until the model energy efficiency requirement is met or the iteration limit is reached. In order to ensure that the algorithm operation time does not exceed 10 minutes, the number of iterations is generally not more than 50 times.
[0131] S8: Update and output the optimal hyperparameter combination found during the optimization process.
[0132] With this embodiment, since the actual load data is the real load data of the heating network, the first performance evaluation value can reflect the difference between the predicted load data and the actual load data, thereby being able to characterize the prediction accuracy of the heating network model. That is, a larger difference indicates a lower prediction accuracy, and a smaller difference indicates a higher prediction accuracy. After determining the objective function based on the first performance evaluation value, the objective function is processed using an optimization algorithm, which is conducive to finding the minimum value in the first performance evaluation value, so that the hyperparameter value corresponding to the minimum value in the first performance evaluation value can be used as the optimized hyperparameter value to achieve the optimization of the heating network model. Since the actual load data is used in the optimization process, the optimization of the heating network model can make the prediction more accurate, improve the prediction accuracy, and thus improve the monitoring reliability of the heating network.
[0133] Optionally, in an implementation manner of this embodiment, the first performance evaluation value includes at least one of a mean square error value, a mean absolute error value, and a Pearson correlation coefficient value.
[0134] The calculation formula is as follows:
[0135]
[0136] Among them, MSE is the mean square error between the predicted load data and the actual load data, y pred is the predicted load data, y represents the actual load data, and n represents the number of samples of the predicted load data.
[0137]
[0138] Among them, MAE is the mean absolute error between the predicted load data and the actual load data, y pred is the predicted load data, y represents the actual load data, and n represents the number of samples of the predicted load data.
[0139]
[0140] Among them, PCC is the Pearson correlation coefficient between the predicted load data and the actual load data, y pred To predict load data, represents the mean of the predicted load data, y represents the actual load data, Indicates the mean of actual load data.
[0141] By using this embodiment, the mean square error value, the mean absolute error value and the Pearson correlation coefficient value can all reflect the degree of difference between the predicted load data and the actual load data, so that the objective function generated according to the mean square error value, the mean absolute error value and / or the Pearson correlation coefficient value can easily improve the optimization effect, thereby improving the prediction accuracy and further improving the monitoring reliability of the heating network.
[0142] Optionally, in an implementation of this embodiment, after optimizing at least one hyperparameter item of the heating network model according to the predicted load data and the actual load data and a preset optimization algorithm to obtain an optimized hyperparameter value corresponding to the hyperparameter item, the method further includes:
[0143] Acquire first historical data of the heating network, wherein the first historical data includes historical operation data and historical load data corresponding to the historical operation data;
[0144] The optimized heating network model is used to process the historical operation data to obtain the target predicted load data;
[0145] Calculating a second performance evaluation value based on the target forecast load data and the corresponding historical load data;
[0146] An optimization result is determined according to the first performance evaluation value and the second performance evaluation value, wherein the optimization result is used to characterize the effect of the optimization.
[0147] In other words, the optimization result can reflect whether the optimization algorithm has an effect on the heating network model, including positive and negative effects. When the effect is positive, it proves that the optimization improves the prediction accuracy of the heating network model; when the effect is negative, it proves that the optimization reduces the prediction accuracy of the heating network model.
[0148] When the prediction accuracy decreases, an alarm can be issued so that relevant personnel can be informed of the situation and update the optimization algorithm or manually debug the heating network model to improve the prediction accuracy.
[0149] Preferably, the difference value between the first performance evaluation value and the second performance evaluation value is calculated, and the optimization result is determined according to the size of the difference value. The larger the difference value, the worse the effect of the optimization determined by the optimization result, and the smaller the difference value, the better the effect of the optimization determined by the optimization result. For example, the difference value is partitioned, each partition corresponds to a different optimization result, and the larger the difference value represented by the partition, the worse the effect represented by the corresponding optimization result. After obtaining the difference value, the partition corresponding to the difference value can be determined, so that the optimization result of the partition is used as the optimization result of the difference value.
[0150] According to this embodiment, after the heating network model is optimized, the historical operation data will be used for testing to obtain the optimization results. The optimization results can be used to know the effect of the optimization. If there is an effect or the effect is good, it proves that the optimization has played a certain role. Otherwise, the optimization results can be used to remind relevant personnel to manually optimize the heating network model to avoid the difficulty in timely discovery when the optimization algorithm does not produce an optimization effect.
[0151] Optionally, in an implementation of this embodiment, the optimization algorithm includes a Bayesian optimization algorithm.
[0152] It should be noted that when the optimization algorithm is a Bayesian optimization algorithm, in addition to setting the objective function, it is also necessary to set the boundary of the parameter search space, the number of iterations, the number of initial sampling points, the selected posterior probability function, and the parameters controlling the trade-off between exploration and development. The above contents that need to be set are all the contents that must be set when the Bayesian optimization algorithm is used, and this embodiment will not be repeated here.
[0153] By adopting this embodiment, the Bayesian optimization algorithm helps to reduce the amount of calculation, save computing resources, and thus reduce the optimization cost.
[0154] Optionally, in an implementation of this embodiment, the heating network model includes a random forest regression model.
[0155] It should be noted that in the process of training or testing the random forest regression model, it is necessary not only to input the historical operation data and historical load data of the heating network, but also to set the hyperparameter values of the following hyperparameters: the number of trees in the forest, the maximum number of features used by each tree, the maximum depth of each tree, the minimum number of samples required for internal node splitting, the minimum number of samples required for leaf nodes, and the seed of the random number generator.
[0156] The present application also provides a method for predicting the load of a heating network. Figure 3 As shown, including:
[0157] S300: Obtain operation data of the heating network.
[0158] The operation data refers to data related to the operation status and performance of the heating network, or data that can characterize the characteristics of the heating network. For example, the temperature, pressure, flow rate, etc. of the carrier used to transfer heat in the heating network. This embodiment does not specifically limit this. Specifically, the carrier used to transfer heat can be water or oil.
[0159] S302: Process the operation data using a preset heating network model to obtain predicted load data.
[0160] Among them, the predicted load data is used to characterize the load conditions of the heating network in the target time period.
[0161] S304: Optimize at least one hyper-parameter item of the heating network model according to the predicted load data and the actual load data of the heating network in the target time period.
[0162] By adopting this embodiment, in the process of load forecasting for the heating network, the heating network model will be optimized to facilitate the heating network model to change according to changes in operating data, so that the matching degree between the heating network model and the operating data is higher, thereby predicting more accurate load data and improving the monitoring effect and reliability of the heating network.
[0163] Optionally, in an implementation of this embodiment, the operating data includes operating data of different types and / or operating data obtained in different acquisition methods;
[0164] Before processing the operation data using the preset heating network model to obtain the predicted load data, the method further includes:
[0165] The operating data is pre-processed using the same or different data processing methods according to the type and / or acquisition method of the operating data.
[0166] Among them, the types include temperature, pressure, flow, etc., and the acquisition methods include obtaining through sensors, obtaining through calculations, obtaining through human input, etc.
[0167] Preprocessing includes outlier detection, feature engineering, data normalization, and time series analysis. Specifically, outlier detection uses the Z-Score method based on mean and standard deviation, feature engineering uses two or more features to synthesize a more representative feature value, data normalization uses minimum-maximum normalization, and time series analysis uses the sliding average smoothing technique.
[0168] Among them, outlier detection mainly uses the Z-Score method (standard score method) based on mean and standard deviation, and its calculation formula is:
[0169]
[0170] Among them, Z-Score represents the Z-Score value, X is each sample data, μ is the mean sample data value, and σ is the standard deviation of the sample data. Sample refers to the running data.
[0171] The Z-Score value indicates the degree of deviation of the data relative to the overall data distribution. According to the preset threshold, each Z-Score value is judged to be greater than the threshold. If the absolute value of the Z-Score is greater than the threshold, the sample data is judged as an outlier, so that the outlier does not participate in subsequent calculations.
[0172] Feature engineering mainly uses two or more features to synthesize a more representative feature value, such as:
[0173] Set a characteristic parameter as temperature-pressure ratio (TPRatio), and its calculation formula is:
[0174]
[0175] Among them, TPRatio is the temperature-pressure ratio, T is the hot water temperature in the current section of the pipeline network, and P is the pressure level of the current section of the pipeline network.
[0176] By monitoring the changes in the temperature-pressure ratio, the energy efficiency coefficient of the current heating network can be better reflected. A higher temperature-pressure ratio may mean that under given temperature conditions, the system requires a higher pressure to maintain the flow of the heat medium. By optimizing the value of the temperature-pressure ratio, the energy efficiency of the heating network can be improved and energy consumption and loss can be reduced.
[0177] Data normalization mainly uses the minimum-maximum normalization method, and its calculation formula is:
[0178]
[0179] Among them, X scale is the normalized value, X refers to the original sample data, and X min Refers to the minimum value in the sample, X max Refers to the maximum value in the sample.
[0180] By subtracting the minimum value from the original data and dividing it by the difference between the maximum and minimum values, the original data can be scaled to a range between 0 and 1, thereby achieving normalization. This normalization method is mainly used to unify data with different value ranges to the same scale so that they can be reliably compared and analyzed. Using the minimum-maximum normalization method, the original data X can be mapped to a range of 0 to 1, where 0 represents the minimum value and 1 represents the maximum value. The processed data has a relative proportional relationship, which is convenient for data analysis, model training and other tasks.
[0181] Time series analysis mainly uses the sliding average smoothing technique, and its steps are:
[0182] Select a window size (usually an odd number), which represents the number of data points used to calculate the average; iterate from left to right in the data sequence, and for each position, calculate the average of the data points in the window; use the calculated average as the smoothing value at that position; repeat the above process until the entire data sequence is traversed.
[0183] With this embodiment, the operating data has different types and / or different acquisition methods, so that the load prediction process of the heating network needs to use multi-label, that is, multi-dimensional operating data, which will cause the prediction accuracy of the heating network model to decrease when the dimensions increase, decrease or change. However, since this application optimizes the heating network model according to the predicted load data and the actual load data after the heating network model outputs the predicted load data, the optimized heating network model can be applied to the operating data with increased, decreased or changed dimensions, thereby improving the accuracy of the prediction, that is, improving the monitoring reliability of the heating network.
[0184] In addition, preprocessing the operation data helps to improve the difficulty of the heating network model to process the operation data and improve the data processing efficiency. At the same time, when preprocessing, the same or different preprocessing will be used according to the type and / or acquisition method of the operation data, which helps to improve the preprocessing effect.
[0185] Optionally, in an implementation of this embodiment, the operation data includes at least two of water supply temperature, water supply pressure, return water temperature, return water pressure, heating network flow, and opening of regulating valves in the heating network; the preprocessing includes feature engineering;
[0186] The method also includes:
[0187] The water supply temperature and water supply pressure are processed by the feature engineering to obtain a temperature-pressure ratio, and the temperature-pressure ratio is used as the operating data to obtain the processing of the heating network model.
[0188] and / or, performing the feature engineering processing on the water supply temperature and the heating network flow to obtain a temperature-flow ratio, and using the temperature-flow ratio as the operating data to obtain the heating network model.
[0189] and / or, calculating the average value of the difference between the supply water temperature and the return water temperature and performing the feature engineering on the average value and the heat supply network flow to obtain an average flow ratio, and using the average flow ratio as the operating data to obtain the heat supply network model.
[0190] and / or, performing the feature engineering processing on the average value and the regulating valve opening to obtain an average opening ratio, and using the average opening ratio as the operating data to obtain the heating network model.
[0191] And / or, the difference between the water supply pressure and the return water pressure is calculated and the average value and the difference are processed by the feature engineering to obtain a mean-difference ratio, and the mean-difference ratio is used as the operating data to obtain the processing of the heating network model.
[0192] Specifically, regarding the feature engineering in preprocessing, the temperature-pressure ratio, temperature-flow ratio, average flow ratio, average opening ratio and average difference ratio may be introduced in the field of heating. Among them, the temperature-pressure ratio refers to the ratio of the water supply temperature to the water supply pressure, the temperature-flow ratio refers to the ratio of the water supply temperature to the flow rate of the heating network, the average flow ratio refers to the ratio of the average value to the flow rate of the heating network, the average opening ratio refers to the ratio of the average value to the opening of the regulating valve, and the average difference ratio refers to the ratio of the average value to the difference. Among them, the average value is the average value of the difference between the supply water temperature and the return water temperature, that is, a set of supply water temperature and return water temperature will be collected at different time nodes, and the difference between the supply water temperature and the return water temperature at the time node will be calculated. After obtaining the differences corresponding to multiple time nodes, the average value of these differences is calculated to obtain the average value mentioned above. Among them, the difference is the value obtained by subtracting the return water pressure from the supply water pressure.
[0193] The above-mentioned characteristic engineering (such as temperature-pressure ratio, temperature-flow ratio, average flow ratio, average opening ratio and average difference ratio) can be applied to heating networks of different types, scales, hydraulic and thermal working conditions. For example, the temperature-flow ratio is suitable for heating networks with high heat exchange efficiency, fast thermal balance establishment and sufficient flow. In this type of heating network, the water supply temperature is highly correlated with the flow of the heating network, and its ratio can be directly related to the terminal heating quality. For heating networks with larger scale, lower heat exchange efficiency and slower thermal balance establishment, the average value can generally be used as a characteristic indicator of the actual heat exchange effect, supplemented by one or more characteristic values of flow, electric control valve opening or supply-return pressure difference, which can characterize the actual heat obtained by the node.
[0194] That is, in some application scenarios, the corresponding feature engineering can be selected by obtaining the type, scale, hydraulic and thermal conditions of the heating network.
[0195] In addition, in some application scenarios, in the process of acquiring data such as water supply temperature, water supply pressure, return water temperature, return water pressure, and heating network flow, a year-on-year and / or year-on-year comparison will be performed to screen out abnormal values. Among them, year-on-year comparison refers to comparing the collected data with the data obtained at the same collection time in other upstream and downstream links, so as to screen out significant abnormal values. Year-on-year comparison refers to comparing the collected data with the data collected at the same collection point over a period of time in the past, so as to screen out significant abnormal values. Preferably, whether it is a significant abnormal value can be determined by setting an abnormal threshold, such as data in the data that exceeds the abnormal threshold is a significant abnormal value, or data in the data whose difference with the average value exceeds the abnormal threshold is a significant abnormal value, and this embodiment does not make specific limitations on this.
[0196] By adopting this embodiment, the temperature and pressure ratio is used instead of the temperature and pressure, which helps to reduce the data processing amount of the heating network model and improve the processing efficiency of the heating network model.
[0197] The present application also provides a method for predicting the load of a heating network, the method comprising:
[0198] Obtaining the operation data of the heating network;
[0199] The operation data is processed using a preset heating network model to obtain predicted load data, wherein the predicted load data is used to characterize the load condition of the heating network in a target time period;
[0200] According to the predicted load data and the actual load data of the heating network in the target time period, the above-mentioned heating network model optimization method is used to optimize at least one hyperparameter item of the heating network model.
[0201] In the above-mentioned embodiments of the present application, the description of each embodiment has its own emphasis. For parts that are not described in detail in a certain embodiment, please refer to the relevant description of other embodiments. The steps shown in the relevant flow chart can be executed in a computer system such as a set of computer executable instructions, and although the logical order is shown in the flow chart, in some cases, the steps shown or described can be executed in an order different from that here. In other words, the order of steps described in the foregoing embodiments is only an example, and it is also within the scope of protection of the embodiments of the present application to reasonably adjust the order of steps based on the content of the embodiments of the present application.
[0202] In a specific implementation of the embodiment of the present application, the load prediction method of the heating network includes the following processing steps:
[0203] like Figure 4-6 As shown, step 1 is to collect characteristic data of the heating network in the current heating season, such as temperature, pressure, flow, etc.
[0204] Step 2: preprocess the original data of the heating network characteristic values.
[0205] In response to step 2, the preprocessing methods that can be used mainly include outlier detection, feature engineering, data normalization, and time series analysis.
[0206] Step 3: Build a random forest regression model based on the preprocessed data. First, define an empty list to save each decision tree; then for i in the range of [0, n_estimators], randomly extract a part of the training data with replacement, and use the above hyperparameters to build a decision tree, and add the generated decision tree to the list; then use each generated decision tree to predict the test data: for each sample in the test data, predict the label of the sample in all decision trees, average the prediction results of all decision trees as the final prediction label, and save the final prediction label of all test samples; finally, return the final prediction label of the test data.
[0207] In response to step 3, the input values of the model are: x: training data features, y: training data labels, n_estimators: the number of trees in the forest, max_features: the maximum number of features used by each tree, max_depth: the maximum depth of each tree, min_samples_split: the minimum number of samples required for internal node splits, min_samples_leaf: the minimum number of samples required for leaf nodes, random_state: the seed of the random number generator.
[0208] In response to step 3, the output value of the model is: y_pred: predicted label of the test data
[0209] Step 4: After the model is established, the performance of the model is evaluated.
[0210] In response to step 4, the evaluation indicators that can be used mainly include calculating the mean square error MSE between the predicted value and the true value, calculating the mean absolute error MAE between the predicted value and the true value, and calculating the Pearson correlation coefficient PCC between the predicted value and the true value.
[0211] Step 5: Apply the Bayesian optimization algorithm to optimize the progressive forest regression model. First, initialize a set of initial sampling points to construct the Gaussian process model. These initial points are randomly sampled from the points between the boundaries of the parameter search space; then, for t in the range of [0, n_iter], perform the following operations: (1) Use the current Gaussian process model and the selected posterior probability function to determine the optimal value of the next parameter. This is based on the core idea of the Bayesian optimizer: using the information of the existing data, perform Bayesian inference through the Gaussian process model, and calculate the next possible optimal parameter value. (2) Evaluate the objective function at the next optimal value, that is, calculate the function value of the objective function here. (3) Add the evaluation results to the existing observations and retrain the Gaussian process model so that the latest information can be used for prediction in the next iteration; finally, return the best parameter value found, that is, the parameter value corresponding to the minimum value of the objective function obtained in all iterations.
[0212] In response to step 5, the input values of the Bayesian optimization algorithm are: objective_function: the objective function to be optimized, bounds: the boundary of the parameter search space, n_iter: the number of iterations, init_points: the number of initial sampling points, acq_func: the selected posterior probability function, kappa: the parameter controlling the trade-off between exploration and exploitation.
[0213] In response to step 5, the output value of the algorithm is: best_params: optimal parameters.
[0214] Step 6: Train the random forest model based on Bayesian optimization on the test set collected during the operation of the heating network in a heating season.
[0215] In response to step 6, the mean square error and the coefficient of determination are used to evaluate the results of the model training.
[0216] The above is an example of an embodiment of the method according to the present application. The embodiment of the present invention also provides an optimization device for a heating network model. Figure 7 is a schematic diagram of the structure of an optimization device for a heating network model according to an embodiment of the present invention. Figure 7 ,The optimization device of the heating network model includes the following modules.
[0217] The first acquisition module 1 is used to acquire the predicted load data output by the heating network model for predicting the load condition of the heating network in the target time period during the use phase of the heating network model;
[0218] The second acquisition module 2 is used to obtain the actual load data of the heating network in the target time period;
[0219] The first optimization module 3 is used to optimize at least one hyperparameter item of the heating network model according to the predicted load data, the actual load data and a preset optimization algorithm to obtain an optimized hyperparameter value corresponding to the hyperparameter item.
[0220] With this embodiment, the first acquisition module 1 can use the heating network model to predict the load of the heating network and obtain predicted load data, so as to facilitate the regulation of the heating network according to the predicted load data, improve the load in the target time period, and realize the monitoring of the heating network. During the use stage of the heating network model, the first optimization module 3 will use the actual load data and the optimization algorithm to optimize the hyperparameters of the heating network model in combination with the predicted load data, so that the heating network model can be adjusted according to the actual operation of the heating network, thereby improving the accuracy of the subsequent predicted load data and improving the reliability of the monitoring of the heating network.
[0221] Optionally, the first optimization module 3 includes a performance evaluation unit, which is used to calculate a first performance evaluation value according to the predicted load data and the actual load data, wherein the first performance evaluation value is used to characterize the accuracy of the prediction performed by the heating network model;
[0222] A function unit, configured to determine an objective function according to a first performance evaluation value;
[0223] The first optimization unit is used to process the objective function using an optimization algorithm to obtain an optimized hyperparameter value corresponding to at least one hyperparameter item of the heating network model.
[0224] Optionally, the first performance evaluation value includes at least one of a mean square error value, a mean absolute error value, and a Pearson correlation coefficient value.
[0225] Optionally, the device further comprises a historical data acquisition module, which is used to acquire first historical data of the heating network, wherein the first historical data comprises historical operation data and historical load data corresponding to the historical operation data;
[0226] The target prediction module is used to process the historical operation data using the optimized heating network model to obtain the target predicted load data;
[0227] A performance evaluation module, used for calculating a second performance evaluation value according to the target forecast load data and the corresponding historical load data;
[0228] The result module is used to determine the optimization result according to the first performance evaluation value and the second performance evaluation value, wherein the optimization result is used to characterize the effect of the optimization.
[0229] Optionally, the result module includes a difference unit, configured to calculate a difference value between the first performance evaluation value and the second performance evaluation value;
[0230] A result unit is used to determine the optimization result according to the size of the difference value, wherein the larger the difference value is, the worse the effect of the optimization is represented by the determined optimization result.
[0231] Optionally, the optimization algorithm comprises a Bayesian optimization algorithm.
[0232] Optionally, the heating network model includes a random forest regression model.
[0233] The method embodiments according to the present application are described above by way of example. The embodiments of the present invention further provide a load prediction device for a heating network. Figure 8 Schematic diagram of a load prediction device for a heating network according to an embodiment of the present invention. Figure 8 , the load forecasting device of the heating network includes the following modules.
[0234] The third acquisition module 4 is used to obtain the operation data of the heating network;
[0235] Prediction module 5, used to process the operation data using a preset heating network model to obtain predicted load data, wherein the predicted load data is used to characterize the load condition of the heating network in a target time period;
[0236] The second optimization module 6 is used to optimize at least one hyper-parameter item of the heating network model according to the predicted load data and the actual load data of the heating network in the target time period.
[0237] Optionally, the operating data includes operating data of different types and / or operating data obtained in different acquisition methods;
[0238] The device also includes a preprocessing module, which is used to preprocess the operating data using the same or different data processing methods according to the type and / or acquisition method of the operating data.
[0239] Optionally, the operating data includes temperature and pressure; the preprocessing includes feature engineering;
[0240] The device also includes a feature engineering module for performing feature engineering processing on temperature and pressure to obtain a temperature-pressure ratio, so as to use the temperature-pressure ratio as operating data to obtain a heating network model.
[0241] The above describes the device embodiments of the present application. For detailed descriptions of the specific execution processes of data, terms, nouns, steps, technical issues and effects, alternative methods and combinations, please refer to the descriptions in the method embodiments, which will not be repeated here.
[0242] The embodiment of the present application also provides a computer program product, which includes computer instructions. When the computer instructions are executed by a computer or a processor, the steps of the above method are executed.
[0243] An embodiment of the present application also provides a computer-readable storage medium, which stores a computer program. When the computer program runs on a computer or a processor, the computer or the processor executes the steps of the above method.
[0244] An embodiment of the present application also provides an electronic device, including a memory and a processor, wherein a computer program is stored in the memory, and the processor is configured to adopt the steps of the above method when executing the computer program.
[0245] Specifically, Fig. 9 As shown, the electronic device includes a processor 100, at least one communication bus 200, a user interface 300, at least one external communication interface 400 and a memory 500. The communication bus 200 is configured to realize connection and communication between these components. The user interface 300 may include a display screen, and the external communication interface 400 may include a standard wired interface and a wireless interface. The memory 500 stores an optimization method for a heating network model and / or a load prediction method for a heating network. The processor 100 is used to adopt the above-mentioned corresponding method when executing the optimization method for a heating network model and / or the load prediction method for a heating network stored in the memory 500.
[0246] The description of the above computer program product, computer-readable storage medium, and electronic device is similar to the description of the above method embodiment, and has similar beneficial effects as the method embodiment. For technical details not disclosed in the computer program product, computer-readable storage medium, and electronic device of this application, please refer to the description of the method embodiment of this application for understanding.
[0247] The sequence of serial numbers or introduction of the embodiments of the present application is for description only and does not represent the superiority or inferiority of the embodiments.
[0248] In the several embodiments provided in this application, it should be understood that the disclosed technical content can be implemented in other ways. Among them, the device embodiments described above are only schematic. For example, the division of the units can be a logical function division. There may be other division methods in actual implementation. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of units or modules, which can be electrical or other forms.
[0249] 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 on multiple units. Some or all of the units may be selected according to actual needs to achieve the purpose of the present embodiment.
[0250] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.
[0251] In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware or any combination thereof. When implemented using software, it can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer instructions are loaded and executed on a computer, the process or function described in the embodiment of the present application is generated in whole or in part. The computer can be a general-purpose computer, a special-purpose computer, a computer network or other programmable device. The computer instructions can be stored in a computer-readable storage medium, or transmitted from one computer-readable storage medium to another computer-readable storage medium. For example, the computer instructions can be transmitted from a website site, computer, server or data center by wired (e.g., coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) mode to another website site, computer, server or data center. The computer-readable storage medium can be any available medium that a computer can access, or a data storage device such as a server or data center that includes one or more available media integrated. The available medium may be a magnetic medium (e.g., a floppy disk, a hard disk, a magnetic tape), an optical medium (e.g., a digital versatile disc (DVD)), or a semiconductor medium (e.g., a solid state disk (SSD)). It is worth noting that the computer-readable storage medium mentioned in the embodiment of the present application may be a non-volatile storage medium, in other words, a non-transient storage medium.
[0252] It should be noted that the information (including but not limited to user device information, user personal information, etc.), data (including but not limited to data for analysis, stored data, displayed data, etc.) and signals involved in the embodiments of this application are all authorized by the user or fully authorized by all parties, and the collection, use and processing of relevant data must comply with the relevant laws, regulations and standards of the relevant countries and regions. For example, the scene data of the current frame in the three-dimensional virtual scene, the device information of the client, and the scene interaction information involved in the embodiments of this application are all obtained with full authorization.
[0253] The above is only a preferred implementation of the present application. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principles of the present application. These improvements and modifications should also be regarded as the scope of protection of the present application.
Claims
1. A method for optimizing a heating network model, characterized in that: The method comprises: During the use phase of the heating network model, the predicted load data output by the heating network model for predicting the load condition of the heating network in a target time period is obtained; Acquire actual load data of the heating network in the target time period; According to the predicted load data, the actual load data and a preset optimization algorithm, at least one hyperparameter item of the heating network model is optimized to obtain an optimized hyperparameter value corresponding to the hyperparameter item.
2. The method for optimizing a heating network model according to claim 1, characterized in that: The step of optimizing at least one hyperparameter item of the heating network model according to the predicted load data, the actual load data and a preset optimization algorithm to obtain an optimized hyperparameter value corresponding to the hyperparameter item includes: Calculating a first performance evaluation value according to the predicted load data and the actual load data, wherein the first performance evaluation value is used to characterize the accuracy of the prediction performed by the heating network model; Determining an objective function according to the first performance evaluation value; The objective function is processed using the optimization algorithm to obtain the optimized hyperparameter value corresponding to at least one hyperparameter item of the heating network model.
3. The method for optimizing a heating network model according to claim 2, characterized in that: The first performance evaluation value includes at least one of a mean square error value, a mean absolute error value, and a Pearson correlation coefficient value.
4. The optimization method of the heating network model according to claim 2, characterized in that: After optimizing at least one hyperparameter item of the heating network model according to the predicted load data and the actual load data and a preset optimization algorithm to obtain an optimized hyperparameter value corresponding to the hyperparameter item, the method further includes: Acquire first historical data of the heating network, wherein the first historical data includes historical operation data and historical load data corresponding to the historical operation data; Processing the historical operation data using the optimized heating network model to obtain target predicted load data; Calculating a second performance evaluation value based on the target predicted load data and the corresponding historical load data; An optimization result is determined according to the first performance evaluation value and the second performance evaluation value, wherein the optimization result is used to characterize the effect of the optimization.
5. The method for optimizing a heating network model according to claim 4, characterized in that: The determining of the optimization result according to the first performance evaluation value and the second performance evaluation value comprises: calculating a difference between the first performance evaluation value and the second performance evaluation value; The optimization result is determined according to the size of the difference value, wherein the larger the difference value is, the worse the optimization effect represented by the determined optimization result is.
6. The method for optimizing a heating network model according to any one of claims 1 to 5, characterized in that: The optimization algorithm includes a Bayesian optimization algorithm.
7. The method for optimizing a heating network model according to any one of claims 1 to 5, characterized in that: The heating network model includes a random forest regression model.
8. A method for predicting the load of a heating network, characterized in that: The method comprises: Obtaining operation data of the heating network; Processing the operating data using a preset heating network model to obtain predicted load data, wherein the predicted load data is used to characterize the load condition of the heating network in a target time period; At least one hyper-parameter item of the heating network model is optimized according to the predicted load data and the actual load data of the heating network in the target time period.
9. The method for load prediction of a heating network according to claim 8, characterized in that: The operation data includes different types of operation data and / or operation data obtained in different acquisition methods; Before the operation data is processed by using a preset heating network model to obtain predicted load data, the method further includes: The operation data is pre-processed using the same or different data processing methods according to the type and / or acquisition method of the operation data.
10. The method for load prediction of a heating network according to claim 9, characterized in that: The operation data includes at least two of the following: water supply temperature, water supply pressure, return water temperature, return water pressure, heating network flow, and opening of regulating valves in the heating network; The preprocessing includes feature engineering; The method further comprises: The water supply temperature and water supply pressure are processed by the feature engineering to obtain a temperature-pressure ratio, and the temperature-pressure ratio is used as the operating data to obtain the processing of the heating network model. and / or, performing the feature engineering process on the water supply temperature and the heating network flow to obtain a temperature-flow ratio, and using the temperature-flow ratio as the operating data to obtain the heating network model. and / or, calculating the average value of the difference between the supply water temperature and the return water temperature and performing the feature engineering on the average value and the heat supply network flow to obtain an average flow ratio, and using the average flow ratio as the operating data to obtain the heat supply network model. and / or, performing the feature engineering processing on the average value and the regulating valve opening to obtain an average opening ratio, and using the average opening ratio as the operating data to obtain the heating network model. And / or, the difference between the water supply pressure and the return water pressure is calculated and the average value and the difference are processed by the feature engineering to obtain a mean-difference ratio, and the mean-difference ratio is used as the operating data to obtain the processing of the heating network model.
11. A method for predicting load of a heating network, characterized in that: The method comprises: Obtaining operation data of the heating network; Processing the operating data using a preset heating network model to obtain predicted load data, wherein the predicted load data is used to characterize the load condition of the heating network in a target time period; According to the predicted load data and the actual load data of the heating network in the target time period, at least one hyperparameter item of the heating network model is optimized using the heating network model optimization method described in any one of claims 1 to 7.
12. An optimization device for a heating network model, characterized in that: The device comprises: A first acquisition module is used to acquire, during the use phase of the heating network model, predicted load data output by the heating network model for predicting the load condition of the heating network in a target time period; A second acquisition module is used to acquire actual load data of the heating network during the target time period; The first optimization module is used to optimize at least one hyperparameter item of the heating network model according to the predicted load data, the actual load data and a preset optimization algorithm to obtain an optimized hyperparameter value corresponding to the hyperparameter item.
13. A load prediction device for a heating network, characterized in that: The device comprises: A third acquisition module is used to acquire the operation data of the heating network; A prediction module, used to process the operation data using a preset heating network model to obtain predicted load data, wherein the predicted load data is used to characterize the load condition of the heating network in a target time period; The second optimization module is used to optimize at least one hyper-parameter item of the heating network model according to the predicted load data and the actual load data of the heating network in the target time period.
14. An electronic device, characterized in that: The electronic device comprises a memory and a processor; The memory is used to store computer programs; The processor is used to execute the computer program to implement the steps of the method described in any one of claims 1-11.
15. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program runs on a computer or a processor, the computer or the processor executes the steps of the method according to any one of claims 1 to 11.
16. A computer program product, characterized in that The computer program product comprises computer instructions, and when the computer instructions are executed by a computer or a processor, the steps of the method according to any one of claims 1 to 11 are performed.
Citation Information
Patent Citations
Heat supply load prediction method and device
CN110991749A
High-rise residential building group thermal load prediction method and system based on SBO optimization CNN
CN112926795A
Secondary network heat supply autonomous optimization regulation and control method based on data association and deep learning
CN114777192A
Heat supply load prediction method and device
CN114857656A
Heat supply secondary network household regulation and control method based on user portraits
CN115013859A
