Multi-source power outage prediction model construction method, system, terminal and storage medium

Through multi-source data integration and a two-layer model structure, a power outage prediction model that comprehensively considers meteorological and power consumption factors is constructed, which solves the shortcomings of single-factor early warning in the existing technology, improves the comprehensiveness and accuracy of power outage prediction, and enhances improve the reliability of early warning.

CN118503716BActive Publication Date: 2024-10-22TAIAN POWER SUPPLY CO OF STATE GRID SHANDONG ELECTRIC POWER CO +2
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410963062.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-07-18
Publication Date
2024-10-22
Estimated Expiration
2044-07-18

AI Technical Summary

Technical Problem

Existing power outage risk early warning technology is mainly based on the monitoring and analysis of a single factor, which cannot comprehensively assess power outage risks, resulting in low accuracy of early warning, false alarms and underreporting, which affects the timeliness and effectiveness of emergency measures.

Method used

Using a multi-source power outage prediction model construction method, by acquiring meteorological data, power grid operation data and power outage record data in the Taiwan area, mining relevant feature items, and constructing a power outage prediction model including the first sub-model and the second sub-model, using the TimeGAN model and Bei The Yeasian neural network performs data expansion and prediction, and combines Pearson correlation coefficient and kernel density function to filter feature data to improve the accuracy of the prediction model.

Benefits of technology

It improves the comprehensiveness and accuracy of power outage prediction, comprehensively considers meteorological and power consumption data through a two-layer model structure, enhances the pertinence and reliability of early warning, and reduces the rate of false alarms and omissions.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118503716B_ABST
    Figure CN118503716B_ABST
Patent Text Reader

Abstract

The present invention relates to the field of machine learning technology, and specifically provides a method, system, terminal and storage medium for constructing a multi-source power outage prediction model, including: obtaining substation meteorological data, power grid operation data and power outage record data; mining feature items in the substation meteorological data and power grid operation data that are correlated with the power outage record data, and filtering out training data from the substation meteorological data and power grid operation data based on the feature items; expanding the training data to obtain a data set; constructing a power outage prediction model, the power outage prediction model including a first sub-model and a second sub-model, the output parameter of the first sub-model is a power grid operation characteristic value, and the input layer of the second sub-model includes a power grid operation characteristic value and a meteorological characteristic value; using the data set to train the power outage prediction model to obtain a multi-source power outage prediction model. The present invention comprehensively considers various factors that affect power outages, thereby improving the comprehensiveness of power outage prediction.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the technical field of machine learning, and in particular relates to a method, system, terminal and storage medium for constructing a multi-source power outage prediction model. Background Art

[0002] With the continuous development of society and the advancement of science and technology, electricity has become an indispensable infrastructure in modern society. However, power outages have a serious impact on people's lives and production, which not only causes huge losses to the economy, but also may have a serious impact on public safety and social stability. Therefore, it is particularly important to warn of power outage risks.

[0003] The existing power outage risk warning technologies mainly include the following categories:

[0004] Early warning system based on meteorological factors: This system usually uses meteorological data, such as thunderstorms, strong winds, ice and snow, to warn of possible impacts on the power grid. Typical applications include using radar and satellite data to predict thunderstorm activities and using wind speed sensors to monitor strong winds.

[0005] Early warning system based on load forecasting: By analyzing historical load data and electricity consumption patterns, future load changes are predicted and early warnings are issued based on the prediction results. For example, big data analysis technology is used to perform trend analysis and short-term forecasts on power loads to determine possible future load peaks and fluctuations.

[0006] To sum up, the current power outage risk warning is usually based on the monitoring and analysis of a single factor. This single-factor warning method easily ignores other factors that may cause power outages, fails to comprehensively assess the risk of power outages, and the warning accuracy is not high. There are cases of false alarms and missed alarms, which affects the timeliness and effectiveness of emergency measures. Summary of the invention

[0007] In view of the above-mentioned deficiencies in the prior art, the present invention provides a method, system, terminal and storage medium for constructing a multi-source power outage prediction model to solve the above-mentioned technical problems.

[0008] In a first aspect, the present invention provides a method for constructing a multi-source power outage prediction model, comprising:

[0009] Obtain area meteorological data, power grid operation data and power outage record data;

[0010] Mining feature items in the area meteorological data and the power grid operation data that are correlated with the power outage record data, and filtering out training data from the area meteorological data and the power grid operation data based on the feature items;

[0011] Expanding the training data to obtain a data set;

[0012] Constructing a power outage prediction model, the power outage prediction model comprising a first sub-model and a second sub-model, the output parameter of the first sub-model being a power grid operation characteristic value, and the input layer of the second sub-model comprising a power grid operation characteristic value and a meteorological characteristic value;

[0013] The power outage prediction model is trained using the data set to obtain a multi-source power outage prediction model.

[0014] In an optional implementation, mining feature items in the area meteorological data and the power grid operation data that are correlated with the power outage record data, and filtering out training data from the area meteorological data and the power grid operation data based on the feature items, including:

[0015] Meteorological sample data is collected based on the meteorological data of the station area, and the meteorological sample data includes weekly average wind speed, weekly maximum wind speed, weekly average rainfall, weekly maximum rainfall, number of thunderstorm days in a week, weekly average temperature, and weekly average humidity;

[0016] Analyze the operation sample data based on the power grid operation data, the operation sample data includes the monthly maximum load rate, monthly minimum load rate, monthly no-load occurrence times, monthly light load occurrence times, monthly overload occurrence times, monthly maximum three-phase imbalance, monthly three-phase imbalance occurrence times, monthly load rate, and monthly peak-to-valley difference rate of each user;

[0017] Analyze power outage sample data based on power outage record data, wherein the power outage sample data includes the number of power outages per week in the substation area and the number of power outages per month for a single user;

[0018] Pre-processing of meteorological sample data, operation sample data and power outage sample data;

[0019] Calculate the Pearson correlation coefficient of the preprocessed meteorological sample data, operation sample data and power outage sample data, and select the characteristic items based on the correlation coefficient;

[0020] Feature data corresponding to the feature items are extracted from the substation meteorological data and power grid operation data, and power outage records in the same time dimension as the feature data are extracted, and the extracted data are saved as training data, where the time scale of the training data is day.

[0021] In an optional implementation, the training data is expanded to obtain a data set, including:

[0022] Setting a corresponding noise level for each feature item, and generating random noise for the feature item based on the noise level;

[0023] For each power outage event sample, traverse all its feature values ​​and add the corresponding random noise to the corresponding feature value to obtain a new sample;

[0024] Generate simulated data based on the new sample using a TimeGAN model;

[0025] The kernel density function is used to calculate the high-density data area of ​​the data distribution of each feature, and the simulated data in the high-density data area is screened out as valid data;

[0026] The valid data is added to the new sample to obtain a data set.

[0027] In an optional embodiment, the first sub-model includes:

[0028] The stacking model includes an LSTM model and an XGBoost model.

[0029] In an optional embodiment, the second sub-model is a Bayesian neural network model, and the input layer of the Bayesian neural network model includes power grid operation characteristic values ​​and meteorological characteristic values;

[0030] The first sub-model and the second sub-model are in the TensorFlow framework.

[0031] In a second aspect, the present invention provides a multi-source power outage prediction model construction system, comprising:

[0032] Data acquisition module, used to obtain area meteorological data, power grid operation data and power outage record data;

[0033] A feature mining module is used to mine feature items related to the power outage record data in the substation meteorological data and the power grid operation data, and to filter out training data from the substation meteorological data and the power grid operation data based on the feature items;

[0034] A data expansion module, used to expand the training data to obtain a data set;

[0035] A model building module, used to build a power outage prediction model, the power outage prediction model includes a first sub-model and a second sub-model, the output parameter of the first sub-model is a power grid operation characteristic value, and the input layer of the second sub-model includes a power grid operation characteristic value and a meteorological characteristic value;

[0036] The model training module is used to train the power outage prediction model using the data set to obtain a multi-source power outage prediction model.

[0037] In an optional embodiment, the feature mining module includes:

[0038] A meteorological statistics unit is used to collect meteorological sample data based on the meteorological data of the station area, wherein the meteorological sample data includes weekly average wind speed, weekly maximum wind speed, weekly average rainfall, weekly maximum rainfall, number of thunderstorm days in a week, weekly average temperature, and weekly average humidity;

[0039] An operation statistics unit is used to analyze operation sample data based on power grid operation data, wherein the operation sample data includes the monthly maximum load rate, monthly minimum load rate, monthly no-load occurrence times, monthly light-load occurrence times, monthly overload occurrence times, monthly maximum three-phase imbalance, monthly three-phase imbalance occurrence times, monthly load rate, and monthly peak-to-valley difference rate of each user;

[0040] A power outage statistics unit, used to parse power outage sample data based on the power outage record data, wherein the power outage sample data includes the number of power outages per week in the substation area and the number of power outages per month for a single user;

[0041] A preprocessing unit, used for preprocessing meteorological sample data, operation sample data and power outage sample data;

[0042] A correlation calculation unit, used to calculate the Pearson correlation coefficient of the pre-processed meteorological sample data, the operation sample data and the power outage sample data, and to screen out characteristic items based on the correlation coefficient;

[0043] The data advance unit is used to extract feature data corresponding to feature items from the substation meteorological data and power grid operation data, and extract power outage records in the same time dimension as the feature data, and save the extracted data as training data, where the time scale of the training data is day.

[0044] In an optional embodiment, the first sub-model includes:

[0045] The stacking model includes an LSTM model and an XGBoost model.

[0046] In a third aspect, a terminal is provided, including:

[0047] processor, memory, wherein:

[0048] The memory is used to store computer programs.

[0049] The processor is used to call and run the computer program from the memory, so that the terminal executes the above-mentioned terminal method.

[0050] In a fourth aspect, a computer storage medium is provided, wherein the computer-readable storage medium stores instructions, and when the computer-readable storage medium is run on a computer, the computer executes the methods described in the above aspects.

[0051] The beneficial effect of the present invention is that the multi-source power outage prediction model construction method, system, terminal and storage medium provided by the present invention comprehensively consider various factors affecting power outages, thereby improving the comprehensiveness of power outage prediction. In addition, the number of training samples is increased by mining features and expanding training samples. In addition, through a two-layer model structure, power outage prediction based on meteorological data and power consumption data is realized.

[0052] In addition, the invention has a reliable design principle, a simple structure and a very broad application prospect. BRIEF DESCRIPTION OF THE DRAWINGS

[0053] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.

[0054] Figure 1 is a schematic flow chart of a method according to an embodiment of the present invention.

[0055] Figure 2 is a schematic block diagram of a system according to an embodiment of the present invention.

[0056] Figure 3 A schematic diagram of the structure of a terminal provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0057] In order to enable those skilled in the art to better understand the technical solutions in the present invention, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of the present invention.

[0058] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as those commonly understood by those skilled in the art of the present invention. The terms used in the specification of the present invention herein are only for the purpose of describing specific embodiments and are not intended to limit the present invention.

[0059] The multi-source power outage prediction model construction method provided by the embodiment of the present invention is executed by a computer device, and accordingly, the multi-source power outage prediction model construction system runs in the computer device.

[0060] Figure 1 is a schematic flow chart of a method according to an embodiment of the present invention. Figure 1The execution subject can build a system for a multi-source power outage prediction model. According to different requirements, the order of the steps in the flow chart can be changed, and some can be omitted.

[0061] like Figure 1 As shown, the method includes:

[0062] Step 110, obtaining the area meteorological data, power grid operation data and power outage record data;

[0063] Step 120, mining feature items in the area meteorological data and the power grid operation data that are correlated with the power outage record data, and filtering out training data from the area meteorological data and the power grid operation data based on the feature items;

[0064] Step 130, expanding the training data to obtain a data set;

[0065] Step 140, constructing a power outage prediction model, the power outage prediction model comprising a first sub-model and a second sub-model, the output parameter of the first sub-model being a power grid operation characteristic value, and the input layer of the second sub-model comprising a power grid operation characteristic value and a meteorological characteristic value;

[0066] Step 150: Use the data set to train the power outage prediction model to obtain a multi-source power outage prediction model.

[0067] To facilitate understanding of the present invention, the multi-source power outage prediction model construction method provided by the present invention is further described below based on the principle of the multi-source power outage prediction model construction method of the present invention and the process of constructing the multi-source power outage prediction model in the embodiment.

[0068] Specifically, the method for constructing a multi-source power outage prediction model includes:

[0069] S1. Obtain the substation meteorological data, power grid operation data and power outage record data.

[0070] Collect recent meteorological data of the substation area from the meteorological bureau, meteorological station or other reliable sources (including weekly average wind speed, weekly maximum wind speed, weekly average rainfall, weekly maximum rainfall, number of days with thunderstorms in a week, weekly average temperature, weekly average humidity, etc.). Obtain power operation data of each user in the substation area from the power company, power grid management department or other relevant institutions (including load data, active power, reactive power, distribution transformer rated capacity, maximum phase current, minimum phase current, etc.).

[0071] The total number of power outages per week for all users in the area and the number of power outages per month for a single user in recent years are calculated from the power company's power outage record system and user repair records.

[0072] Obtain grid operation data from the power company's grid monitoring system.

[0073] S2. Mining feature items in the substation meteorological data and the power grid operation data that are correlated with the power outage record data, and filtering out training data from the substation meteorological data and the power grid operation data based on the feature items.

[0074] (1) Meteorological sample data are collected based on the meteorological data of the substation area, and the meteorological sample data include weekly average wind speed, weekly maximum wind speed, weekly average rainfall, weekly maximum rainfall, number of thunderstorm days in a week, weekly average temperature, and weekly average humidity.

[0075] (2) Analyze operation sample data based on power grid operation data, wherein the operation sample data includes the monthly maximum load rate, monthly minimum load rate, monthly no-load occurrence times, monthly light-load occurrence times, monthly overload occurrence times, monthly maximum three-phase imbalance, monthly three-phase imbalance occurrence times, monthly load rate, and monthly peak-to-valley difference rate of each user.

[0076] The load rate calculation formula is:

[0077]

[0078] According to the standards of State Grid Corporation, the load status is judged as follows:

[0079] No-load state: 0<load rate<5%;

[0080] Light load state: 5% ≤ load rate <20%;

[0081] Heavy load state: 80% ≤ load rate ≤ 100%.

[0082] Three-phase imbalance will seriously affect the reliability and stability of the low-voltage power grid. The degree of three-phase imbalance is expressed by introducing the three-phase current imbalance. The evaluation formula is:

[0083]

[0084] If the three-phase imbalance degree at a certain moment is greater than 25%, it is determined that three-phase imbalance occurs in the substation at this time.

[0085] The load evaluation index is also used to assess the utilization of power grid equipment. The two load evaluation index formulas referenced by this method are:

[0086] ;

[0087] .

[0088] (3) Analyzing power outage sample data based on the power outage record data, wherein the power outage sample data includes the number of power outages per week in the substation area and the number of power outages per month for a single user.

[0089] (4) Preprocess the meteorological sample data, operation sample data and power outage sample data.

[0090] Missing value handling: Check if there are missing values ​​in the data. If there are, you can choose to fill the missing values ​​or delete the data records containing missing values. The filling method can be using the mean, median, mode, etc.

[0091] Outlier processing: Detect and process outliers to ensure data accuracy. Outliers may affect the results of correlation analysis. Common outlier processing methods include truncation, replacement, deletion, etc.

[0092] Data normalization: Normalize all feature data to have similar scales. This helps avoid unnecessary effects of features of different magnitudes on correlation analysis. Common normalization methods include Z-score normalization and minimum-maximum normalization.

[0093] (5) Calculate the Pearson correlation coefficient of the preprocessed meteorological sample data, operation sample data, and power outage sample data, and filter out feature items based on the correlation coefficient.

[0094] The Pearson correlation coefficient was used to analyze the correlation between meteorological characteristics and the total number of weekly power outages for all users in the substation area. The Pearson correlation coefficient was used to analyze the correlation between user monthly load characteristics and the number of monthly power outages for a single user.

[0095] Calculate the Pearson correlation coefficient, ,in, and are the observed values ​​of the ith feature and the observed values ​​of the number of weekly power outages, is the mean of the ith feature, is the mean of the weekly power outage times. The correlation strength and direction of each feature and the weekly power outage times are determined by the positive and negative correlation coefficient and the absolute value. |r|=1 indicates a complete linear correlation, |r|=0 indicates no linear correlation, r>0 indicates a positive correlation, and r<0 indicates a negative correlation.

[0096] 1.5.2 The strength and direction of the correlation are determined based on the positive and negative sign and absolute value of the correlation coefficient, and features with an absolute value of the correlation coefficient greater than or equal to 0.3 are selected as features that affect power outage events.

[0097] (6) Extracting feature data corresponding to the feature items from the substation meteorological data and power grid operation data, and extracting power outage records in the same time dimension as the feature data, and saving the extracted data as training data, wherein the time scale of the training data is daily.

[0098] Pearson correlation analysis was used to screen out multiple features with strong correlation with power outage events, which reduced the interference of irrelevant factors and improved the accuracy and pertinence of early warning. The perfect data preprocessing steps ensured data quality, reduced the impact of errors, and provided a reliable basis for subsequent analysis and modeling.

[0099] S3. Expand the training data to obtain a data set.

[0100] S301. Set a corresponding noise level for each feature item, and generate random noise for the feature item based on the noise level; for each power outage event sample, traverse all its feature values, and add the corresponding random noise to the corresponding feature value to obtain a new sample.

[0101] The time scale of the features selected by the correlation analysis is changed to daily, such as daily average wind speed, daily average rainfall, daily average temperature, daily average humidity, daily maximum load rate, daily three-phase imbalance occurrence times, daily load rate, daily peak-to-valley difference rate, and whether a power outage occurs on that day is used as a label (power outage is 1, no power outage is 0).

[0102] Since there are too few power outage events in the actual data and there is a sample imbalance problem, by adding noise to the minority class samples (i.e., power outage event samples) when training the model, we can simulate the uncertainty and changes in the real environment and help the model learn more robust feature representations.

[0103] Determine the noise level. For each feature, you need to set an appropriate noise level to ensure that the generated noise can simulate the uncertainty of the real environment without excessively distorting the original data. First, observe and analyze the magnitude and range of each feature to understand the distribution of the feature data. According to the magnitude of the feature, select a smaller standard deviation as the initial noise level. For example, if the feature value is usually in the range of [0, 1], you can set a smaller standard deviation, such as 0.05 or 0.1.

[0104] Generate noise. For each feature, generate random noise from a Gaussian distribution with a mean of 0 and a standard deviation of the determined noise level. Make sure that the generated noise follows a normal distribution and that the noise level meets the pre-set standard deviation.

[0105] Add noise, add the generated random noise to the feature value of the original power outage event sample to generate a new enhanced sample. For each power outage event sample, traverse all its feature values ​​and add the corresponding random noise value to these feature values. Replace the original feature value with the feature value after adding noise to obtain a new enhanced sample.

[0106] Limit the feature range. In order to ensure that the generated data conforms to the actual situation, it is necessary to limit the range of the feature values ​​after adding noise. For feature values ​​that exceed the reasonable range after adding noise, truncation or scaling is required. For example, if a feature value exceeds the range of [0, 1], it can be truncated to 0 or 1 (or the closest boundary value), or scaled to this range. If a sample becomes invalid after adding noise and range restriction (for example, some feature values ​​do not meet physical constraints), the sample needs to be removed from the dataset.

[0107] S302: Generate enhanced data based on the new sample using a TimeGAN model.

[0108] Building the TimeGAN model:

[0109] Generator: The generator network is responsible for generating new time series data. It usually uses a recurrent neural network (RNN) or its variants (such as LSTM, GRU) to capture the temporal dependencies in the time series.

[0110] Discriminator: The discriminator network is responsible for distinguishing between real data and generated data. It usually uses a convolutional neural network (CNN) or RNN to extract features of the data and uses a classifier to make decisions.

[0111] Embedding Network: In some implementations of TimeGAN, an embedding network is also included to embed the original time series data into a low-dimensional space so that the generator and discriminator can better process it.

[0112] Training the TimeGAN model:

[0113] Set hyperparameters: Configure the model's hyperparameters, such as learning rate, batch size, number of iterations, etc.

[0114] Training process: Use real time series data to train the TimeGAN model. During the training process, the generator network tries to generate data that is as similar as possible to the real data, while the discriminator network tries to distinguish between the real data and the generated data. Through continuous iteration and optimization, the generator network gradually improves the quality of its generated data.

[0115] S303. Calculate the data distribution peak of each feature using the kernel density function; determine whether the distribution peak exists in the training data, and mark the distribution peak that is not in the training data as an invalid peak; delete the enhanced data corresponding to the invalid peak, and add the remaining enhanced data to the new sample to obtain a data set.

[0116] Kernel Density Estimation (KDE) is a nonparametric method for estimating probability density functions. and The probability density function and cumulative distribution function of all data values ​​of a certain feature are respectively drawn from the population n Independent and identically distributed data , whose sample value is , then in x KDE value of the distribution function at for: , where is the selected KDE kernel function, h is bandwidth;

[0117] The kernel function is a Gaussian kernel function, that is: ;

[0118] The bandwidth uses the optimal fixed bandwidth ; Estimated probability density distribution by using integrated mean square error evaluation and the true probability density distribution The error is taken as the constraint condition to calculate the optimal fixed bandwidth.

[0119] The optimal fixed bandwidth Substitution , and Perform integration. Set a threshold to define the "high density" area. This threshold can be determined based on data characteristics, application requirements, or experience. The area exceeding the threshold in the KDE result is considered a high density area.

[0120] Because they belong to the same feature, they are one-dimensional data. For one-dimensional data, the data points corresponding to the high-density area in the KDE results can be directly extracted from the original data set.

[0121] KDE uses a statistical method to determine high-density data areas. If the data generated by TimeGAN is located in the high-density area of ​​KDE, it is closer to the distribution of the original data and the quality of the generated data is higher. Otherwise, it is believed that the generated data has a certain deviation from the distribution of the original data and the quality of the generated data is relatively low.

[0122] In actual data, there are often fewer power outage events, which leads to sample imbalance. To solve this problem, the present invention expands the sample by adding noise to the minority class samples (i.e., power outage event samples). This method of adding noise simulates the uncertainty and changes of data in the real environment, which helps the model learn a more robust feature representation. In addition, data enhancement is performed in the high-density data area of ​​TimeGAN+KDE to further expand the sample and ensure that the generated sample is close to the real data. This enables the model to maintain a high prediction accuracy when facing changes in the actual environment.

[0123] S4. Construct a power outage prediction model, wherein the power outage prediction model includes a first sub-model and a second sub-model, wherein the output parameter of the first sub-model is a power grid operation characteristic value, and the input layer of the second sub-model includes a power grid operation characteristic value and a meteorological characteristic value.

[0124] The first sub-model and the second sub-model are constructed in the TensorFlow framework, so that the output parameters of the first sub-model can be directly passed to the input layer of the second sub-model in the framework.

[0125] The first sub-model includes: Stacking model, the machine model of Stacking model includes LSTM model and XGBoost model. Since the user's electricity consumption is related to the time series characteristics and is affected by weather factors, the Stacking model is used.

[0126] The second sub-model is a Bayesian neural network model, and the input layer of the Bayesian neural network model includes power grid operation characteristic values ​​and meteorological characteristic values.

[0127] Bayesian neural network (BNN) is selected as the power outage prediction model. BNN introduces Bayesian method into neural network, which can express the uncertainty of model parameters and propagate uncertainty to the prediction results. Weights exist in the form of probability distribution, and the posterior probability distribution of weights can be inferred based on training data, thereby improving the robustness and robustness of the model. Design a suitable neural network structure, including the number of nodes and connection methods of the input layer, hidden layer and output layer. The output layer uses sigmoid activation function to output the power outage probability. In BNN, a prior distribution is defined for the parameters of each layer, and the choice of prior distribution can be determined based on experience or domain knowledge. The loss function of Bayesian neural network usually includes data likelihood and prior distribution of parameters. The complex posterior distribution is approximated to a simpler distribution (such as Gaussian distribution) through variational inference, and the difference between them is minimized to improve the fitting performance and generalization ability of the model.

[0128] S5. Using the data set to train the power outage prediction model to obtain a multi-source power outage prediction model.

[0129] The second sub-model is trained and validated using the dataset.

[0130] Meteorological characteristic data and power consumption are extracted from the substation meteorological data and power grid operation data on a daily basis to form a data sequence, which is saved in a second data set, and the second data set is used to train and verify the first sub-model.

[0131] The process of power outage prediction using the multi-source power outage prediction model is as follows:

[0132] For each user in the substation area, the feature values ​​of tomorrow's meteorological data obtained through weather forecast and the feature values ​​of power data obtained through the power data prediction model are constructed into feature vectors according to the input format of the power outage prediction model. Ensure that the dimension of the feature vector matches the number of input layer nodes of the model.

[0133] The constructed feature vector is input into the power outage prediction model for inference to obtain the power outage probability value p of each user in the substation area who will experience a power outage tomorrow.

[0134] The power outage probability is divided into four risk intervals and marked with different colors, as shown in Table 1. The color corresponding to the power outage probability of each user is displayed on the power outage warning system.

[0135] Table 1 Power outage risk interval, probability interval and color correspondence table

[0136]

[0137] In some embodiments, the multi-source power outage prediction model construction system may include multiple functional modules composed of computer program segments. The computer program of each program segment in the multi-source power outage prediction model construction system may be stored in the memory of a computer device and executed by at least one processor to perform (see Figure 1 Description) Function of building a multi-source power outage prediction model.

[0138] In this embodiment, the multi-source power outage prediction model construction system can be divided into multiple functional modules according to the functions it performs, such as Figure 2 As shown. The functional modules of the system 200 may include: a data acquisition module 210, a feature mining module 220, a data expansion module 230, a model building module 240, and a model training module 250. The module referred to in the present invention refers to a series of computer program segments that can be executed by at least one processor and can complete fixed functions, which are stored in a memory. In this embodiment, the functions of each module will be described in detail in subsequent embodiments.

[0139] Data acquisition module, used to obtain area meteorological data, power grid operation data and power outage record data;

[0140] A feature mining module is used to mine feature items related to the power outage record data in the substation meteorological data and the power grid operation data, and to filter out training data from the substation meteorological data and the power grid operation data based on the feature items;

[0141] A data expansion module, used to expand the training data to obtain a data set;

[0142] A model building module, used to build a power outage prediction model, the power outage prediction model includes a first sub-model and a second sub-model, the output parameter of the first sub-model is a power grid operation characteristic value, and the input layer of the second sub-model includes a power grid operation characteristic value and a meteorological characteristic value;

[0143] The model training module is used to train the power outage prediction model using the data set to obtain a multi-source power outage prediction model.

[0144] Optionally, as an embodiment of the present invention, the feature mining module includes:

[0145] A meteorological statistics unit is used to collect meteorological sample data based on the meteorological data of the station area, wherein the meteorological sample data includes weekly average wind speed, weekly maximum wind speed, weekly average rainfall, weekly maximum rainfall, number of thunderstorm days in a week, weekly average temperature, and weekly average humidity;

[0146] An operation statistics unit is used to analyze operation sample data based on power grid operation data, wherein the operation sample data includes the monthly maximum load rate, monthly minimum load rate, monthly no-load occurrence times, monthly light-load occurrence times, monthly overload occurrence times, monthly maximum three-phase imbalance, monthly three-phase imbalance occurrence times, monthly load rate, and monthly peak-to-valley difference rate of each user;

[0147] A power outage statistics unit, used to parse power outage sample data based on the power outage record data, wherein the power outage sample data includes the number of power outages per week in the substation area and the number of power outages per month for a single user;

[0148] A preprocessing unit, used for preprocessing meteorological sample data, operation sample data and power outage sample data;

[0149] A correlation calculation unit, used to calculate the Pearson correlation coefficient of the pre-processed meteorological sample data, the operation sample data and the power outage sample data, and to screen out characteristic items based on the correlation coefficient;

[0150] The data advance unit is used to extract feature data corresponding to feature items from the substation meteorological data and power grid operation data, and extract power outage records in the same time dimension as the feature data, and save the extracted data as training data, where the time scale of the training data is day.

[0151] Optionally, as an embodiment of the present invention, the first sub-model includes:

[0152] The stacking model includes an LSTM model and an XGBoost model.

[0153] Figure 3 The present invention provides a schematic diagram of the structure of a terminal 300 provided in an embodiment of the present invention. The terminal 300 can be used to execute the method for constructing a multi-source power outage prediction model provided in an embodiment of the present invention.

[0154] The terminal 300 may include: a processor 310, a memory 320 and a communication unit 330. These components communicate via one or more buses. Those skilled in the art will appreciate that the server structure shown in the figure does not limit the present invention, and it may be a bus structure or a star structure, and may include more or fewer components than shown in the figure, or combine certain components, or arrange the components differently.

[0155] The memory 320 can be used to store the execution instructions of the processor 310, and the memory 320 can be implemented by any type of volatile or non-volatile storage terminal or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic disk or optical disk. When the execution instructions in the memory 320 are executed by the processor 310, the terminal 300 can perform some or all of the steps in the following method embodiments.

[0156] The processor 310 is the control center of the storage terminal, and uses various interfaces and lines to connect various parts of the entire electronic terminal. It runs or executes software programs and / or modules stored in the memory 320, and calls data stored in the memory to perform various functions of the electronic terminal and / or process data. The processor can be composed of an integrated circuit (IC), for example, it can be composed of a single packaged IC, or it can be composed of multiple packaged ICs with the same or different functions. For example, the processor 310 can only include a central processing unit (CPU). In the embodiment of the present invention, the CPU can be a single computing core or multiple computing cores.

[0157] The communication unit 330 is used to establish a communication channel so that the storage terminal can communicate with other terminals, receive user data sent by other terminals or send user data to other terminals.

[0158] The present invention also provides a computer storage medium, wherein the computer storage medium may store a program, and when the program is executed, the program may include some or all of the steps in each embodiment provided by the present invention. The storage medium may be a magnetic disk, an optical disk, a read-only memory (ROM) or a random access memory (RAM).

[0159] Therefore, the present invention comprehensively considers various factors that affect power outages, thereby improving the comprehensiveness of power outage prediction. In addition, the number of training samples is increased by mining features and expanding training samples. In addition, through a two-layer model structure, power outage prediction based on meteorological data and power consumption data is achieved. The technical effects that can be achieved by this embodiment can be found in the description above and will not be repeated here.

[0160] Those skilled in the art can clearly understand that the technology in the embodiments of the present invention can be implemented by means of software plus a necessary general hardware platform. Based on this understanding, the technical solution in the embodiments of the present invention, in essence or in other words, the part that contributes to the prior art, can be embodied in the form of a software product, which is stored in a storage medium such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a disk or an optical disk, and other media that can store program codes, including several instructions for enabling a computer terminal (which can be a personal computer, a server, or a second terminal, a network terminal, etc.) to execute all or part of the steps of the methods described in each embodiment of the present invention.

[0161] In this specification, the same or similar parts between the various embodiments can be referred to each other. In particular, for the terminal embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the description in the method embodiment.

[0162] In the several embodiments provided by the present invention, it should be understood that the disclosed systems and methods can be implemented in other ways. For example, the system embodiments described above are only schematic. For example, the division of the modules is only a logical function division. There may be other division methods in actual implementation, such as multiple modules or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of systems or modules, which can be electrical, mechanical or other forms.

[0163] The modules described as separate components may or may not be physically separated, and the components shown as modules may or may not be physical modules, that is, they may be located in one place or distributed on multiple network modules. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0164] In addition, each functional module in each embodiment of the present invention may be integrated into one processing module, or each module may exist physically separately, or two or more modules may be integrated into one module.

[0165] Although the present invention has been described in detail with reference to the accompanying drawings and in combination with the preferred embodiments, the present invention is not limited thereto. Without departing from the spirit and essence of the present invention, a person of ordinary skill in the art may make various equivalent modifications or substitutions to the embodiments of the present invention, and these modifications or substitutions shall be within the scope of the present invention. Any person of ordinary skill in the art may easily think of changes or substitutions within the technical scope disclosed by the present invention, and these shall be within the scope of protection of the present invention.

Claims

1. A method for constructing a multi-source power outage prediction model. It is characterized in that include: Obtain area meteorological data, power grid operation data and power outage record data; Mining feature items in the area meteorological data and the power grid operation data that are correlated with the power outage record data, and filtering out training data from the area meteorological data and the power grid operation data based on the feature items; Expanding the training data to obtain a data set; Constructing a power outage prediction model, the power outage prediction model comprising a first sub-model and a second sub-model, the output parameter of the first sub-model being a power grid operation characteristic value, and the input layer of the second sub-model comprising a power grid operation characteristic value and a meteorological characteristic value; The first sub-model includes: a Stacking model, wherein the machine model of the Stacking model includes an LSTM model and an XGBoost model; the second sub-model is a Bayesian neural network model; the first sub-model and the second sub-model are in a TensorFlow framework; Using the data set to train the power outage prediction model to obtain a multi-source power outage prediction model; The training data is expanded to obtain a data set, including: Setting a corresponding noise level for each feature item, and generating random noise for the feature item based on the noise level; For each power outage event sample, traverse all its feature values ​​and add the corresponding random noise to the corresponding feature value to obtain a new sample; Generate simulated data based on the new sample using a TimeGAN model; The kernel density function is used to calculate the high-density data area of ​​the data distribution of each feature, and the simulated data in the high-density data area is screened out as valid data; The valid data is added to the new sample to obtain a data set.

2. The method according to claim 1, It is characterized in that Mining feature items in the area meteorological data and the power grid operation data that are relevant to the power outage record data, and filtering out training data from the area meteorological data and the power grid operation data based on the feature items, including: Meteorological sample data is collected based on the meteorological data of the station area, and the meteorological sample data includes weekly average wind speed, weekly maximum wind speed, weekly average rainfall, weekly maximum rainfall, number of thunderstorm days in a week, weekly average temperature, and weekly average humidity; Analyze the operation sample data based on the power grid operation data, the operation sample data includes the monthly maximum load rate, monthly minimum load rate, monthly no-load occurrence times, monthly light load occurrence times, monthly overload occurrence times, monthly maximum three-phase imbalance, monthly three-phase imbalance occurrence times, monthly load rate, and monthly peak-to-valley difference rate of each user; Analyze power outage sample data based on power outage record data, wherein the power outage sample data includes the number of power outages per week in the substation area and the number of power outages per month for a single user; Pre-processing of meteorological sample data, operation sample data and power outage sample data; Calculate the Pearson correlation coefficient of the preprocessed meteorological sample data, operation sample data and power outage sample data, and select the characteristic items based on the correlation coefficient; Feature data corresponding to the feature items are extracted from the substation meteorological data and power grid operation data, and power outage records in the same time dimension as the feature data are extracted, and the extracted data are saved as training data, where the time scale of the training data is day.

3. A multi-source power outage prediction model construction system, It is characterized in that include: Data acquisition module, used to obtain area meteorological data, power grid operation data and power outage record data; A feature mining module is used to mine feature items related to the power outage record data in the substation meteorological data and the power grid operation data, and to filter out training data from the substation meteorological data and the power grid operation data based on the feature items; A data expansion module, used to expand the training data to obtain a data set; A model building module, used to build a power outage prediction model, the power outage prediction model includes a first sub-model and a second sub-model, the output parameter of the first sub-model is a power grid operation characteristic value, and the input layer of the second sub-model includes a power grid operation characteristic value and a meteorological characteristic value; The first sub-model includes: a Stacking model, wherein the machine model of the Stacking model includes an LSTM model and an XGBoost model; the second sub-model is a Bayesian neural network model; the first sub-model and the second sub-model are in a TensorFlow framework; A model training module, used to train the power outage prediction model using the data set to obtain a multi-source power outage prediction model; The training data is expanded to obtain a data set, including: Setting a corresponding noise level for each feature item, and generating random noise for the feature item based on the noise level; For each power outage event sample, traverse all its feature values ​​and add the corresponding random noise to the corresponding feature value to obtain a new sample; Generate simulated data based on the new sample using a TimeGAN model; The kernel density function is used to calculate the high-density data area of ​​the data distribution of each feature, and the simulated data in the high-density data area is screened out as valid data; The valid data is added to the new sample to obtain a data set.

4. The system according to claim 3, It is characterized in that The feature mining module comprises: A meteorological statistics unit is used to collect meteorological sample data based on the meteorological data of the station area, wherein the meteorological sample data includes weekly average wind speed, weekly maximum wind speed, weekly average rainfall, weekly maximum rainfall, number of thunderstorm days in a week, weekly average temperature, and weekly average humidity; An operation statistics unit is used to analyze operation sample data based on power grid operation data, wherein the operation sample data includes the monthly maximum load rate, monthly minimum load rate, monthly no-load occurrence times, monthly light-load occurrence times, monthly overload occurrence times, monthly maximum three-phase imbalance, monthly three-phase imbalance occurrence times, monthly load rate, and monthly peak-to-valley difference rate of each user; A power outage statistics unit, used to parse power outage sample data based on the power outage record data, wherein the power outage sample data includes the number of power outages per week in the substation area and the number of power outages per month for a single user; A preprocessing unit, used for preprocessing meteorological sample data, operation sample data and power outage sample data; A correlation calculation unit, used to calculate the Pearson correlation coefficient of the pre-processed meteorological sample data, the operation sample data and the power outage sample data, and to screen out characteristic items based on the correlation coefficient; The data advance unit is used to extract feature data corresponding to feature items from the substation meteorological data and power grid operation data, and extract power outage records in the same time dimension as the feature data, and save the extracted data as training data, where the time scale of the training data is day.

5. A terminal, It is characterized in that include: A memory, used for storing a multi-source power outage prediction model building program; A processor is used to implement the steps of the multi-source power outage prediction model construction method as described in any one of claims 1-2 when executing the multi-source power outage prediction model construction program.

6. A computer-readable storage medium storing a computer program, It is characterized in that The readable storage medium stores a multi-source power outage prediction model construction program, and when the multi-source power outage prediction model construction program is executed by the processor, the steps of the multi-source power outage prediction model construction method according to any one of claims 1-2 are implemented.