Frequency prediction method of power system
By determining key features from the historical operating data of the power system, building a frequency prediction model, and using the perturbation data sample set and loss function for training, the problem of low frequency prediction accuracy in the prior art is solved, and more efficient frequency prediction is achieved.
Patent Information
- Application Number
- CN202411860547.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-17
- Publication Date
- 2025-03-25
AI Technical Summary
In the existing frequency prediction methods, only a large amount of sample data is input into the model for training, resulting in low prediction accuracy.
By obtaining the historical operation data of the power system, determining the key features corresponding to the frequency, building a frequency prediction model, and establishing a disturbed data sample set and loss function, the model is trained to improve prediction accuracy.
It improves the accuracy of frequency prediction of the power system, can make frequency prediction based on the input data more accurately, and enhances the safe and stable operation of the power system.
Smart Images

Figure CN119692500A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of frequency prediction, and in particular to a frequency prediction method for a power system. Background Art
[0002] As a key infrastructure supporting economic development and people's daily life, the stable operation of the power system is of vital importance. The frequency of the power system is a key indicator to measure the operating status of the system. When a fault causes a power shortage, the reduction in the inertia level will lead to a large rate of change of frequency (RoCoF) and frequency deviation, and may even trigger low-frequency load reduction and cause power outages, threatening the safe and stable operation of the power system. Therefore, frequency prediction of the power system is crucial.
[0003] Traditional frequency prediction methods are implemented by training prediction models, but this only involves inputting massive amounts of sample data into the model for training, resulting in an ordinary model with low prediction accuracy. Summary of the invention
[0004] In view of this, the present application provides a frequency prediction method for an electric power system, which can solve the problem that the existing prediction method only inputs a large amount of sample data into the model for training to obtain an ordinary model whose prediction accuracy is not high.
[0005] To achieve the above objectives, the proposed solution is as follows:
[0006] In a first aspect, a frequency prediction method for a power system includes:
[0007] Acquiring historical operating data of the power system, and determining key features corresponding to the frequency of the power system from the historical operating data;
[0008] According to the key features, a frequency prediction model is constructed;
[0009] Establish a perturbation data sample set and loss function;
[0010] Inputting the disturbance data sample set into the frequency prediction model, and training the frequency prediction model with the goal of minimizing the loss function to obtain a trained frequency prediction model;
[0011] The active power disturbance information to be measured of the power system is obtained, and the trained frequency prediction model is used to process the active power disturbance information to be measured to obtain a frequency prediction result of the power system.
[0012] Preferably, determining the key features corresponding to the frequency of the power system from the historical operation data comprises:
[0013] constructing an operation feature set of the power system according to the historical operation data;
[0014] Maximizing mutual information of the operation feature set to obtain correlation information;
[0015] Key features are determined from the set of operational features based on the association information.
[0016] Preferably, the establishing of the disturbance data sample set comprises:
[0017] Generate original operation data files and dynamic operation data files;
[0018] Calling simulation software to read the original operation data file, so as to edit the original operation data file and save it as a binary format file;
[0019] Reading in the dynamic operation data file;
[0020] Select the output channel and assign the channel number of the output quantity;
[0021] Initializing the simulation software, creating and outputting a simulation result binary file;
[0022] Set simulation parameters and simulation output step size;
[0023] A dynamic simulation is performed to generate the perturbation data sample set.
[0024] Preferably, the process of establishing the loss function includes:
[0025] Construct an initial function based on the mean square error function;
[0026] A cross entropy loss function is used to introduce a sensitive factor into the initial function, and the disturbance data sample set is divided into severe disturbance fault samples and frequency stable samples according to the frequency offset value;
[0027] A penalty coefficient is set for the severe disturbance fault sample in the initial function to obtain a loss function.
[0028] Preferably, the loss function is:
[0029] ;
[0030] in, is the loss function, is the compensation factor, is the probability corresponding to the severe disturbance fault sample, is the first The measured frequency value of samples, is the first The frequency prediction value of samples, is the total number of samples in the perturbed data sample set, Indicates the judgment threshold of the third line of defense of the power grid, is the penalty coefficient.
[0031] Preferably, maximizing the mutual information of the operation feature set to obtain correlation information between the operation features includes:
[0032] For each operating feature in the operating feature set, calculating the mutual information between the operating feature and a preset maximum frequency offset value;
[0033] Determining each selected feature from the operating feature set with the goal of maximizing the mutual information;
[0034] According to each of the selected features and the mutual information, the association information between the operation features of the operation feature sequence is obtained.
[0035] Preferably, determining the key feature from the operation feature set based on the association information comprises:
[0036] Normalizing the associated information to obtain the operating feature importance of each selected feature in the operating feature set;
[0037] Determining whether the operational feature importance of each of the selected features is greater than a preset threshold;
[0038] The selected features whose running feature importance is greater than a preset threshold are regarded as key features.
[0039] In a second aspect, a frequency prediction device for a power system includes:
[0040] A key feature determination module, used to obtain historical operation data of the power system and determine key features corresponding to the frequency of the power system from the historical operation data;
[0041] A frequency prediction model building module, used to build a frequency prediction model according to the key features;
[0042] The sample set and loss function establishment module is used to establish the perturbation data sample set and loss function;
[0043] A model training module, used for inputting the disturbance data sample set into the frequency prediction model, and training the frequency prediction model with the goal of minimizing the loss function to obtain a trained frequency prediction model;
[0044] The frequency prediction module is used to obtain the active power disturbance information to be measured of the power system, and use the trained frequency prediction model to process the active power disturbance information to be measured to obtain the frequency prediction result of the power system.
[0045] In a third aspect, a frequency prediction device for a power system includes a memory and a processor;
[0046] The memory is used to store programs;
[0047] The processor is used to execute the program to implement each step of the frequency prediction method of the power system as described in any one of the first aspects.
[0048] In a fourth aspect, a storage medium stores a computer program thereon, wherein when the computer program is executed by a processor, the steps of the method for frequency prediction of a power system as described in any one of the first aspects are implemented.
[0049] It can be seen from the above technical scheme that the present application obtains the historical operation data of the power system, and determines the key features corresponding to the frequency of the power system from the historical operation data; constructs a frequency prediction model according to the key features; establishes a disturbance data sample set and a loss function; inputs the disturbance data sample set into the frequency prediction model, and trains the frequency prediction model with the goal of minimizing the loss function to obtain a trained frequency prediction model; obtains the active disturbance information to be measured of the power system, and uses the trained frequency prediction model to process the active disturbance information to be measured to obtain the frequency prediction result of the power system. The present application first obtains the historical operation data of the power system, and determines the key features corresponding to the frequency of the power system, that is, the key features that can affect the frequency change of the power system, establishes a frequency prediction model according to the key features, sets a disturbance data sample set and a loss function, and uses the disturbance data sample set to train the model, and inputs the active disturbance information to be measured into the trained model, so that a frequency prediction model that can accurately obtain frequency prediction results based on the input data can be trained more efficiently. BRIEF DESCRIPTION OF THE DRAWINGS
[0050] 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, the drawings described below are only embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on the provided drawings without paying creative work.
[0051] Figure 1 An optional flow chart of a frequency prediction method for a power system provided in an embodiment of the present application;
[0052] Figure 2 A schematic diagram of a generation process of a disturbance data sample set provided in an embodiment of the present application;
[0053] Figure 3 A schematic diagram of the structure of a frequency prediction model provided in an embodiment of the present application;
[0054] Figure 4 A schematic diagram of a process for constructing a frequency prediction model provided in an embodiment of the present application;
[0055] Figure 5 A schematic diagram of the structure of a frequency prediction device for a power system provided in an embodiment of the present application;
[0056] Figure 6 A schematic diagram of the structure of a frequency prediction device for an electric power system provided in an embodiment of the present application. DETAILED DESCRIPTION
[0057] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.
[0058] As a key infrastructure supporting economic development and people's daily life, the stable operation of the power system is of vital importance. The frequency of the power system is a key indicator to measure the operating status of the system. The uncertainty, volatility and intermittency of wind and photovoltaic power generation bring huge challenges to the stable operation of the power grid. Frequency stability is an important prerequisite for the system to absorb these new energy sources. At the same time, the two new characteristics of the power grid, "high proportion of renewable energy" and "high proportion of power electronic equipment", have led to a significant decrease in system inertia and spinning reserve capacity. When a fault causes a power shortage, the reduction in inertia level will lead to a large rate of change of frequency (RoCoF) and frequency deviation, and may even trigger low-frequency load reduction actions and cause power outages, threatening the safe and stable operation of the power system. Therefore, frequency prediction of the power system is crucial.
[0059] Traditional frequency prediction methods are implemented by training prediction models, but this only involves inputting massive amounts of sample data into the model for training, resulting in an ordinary model with low prediction accuracy.
[0060] The present invention can be used in many general or special computing device environments or configurations, such as personal computers, server computers, handheld or portable devices, tablet devices, multi-processor devices, distributed computing environments including any of the above devices or devices, etc.
[0061] In order to solve the defects of the above-mentioned prior art, an embodiment of the present invention provides a frequency prediction method for a power system. The method can be applied to various computer terminals or smart terminals, and its execution subject can be a processor or server of the computer terminal or smart terminal. The method flow chart of the method is as follows: Figure 1 As shown, specifically including:
[0062] S1: Acquire historical operation data of a power system, and determine key features corresponding to the frequency of the power system from the historical operation data.
[0063] The process of determining key features is actually to build a feature engineering based on multi-source information fusion technology, which is suitable for scenarios where key frequency regulation characteristic parameters of the system are missing or difficult to collect. In other words, key features that can affect frequency changes in the power system can be determined from historical operating data. By building a model based on key features, the trained model can obtain more accurate frequency prediction results for the input data.
[0064] S2: Construct a frequency prediction model based on the key features.
[0065] In this step, an intelligent algorithm and a reasonable network model structure suitable for frequency prediction can be selected according to key features. For example, when setting the structure of the model or fixing parameters, weights and other data, key features can be focused on, and the model can be established based on key features and as a starting point.
[0066] S3: Establish a perturbation data sample set and loss function.
[0067] Among the many power system analysis software, PSS / E (Power System Simulator for Engineering) is the most widely used. It has an automated environment of Python language, which allows users to flexibly call and implement customized operations, and can generate large quantities of data samples. Therefore, this application can use Python language programming to call PSS / E software simulation to generate operating status data of the power system after disturbance. This is because the operating mode of the power system and the disturbance information are the two key factors affecting the dynamic frequency response of the power system.
[0068] In fact, due to the influence of many factors such as system planning, overhaul and maintenance, peak and valley electricity consumption, the operation mode of the power system before the disturbance is different, which can be reflected in different load levels, load models, system inertia levels and spinning reserve capacity. The disturbance information includes the disturbance type, disturbance location, disturbance time, disturbance amount and other elements.
[0069] When establishing the loss function, we can consider enhancing the fault tolerance and generalization ability of the frequency prediction model, so as to make the performance of the frequency prediction model more powerful. For example, we can choose the mean square error function as the loss function.
[0070] S4: Inputting the disturbance data sample set into the frequency prediction model, and training the frequency prediction model with the goal of minimizing the loss function to obtain a trained frequency prediction model.
[0071] Optionally, the perturbation data sample set can be divided into two parts, one part is used as the actual input sample for training, and the other part is used for testing after training to verify the prediction accuracy of the frequency prediction model.
[0072] In the loss calculation process, the frequency predicted by the frequency prediction model is compared with the corresponding actual frequency in the perturbation data sample set to calculate the difference between the two. For example, if the mean square error function is used as the loss function, for a sample, its loss value is the square of the difference between the predicted frequency and the actual frequency. The parameters of the frequency prediction model can be adjusted through the optimization algorithm, and the key features can also be taken into account during the adjustment.
[0073] S5: Acquire the active power disturbance information to be measured of the power system, and use the trained frequency prediction model to process the active power disturbance information to be measured to obtain a frequency prediction result of the power system.
[0074] After the frequency prediction model is trained in step S4, the active disturbance information to be measured can be obtained and input into the frequency prediction model for processing to obtain a frequency prediction result.
[0075] It can be seen from the above technical scheme that the present application obtains the historical operation data of the power system, and determines the key features corresponding to the frequency of the power system from the historical operation data; constructs a frequency prediction model according to the key features; establishes a disturbance data sample set and a loss function; inputs the disturbance data sample set into the frequency prediction model, and trains the frequency prediction model with the goal of minimizing the loss function to obtain a trained frequency prediction model; obtains the active disturbance information to be measured of the power system, and uses the trained frequency prediction model to process the active disturbance information to be measured to obtain the frequency prediction result of the power system. The present application first obtains the historical operation data of the power system, and determines the key features corresponding to the frequency of the power system, that is, the key features that can affect the frequency change of the power system, establishes a frequency prediction model according to the key features, sets a disturbance data sample set and a loss function, and uses the disturbance data sample set to train the model, and inputs the active disturbance information to be measured into the trained model, so that a frequency prediction model that can accurately obtain frequency prediction results based on the input data can be trained more efficiently.
[0076] In the method provided in the embodiment of the present invention, the process of determining the key features corresponding to the frequency of the power system from the historical operation data is specifically described as follows:
[0077] constructing an operation feature set of the power system according to the historical operation data;
[0078] Maximizing mutual information of the operation feature set to obtain correlation information;
[0079] Key features are determined from the set of operational features based on the association information.
[0080] Set the run feature set to , , For the running feature set operating characteristics, is the running feature dimension.
[0081] The process of maximizing the mutual information of the operation feature set to obtain the correlation information between the operation features may specifically include:
[0082] For each operating feature in the operating feature set, calculating the mutual information between the operating feature and a preset maximum frequency offset value;
[0083] Determining each selected feature from the operating feature set with the goal of maximizing the mutual information;
[0084] According to each of the selected features and the mutual information, the association information between the operation features of the operation feature sequence is obtained.
[0085] Specifically, each operation feature in the operation feature set may refer to an operation feature sequence, the maximum frequency offset value may be preset, and the mutual information between the operation feature and the maximum frequency offset value may be expressed as , and then use the Joint Mutual Information Maximization (JMIM) method to continuously select the one that can maximize The operating characteristics of , as each selected feature, such as The conditions that need to be met during the selection process, namely the feature selection criteria yes:
[0086] ;
[0087] in, represents the set of selected features. express , and maximum frequency deviation The joint mutual information between .
[0088] The process of determining the key feature from the operation feature set based on the association information may specifically include:
[0089] Normalizing the associated information to obtain the operating feature importance of each selected feature in the operating feature set;
[0090] Determining whether the operational feature importance of each of the selected features is greater than a preset threshold;
[0091] The selected features whose running feature importance is greater than a preset threshold are regarded as key features.
[0092] Specifically, the operational feature importance of each selected feature obtained after normalization is:
[0093] ;
[0094] in, It is the mutual information of the selected features, and can also be expressed as the mutual information between the selected features, in which the JMIM method can also be used.
[0095] The process of establishing a disturbance data sample set in this application is described in detail below.
[0096] Generate original operation data files and dynamic operation data files;
[0097] Calling simulation software to read the original operation data file, so as to edit the original operation data file and save it as a binary format file;
[0098] Reading in the dynamic operation data file;
[0099] Select the output channel and assign the channel number of the output quantity;
[0100] Initializing the simulation software, creating and outputting a simulation result binary file;
[0101] Set simulation parameters and simulation output step size;
[0102] A dynamic simulation is performed to generate the perturbation data sample set.
[0103] Specifically, the format of the original running data file is .raw, the format of the binary format file is .sav, the format of the dynamic running data file is .dyr, and the format of the simulation result binary file is .out.
[0104] Optionally, after generating the perturbation data sample set, it is also possible to determine whether the preset operation mode and perturbation set have been traversed. If not, the current operation mode is changed and replaced with other operation modes to continue the sample generation process. If yes, the currently generated perturbation data sample set is used as the training set that is finally input into the model for training. The above process can be as follows: Figure 2 shown.
[0105] The process of establishing the loss function is described in detail below.
[0106] Construct an initial function based on the mean square error function;
[0107] A cross entropy loss function is used to introduce a sensitive factor into the initial function, and the disturbance data sample set is divided into severe disturbance fault samples and frequency stable samples according to the frequency offset value;
[0108] A penalty coefficient is set for the severe disturbance fault sample in the initial function to obtain a loss function.
[0109] Specifically, before establishing the loss function value, the frequency prediction result output by the frequency prediction model can be defined first. :
[0110] ;
[0111] in, Represents the tree model functions, , Represents a set of functions, Represents the operational characteristics of the input.
[0112] In fact, the traditional frequency prediction method also uses the time domain simulation analysis method, which takes into account the detailed parameters of the power system. Its calculation method is mature and the simulation error is small. However, time domain simulation often takes a long time to analyze large-scale power systems. It is more suitable for offline analysis of power grid planning and accident reproduction, but not for analysis of real-time operation status of power grids with strong timeliness requirements. Therefore, this application considers the lightweight gradient boosting machine. The lightweight gradient boosting machine (Light gradient boosting machine, LightGBM) is an efficient algorithm in the field of integrated learning. This application is based on the gradient boosting tree framework for improvement, which can effectively improve the model's ability to process big data and prediction accuracy. Weak Regression Tree Perform an ensemble to build a strong learner:
[0113] ;
[0114] In addition, some existing frequency prediction methods realize frequency prediction by offline training of massive sample data, but this will be too dependent on the quality of the samples. If the quality of some samples is relatively poor, the time series characteristics of dynamic frequency changes cannot be accurately reflected. At the same time, there will be problems such as high feature dimension and weak generalization ability. Therefore, the improved lightweight gradient boosting machine in this application integrates multiple weak learners to increase the diversity of outputs, avoid the negative impact of low-precision weak learners, and thus reduce the dependence on sample quality to a certain extent. At the same time, this application can also reduce memory consumption by means of measures such as gradient-based one-sided sampling and mutual feature compression.
[0115] On the other hand, considering that the deep forest method realizes the multi-layer expression effect of the deep learning framework by connecting random forests in series step by step, and has high computational efficiency, this application uses the framework of the deep forest method to enhance the ability of the lightweight gradient boosting machine to express high-dimensional, strongly nonlinear and complex power system functions, and realizes the layer-by-layer expression learning of key features affecting frequency dynamics. The random forest is replaced by LightGBM to construct a cascaded light gradient boosting machine (CasLightGBM). In terms of the network structure of CasLightGBM, multiple different LightGBM learners are constructed as a cascade layer of CasLightGBM. In the process of establishing CasLightGBM, the mean square error (MSE) is used as a judgment indicator for whether it is necessary to continue to increase the cascade layer. The specific calculation formula is as follows:
[0116] ;
[0117] in, is the number of samples in the perturbed data sample set, is the first The measured frequency value of samples, is the first The frequency prediction value of the samples.
[0118] When CasLightGBM expands to a new cascade layer T, it determines whether the mean square error value calculated by the current layer is greater than that of the T-1 layer. If so, it continues to expand the cascade layer, such as Figure 3 shown.
[0119] Then when establishing the loss function, the initial function is established based on the mean square error function. The formula is:
[0120] ;
[0121] in, is the error function, which measures the error of the frequency prediction model.
[0122] In order to ensure that the frequency prediction model has good adaptability, the distribution difference of samples needs to be considered in the loss function. During the operation of the power system, the number of large-capacity active disturbance events is usually much smaller than the number of small disturbance events, which makes the distribution of the maximum offset often present a steep slope at the edge, with the left side higher than the right side. In this case, if the frequency prediction model is trained using the disturbance data sample set, the total loss value of a large number of frequency-stable samples will be much greater than the total loss value of severe disturbance fault samples. This allows the model to pay more attention to frequency-stable samples during training and ignores severe disturbance fault samples that are of great reference significance to the action of the control device. Therefore, this application uses the cross entropy loss function to introduce a sensitive factor in the initial function. , in order to balance the influence of the frequency offset sample distribution difference, the expression of the sensitivity factor is:
[0123] ;
[0124] in, is the frequency offset value, is the probability corresponding to the severe disturbance fault sample, is a compensation factor used to prevent the problem of gradient disappearance caused by excessively high probability of frequency-stable samples. The judgment threshold for the third line of defense of the power grid can generally be set to 0.5HZ.
[0125] When the disturbance occurs, the frequency deviation is greater than When the low-frequency load shedding or high-frequency machine shedding device in the third line of defense is triggered, the units and equipment in the power grid will be cut off on a large scale. Therefore, the maximum frequency deviation after the disturbance accident will be greater than The samples are classified as severe disturbance fault samples, and the others are classified as frequency stable samples.
[0126] From the expression of the sensitive factor, we can know that The closer the value is to 1, the smaller the sensitivity factor is, thus avoiding the problem of excessive total loss of frequency stable samples, and balancing the distribution difference impact brought by the maximum frequency offset value to a certain extent.
[0127] In addition to the difference in the distribution of frequency offset size, there are also significant differences in whether the predicted frequency of severe disturbance fault samples can accurately reflect the cost corresponding to the risk of frequency instability. For samples exceeding the action threshold of the third line of defense, a predicted value slightly greater than the action threshold of the control measure will not cause serious consequences, but a predicted value less than the action threshold of the control measure will easily induce cascading failures and lead to instability or frequency collapse due to the inability to take appropriate emergency control measures in time. Therefore, this application sets a penalty coefficient for severe disturbance fault samples in the initial function. , the final loss function is a loss function that takes into account the penalty-sensitive mechanism:
[0128] ;
[0129] This loss function not only balances the impact of frequency offset distribution differences during model training, but also takes into account the penalty cost of conservative prediction of severe disturbance events, making it more practical in frequency prediction scenarios of power systems. Figure 4 Schematic diagram of the construction process of the frequency prediction model of this application.
[0130] and Figure 1 Corresponding to the method described above, the embodiment of the present invention further provides a frequency prediction device for a power system, which is used to Figure 1 In the specific implementation of the method, the frequency prediction device of the power system provided by the embodiment of the present invention can be used in a computer terminal or various mobile devices, combined with Figure 5 , the frequency prediction device of the power system is introduced, such as Figure 5 As shown, the device may include:
[0131] A key feature determination module 10, configured to obtain historical operation data of the power system and determine key features corresponding to the frequency of the power system from the historical operation data;
[0132] A frequency prediction model building module 20, used to build a frequency prediction model according to the key features;
[0133] A sample set and loss function establishment module 30, used to establish a perturbation data sample set and a loss function;
[0134] A model training module 40 is used to input the disturbance data sample set into the frequency prediction model, and train the frequency prediction model with the goal of minimizing the loss function to obtain a trained frequency prediction model;
[0135] The frequency prediction module 50 is used to obtain the active power disturbance information to be measured of the power system, and use the trained frequency prediction model to process the active power disturbance information to be measured to obtain a frequency prediction result of the power system.
[0136] It can be seen from the above technical scheme that the present application obtains the historical operation data of the power system, and determines the key features corresponding to the frequency of the power system from the historical operation data; constructs a frequency prediction model according to the key features; establishes a disturbance data sample set and a loss function; inputs the disturbance data sample set into the frequency prediction model, and trains the frequency prediction model with the goal of minimizing the loss function to obtain a trained frequency prediction model; obtains the active disturbance information to be measured of the power system, and uses the trained frequency prediction model to process the active disturbance information to be measured to obtain the frequency prediction result of the power system. The present application first obtains the historical operation data of the power system, and determines the key features corresponding to the frequency of the power system, that is, the key features that can affect the frequency change of the power system, establishes a frequency prediction model according to the key features, sets a disturbance data sample set and a loss function, and uses the disturbance data sample set to train the model, and inputs the active disturbance information to be measured into the trained model, so that a frequency prediction model that can accurately obtain frequency prediction results based on the input data can be trained more efficiently.
[0137] Furthermore, an embodiment of the present application provides a frequency prediction device for a power system. Optionally, Figure 6 The hardware structure diagram of the frequency prediction device of the power system is shown in FIG. Figure 6 The hardware structure of the frequency prediction device of the power system may include: at least one processor 01 , at least one communication interface 02 , at least one memory 03 and at least one communication bus 04 .
[0138] In the embodiment of the present application, the number of the processor 01 , the communication interface 02 , the memory 03 , and the communication bus 04 is at least one, and the processor 01 , the communication interface 02 , and the memory 03 communicate with each other through the communication bus 04 .
[0139] The processor 01 may be a central processing unit (CPU), or an application specific integrated circuit (ASIC), or one or more integrated circuits configured to implement the embodiments of the present invention.
[0140] The memory 03 may include a high-speed RAM memory, and may also include a non-volatile memory (non-volatile memory), etc., such as at least one disk memory.
[0141] The memory stores a program, and the processor can call the program stored in the memory, and the program is used to execute the following frequency prediction method of the power system, including:
[0142] Acquiring historical operating data of the power system, and determining key features corresponding to the frequency of the power system from the historical operating data;
[0143] According to the key features, a frequency prediction model is constructed;
[0144] Establish a perturbation data sample set and loss function;
[0145] Inputting the disturbance data sample set into the frequency prediction model, and training the frequency prediction model with the goal of minimizing the loss function to obtain a trained frequency prediction model;
[0146] The active power disturbance information to be measured of the power system is obtained, and the trained frequency prediction model is used to process the active power disturbance information to be measured to obtain a frequency prediction result of the power system.
[0147] Optionally, the detailed functions and extended functions of the program may refer to the description of the frequency prediction method of the power system in the method embodiment.
[0148] The embodiment of the present application further provides a storage medium, which may store a program suitable for execution by a processor, and when the program is executed, controls the device where the storage medium is located to execute the following power system frequency prediction method, including:
[0149] Acquiring historical operating data of the power system, and determining key features corresponding to the frequency of the power system from the historical operating data;
[0150] According to the key features, a frequency prediction model is constructed;
[0151] Establish a perturbation data sample set and loss function;
[0152] Inputting the disturbance data sample set into the frequency prediction model, and training the frequency prediction model with the goal of minimizing the loss function to obtain a trained frequency prediction model;
[0153] The active power disturbance information to be measured of the power system is obtained, and the trained frequency prediction model is used to process the active power disturbance information to be measured to obtain a frequency prediction result of the power system.
[0154] Specifically, the storage medium may be a computer-readable storage medium, and the computer-readable storage medium may be an electronic memory such as a flash memory, an EEPROM (Electrically Erasable Programmable Read-Only Memory), an EPROM, a hard disk or a ROM.
[0155] Optionally, the detailed functions and extended functions of the program may refer to the description of the frequency prediction method of the power system in the method embodiment.
[0156] In addition, the functional modules in the various embodiments of the present disclosure can be integrated together to form an independent part, or each module can exist separately, or two or more modules can be integrated to form an independent part. If the function is implemented in the form of a software functional module and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present disclosure is essentially or the part that contributes to the prior art or the part of the technical solution can be embodied in the form of a software product, which is stored in a storage medium and includes a number of instructions for a computer device (which can be a personal computer, a live broadcast device, or a network device, etc.) to perform all or part of the steps of the methods of the various embodiments of the present disclosure.
[0157] Finally, it should be noted that, in this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise a ..." do not exclude the presence of other identical elements in the process, method, article or device including the elements.
[0158] The various embodiments in this specification are described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same or similar parts between the various embodiments can be referenced to each other.
[0159] The above description of the disclosed embodiments enables those skilled in the art to implement or use the present application. Various modifications to these embodiments will be apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present application. Therefore, the present application will not be limited to the embodiments shown herein, but will conform to the widest scope consistent with the principles and novel features disclosed herein.
Claims
1. A frequency prediction method for a power system, characterized in that: include: Acquiring historical operating data of the power system, and determining key features corresponding to the frequency of the power system from the historical operating data; According to the key features, a frequency prediction model is constructed; Establish a perturbation data sample set and loss function; Inputting the disturbance data sample set into the frequency prediction model, and training the frequency prediction model with the goal of minimizing the loss function to obtain a trained frequency prediction model; The active power disturbance information to be measured of the power system is obtained, and the trained frequency prediction model is used to process the active power disturbance information to be measured to obtain a frequency prediction result of the power system.
2. The method according to claim 1, characterized in that Determining the key features corresponding to the frequency of the power system from the historical operation data includes: constructing an operation feature set of the power system according to the historical operation data; Maximizing mutual information of the operation feature set to obtain correlation information; Key features are determined from the set of operational features based on the association information.
3. The method according to claim 1, characterized in that The step of establishing a disturbance data sample set comprises: Generate original operation data files and dynamic operation data files; Calling simulation software to read the original operation data file, so as to edit the original operation data file and save it as a binary format file; Reading in the dynamic operation data file; Select the output channel and assign the channel number of the output quantity; Initializing the simulation software, creating and outputting a simulation result binary file; Set simulation parameters and simulation output step size; A dynamic simulation is performed to generate the perturbation data sample set.
4. The method according to claim 1, characterized in that The process of establishing the loss function includes: Construct an initial function based on the mean square error function; A cross entropy loss function is used to introduce a sensitive factor into the initial function, and the disturbance data sample set is divided into severe disturbance fault samples and frequency stable samples according to the frequency offset value; A penalty coefficient is set for the severe disturbance fault sample in the initial function to obtain a loss function.
5. The method according to claim 1, characterized in that The loss function is: ; in, is the loss function, is the compensation factor, is the probability corresponding to the severe disturbance fault sample, is the first The measured frequency value of samples, is the first The frequency prediction value of samples, is the total number of samples in the perturbed data sample set, Indicates the judgment threshold of the third line of defense of the power grid, is the penalty coefficient.
6. The method according to claim 2, characterized in that The step of maximizing the mutual information of the operation feature set to obtain correlation information between the operation features includes: For each operating feature in the operating feature set, calculating the mutual information between the operating feature and a preset maximum frequency offset value; Determining each selected feature from the operating feature set with the goal of maximizing the mutual information; According to each of the selected features and the mutual information, the association information between the operation features of the operation feature sequence is obtained.
7. The method according to any one of claims 2 or 6, characterized in that: The determining the key feature from the operation feature set based on the association information includes: Normalizing the associated information to obtain the operating feature importance of each selected feature in the operating feature set; Determining whether the operational feature importance of each of the selected features is greater than a preset threshold; The selected features whose running feature importance is greater than a preset threshold are regarded as key features.
8. A frequency prediction device for a power system, characterized in that: include: A key feature determination module, used to obtain historical operation data of the power system and determine key features corresponding to the frequency of the power system from the historical operation data; A frequency prediction model building module, used to build a frequency prediction model according to the key features; The sample set and loss function establishment module is used to establish the perturbation data sample set and loss function; A model training module, used for inputting the disturbance data sample set into the frequency prediction model, and training the frequency prediction model with the goal of minimizing the loss function to obtain a trained frequency prediction model; The frequency prediction module is used to obtain the active power disturbance information to be measured of the power system, and use the trained frequency prediction model to process the active power disturbance information to be measured to obtain the frequency prediction result of the power system.
9. A frequency prediction device for a power system, characterized in that: including memory and processor; The memory is used to store programs; The processor is used to execute the program to implement the various steps of the frequency prediction method of the power system as described in any one of claims 1-7.
10. A storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, each step of the frequency prediction method of the power system as described in any one of claims 1 to 7 is implemented.
Citation Information
Cited By
Operating parameter sampling method and device of circulating water system and electronic equipment
CN121682745A