Building load prediction model training method, building load prediction method and device
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- ELECTRIC POWER RES INST CHINA SOUTHERN POWER GRID CO LTD
- Filing Date
- 2023-07-26
- Publication Date
- 2026-08-07
AI Technical Summary
[0003]然而,点预测方法缺乏对负荷波动的预测能力,还对异常情况的响应能力较弱,并且模型复杂度较低导致结果准确性受限;目前的负荷概率预测方法在提供不确定性信息的同时,相关的预测精度一般较低,如预测区间宽度等评价指标通常表现不佳
[0044] The building load prediction model training method, building load prediction method, and apparatus provided in this application include: the building load prediction model training method comprising: using at least two single clustering algorithms to cluster historical building load datasets respectively, obtaining multiple cluster sets for each single clustering algorithm; using a soft voting method to perform ensemble clustering on each cluster set, obtaining multiple similar load datasets, wherein the number of cluster sets for each single clustering algorithm is the same as the number of sets for the similar load datasets; constructing a probabilistic prediction model corresponding to each similar load dataset based on a CNN neural network and a temporal neural network respectively; for each similar load dataset, using the similar load dataset as training data and a quantile regression function as a loss function, iteratively training the probabilistic prediction model corresponding to the similar load dataset until the probabilistic prediction model corresponding to the similar load dataset meets a preset training termination condition, and using the trained probabilistic prediction model as the building load prediction model corresponding to the similar load dataset, wherein the quantile regression loss function is used to calculate a loss value based on a quantile in each round of training, and the same probabilistic prediction model corresponds to multiple quantiles. By integrating the results of at least two different individual clustering algorithms through ensemble clustering, the bias of individual clustering algorithms can be reduced, thereby improving the stability and accuracy of the clustering results. Using soft voting in ensemble clustering can improve the robustness of the final clustering results. Constructing a probabilistic prediction model for each similar load dataset can improve prediction accuracy. Using a quantile regression function as the loss function can fully consider the data distribution and improve the model's robustness. In these ways, the accuracy of building load prediction results can be improved.
Smart Images

Figure CN116975665B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of power load forecasting technology, and in particular to a building load forecasting model training method, building load forecasting method and device. Background Technology
[0002] With the acceleration of urbanization, building energy consumption in my country is rising rapidly. Therefore, building energy conservation has attracted widespread attention from industry and academia. The main solution to this problem is to use building load forecasting to formulate and improve building energy conservation schemes, thereby reducing building energy consumption. Methods for constructing building load forecasts can be divided into physical methods and data-driven methods. Physical methods predict loads based on physical models of building and environmental parameters, while data-driven methods predict loads based on the analysis of large amounts of data. Depending on the type of forecast result, data-driven forecasting methods can be further divided into deterministic forecasting and probabilistic forecasting. Deterministic forecasting methods, also known as point forecasting methods, are easy to implement and provide more intuitive results. Probabilistic forecasting, based on historical data or known conditions, uses mathematical models to calculate the probability of events occurring, obtaining a quantitative analysis of forecast uncertainty and providing richer forecasting information for building systems.
[0003] However, point forecasting methods lack the ability to predict load fluctuations and have a weak response to abnormal situations. Furthermore, the low model complexity limits the accuracy of the results. Current load probability forecasting methods provide information on uncertainties, but the relevant forecast accuracy is generally low, and evaluation indicators such as forecast interval width usually perform poorly.
[0004] In summary, existing technologies suffer from low accuracy in building load forecasting. Summary of the Invention
[0005] The purpose of this application is to at least address one of the aforementioned technical deficiencies, particularly the low accuracy of building load forecasting results in the prior art.
[0006] Firstly, this application provides a method for training a building load prediction model, the method comprising:
[0007] At least two single clustering algorithms are used to cluster the historical building load dataset, resulting in multiple cluster sets for each single clustering algorithm.
[0008] The soft voting method is used to perform ensemble clustering on each of the cluster sets to obtain multiple similar load datasets, wherein the number of cluster sets for each of the single clustering algorithms is the same as the number of sets of the similar load datasets;
[0009] Based on CNN neural networks and temporal neural networks, probabilistic prediction models are constructed for each of the similar load datasets.
[0010] For each of the similar load datasets, the similar load dataset is used as training data, and the quantile regression function is used as the loss function. The probabilistic prediction model corresponding to the similar load dataset is iteratively trained until the probabilistic prediction model corresponding to the similar load dataset meets the preset training termination condition. The trained probabilistic prediction model is used as the building load prediction model corresponding to the similar load dataset. The quantile regression loss function is used to calculate the loss value based on a quantile in each round of training, and the same probabilistic prediction model corresponds to multiple quantiles.
[0011] In one embodiment, the step of using at least two single clustering algorithms to cluster the historical building load dataset to obtain multiple cluster sets for each single clustering algorithm includes:
[0012] The historical building load dataset is preprocessed to obtain the target building load data;
[0013] Within a preset range of cluster numbers, the clustering results corresponding to each cluster number within the preset range are evaluated sequentially using preset clustering indicators to obtain the evaluation result for each cluster number.
[0014] Based on each of the evaluation results, the number of clusters corresponding to the optimal evaluation result is taken as the target number of clusters, where the target number of clusters is the number of cluster sets for each of the single clustering algorithms.
[0015] Based on the target number of clusters, the target building load data is input into at least two of the single clustering algorithms to obtain multiple cluster sets for each single clustering algorithm.
[0016] In one embodiment, the step of performing ensemble clustering on each of the cluster sets using a soft voting method to obtain multiple similar load datasets includes:
[0017] For each target building load data, the probability distribution of the target building load data in each cluster category is determined based on the cluster category of each cluster where the target building load data is located and the probability weight of each cluster category, and the cluster category with the highest probability is taken as the target category of the target building load data;
[0018] Based on the target category of each target building load data, the target building load data are classified to obtain multiple categories of similar load datasets.
[0019] In one embodiment, the temporal neural network is an LSTM neural network, and the CNN neural network includes convolutional layers, pooling layers, and fully connected layers;
[0020] The convolutional layer, the pooling layer, the fully connected layer, and the LSTM neural network are connected sequentially;
[0021] The convolutional layer is used to extract local features of building load data, the pooling layer is used to downsample the local features, the fully connected layer is used to convert the downsampled local features into feature vectors, and the LSTM neural network is used to perform time series learning on the feature vectors to obtain the variation pattern of the feature vectors.
[0022] In one embodiment, the method further includes:
[0023] The quantile regression function is optimized using an adaptive motion estimation gradient descent algorithm to obtain the optimal parameter estimates of the probability prediction model.
[0024] The expression for the quantile regression function is as follows:
[0025]
[0026] Among them, Y i This represents the actual value of the load data for the i-th building. Let w represent the building load forecast value output by the probabilistic prediction model at the i-th quantile, w represent the quantile level in quantile regression, θ represent the weight parameters of the probabilistic prediction model, β represent the bias vector of the time-series neural network, and the quantile τ ranges from 0 to 1.
[0027] Secondly, this application provides a building load forecasting method, the method comprising:
[0028] Obtain the building load data to be predicted, and determine the similarity between the building load data to be predicted and each similar load dataset;
[0029] Based on the aforementioned similarities, the similarity dataset corresponding to the highest similarity is selected as the target similarity dataset;
[0030] The building load data to be predicted is input into the building load prediction model corresponding to the target similar load dataset to obtain the building load prediction value corresponding to each quantile. The building load prediction model is generated using the building load prediction model training method described in any of the above embodiments.
[0031] Thirdly, this application provides a building load prediction model training device, the device comprising:
[0032] The cluster set acquisition module is used to perform clustering processing on the historical building load dataset using at least two single clustering algorithms, and obtain multiple cluster sets for each single clustering algorithm;
[0033] The similar load dataset acquisition module is used to perform integrated clustering processing on each of the cluster sets using a soft voting method to obtain multiple similar load datasets, wherein the number of cluster sets of each of the single clustering algorithms is the same as the number of sets of the similar load datasets;
[0034] The probability prediction model building module is used to build probability prediction models for each of the similar load datasets based on CNN neural networks and temporal neural networks, respectively.
[0035] The building load prediction model training module is used to iteratively train the probability prediction model corresponding to each similar load dataset using the similar load dataset as training data and the quantile regression function as the loss function, until the probability prediction model corresponding to the similar load dataset meets the preset training termination condition. The trained probability prediction model is then used as the building load prediction model corresponding to the similar load dataset. The quantile regression loss function is used to calculate the loss value based on a quantile in each round of training, and the same probability prediction model corresponds to multiple quantiles.
[0036] Fourthly, this application provides a building load forecasting device, the device comprising:
[0037] A similarity determination module is used to acquire building load data to be predicted and determine the similarity between the building load data to be predicted and each similar load dataset.
[0038] The target similar load dataset selection module is used to select the similar load dataset with the highest similarity as the target similar load dataset based on each of the aforementioned similarities.
[0039] The building load prediction value acquisition module is used to input the building load data to be predicted into the building load prediction model corresponding to the target similar load dataset to obtain the building load prediction value corresponding to each quantile. The building load prediction model is generated using the building load prediction model training method described in any of the above embodiments.
[0040] Fifthly, this application provides a storage medium storing computer-readable instructions, which, when executed by one or more processors, cause the one or more processors to perform the steps of the building load forecasting model training method described in any of the above embodiments, and / or perform the steps of the building load forecasting method described in the above embodiments.
[0041] Sixthly, this application provides a computer device, including: one or more processors, and a memory;
[0042] The memory stores computer-readable instructions, which, when executed by the one or more processors, perform the steps of the building load forecasting model training method described in any of the above embodiments, and / or perform the steps of the building load forecasting method described in the above embodiments.
[0043] As can be seen from the above technical solutions, the embodiments of this application have the following advantages:
[0044] The building load prediction model training method, building load prediction method, and apparatus provided in this application include: the building load prediction model training method comprising: using at least two single clustering algorithms to cluster historical building load datasets respectively, obtaining multiple cluster sets for each single clustering algorithm; using a soft voting method to perform ensemble clustering on each cluster set, obtaining multiple similar load datasets, wherein the number of cluster sets for each single clustering algorithm is the same as the number of sets for the similar load datasets; constructing a probabilistic prediction model corresponding to each similar load dataset based on a CNN neural network and a temporal neural network respectively; for each similar load dataset, using the similar load dataset as training data and a quantile regression function as a loss function, iteratively training the probabilistic prediction model corresponding to the similar load dataset until the probabilistic prediction model corresponding to the similar load dataset meets a preset training termination condition, and using the trained probabilistic prediction model as the building load prediction model corresponding to the similar load dataset, wherein the quantile regression loss function is used to calculate a loss value based on a quantile in each round of training, and the same probabilistic prediction model corresponds to multiple quantiles. By integrating the results of at least two different individual clustering algorithms through ensemble clustering, the bias of individual clustering algorithms can be reduced, thereby improving the stability and accuracy of the clustering results. Using soft voting in ensemble clustering can improve the robustness of the final clustering results. Constructing a probabilistic prediction model for each similar load dataset can improve prediction accuracy. Using a quantile regression function as the loss function can fully consider the data distribution and improve the model's robustness. In these ways, the accuracy of building load prediction results can be improved. Attached Figure Description
[0045] To more clearly illustrate the technical solutions in the embodiments of this application or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0046] Figure 1 A flowchart illustrating the building load prediction model training method provided in this application embodiment;
[0047] Figure 2 A schematic diagram illustrating the process of obtaining cluster sets provided in an embodiment of this application;
[0048] Figure 3 A schematic flowchart illustrating the building load forecasting method provided in this application embodiment;
[0049] Figure 4 This is a schematic diagram of the structure of the building load prediction model training device provided in the embodiments of this application;
[0050] Figure 5 This is a schematic diagram of the building load forecasting device provided in the embodiments of this application;
[0051] Figure 6 This is a schematic diagram of the internal structure of a computer device provided in an embodiment of this application. Detailed Implementation
[0052] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.
[0053] This application provides a method for training a building load forecasting model. The following embodiments illustrate this method using a computer device as an example. It is understood that the computer device can be any device with data processing capabilities, including but not limited to a single server, server cluster, personal laptop, desktop computer, etc. Figure 1 As shown, the building load prediction model training method of this application may include the following steps:
[0054] S101: At least two single clustering algorithms are used to cluster the historical building load dataset, respectively, to obtain multiple cluster sets for each single clustering algorithm.
[0055] In this step, "single clustering algorithm" refers to using a specific clustering algorithm to perform clustering analysis on the dataset. This single clustering algorithm can include K-means clustering, Gaussian Mixed Model (GMM) clustering, Fuzzy C-means (FCM) clustering, Balanced Iterative Reducing and Clustering using Hierarchies (BIRCH), and Spectral Clustering. The choice of single clustering algorithm can be determined based on the actual situation, and this application does not impose specific restrictions. For each single clustering algorithm, the historical building load dataset is input into that algorithm to obtain multiple cluster sets.
[0056] Furthermore, historical building load data refers to data on the monitoring and recording of the power load of buildings or other structures, which may include timestamps and power load values.
[0057] It is understood that the number of cluster sets is the same for each individual clustering algorithm. The choice of the number of cluster sets for each individual clustering algorithm can be made according to the actual situation, and this application does not impose specific restrictions on it.
[0058] S102: The soft voting method is used to perform integrated clustering processing on each of the cluster sets to obtain multiple similar load datasets, wherein the number of cluster sets of each of the single clustering algorithms is the same as the number of sets of the similar load datasets.
[0059] In this step, soft voting is an ensemble learning method used to combine the predictions of multiple classifiers to arrive at the final classification result. Therefore, by using soft voting to perform ensemble clustering on various cluster sets, multiple similar load datasets can be obtained.
[0060] Furthermore, when clustering historical building load data, clustering can be performed based on timestamps and electricity load values. The similarity between building load data in a similar load dataset reaches a preset threshold, which can be determined based on actual conditions. Generally, building load data from different dates but with similar characteristics and patterns have high similarity. For example, building load data for each weekday can be considered as a similar load dataset; similarly, building load data for each rest day can also be considered as a similar load dataset. For instance, weekdays can be finely divided, with building load data from each Monday considered as a similar load dataset, and rest days can be finely divided, with building load data from each Sunday considered as a similar load dataset.
[0061] It is understandable that since the number of cluster sets is the same for each single clustering algorithm, after performing set clustering on each cluster set, the number of sets of similar load datasets is also the same as the number of sets of cluster sets for each single clustering algorithm.
[0062] S103: Construct a probability prediction model for each of the similar load datasets based on CNN neural networks and temporal neural networks.
[0063] In this step, a temporal neural network refers to a neural network model used to process time-series data, which can capture the temporal relationships and time dependencies in the data. Temporal neural networks can include Long Short-Term Memory (LSTM) networks, Recurrent Neural Networks (RNNs), and Gated Recurrent Units (GRUs). The choice of temporal neural network can be determined according to the actual situation, and this application does not impose specific restrictions on it.
[0064] Understandably, CNNs possess the characteristics of parameter sharing and local connectivity, enabling them to process high-dimensional input data with fewer parameters and exhibiting good feature extraction and classification capabilities. Therefore, combining CNNs with temporal neural networks to construct probabilistic prediction models for each similar load dataset can improve the prediction accuracy of the probabilistic prediction models.
[0065] S104: For each of the similar load datasets, the similar load dataset is used as training data, and the quantile regression function is used as the loss function to iteratively train the probability prediction model corresponding to the similar load dataset until the probability prediction model corresponding to the similar load dataset meets the preset training termination condition. The trained probability prediction model is used as the building load prediction model corresponding to the similar load dataset. The quantile regression loss function is used to calculate the loss value based on a quantile in each round of training, and the same probability prediction model corresponds to multiple quantiles.
[0066] In this step, the quantile regression function is used to estimate the relationship between the conditional distribution of a dependent variable at different quantiles and the independent variable. Using the quantile regression function as the loss function can improve the robustness of the probabilistic prediction model to outliers and extreme observations. For each similar load dataset, the similar load dataset is used as training data, and the quantile regression function is used as the loss function to iteratively train the probabilistic prediction model for that similar load dataset, thereby improving the model performance and robustness. In each round of iterative training, after that round of training, it is evaluated whether the probabilistic prediction model meets the preset training termination condition. If it does, the iterative training ends, and the trained probabilistic prediction model is used as the building load prediction model for that similar load dataset. If it does not meet the condition, the next round of training is performed. The training termination condition can be selected according to the actual situation, and this application does not impose specific restrictions on it. For example, it can be the number of iterations, time limits, and convergence criteria.
[0067] Understandably, the quantile regression loss function calculates the loss value based on a quantile in each training round, and the same probabilistic prediction model corresponds to multiple quantiles. This improves the accuracy of the probabilistic prediction model's predictions at different quantiles.
[0068] Furthermore, each similar load dataset corresponds to a building load forecasting model. New building load data can be input into the corresponding building load forecasting model to obtain highly accurate forecast results. For example, inputting Monday's building load data into Monday's building load forecasting model will yield a predicted value.
[0069] In the above embodiments, the method includes: using at least two single clustering algorithms to cluster historical building load datasets respectively, obtaining multiple cluster sets for each single clustering algorithm; using a soft voting method to perform ensemble clustering on each cluster set, obtaining multiple similar load datasets, wherein the number of cluster sets for each single clustering algorithm is the same as the number of sets for the similar load datasets; constructing a probabilistic prediction model corresponding to each similar load dataset based on a CNN neural network and a temporal neural network respectively; for each similar load dataset, using the similar load dataset as training data and a quantile regression function as a loss function, iteratively training the probabilistic prediction model corresponding to the similar load dataset until the probabilistic prediction model corresponding to the similar load dataset meets a preset training termination condition, and using the trained probabilistic prediction model as the building load prediction model corresponding to the similar load dataset, wherein the quantile regression loss function is used to calculate the loss value based on a quantile in each round of training, and the same probabilistic prediction model corresponds to multiple quantiles. By integrating the results of at least two different individual clustering algorithms through ensemble clustering, the bias of individual clustering algorithms can be reduced, thereby improving the stability and accuracy of the clustering results. Using soft voting in ensemble clustering can improve the robustness of the final clustering results. Constructing a probabilistic prediction model for each similar load dataset can improve prediction accuracy. Using a quantile regression function as the loss function can fully consider the data distribution and improve the model's robustness. In these ways, the accuracy of building load prediction results can be improved.
[0070] like Figure 2 As shown, in one embodiment, the step of using at least two single clustering algorithms to cluster the historical building load dataset to obtain multiple cluster sets for each single clustering algorithm includes:
[0071] S201: Preprocess the historical building load dataset to obtain the target building load data;
[0072] S202: Within a preset range of cluster numbers, the clustering results corresponding to each cluster number within the preset range are evaluated sequentially using preset clustering indicators to obtain the evaluation result for each cluster number.
[0073] S203: Based on each of the evaluation results, the number of clusters corresponding to the optimal evaluation result is taken as the target number of clusters, where the target number of clusters is the number of cluster sets for each of the single clustering algorithms.
[0074] S204: Based on the target number of clusters, the target building load data is input into at least two of the single clustering algorithms to obtain multiple cluster sets for each single clustering algorithm.
[0075] Specifically, preprocessing the historical building load dataset refers to feature selection and feature extraction. Feature selection can reduce the dimensionality of the historical building load dataset to a certain extent. The features extracted generally have specific physical meanings, and the extracted features can be selected according to the actual situation. This application does not impose specific restrictions on this. For example, the extracted features can be the average value, maximum value, minimum value, variance, and other parameters calculated based on the historical building load dataset. By preprocessing the historical building load dataset, the target building load data can be obtained.
[0076] Furthermore, before inputting the target building load data into each individual clustering algorithm, it is necessary to determine the target number of clusters. The target number of clusters refers to the number of cluster sets for each individual clustering algorithm. Within a preset clustering range, the clustering results corresponding to each number of clusters within the preset clustering range are evaluated sequentially using preset clustering indices. Based on the evaluation results of each number of clusters, the number of clusters corresponding to the optimal evaluation result is taken as the target number of clusters. The range of the number of clusters can be selected according to the actual situation, and this application does not impose specific restrictions on it. For example, it can be 2 to 20, or 5 to 18. The clustering indices are used to evaluate and compare different clustering results. The clustering indices can be selected according to the actual situation, and this application does not impose specific restrictions on them. For example, it can be the silhouette coefficient or the Davies-Bouldin Index (DBI). The expressions for the silhouette coefficient S(i) and the Davies-Bouldin Index DBI are as follows:
[0077]
[0078]
[0079] Where b(i) is the distance between samples outside the cluster, a(i) is the distance between samples within the cluster, the silhouette coefficient is the average of the silhouette coefficients of all samples; avg is the average distance between samples within the cluster, k is the number of clusters, and C i and C j All are sample clusters, c i and c jAll samples are cluster centers. The silhouette coefficient ranges from -1 to 1, where -1 indicates the worst clustering quality, 1 indicates the best clustering quality, and 0 indicates average clustering quality. Dispersion Index (DBI) is calculated based on the ratio between the compactness within clusters and the separation between different clusters; a smaller DBI value indicates better clustering results. Therefore, the final target number of clusters can be determined by comprehensively comparing the silhouette coefficient and DBI under different numbers of clusters. Based on the target number of clusters, the target building load data is input into each individual clustering algorithm, resulting in multiple cluster sets for each algorithm.
[0080] It is understandable that preprocessing the historical building load dataset and determining the target number of clusters through evaluation metrics before clustering the target building load dataset can improve the stability and accuracy of the clustering results.
[0081] In one embodiment, the step of performing ensemble clustering on each of the cluster sets using a soft voting method to obtain multiple similar workload datasets includes:
[0082] For each target building load data, the probability distribution of the target building load data in each cluster category is determined based on the cluster category of each cluster where the target building load data is located and the probability weight of each cluster category, and the cluster category with the highest probability is taken as the target category of the target building load data;
[0083] Based on the target category of each target building load data, the target building load data are classified to obtain multiple categories of similar load datasets.
[0084] Specifically, for each target building load data point, the probability distribution of the target building load data in each cluster category is determined based on the cluster category of each cluster and the probability weight of each cluster. The probability distribution can be calculated by using the clustering index evaluation results of each individual clustering algorithm as confidence levels, and then obtaining the probability distribution through weighted summation. Next, the cluster category with the highest probability is selected as the target category of the target building load data. Based on the target category of each target building load data point, the data is classified into multiple similar load datasets, resulting in a multi-class similar load dataset.
[0085] Understandably, soft voting not only considers the frequency of class occurrence in different clustering algorithms, but also the probability distribution of target building load data in different classes, thereby improving overall classification performance.
[0086] In one embodiment, the temporal neural network is an LSTM neural network, and the CNN neural network includes convolutional layers, pooling layers, and fully connected layers;
[0087] The convolutional layer, the pooling layer, the fully connected layer, and the LSTM neural network are connected sequentially;
[0088] The convolutional layer is used to extract local features of building load data, the pooling layer is used to downsample the local features, the fully connected layer is used to convert the downsampled local features into feature vectors, and the LSTM neural network is used to perform time series learning on the feature vectors to obtain the variation pattern of the feature vectors.
[0089] Specifically, the LSTM neural network is a variant of the recurrent neural network. The CNN neural network consists of convolutional layers, pooling layers, and fully connected layers, which are sequentially connected to the LSTM neural network. In the convolutional layers, local features of the building load data can be extracted. In the pooling layers, the local features output by the convolutional layers are downsampled to improve robustness and generalization ability. In the fully connected layers, the downsampled local features are transformed into feature vectors. The LSTM neural network learns the changing patterns of these feature vectors through time-series learning. During the training process of the LSTM neural network, the output results are compared with the sample label values. The error between the output results and the sample label values is used for backpropagation to update the node weights of the LSTM neural network. Finally, the result is output through the fully connected layers. Let the input and output of the CNN-LSTM neural network be X and Y, respectively, and their relationship can be described as:
[0090] Y = F(X, W, b)
[0091] Where X and W are the weights and biases of the CNN-LSTM neural network, respectively, and F is a nonlinear function reflecting the relationship between X and Y.
[0092] Understandably, LSTM neural networks can effectively capture long-range dependencies in sequences and have better memory performance and stronger generalization ability, thereby improving the accuracy of probabilistic prediction model prediction results.
[0093] In one embodiment, the method further includes:
[0094] The quantile regression function is optimized using an adaptive motion estimation gradient descent algorithm to obtain the optimal parameter estimates of the probability prediction model.
[0095] The expression for the quantile regression function is as follows:
[0096]
[0097] Among them, Y i This represents the actual value of the load data for the i-th building. Let w represent the building load forecast value output by the probabilistic prediction model at the i-th quantile, w represent the quantile level in quantile regression, θ represent the weight parameters of the probabilistic prediction model, β represent the bias vector of the time-series neural network, and the quantile τ ranges from 0 to 1.
[0098] Specifically, the Adaptive Moment Estimation (Adam) gradient descent algorithm is used to train neural networks and other machine learning models. It combines momentum methods and adaptive learning rate methods, adaptively adjusting the learning rate during training and effectively handling non-stationary objective functions and sparse gradients. Optimizing the quantile regression function using Adam yields optimal parameter estimates for the probabilistic prediction model, enabling faster convergence, increasing the adaptive learning rate, and enhancing robustness. This, in turn, improves the accuracy, stability, and efficiency of the probabilistic prediction model, allowing it to better fit data and perform probabilistic predictions.
[0099] This application also provides a building load forecasting method. The following embodiments illustrate this method applied to computer equipment. It is understood that the computer equipment can be various devices with data processing capabilities, including, but not limited to, a single server, server cluster, personal laptop, desktop computer, etc. Figure 3 As shown, the building load forecasting method of this application may include the following steps:
[0100] S301: Obtain the building load data to be predicted, and determine the similarity between the building load data to be predicted and each similar load dataset.
[0101] In this step, the method for obtaining the building load data to be predicted can be selected according to the actual situation, and this application does not impose specific restrictions on it. For example, it can be reading data from relevant monitoring equipment or obtaining publicly available data files. The method for determining the similarity between the building load data to be predicted and each similar load dataset can be selected according to the actual situation, and this application does not impose specific restrictions on it. For example, it can be done through cosine similarity or Euclidean distance, etc.
[0102] S302: Based on each of the aforementioned similarities, select the similarity dataset corresponding to the highest similarity as the target similarity dataset.
[0103] In this step, the method for selecting the highest similarity can be chosen according to the actual situation, and this application does not impose specific restrictions on it. For example, the highest similarity can be determined by comparing every two similarities, or the similarities can be sorted in ascending order and the last similarity is selected, or sorted in descending order and the first similarity is selected. The corresponding similarity load dataset is selected as the target similarity load dataset based on the highest similarity.
[0104] S303: Input the building load data to be predicted into the building load prediction model corresponding to the target similar load dataset to obtain the building load prediction value corresponding to each quantile.
[0105] The building load prediction model is generated using the building load prediction model training method described in any of the above embodiments.
[0106] In this step, a building load prediction model for the target similar load dataset is obtained, and the building load data to be predicted is input into the building load prediction model to obtain the building load prediction value corresponding to each quantile.
[0107] In the above embodiments, the building load forecasting method includes: acquiring building load data to be predicted, and determining the similarity between the building load data to be predicted and each similar load dataset; selecting the similar load dataset corresponding to the highest similarity as the target similar load dataset based on each similarity; inputting the building load data to be predicted into the building load forecasting model corresponding to the target similar load dataset to obtain the building load forecast value corresponding to each quantile. In this way, the building load data to be predicted can be input into the corresponding building load forecasting model, thereby quickly obtaining a high-precision building load forecast value corresponding to each quantile.
[0108] The building load forecasting model training device provided in the embodiments of this application is described below. The building load forecasting model training device described below can be referred to in correspondence with the building load forecasting model training method described above. Figure 4 As shown, this application provides a building load prediction model training device, the device comprising:
[0109] The cluster set acquisition module 401 is used to perform clustering processing on the historical building load dataset using at least two single clustering algorithms to obtain multiple cluster sets for each single clustering algorithm;
[0110] The similar load dataset acquisition module 402 is used to perform integrated clustering processing on each of the cluster sets using a soft voting method to obtain multiple similar load datasets, wherein the number of cluster sets of each of the single clustering algorithms is the same as the number of sets of the similar load datasets;
[0111] The probability prediction model construction module 403 is used to construct a probability prediction model corresponding to each of the similar load datasets based on CNN neural network and temporal neural network, respectively.
[0112] The building load prediction model training module 404 is used to iteratively train the probability prediction model corresponding to each similar load dataset using the similar load dataset as training data and the quantile regression function as the loss function, until the probability prediction model corresponding to the similar load dataset meets the preset training termination condition. The trained probability prediction model is then used as the building load prediction model corresponding to the similar load dataset. The quantile regression loss function is used to calculate the loss value based on a quantile in each round of training, and the same probability prediction model corresponds to multiple quantiles.
[0113] In one embodiment, the cluster set acquisition module 401 includes:
[0114] The target building load data acquisition submodule is used to preprocess the historical building load dataset to obtain the target building load data;
[0115] The evaluation result acquisition submodule is used to evaluate the clustering results corresponding to each cluster number within a preset clustering range by using preset clustering indicators, and obtain the evaluation result for each cluster number.
[0116] The target cluster number determination submodule is used to determine the cluster number corresponding to the optimal evaluation result as the target cluster number based on each of the evaluation results. The target cluster number is the number of cluster sets for each of the single clustering algorithms.
[0117] The cluster set acquisition submodule is used to input the target building load data into at least two of the single clustering algorithms based on the target number of clusters, and obtain multiple cluster sets for each of the single clustering algorithms.
[0118] In one embodiment, the similar load dataset acquisition module 402 includes:
[0119] The target category determination submodule is used to determine the probability distribution of each target building load data in each cluster category based on the cluster category of each cluster to which the target building load data belongs and the probability weight of each cluster category, and to take the cluster category with the highest probability as the target category of the target building load data.
[0120] The similar load dataset determination submodule is used to classify each target building load data according to the target category of each target building load data to obtain multiple categories of similar load datasets.
[0121] In one embodiment, the apparatus further includes:
[0122] The optimal parameter estimate acquisition module is used to optimize the quantile regression function using the adaptive motion estimation gradient descent algorithm to obtain the optimal parameter estimate of the probability prediction model.
[0123] The building load forecasting device provided in the embodiments of this application is described below. The building load forecasting device described below can be referred to in correspondence with the building load forecasting method described above. Figure 5 As shown, this application provides a building load forecasting device, the device comprising:
[0124] The similarity determination module 501 is used to acquire the building load data to be predicted and determine the similarity between the building load data to be predicted and each similar load dataset;
[0125] The target similar load dataset selection module 502 is used to select the similar load dataset corresponding to the highest similarity as the target similar load dataset based on each of the aforementioned similarities.
[0126] The building load prediction value acquisition module 503 is used to input the building load data to be predicted into the building load prediction model corresponding to the target similar load dataset to obtain the building load prediction value corresponding to each quantile. The building load prediction model is generated using the building load prediction model training method described in any of the above embodiments.
[0127] In one embodiment, this application also provides a storage medium storing computer-readable instructions that, when executed by one or more processors, cause the one or more processors to perform the steps of the building load forecasting model training method as described in any of the above embodiments, and / or perform the steps of the building load forecasting method as described in the above embodiments.
[0128] In one embodiment, this application also provides a computer device storing computer-readable instructions that, when executed by one or more processors, cause the one or more processors to perform the steps of the building load forecasting model training method as described in any of the foregoing embodiments, and / or perform the steps of the building load forecasting method as described in the foregoing embodiments.
[0129] Indicatively, such as Figure 6 As shown, Figure 6This is a schematic diagram of the internal structure of a computer device 600 provided in an embodiment of this application. The computer device 600 can be provided as a server. (Refer to...) Figure 6 The computer device 600 includes a processing component 602, which further includes one or more processors, and memory resources represented by memory 601 for storing instructions executable by the processing component 602, such as application programs. The application programs stored in memory 601 may include one or more modules, each corresponding to a set of instructions. Furthermore, the processing component 602 is configured to execute instructions to perform the building load forecasting model training method of any of the above embodiments, and / or to perform the building load forecasting method described in the above embodiments.
[0130] The computer device 600 may also include a power supply component 603 configured to perform power management of the computer device 600, a wired or wireless network interface 604 configured to connect the computer device 600 to a network, and an input / output (I / O) interface 605. The computer device 600 may operate on an operating system stored in memory 601, such as Windows Server™, Mac OS X™, Unix™, Linux™, Free BSD™, or similar.
[0131] Those skilled in the art will understand that Figure 6 The structure shown is merely a block diagram of a portion of the structure related to the present application and does not constitute a limitation on the computer device to which the present application is applied. Specific computer devices may include more or fewer components than those shown in the figure, or combine certain components, or have different component arrangements.
[0132] Finally, it should be noted that in this document, relational terms such as "first" and "second" are used only to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Unless otherwise specified, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element. In this document, "a," "an," "the," "the," and "its" may also include plural forms unless the context clearly indicates otherwise. "Multiple" refers to at least two, such as 2, 3, 5, or 8, etc. "And / or" includes any and all combinations of the related listed items.
[0133] The various embodiments in this specification are described in a progressive manner. Each embodiment focuses on the differences from other embodiments. The various embodiments can be combined as needed, and the same or similar parts can be referred to each other.
[0134] The above description of the disclosed embodiments enables those skilled in the art to make or use this application. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of this application. Therefore, this application is not to be limited to the embodiments shown herein, but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.
Claims
1. A method for training a building load forecasting model, characterized in that, The method includes: The historical building load dataset is preprocessed to obtain target building load data. Within a preset range of cluster numbers, the clustering results corresponding to each cluster number within the range are evaluated sequentially using preset clustering indicators to obtain an evaluation result for each cluster number. Based on each evaluation result, the cluster number corresponding to the optimal evaluation result is taken as the target cluster number, which is the number of cluster sets for each single clustering algorithm. Based on the target cluster number, the target building load data is input into at least two single clustering algorithms to obtain multiple cluster sets for each single clustering algorithm. For each target building load data, the probability distribution of the target building load data in each cluster category is determined based on the cluster category of each cluster set to which the target building load data belongs and the probability weight of each cluster set. The cluster category with the highest probability is taken as the target category of the target building load data. Based on the target category of each target building load data, each target building load data is classified to obtain a multi-class similar load dataset. The number of cluster sets of each single clustering algorithm is the same as the number of sets of the similar load dataset. Based on CNN neural networks and temporal neural networks, probabilistic prediction models are constructed for each of the similar load datasets. For each of the similar load datasets, the similar load dataset is used as training data, and the quantile regression function is used as the loss function. The probabilistic prediction model corresponding to the similar load dataset is iteratively trained until the probabilistic prediction model corresponding to the similar load dataset meets the preset training termination condition. The trained probabilistic prediction model is used as the building load prediction model corresponding to the similar load dataset. The quantile regression loss function is used to calculate the loss value based on a quantile in each round of training, and the same probabilistic prediction model corresponds to multiple quantiles.
2. The building load prediction model training method according to claim 1, characterized in that, The temporal neural network is an LSTM neural network, and the CNN neural network includes convolutional layers, pooling layers, and fully connected layers; The convolutional layer, the pooling layer, the fully connected layer, and the LSTM neural network are connected sequentially. The convolutional layer is used to extract local features of building load data, the pooling layer is used to downsample the local features, the fully connected layer is used to convert the downsampled local features into feature vectors, and the LSTM neural network is used to perform time series learning on the feature vectors to obtain the variation pattern of the feature vectors.
3. The building load forecasting model training method according to any one of claims 1 to 2, characterized in that, The method further includes: The quantile regression function is optimized using an adaptive motion estimation gradient descent algorithm to obtain the optimal parameter estimates of the probability prediction model. The expression for the quantile regression function is as follows: ; in, Indicates the first Actual values of building load data. Indicates the first One in Building load forecast values output by the quantile probability forecasting model This represents the quantile level in quantile regression. The weight parameters represent the probabilistic prediction model. The bias vector and quantiles of a temporal neural network The value range is from 0 to 1.
4. A building load forecasting method, characterized in that, The method includes: Obtain the building load data to be predicted, and determine the similarity between the building load data to be predicted and each similar load dataset; Based on the aforementioned similarities, the similarity dataset corresponding to the highest similarity is selected as the target similarity dataset; The building load data to be predicted is input into the building load prediction model corresponding to the target similar load dataset to obtain the building load prediction value corresponding to each quantile. The building load prediction model is generated using the building load prediction model training method of any one of claims 1 to 3.
5. A building load prediction model training device, characterized in that, The device includes: The cluster set acquisition module is used to preprocess the historical building load dataset to obtain target building load data; within a preset cluster number range, the clustering results corresponding to each cluster number within the preset cluster number range are evaluated sequentially using preset clustering indicators to obtain an evaluation result for each cluster number; based on each evaluation result, the cluster number corresponding to the optimal evaluation result is taken as the target cluster number, where the target cluster number is the number of cluster sets for each single clustering algorithm; based on the target cluster number, the target building load data is input into at least two single clustering algorithms to obtain multiple cluster sets for each single clustering algorithm; The similar load dataset acquisition module is used to determine the probability distribution of each target building load data in each cluster category based on the cluster category of each cluster set to which the target building load data belongs and the probability weight of each cluster set, and to take the cluster category with the highest probability as the target category of the target building load data. Based on the target category of each target building load data, the module classifies each target building load data to obtain a multi-class similar load dataset. The number of cluster sets of each single clustering algorithm is the same as the number of sets in the similar load dataset. The probability prediction model building module is used to build probability prediction models for each of the similar load datasets based on CNN neural networks and temporal neural networks, respectively. The building load prediction model training module is used to iteratively train the probability prediction model corresponding to each similar load dataset using the similar load dataset as training data and the quantile regression function as the loss function, until the probability prediction model corresponding to the similar load dataset meets the preset training termination condition. The trained probability prediction model is then used as the building load prediction model corresponding to the similar load dataset. The quantile regression loss function is used to calculate the loss value based on a quantile in each round of training, and the same probability prediction model corresponds to multiple quantiles.
6. A building load forecasting device, characterized in that, The device includes: A similarity determination module is used to acquire building load data to be predicted and determine the similarity between the building load data to be predicted and each similar load dataset. The target similar load dataset selection module is used to select the similar load dataset with the highest similarity as the target similar load dataset based on each of the aforementioned similarities. The building load prediction value acquisition module is used to input the building load data to be predicted into the building load prediction model corresponding to the target similar load dataset to obtain the building load prediction value corresponding to each quantile, wherein the building load prediction model is generated by the building load prediction model training method according to any one of claims 1 to 3.
7. A storage medium, characterized in that: The storage medium stores computer-readable instructions that, when executed by one or more processors, cause the one or more processors to perform the steps of the building load forecasting model training method as described in any one of claims 1 to 3, and / or perform the steps of the building load forecasting method as described in claim 4.
8. A computer device, characterized in that, include: One or more processors, and memory; The memory stores computer-readable instructions, which, when executed by the one or more processors, perform the steps of the building load forecasting model training method as described in any one of claims 1 to 3, and / or perform the steps of the building load forecasting method as described in claim 4.
Citation Information
Patent Citations
Public transformer district power load three-phase imbalance prediction method
CN110535149A
Short-term load probability prediction method and probability prediction device
CN111860977A
Full-topology load prediction method and device and computer equipment
CN112488418A
Method and system for predicting short-term load of power grid, equipment and medium
CN113505943A