Electric load prediction model construction method for summer high-temperature heat wave scene

By expanding the dataset with TimeGAN and BiLSTM networks and combining them with a dual attention mechanism, the problems of insufficient historical samples and interpretability in power load prediction under extreme high temperature scenarios are solved, achieving high-precision and high-confidence prediction results.

CN120855266APending Publication Date: 2025-10-28XIAMEN UNIV
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510738428.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-06-04
Publication Date
2025-10-28

AI Technical Summary

Technical Problem

Existing technologies suffer from insufficient historical samples and a lack of model interpretability in predicting electricity load under extreme high-temperature scenarios, resulting in low prediction accuracy and insufficient reliability.

Method used

The TimeGAN network is used to expand the dataset for summer heat waves, and BiLSTM network and dual attention mechanism are combined to improve the data balance and interpretability of the model through feature and temporal attention layers.

Benefits of technology

It improves the accuracy of electricity load prediction in high-temperature summer scenarios and enhances the interpretability and accuracy of the model by visually presenting the attention weights of features and time.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120855266A_ABST
    Figure CN120855266A_ABST
Patent Text Reader

Abstract

The invention discloses an electrical load prediction model construction method for a summer high-temperature heat wave scene, and relates to the technical field of artificial intelligence and intelligent power utilization. The method comprises the following steps: acquiring summer electrical load data and meteorological characteristic data of a to-be-predicted area; carrying out data expansion by utilizing a T imeGAN network; training an electrical load prediction model by using the expanded data set, and executing the following operations in the model: inputting a time sequence formed by electrical load data and a plurality of meteorological feature data into a feature attention layer, learning attention weights among input features in the time sequence, and correcting the time sequence by using the attention weights; inputting the corrected time sequence into a Bi LSTM network and a time sequence attention layer, learning attention weights among time steps, and obtaining context features; and predicting the electrical load of the next time step of the time sequence by using the context features.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The embodiments of the present invention relate to the fields of artificial intelligence and smart electricity technology, and in particular to a method for constructing an electricity load prediction model, an electricity load prediction method, and a remote measurement device for summer high temperature heat wave scenarios. Background Technology

[0002] Electricity load forecasting refers to predicting electricity demand over a specific period based on historical data, development trends, seasonal variations, and other factors. Accurate electricity load forecasting helps in the rational planning of power generation, optimizing resource allocation, and improving the operational efficiency and reliability of the power grid.

[0003] Electricity load forecasting typically requires a large amount of historical data, but for electricity load forecasting in extreme high-temperature scenarios, there is a problem of insufficient historical samples. General data augmentation methods cannot consider temporal dependencies and cannot generate small sample data for specific high-temperature weather scenarios, which affects the model training effect in high-temperature scenarios. At the same time, existing load forecasting models are mostly black-box models, lacking interpretable design, making it difficult to verify whether they conform to domain knowledge, thus limiting the accuracy and reliability of the models. Summary of the Invention

[0004] This invention provides a method for constructing an electricity load prediction model, an electricity load prediction method, and a remote measurement device for summer high-temperature heat waves, in order to solve at least one of the above-mentioned technical problems.

[0005] The specific embodiments of the present invention are as follows:

[0006] In a first aspect, embodiments of the present invention provide a method for constructing an electricity load prediction model for summer high-temperature heat wave scenarios, including:

[0007] Obtain summer electricity load data and meteorological characteristic data for the area to be predicted;

[0008] The summer electricity load data and meteorological characteristic data are expanded using the TimeGAN network;

[0009] Using the expanded dataset as the sample set, the electricity load prediction model is trained, wherein the model performs the following operations:

[0010] S1-1. Input the time series consisting of electricity load data and multiple meteorological feature data into the feature attention layer composed of a convolutional network, learn the attention weights between each input feature in the time series, and use each attention weight to correct the time series.

[0011] S1-2. Input the corrected time series into the BiLSTM network and the temporal attention layer in sequence to learn the attention weights between each time step, and use the attention weights between each time step to obtain the context features.

[0012] S1-3. Using the aforementioned contextual features, predict the electricity load for the next time step of the time series.

[0013] Secondly, embodiments of the present invention provide a method for predicting electricity load in summer heatwave scenarios, including:

[0014] Obtain summer electricity load data and meteorological characteristic data for the area to be predicted;

[0015] The time series consisting of the electricity load data and meteorological characteristic data is input into the electricity load prediction model constructed using the method described in the above embodiments to obtain the electricity load of the next time step of the time series.

[0016] Thirdly, embodiments of the present invention also provide an electronic device, the electronic device comprising:

[0017] one or more processors;

[0018] Memory, used to store one or more programs.

[0019] When the one or more programs are executed by the one or more processors, the one or more processors implement the method for constructing an electricity load forecasting model for summer high temperature heat wave scenarios, or the method for forecasting electricity load for summer high temperature heat wave scenarios, as described in any embodiment.

[0020] Fourthly, embodiments of the present invention also provide a computer-readable storage medium storing a computer program thereon, which, when executed by a processor, implements the method for constructing an electricity load prediction model for summer high-temperature heat wave scenarios, or the method for predicting electricity load for summer high-temperature heat wave scenarios, as described in any embodiment.

[0021] In summary, the embodiments of the present invention provide a method for constructing an electricity load forecasting model, an electricity load forecasting method, and a remote measurement device for summer high-temperature heat waves, which can achieve the following beneficial effects:

[0022] 1. Conventional load forecasting methods require a large amount of historical data, which leads to insufficient historical samples in extreme high-temperature scenarios. To address this issue, this embodiment uses the TimeGAN method to expand the limited sample dataset under heat wave conditions, solving the problem of low load forecasting accuracy caused by dataset imbalance and improving the forecasting accuracy of electricity load in summer high-temperature scenarios.

[0023] 2. Due to the "black box" nature of deep learning, the accuracy and reliability of typical prediction models are low. This embodiment integrates domain knowledge into the BiLSTM neural network through a dual attention mechanism, which captures the correlation between input features (such as the synergistic effect of temperature and humidity on load) and temporal dynamic changes. This not only improves the accuracy of model predictions but also evaluates the impact of input features and time series on prediction results. Furthermore, it enhances the interpretability of the model by visually presenting the attention weights of preliminary explanatory features and time. Attached Figure Description

[0024] To more clearly illustrate the specific embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the specific embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of the present invention. For those skilled in the art, other drawings can be obtained from these drawings without creative effort.

[0025] Figure 1 This is a flowchart of a method for constructing an electricity load prediction model for summer high temperature heat wave scenarios provided by an embodiment of the present invention;

[0026] Figure 2 This is a schematic diagram of the TimeGAN network structure;

[0027] Figure 3 This is a flowchart of another method for constructing an electricity load prediction model for summer high temperature heat wave scenarios provided by an embodiment of the present invention;

[0028] Figure 4 This is a schematic diagram of a feature attention layer provided in an embodiment of the present invention;

[0029] Figure 5 This is a schematic diagram of the structure of a BiLSTM network provided in an embodiment of the present invention;

[0030] Figure 6 This is a schematic diagram of a temporal attention layer provided in an embodiment of the present invention;

[0031] Figure 7 This is a flowchart of a method for predicting electricity load in summer heat waves, provided by an embodiment of the present invention.

[0032] Figure 8 This is a t-SNE comparison chart of real data and generated data provided in an embodiment of the present invention;

[0033] Figure 9 This is a comparison chart of the prediction results of the prediction model provided in this embodiment of the invention with those of other models;

[0034] Figure 10 This is a schematic diagram of the structure of an electronic device provided in an embodiment of the present invention. Detailed Implementation

[0035] To make the objectives, technical solutions, and advantages of this invention clearer, the technical solutions of this invention will be clearly and completely described below. Obviously, the described embodiments are only a part of the embodiments of this invention, and not all of them. Based on the embodiments of this invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this invention.

[0036] In the description of this invention, it should be noted that the terms "center," "upper," "lower," "left," "right," "vertical," "horizontal," "inner," and "outer," etc., indicate the orientation or positional relationship based on the orientation or positional relationship shown in the accompanying drawings. They are used only for the convenience of describing the invention and for simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation. Therefore, they should not be construed as limitations on the invention. Furthermore, the terms "first," "second," and "third" are used for descriptive purposes only and should not be construed as indicating or implying relative importance.

[0037] In the description of this invention, it should also be noted that, unless otherwise explicitly specified and limited, the terms "installation," "connection," and "linking" should be interpreted broadly. For example, they can refer to a fixed connection, a detachable connection, or an integral connection; they can refer to a mechanical connection or an electrical connection; they can refer to a direct connection or an indirect connection through an intermediate medium; and they can refer to the internal connection of two components. Those skilled in the art can understand the specific meaning of the above terms in this invention based on the specific circumstances.

[0038] Figure 1 This is a flowchart illustrating a method for constructing an electricity load prediction model for summer heatwave scenarios, provided by an embodiment of the present invention. The method is executed by electronic equipment, such as... Figure 1 As shown, the method specifically includes:

[0039] S110. Obtain summer electricity load data and meteorological characteristic data for the area to be predicted.

[0040] This embodiment collects historical data of the area to be predicted under summer high temperature heat wave scenarios as the data source for constructing the electricity load prediction model.

[0041] In one specific implementation, historical data on electricity load, as well as historical data on five individual meteorological characteristics—temperature, humidity, wind speed, solar radiation, and rainfall—can be collected first. Then, based on these five individual meteorological characteristic data, multiple comprehensive meteorological characteristic data are calculated. These multiple comprehensive meteorological indicators include the greenhouse index, perceived temperature, perceived temperature, and human comfort level. The specific calculation methods are existing technologies and will not be elaborated here.

[0042] Finally, a multi-dimensional feature screening was performed on the above nine meteorological features (five single meteorological features + four comprehensive meteorological features). The Pearson correlation coefficient and MIC (Maximum information coefficient) between these indicators and electricity load were calculated respectively. The most critical meteorological features were selected from both linear and nonlinear dimensions. The selected meteorological features and historical data of electricity load were used as the final input dataset.

[0043] S120. The summer electricity load data and meteorological characteristic data are expanded using the TimeGAN network.

[0044] This embodiment addresses the problem of insufficient sample data in summer heat waves by using TimeGAN (Timeseries Generative Adversarial Networks) to expand the load and meteorological data in heat wave scenarios, thereby balancing the dataset and achieving higher prediction accuracy. Figure 2 This is a schematic diagram of the TimeGAN network structure, which includes two autoencoder networks (embedding network and recovery network) and two adversarial networks (generator and discriminator).

[0045] The autoencoder network is used to establish a mapping between the feature vectors of the original input data and the low-dimensional latent space. The embedding network maps high-dimensional data to the latent space and extracts valuable feature information from the high-dimensional vectors; while the reconstruction network is responsible for reconstructing these features into data with the same dimension as the original input data, thus helping the adversarial network components more effectively capture static and time-varying features in the original input data. Specifically, the reconstruction loss L of the autoencoder network... R as follows:

[0046]

[0047] Where s represents the static data in the original input data, This represents static data obtained through autoencoder network mapping-inverse mapping learning; x t This represents the time-varying data in the original input data. This represents time-varying data obtained through autoencoder network mapping-inverse mapping learning; This represents the expectation between the distributions. It is the mean squared error between the original input data and the reconstructed data.

[0048] The generator then generates new time series within this latent space, while the discriminator improves the generation quality by distinguishing between real and generated time series. During the training of TimeGAN, the adversarial training loss function for the discriminator and generator is an unsupervised loss, designed to match the overall distribution characteristics of the data. This unsupervised loss L... U Focusing on capturing the difference between generated data and the distribution of real data, defined as:

[0049]

[0050] Among them, y s This represents the classification result of static data in the original input data; y t This represents the classification result of time-varying data in the original input data; and These represent the classification results for static data and time-varying data in the generated data, respectively. and It is calculating the mean log-likelihood.

[0051] To more effectively capture the stepwise conditional distribution of the data, TimeGAN introduces an additional supervised loss to further enhance the generator's ability to model temporal features. This supervised loss L... S The mathematical expression is:

[0052]

[0053] Among them, g X h represents the generator. t and h t-1 g represents the latent representation (i.e., latent features) of the original input data at time steps t and t-1, respectively. X (h s ,h t-1 ,z t ) represents the potential representation of the generated data at time step t, h s z represents the potential representation of static data in the original input data. t This represents random noise input.

[0054] TimeGAN combines autoencoder networks and adversarial training to minimize three loss functions, further optimizing temporal dependencies and data distribution matching, generating a temporal dynamic distribution similar to the real data (i.e., the original input data).

[0055] In this embodiment, summer electricity load data and meteorological characteristic data at the same time step are used as a single time step sample. Multiple consecutive time step samples constitute a real time series, which is then input into the TimeGAN network, which automatically generates a random time series. During the generation process, the generation direction of the time series is adjusted by constraining the difference between the reconstructed sequence of the autoencoder network and the real time series, constraining the discriminator to correctly distinguish between the real and random time series, and constraining the potential characteristics of the random and real time series to be consistent (i.e., minimizing the three loss functions mentioned above). This ensures that the random time series generated by the model continuously approximates the data characteristics of the real time series, thus serving as an extended time series. It is worth noting that the input data in this embodiment are all time-varying data; setting the static data to 0 is sufficient.

[0056] Furthermore, in one specific implementation, the expanded time series can be used as the generated dataset and compared with the original input dataset to evaluate the effectiveness of the TimeGAN-generated data. Optionally, the evaluation can be performed from three aspects:

[0057] First, the statistical characteristics are evaluated: by comparing the statistical distribution histograms of the generated data and the real data, the global distribution characteristics of the generated data are analyzed, and the maximum, minimum and numerical distributions are compared.

[0058] Second, the evaluation of the feature dimension distribution characteristics: The t-SNE (t-distribution stochastic neighbor embedding) algorithm is used to map the high-dimensional data to a two-dimensional space for visualization. By observing the distribution relationship between the generated data and the original data in the low-dimensional space, the model's fit to the distribution of the original data is evaluated.

[0059] Thirdly, the correlation characteristics are evaluated: verification is conducted from two aspects: characteristic correlation and time-series correlation. For characteristic correlation, the Pearson correlation coefficient is used to quantify the correlation between meteorological characteristics and electricity load in the generated data, and the correspondence is compared with that in the real data to verify whether the generated data maintains the inherent correlation between meteorology and load. The time-series characteristics focus on analyzing the peak characteristics of the 24-hour load curve. By comparing the distribution of peak load values ​​and their occurrence time steps in the generated data and the real data, it is verified whether the generated data conforms to the physical characteristics and temporal patterns of electricity load.

[0060] S130. Using the expanded dataset as the sample set, the electricity load prediction model is trained. The trained model takes the time series consisting of electricity load and multiple meteorological features within a certain period as input and the electricity load of the next time step of the time series as output. It can be used to predict the electricity load in the summer high temperature heat wave scenario in advance.

[0061] This step expands, supplements, or replaces the dataset generated by the TimeGAN network into the original input set, resulting in a new input dataset, which is then fed into the prediction model for training. Figure 3 The load prediction model in this embodiment is based on BiLSTM (Bi-directional long short-term memory networks), which integrates feature attention mechanism and temporal attention mechanism. The input data is processed in the model in the following order:

[0062] S1-1. A time series consisting of electricity load data and multiple meteorological feature data is input into a feature attention layer constructed by a convolutional network. The network learns the attention weights between each input feature in the time series and uses these attention weights to correct the time series. Optionally, the convolutional network includes a global average pooling layer, a 1d (one-dimensional) convolutional layer, and an activation function layer, combined with... Figure 4 The specific steps in a convolutional network include:

[0063] Step 1: Perform global average pooling along the time dimension on the input time series to obtain the average pooling value for each input feature. That is...

[0064]

[0065] Among them, X f This represents the time series of the f-th input feature, where the input feature is either electricity load or a certain meteorological feature, f = 1, 2, ..., F, and F represents the number of input features, which is equal to the number of meteorological features + 1; g(·) represents the global average pooling operation in the time dimension, and T represents X. f The number of time steps in the middle. Represents X f Data at time step t.

[0066] Step 2: Perform a 1D convolution operation on the feature vectors formed by arranging the average pooling values ​​to obtain the weight vectors of each input feature. For example... Figure 4 As shown, the average pooling values ​​are arranged into a feature vector, and a 1×1×F 1d convolution operation is performed on the vector to obtain a vector of dimension F, where each element in the vector is the weight corresponding to each input feature.

[0067] Step 3: Perform nonlinear operations on the weight vector using an activation function to obtain the final weights of each input feature. For ease of distinction and description, the weights obtained from the 1D convolution operation are called the initial weights, and the weights obtained after the activation function are called attention weights. Each attention weight represents the importance of each input feature.

[0068] Steps two and three above can be represented by the following formula:

[0069] w=σ(conv1d k (g(X))) (5)

[0070] Where w represents the vector composed of the attention weights of each input feature, g(X) represents the feature vector composed of the average pooling values ​​of each meteorological feature, and conv1d k (·) represents a 1d convolution operation, and σ(·) represents the activation function. Optionally, the activation function can be the sigmoid function.

[0071] Step 4: Multiply the time series of each input feature by the attention weight of each input feature to obtain the corrected time series.

[0072] In summary, the feature attention layer built through a convolutional network in the predictive model analyzes the input multivariate time series and uses attention weights to calculate the importance of different feature variables, thereby mining more feature correlation information from the original data and enhancing the model's representational ability. Compared with directly defined feature weights or feature weights obtained through direct training, the feature weights in this embodiment are derived from the feature data, better reflecting the data patterns of the features themselves and offering stronger interpretability.

[0073] S1-2. Input the corrected time series data into a BiLSTM network to learn the attention weights between each time step, and use these attention weights to obtain contextual features. This step, through the bidirectional structure of the BiLSTM, captures and preserves long-term dependency features in the load, enabling the model to better fit the peak and trough variations of the load. Optionally, combine... Figure 5 and Figure 6 The process may include the following steps:

[0074] Step 1: Input the corrected time series into the BiLSTM network, and extract the forward and backward hidden states of the BiLSTM network at each time step. Then, fuse the forward and backward hidden states at each time step to obtain the final hidden state at each time step. Specifically, the BiLSTM output calculation formula is as follows:

[0075]

[0076] Where, xt This represents the vector of the corrected time series at time step t. and Let f(·) represent the forward and backward hidden states of the BiLSTM network at time step t, respectively, and let f(·) represent the activation function. and These represent the forward and backward weight matrices from the input data to the hidden layer, respectively. and Let represent the forward weight matrix and the reverse weight matrix from the hidden state at time step t-1 to the hidden state at time step t, respectively. and These represent the positive bias term and the negative bias term, respectively.

[0077] The final hidden state h after splicing t It can be represented as:

[0078]

[0079] Here, conn(·) represents the vector concatenation operation.

[0080] Step 2: In the temporal attention layer, the correlation between each time step and the current time step is calculated using the final hidden state, and normalized to obtain the attention weight of each time step relative to the current time step; the final hidden state of each time step is weighted using each attention weight to obtain the contextual features of the current time step. Combined with... Figure 6 The operations in the temporal attention layer can be represented as follows:

[0081]

[0082] s t =v T (w·h t +b s (10)

[0083]

[0084] Among them, s t a represents the correlation score between time step t and the current time step. t h represents the attention weight of time step t relative to the current time step. t Let v represent the final hidden state at time step t, where v and w are both learnable parameter matrices; b s c represents the deviation vector; t Let represent the context vector at time step t, softmax(·) represent the activation function, and exp(·) represent the exponential function with base e.

[0085] In summary, S1-2 utilizes BiLSTM and temporal attention mechanisms to further learn the importance of different time steps, enhancing the model's understanding of temporal dynamics. The input sequence is processed by BiLSTM to obtain the final hidden state at each time step. For the prediction at the current time step, the correlation between the final hidden state at each previous time step and the current time step is calculated and then normalized to obtain attention weights. The attention weights are then used to perform a weighted summation of all the final hidden states to obtain the context feature vector. The context feature vector represents the comprehensive expression of the historical information that the model focuses on at the current time step.

[0086] S1-3. Utilize the aforementioned contextual features to predict the electricity load for the next time step of the time series. Optionally, combine... Figure 6 The context feature vector is combined with the final hidden state at the current time step to generate the final output H. t Then H t The predicted power load is output through mapping by the fully connected layer. The combination of the context feature vector and the final hidden state at the current time step can be either vector concatenation or weighted fusion; this embodiment does not impose specific limitations.

[0087] The network parameters in S1-1 to S1-3 above can be jointly trained, that is: using the expanded dataset as the sample set, the meteorological characteristic data of the same time period in each sample is input into the electricity load prediction model, and the network parameters of the 1d convolution operation, BiLSTM network, temporal attention layer, fully connected layer, etc. are jointly trained so that the output of the model continuously approximates the electricity load data of the next time step of the corresponding time period of each sample.

[0088] Furthermore, after the model training is complete, the mean absolute error percentage (MAPE), root mean square error (RMSE), and multiple coefficient of determination (R²) can be selected. 2 As an indicator, it is used to evaluate the model's accuracy. After the model is validated, feature attention weights and temporal attention weights can be output separately to analyze which features and time steps are more important in the model's prediction, thereby enhancing the model's interpretability. At the same time, it can also verify whether the model is consistent with domain knowledge, thereby enhancing the model's credibility.

[0089] In summary, this embodiment provides a method for constructing an electricity load forecasting model for summer heat waves, which can achieve the following beneficial effects:

[0090] 1. Conventional load forecasting methods require a large amount of historical data. However, in response to the problem of insufficient historical samples under extreme high-temperature scenarios, this embodiment adopts the TimeGAN method to expand the limited sample dataset under heat wave conditions. This solves the problem of low load forecasting accuracy caused by dataset imbalance and improves the forecasting accuracy of electricity load under summer high-temperature scenarios.

[0091] 2. Due to the "black box" nature of deep learning, the reliability of typical prediction models is low. This embodiment integrates domain knowledge into the Bi LSTM neural network through a dual attention mechanism, while capturing the correlation between input features (such as the synergistic effect of temperature and humidity on load) and temporal dynamic changes. This not only improves the accuracy of model predictions but also evaluates the impact of input features and time series on prediction results. Furthermore, it enhances the interpretability of the model by visually presenting the attention weights of preliminary explanatory features and time.

[0092] Based on the above prediction model Figure 7 This is a flowchart of a method for predicting electricity load in summer heatwave scenarios provided by an embodiment of the present invention. Figure 7 As shown, the method includes:

[0093] S210. Obtain summer electricity load data and meteorological characteristic data for the area to be predicted.

[0094] S220. Input the time series composed of the electricity load data and meteorological characteristic data into the electricity load prediction model constructed using the method of any of the above embodiments to obtain the electricity load of the next time step of the time series.

[0095] It is worth mentioning that this embodiment is based on the same inventive concept as any of the above embodiments and can achieve the beneficial effects of any of the above embodiments, which will not be repeated here.

[0096] Furthermore, in one specific implementation, a city in Fujian Province was used as the experimental subject, and historical data from January 2021 to August 2022 was used for prediction verification. The dataset includes hourly sampled measured values ​​of electricity load and nine types of meteorological characteristic values, all with a time resolution of 1 hour. Summer data from June to September 2021 was selected as the training set, and data from July to August 2022 was used as the test set. Multidimensional feature filtering was performed on the dataset to select meteorological characteristics that were strongly correlated with both linear and nonlinear properties of the historical load data. In this embodiment, the selected meteorological characteristics are: temperature, humidity, temperature-humidity index, perceived temperature, perceived temperature, and human comfort level.

[0097] Based on these strongly correlated and load data, TimGAN was used for data augmentation, referring to... Figure 8 It can be seen that the generated data has a high degree of similarity to the real historical data, which can effectively improve the model's generalization ability and prediction accuracy in high-temperature scenarios. Figure 8 The coordinate axes t-SNE 1 and t-SNE 2 in the figure are the two dimensions of the two-dimensional space obtained by t-SNE mapping.

[0098] The expanded dataset was then used as a new training set for model training and prediction. Figure 9 The comparison chart of prediction results is shown, where the horizontal axis "Time" represents time, the vertical axis "Load" represents the predicted electricity load value, "Real" represents the actual data, "CNN" corresponds to the convolutional neural network model trained using the unexpanded sample set, and "TimeGAN-Dual Attention-BiLSTM" corresponds to the prediction model consisting of a spatial attention layer + BiLSTM + temporal attention layer + fully connected layer trained using the expanded sample set of TimeGAN, which is the prediction model corresponding to the complete method in this embodiment. The other models correspond to the prediction results obtained by omitting one or more steps from the construction method of this embodiment. "TA-BiLSTM" corresponds to the prediction model consisting of BiLSTM, temporal attention layer and fully connected layer trained using the unexpanded sample set, "FA-BiLSTM" corresponds to the prediction model consisting of a spatial attention layer, BiLSTM and fully connected layer trained using the unexpanded sample set, and "DualAttention-BiLSTM" corresponds to the prediction model consisting of a spatial attention layer, BiLSTM, temporal attention layer and fully connected layer trained using the unexpanded sample set. As can be seen, this embodiment significantly improves prediction accuracy compared to other models by using TimeGAN sample augmentation and dual-attention BiLSTM.

[0099] Figure 10 This is a schematic diagram of the structure of an electronic device provided in an embodiment of the present invention, such as... Figure 10 As shown, the device includes a processor 60, a memory 61, an input device 62, and an output device 63; the number of processors 60 in the device can be one or more. Figure 10 Taking a processor 60 as an example; the processor 60, memory 61, input device 62, and output device 63 in the device can be connected via a bus or other means. Figure 10 The bus connection is taken as an example.

[0100] The memory 61, as a computer-readable storage medium, can be used to store software programs, computer-executable programs, and modules, such as the program instructions / modules corresponding to the method for constructing an electricity load forecasting model for summer high-temperature heat wave scenarios in this embodiment of the invention. The processor 60 executes various functional applications and data processing of the device by running the software programs, instructions, and modules stored in the memory 61, thereby realizing the aforementioned method for constructing an electricity load forecasting model for summer high-temperature heat wave scenarios.

[0101] The memory 61 may primarily include a program storage area and a data storage area. The program storage area may store the operating system and at least one application program required for a given function; the data storage area may store data created based on terminal usage. Furthermore, the memory 61 may include high-speed random access memory and non-volatile memory, such as at least one disk storage device, flash memory, or other non-volatile solid-state storage device. In some instances, the memory 61 may further include memory remotely located relative to the processor 60, which can be connected to the device via a network. Examples of such networks include, but are not limited to, the Internet, intranets, local area networks, mobile communication networks, and combinations thereof.

[0102] Input device 62 can be used to receive input digital or character information, and to generate key signal inputs related to user settings and function control of the device. Output device 63 may include display devices such as a display screen.

[0103] This invention also provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the method for constructing an electricity load prediction model for summer high-temperature heat wave scenarios according to any embodiment.

[0104] The computer storage medium of this invention can be any combination of one or more computer-readable media. A computer-readable medium can be a computer-readable signal medium or a computer-readable storage medium. A computer-readable storage medium can be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination thereof. More specific examples of computer-readable storage media (a non-exhaustive list) include: an electrical connection having one or more wires, a portable computer disk, a hard disk, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage device, magnetic storage device, or any suitable combination thereof. In this document, a computer-readable storage medium can be any tangible medium that contains or stores a program that can be used by or in conjunction with an instruction execution system, apparatus, or device.

[0105] Computer-readable signal media may include data signals propagated in baseband or as part of a carrier wave, carrying computer-readable program code. Such propagated data signals may take various forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination thereof. Computer-readable signal media may also be any computer-readable medium other than computer-readable storage media, capable of sending, propagating, or transmitting programs for use by or in connection with an instruction execution system, apparatus, or device.

[0106] Program code contained on a computer-readable medium may be transmitted using any suitable medium, including but not limited to wireless, wire, optical fiber, RF, etc., or any suitable combination thereof.

[0107] Computer program code for performing the operations of this invention can be written in one or more programming languages ​​or a combination thereof. Programming languages ​​include object-oriented programming languages—such as Java, Smalltalk, and C++—as well as conventional procedural programming languages—such as C or similar programming languages. The program code can be executed entirely on the user's computer, partially on the user's computer, as a standalone software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving remote computers, the remote computer can be connected to the user's computer via any type of network, including a local area network (LAN) or a wide area network (WAN), or it can be connected to an external computer (e.g., via the Internet using an Internet service provider).

[0108] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, and not to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some or all of the technical features; and these modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the technical solutions of the embodiments of the present invention.

Claims

1. A method for constructing an electricity load prediction model for summer heat waves, characterized in that: include: Obtain summer electricity load data and meteorological characteristic data for the area to be predicted; The summer electricity load data and meteorological characteristic data were expanded using the TimeGAN network; Using the expanded dataset as the sample set, the electricity load prediction model is trained, wherein the following steps are performed in the electricity load prediction model: S1-1. Input the time series consisting of summer electricity load data and multiple meteorological feature data into the feature attention layer composed of a convolutional network, learn the attention weights between each input feature in the time series, and use each attention weight to correct the time series to obtain the corrected time series. S1-2. Input the corrected time series into the Bi LSTM network and the temporal attention layer in sequence to learn the attention weights between each time step, and use the attention weights between each time step to obtain the context features. S1-3. Using the context features, predict the electricity load at the next time step of the time series.

2. The method according to claim 1, characterized in that: Obtain summer electricity load data and meteorological characteristic data for the area to be predicted, including: Acquire multiple single meteorological feature data of the area to be predicted, wherein the multiple single meteorological features include temperature, humidity, wind speed, solar radiation, and rainfall; Based on the multiple single meteorological feature data, multiple comprehensive meteorological feature data are generated, wherein the multiple comprehensive meteorological feature data include greenhouse index, perceived temperature, perceived temperature, and human comfort level. Based on the correlation with the summer electricity load data of the area to be predicted, multiple single meteorological feature data and multiple comprehensive meteorological feature data are screened, and the screened meteorological feature data is used as the final meteorological feature data.

3. The method according to claim 1, characterized in that: The method of using a TimeGAN network to augment the summer electricity load data and meteorological characteristic data includes: The real time series composed of the summer electricity load data and meteorological characteristic data is input into the TimeGAN network, and the TimeGAN network automatically generates random time series. During the generation process, the difference between the reconstructed sequence of the constrained autoencoder and the real time series is minimized, the discriminator is constrained to correctly distinguish between the real time series and the random time series, and the potential features of the random time series are constrained to be consistent with those of the real time series, so that the random time series continuously approaches the data characteristics of the real time series. The random time series was used as supplementary summer electricity load data and meteorological characteristic data.

4. The method according to claim 1, characterized in that: The method of using a TimeGAN network to augment the summer electricity load data and meteorological characteristic data includes: The real time series composed of the summer electricity load data and meteorological characteristic data are input into the TimeGAN network, and the TimeGAN network automatically generates random time series that are consistent with the characteristics of each real time series data. Statistical characteristics, feature dimension distribution characteristics, and correlation characteristics of each random time series are evaluated to verify whether each random time series conforms to the physical characteristics and temporal patterns of power load.

5. The method according to claim 1, characterized in that: Step S1-1 specifically includes the following steps: S1-1-1. Perform global average pooling on the time dimension of the time series composed of electricity load data and multiple meteorological feature data to obtain the average pooling value of each input feature in the time series. S1-1-2. Perform 1D convolution operation on the features formed by arranging the average pooling values ​​of each input feature to obtain the initial weight vector of each input feature, and use the activation function to perform nonlinear operation on the initial weight vector of each input feature to obtain the attention weight between each input feature. S1-1-3. Multiply the time series of each input feature by the attention weight of each input feature to obtain the corrected time series.

6. The method according to claim 5, characterized in that: The specific steps S1-1-1 are as follows: According to formula (1), the average pooling value of each input feature in the time series composed of electricity load data and multiple meteorological feature data is obtained; Formula (1) is expressed as follows: Among them, X f Let g(·) represent the time series of the f-th input feature, where the input feature is either electricity load or a certain meteorological feature; g(·) represents the global average pooling operation in the time dimension, and T represents X. f The number of time steps in the middle. X represents f Data at time step t; The specific steps S1-1-2 are as follows: A 1D convolution operation is performed on the features formed by arranging the average pooling values ​​of each input feature to obtain the initial weight vector of each input feature. Then, an activation function is used to perform a non-linear operation on the initial weight vectors of each input feature to obtain the attention weights between the input features, including: The attention weights among the input features are obtained using the following formula: w=σ(conv1d k (g(X))) Where w represents the vector composed of attention weights for each input feature, g(X) represents the feature formed by arranging the average pooling values ​​of each input feature, and conv1d k (·) represents 1d convolution operation, and σ(·) represents activation function.

7. The method according to claim 1, characterized in that: Step S1-2 specifically includes the following steps: S1-2-1. Input the corrected time series into the BiLSTM network and extract the forward hidden state and backward hidden state of the BiLSTM network at each time step. S1-2-2: Merge the forward and reverse hidden states of each time step to obtain the final hidden state of each time step; S1-2-3. In the temporal attention layer, the correlation between each time step and the current time step is calculated using the final hidden state, and the attention weight of each time step relative to the current time step is normalized. The final hidden state of each time step is weighted using the attention weight of each time step relative to the current time step to obtain the context features of the current time step.

8. The method according to claim 7, characterized in that: The specific steps S1-2-3 are as follows: The contextual features of the current time step can be obtained using the following formula: s t =v T (w·h t +b s ) Among them, s t a represents the correlation score between time step t and the current time step. t h represents the attention weight of time step t relative to the current time step. t Let v represent the final hidden state at time step t, where v and w are both learnable parameter matrices; b s c represents the deviation vector; t Let represent the context vector at time step t, softmax(·) represent the activation function, and exp(·) represent the exponential function with base e.

9. A method for predicting electricity load in summer heat waves, characterized in that: include: Obtain summer electricity load data and meteorological characteristic data for the area to be predicted; The time series consisting of the electricity load data and meteorological characteristic data is input into the electricity load prediction model constructed using the method described in any one of claims 1-8 to obtain the electricity load at the next time step of the time series.

10. An electronic device, characterized in that: include: One or more processors; Memory, used to store one or more programs. When the one or more programs are executed by the one or more processors, the one or more processors implement the method for constructing an electricity load forecasting model for summer high temperature heat wave scenarios as described in any one of claims 1-8, and / or the method for forecasting electricity load for summer high temperature heat wave scenarios as described in claim 9.