A static voltage stability margin fast prediction method, system, device and medium
By constructing a fully connected neural network model and combining hierarchical sampling and robust normalization, the problems of insufficient generalization ability and long computation time of the voltage stability margin prediction model are solved, realizing rapid online prediction of static voltage stability margin and proactive safety early warning.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- GUANGXI POWER GRID CORP
- Filing Date
- 2026-05-06
- Publication Date
- 2026-07-31
AI Technical Summary
Existing voltage stability margin prediction models lack generalization ability and accuracy in boundary condition prediction. Errors increase significantly under low margin conditions. Furthermore, traditional methods involve large computational loads and long computation times, making it difficult to meet the real-time requirements of online evaluation.
A dataset is generated using a standard power system. A fully connected neural network model is constructed through hierarchical sampling and robust normalization. The model is trained using a weighted loss function, an adaptive optimizer, and an early stopping mechanism. Combined with a dynamic learning rate scheduler, the model enables rapid prediction of static voltage stability margin.
It enables rapid online prediction of static voltage stability margin under various operating modes, improves the efficiency of operating mode assessment and proactive safety early warning capabilities, and significantly enhances the ability to identify critical states.
Smart Images

Figure CN122495413A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of power system operation mode safety analysis and online assessment technology, specifically to a method, system, device and medium for rapid prediction of static voltage stability margin. Background Technology
[0002] Voltage stability is a crucial characteristic for maintaining the safe operation of a power system, directly impacting the power supply security and quality of the grid. Grid dispatchers need to quickly and accurately formulate operating modes and conduct online assessments of static voltage stability margins. This is an important task for predicting operational safety risks and selecting stable and safe operating ranges. With the large-scale development and utilization of renewable energy and the continuous increase in power load, the voltage stability problems faced by the power system are constantly worsening.
[0003] Traditional voltage stability calculation methods are mostly based on continuous power flow calculation techniques. These methods sequentially add loads until the system collapses to obtain a stability margin. While the results are relatively accurate, the calculations are computationally intensive and time-consuming. Engineers need to perform many nonlinear power flow calculations for each operating time of the day, making these methods insufficient for the real-time requirements of online evaluation.
[0004] In recent years, machine learning methods have opened up new avenues for voltage stability assessment. Many studies have explored using data-driven models such as neural networks and SVMs to learn from historical instances of a specific stability margin and quickly predict system stability margins. However, existing machine learning methods still have many shortcomings. Researchers lack standardized methods for generating training data; different studies employ different load growth patterns, grid models, and collapse criteria, resulting in poor model generalization performance. Stability margin prediction is essentially an imbalanced learning problem; while low-margin samples are sparse, they are crucial. Current methods do not consider sample imbalance, leading to a failure to accurately predict the margin under the most dangerous operating conditions. Commonly used data preprocessing methods are sensitive to outliers, affecting the overall robustness of the model. Furthermore, common neural network structures are often overly complex, leading to overfitting. The lack of regularization during training results in significant prediction errors under low-margin operating conditions. Most literature focuses on model structure rather than addressing the overall balance between data generation, preprocessing, and training, resulting in limited overall improvement. Summary of the Invention
[0005] In view of the above-mentioned existing problems, the present invention provides a method, system, device and medium for rapid prediction of static voltage stability margin, in order to solve the problems of insufficient model generalization ability, insufficient prediction accuracy for boundary conditions and significant increase in error under low margin conditions in the prior art.
[0006] To address the aforementioned technical problems, a fast prediction method for static voltage stability margin is proposed, including: Based on a standard power system, a dataset of output characteristics is generated through systemic load growth and continuous power flow calculations. The dataset is hierarchically sampled into training and testing sets, and robust normalization is used to standardize the input and output features respectively. Based on the standardized training set, a fully connected neural network model is constructed, and the model is trained using a weighted loss function, an adaptive optimizer, a dynamic learning rate scheduler, and an early stopping mechanism to obtain a static voltage stability margin prediction model. The real-time state parameters of the operating mode to be evaluated are processed by the robust normalization method and input into the prediction model. The model output value is then de-normalized to obtain the final static voltage stability margin prediction value.
[0007] As a preferred embodiment of the fast prediction method for static voltage stability margin described in this invention, the dataset for generating output features includes: for all nodes with initial loads, the active and reactive loads are synchronously adjusted in the same proportion to generate a set of initial operating modes covering different load levels. For each initial operating mode, a continuous power flow analysis is performed to determine the voltage collapse point. Based on the initial total active load and the total active load at the collapse point, the static voltage stability margin of the current mode is calculated.
[0008] As a preferred embodiment of the fast prediction method for static voltage stability margin described in this invention, the step of performing hierarchical sampling includes dividing the samples of the entire dataset into a low margin layer, a medium margin layer, and a high margin layer based on the calculated static voltage stability margin value. When dividing the training set and the test set, it is necessary to ensure that the proportion of samples in the training set and the test set of each margin layer is the same as the proportion in the original dataset. The standardization process includes using a standardization method based on the median and interquartile range to standardize the input and output features of all samples in the dataset, thereby obtaining standardized training and test sets.
[0009] As a preferred embodiment of the fast prediction method for static voltage stability margin described in this invention, the construction of the fully connected neural network model includes constructing a fully connected neural network comprising an input layer, a hidden layer, and an output layer, wherein the hidden layer comprises linear transformation, batch normalization processing, and a nonlinear activation function. The weighted loss function includes constructing a weighted mean square error loss function and, by introducing a weight allocation mechanism, assigning penalty weights to the sample prediction errors of the low static voltage stability margin layer.
[0010] As a preferred embodiment of the fast prediction method for static voltage stability margin described in this invention, the training of the model includes: using an adaptive moment estimation algorithm as an optimizer and configuring a cosine annealing strategy as a learning rate scheduler to dynamically adjust the learning rate during the training process, setting an early stopping mechanism to terminate training when the model performance no longer improves, and saving the optimal model parameters to obtain a trained static voltage stability margin prediction model.
[0011] As a preferred embodiment of the fast prediction method for static voltage stability margin described in this invention, the inverse standardization process includes performing the inverse operation of robust standardization, using the same standardization parameters as in preprocessing, based on the median and interquartile range of the data, to restore the standardized prediction values output by the model to the original physical dimensions.
[0012] As a preferred embodiment of the fast prediction method for static voltage stability margin described in this invention, the method for updating the prediction to obtain the final predicted value of static voltage stability margin includes: comparing the predicted value with a preset safety threshold; issuing an early warning when the predicted value is less than the threshold; and for operating modes where the prediction error exceeds the set tolerance, initiating standard continuous power flow calculation for precise verification.
[0013] The beneficial effects of this preferred technical solution are that it utilizes a lightweight neural network model to achieve rapid online prediction of static voltage stability margin under various operating modes, thereby providing real-time margin indicators for the operating mode evaluation process, significantly improving the overall efficiency of online operating mode evaluation, and enhancing the proactive safety early warning capability of the power system by improving the ability to identify critical states.
[0014] As a preferred embodiment of the fast prediction system for static voltage stability margin described in this invention, it is characterized by including a dataset generation module, a data preprocessing module, a model building and training module, and an online prediction and verification module.
[0015] The dataset generation module is used to generate a set of initial operating modes covering different load levels through node load growth strategies, perform standard power flow calculations and continuous power flow analysis on each initial mode, determine the voltage collapse point, calculate the corresponding static voltage stability margin, and construct the dataset.
[0016] The data preprocessing module is used to divide the dataset according to the static voltage stability margin of the samples, adopt a stratified sampling method to divide the training set and test set according to the proportion, and keep the distribution of each margin layer in the training set and test set consistent with the original dataset. It also uses a robust standardization method based on median and interquartile range to standardize the input features and output labels.
[0017] The model building and training module is used to build a lightweight fully connected neural network based on the preprocessing of the training set. During the training process, a weighted loss function is assigned to the prediction error of low-margin samples, and the model is optimized and trained by combining an adaptive optimizer, a cosine annealing learning rate scheduler and early stopping to obtain a prediction model.
[0018] The online prediction and verification module is used to input the real-time state parameters of the operating mode to be evaluated into the trained prediction model after robust standardization, perform millisecond-level margin prediction, destandardize the model output to obtain a margin value with actual physical meaning, set a safety threshold for real-time early warning, and automatically trigger continuous power flow calculation for scenarios where the prediction error exceeds the limit to verify the results.
[0019] A computer device includes a memory and a processor, the memory storing a computer program, the processor executing the computer program to implement the steps of a method for rapid prediction of static voltage stability margin.
[0020] A computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps of a method for rapidly predicting static voltage stability margin.
[0021] The beneficial effects of this invention are as follows: Using the IEEE 14-bus standard power system as the calculation benchmark, this invention generates a static voltage stability margin dataset for training through systemic load growth and standard continuous power flow calculations. The generated dataset is preprocessed using hierarchical sampling and RobustScaler to construct a fully connected neural network model. This model is then trained and optimized using a weighted MSE loss function, Adam optimizer, CosineAnnealingLR learning rate scheduler, and an early stopping mechanism to obtain the final static voltage stability margin prediction model. This trained prediction model can directly predict the voltage stability margin for new operating modes. The prediction results are de-standardized to output the final voltage stability margin value, enabling rapid prediction of static voltage stability margins for various operating modes. This provides an immediate margin indicator for online safety assessment, significantly improving the efficiency of online assessment of operating modes and the system's proactive safety early warning capability. Attached Figure Description
[0022] To more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings used in the following description of the embodiments will be briefly introduced. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0023] Figure 1The above is a flowchart of a method for rapid prediction of static voltage stability margin provided in one embodiment of the present invention.
[0024] Figure 2 This is a scatter plot of the predicted and actual static voltage stability margin values for a fast prediction method for static voltage stability margin provided in an embodiment of the present invention.
[0025] Figure 3 The present invention provides a system scheme flowchart for a fast prediction system for static voltage stability margin according to an embodiment of the present invention. Detailed Implementation
[0026] To make the above-mentioned objects, features, and advantages of the present invention more apparent and understandable, specific embodiments of the present invention will be described in detail below with reference to the accompanying drawings. Obviously, the described embodiments are only a part of the embodiments of the present invention, and not all of them. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort should fall within the protection scope of the present invention.
[0027] Example 1, referring to Figure 1 As an embodiment of the present invention, a method for fast prediction of static voltage stability margin is provided, comprising: S100: Based on a standard power system, a dataset of output characteristics is generated through systemic load growth and continuous power flow calculations.
[0028] S200: The dataset is stratified and divided into training and test sets, and a robust standardization method is used to standardize the input and output features respectively.
[0029] S300: Based on the standardized training set, a fully connected neural network model is constructed. The model is trained using a weighted loss function, an adaptive optimizer, a dynamic learning rate scheduler, and an early stopping mechanism to obtain a static voltage stability margin prediction model.
[0030] S400: The real-time state parameters of the operating mode to be evaluated are processed by a robust normalization method, input into the prediction model, and the model output value is denormalized to obtain the final static voltage stability margin prediction value.
[0031] It should be noted that this invention, by constructing a lightweight neural network model to replace traditional continuous power flow calculation, enables rapid online prediction of static voltage stability margin under various operating modes, providing an instant margin index for operating mode evaluation, and significantly improving evaluation efficiency and proactive safety early warning capabilities.
[0032] Example 2, refer to Figure 1 and Figure 2This is a second embodiment of the present invention, which provides a method for rapid prediction of static voltage stability margin, including: In step S100, the dataset for calculating and generating output features includes performing systemic load growth and continuous power flow calculations based on the IEEE 14-bus standard power system to generate the dataset required for model training, specifically including steps S101 to S103: S101: Perform systemic load growth, set the load growth step size to 0.02%, and for all nodes in the system with initial active load greater than 0, increase active and reactive loads synchronously in the same proportion (keeping the power factor unchanged) to generate 1000 different initial operating mode scenarios. The load growth coefficient of each scenario increases from 0.02% to 19.98% in a step size of 0.02%.
[0033] The formula for calculating the load growth factor is as follows: in, Let be the load growth coefficient for the k-th sample. The sample index is set to a maximum of 1000. While keeping the power factor of each node constant, a large number of scenarios covering different load levels are generated.
[0034] For each generated initial load scenario, standard power flow calculations are performed to filter the load, retaining only stable scenarios with converged power flow as valid samples. The initial load for each scenario is represented as follows: in, Let be the initial active load of node j. Let j be the baseline active load for node j. Let the initial reactive load of node j be . Let be the baseline reactive load for node j.
[0035] S102: Perform two-stage continuous power flow calculation. In the first stage, perform standard power flow calculation for each initial scenario, select stable scenarios with power flow convergence, and record the total active load of the system in the current scenario and the voltage amplitude and phase angle of all nodes.
[0036] The second phase performs load-type continuous power flow analysis for each stable scenario. By gradually increasing the system load until the voltage collapse criterion of node voltage falling below 0.75 pu or all PV nodes turning into PQ nodes is met, the total active load corresponding to the system voltage collapse point is determined.
[0037] S103: Calculate the static voltage stability margin for each scenario based on the results. The calculation formula is as follows: in, This is the static voltage stability margin. The total active load for the initial load scenario. The total active load at the system voltage collapse point is represented by each sample, which contains 56-dimensional input features (active, reactive, voltage amplitude, and voltage phase angle of 14 nodes) and 1-dimensional output features (static voltage stability margin, VSM), together forming the original dataset.
[0038] Furthermore, in step S200, the preprocessing of the dataset includes steps S201 to S203: S201: Implement stratified sampling. Based on the VSM value of the samples, divide all samples into three data layers: low margin layer (VSM < 0.05), medium margin layer (0.05 ≤ VSM < 0.1), and high margin layer (VSM ≥ 0.1).
[0039] S202: Divide the dataset into training and test sets in an 8:2 ratio, and ensure that the sample proportion of each margin layer in the training and test sets is consistent with that in the original dataset to avoid the problem of missing low-margin samples caused by ordinary random sampling.
[0040] S203: Perform feature standardization, using the robust standardization method (RobustScaler) to standardize the 56-dimensional input features and the 1-dimensional output features (VSM) respectively; Scaling is performed based on the median and interquartile range (IQR) of the data, and the normalization formula is expressed as follows: in, These are the standardized eigenvalues. These are the original eigenvalues. The median of the characteristic, The interquartile range is characterized by its interquartile range.
[0041] It should be noted that this invention generates samples by gradually increasing the load. As the load increases, the calculated static voltage stability margin decreases, and the margin distribution becomes uneven. RobustScaler does not assume a data distribution; it scales based on the median and interquartile range, and does not rely on the mean and standard deviation, thus preserving the true distribution characteristics of eigenvalues under critical conditions. dardScaler assumes that the data follows a normal distribution and scales based on the mean and standard deviation. It is sensitive to outliers and affected by extreme values; therefore, RobustScaler is used to standardize the data.
[0042] Furthermore, in step S300, constructing the fully connected neural network model includes using the standardized training set obtained in S200 to construct and optimize the neural network prediction model.
[0043] S301: The model adopts a lightweight fully connected network architecture, specifically: input layer—first hidden layer—second hidden layer—output layer.
[0044] The input layer receives the standardized 56-dimensional input features, and the output layer outputs the standardized voltage stability margin prediction.
[0045] S302: Each hidden layer contains a linear transformation, batch normalization, and ReLU activation function.
[0046] Among them, Linear(56, 50) maps 56-dimensional input features to a 50-dimensional feature space to extract the basic nonlinear relationship between the power system operating state and static voltage stability margin; BatchNorm1d(50) standardizes the hidden layer output to reduce loss fluctuations during training and accelerate model convergence; ReLU is the activation function that introduces nonlinear transformation to avoid the gradient vanishing problem. It should be noted that the second hidden layer adopts the structure of Linear(50, 50) + BatchNorm1d(50) + ReLU to deepen feature extraction and enhance the model's ability to fit complex nonlinear relationships of the power grid; in addition, the output layer adopts the Linear(50, 1) linear transformation layer to output the standardized voltage stability margin prediction value.
[0047] S303: The fully connected neural network model was determined through a finite hyperparameter search. All comparative experiments were conducted under identical training conditions to ensure comparability of results. The performance comparison results are shown in the table below: Table 1 Performance Comparison Results
[0048] Experimental results show that the network structure with 2 hidden layers and 50 neurons per layer is significantly better than the remaining comparison structures in terms of prediction accuracy. At the same time, the model complexity is moderate, effectively avoiding the risk of overfitting. Therefore, this invention selects the current structure as the optimal architecture.
[0049] Furthermore, in step S300, obtaining the static voltage stability margin prediction model includes steps S311~S313: S311: Define a weighted training objective function. For low-margin samples, which correspond to a state where the system is close to collapse, the prediction accuracy weight should be higher than that of the normal state from a safety perspective. Given that low-margin samples account for a small proportion but are of critical engineering significance, a weighted MSE loss function is adopted. The function introduces a binary masking mechanism to assign a higher weight to the prediction error of the low-margin layer samples (VSM<0.05) defined in step S200 (the weight factor for low-margin samples is set to 5.0 based on engineering experience).
[0050] The weighted MSE loss function is expressed as: in, For the sample size, For the true margin of the k-th sample, The prediction margin for the k-th sample. For low-margin sample masks, This is the weighted MSE loss.
[0051] Furthermore, when calculating the loss, the mask value is set to 1 if the true VSM of the sample is less than 0.05, and otherwise set to 0. The mask value is adjusted using the normalization parameter. After inverse normalization to the original margin, a judgment is made to ensure that the loss of low-margin samples is amplified, guiding the model to focus on learning the feature patterns in extreme scenarios.
[0052] S312: Configure the optimization strategy and convergence control, train the model using an adaptive optimizer (i.e., the Adam optimizer), and set the initial learning rate to 0.0005 and the weight decay to 1e. -4, Combined with a dynamic learning rate scheduler (i.e., the CosineAnnealingLR scheduler), the scheduling period is set to 200.
[0053] It should be noted that for each training cycle, the Adam optimizer is responsible for performing forward propagation, calculating loss, backpropagation, and parameter updates for each training batch; and adaptively adjusting the learning step size of each parameter based on the loss gradient calculated from the current batch of data.
[0054] The cosine annealing learning rate scheduler calculates the new learning rate to be used in the next training cycle based on the cosine formula after each training cycle and notifies the Adam optimizer to adjust the learning rate globally.
[0055] S313: Set an early stop mechanism with a patience value of 15. Training will automatically terminate when the test set loss does not decrease for 15 consecutive rounds.
[0056] The maximum number of training epochs for the model is 200. During the training process, the model parameters with the lowest test loss are saved, and the final static voltage stability margin prediction model is obtained after training.
[0057] It should be noted that the early stopping mechanism evaluates the model's performance at the end of each training cycle to determine whether to terminate training. Training is terminated when the loss function value does not decrease continuously. These three mechanisms work together to save the optimal model parameters.
[0058] In step S400, obtaining the final predicted static voltage stability margin includes steps S401 to S403: S401: Perform preprocessing for input feature standardization, obtain real-time state parameters (i.e., 56-dimensional node information) of the operating mode to be evaluated, and perform standardization using the RobustScaler median and IQR parameters for the input features saved in step S200.
[0059] S402: Perform forward propagation prediction of the model, input the standardized feature vector into the static voltage margin prediction model obtained in step S300, and the model outputs the VSM prediction value in standardized format.
[0060] S403: Perform destandardization post-processing on the prediction results. Using the RobustScaler median and IQR parameters for the output feature (VSM) saved in step S200, destandardize the model output. The destandardization formula is expressed as: in, Destandardized eigenvalues These are the standardized eigenvalues. These are the original eigenvalues. The median of the characteristic, The interquartile range is characterized by its interquartile range.
[0061] This yields a final static voltage stability margin prediction with practical physical meaning (i.e., the same dimensions as the original VSM).
[0062] Furthermore, in step S400, after obtaining the final predicted value, it is applied and verified. The system compares the margin value of the batch prediction with the preset safety threshold (0.05) and actively issues a safety warning for the operation mode that is below the threshold.
[0063] The system calculates the error indices (RMSE, MAE) of the prediction results. For individual extreme scenarios where the prediction error exceeds the set tolerance μ+3σ (μ is the mean absolute error and σ is the standard deviation), the system automatically triggers standard continuous power flow calculations for precise verification, forming a closed-loop safety assessment process that combines human-machine collaboration, rapid response, and precise verification.
[0064] Calculate RMSE, MAE, and R 2 The formula is expressed as: in, Let N be the average of the true margins of the N samples. For the sample size, For the true margin of the k-th sample, The prediction margin for the k-th sample. Root mean square error (RMSE) is the value of the model's predictions. The smaller the value, the smaller the overall deviation between the model's predictions and the actual values. This represents the mean absolute error; the smaller the value, the smaller the model's average prediction error. The coefficient of determination is the closest value to 1, indicating that the model has a stronger ability to explain data variation and better predictive performance.
[0065] It should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and not to limit it. Although the present invention has been described in detail with reference to preferred embodiments, those skilled in the art should understand that modifications or equivalent substitutions can be made to the technical solutions of the present invention without departing from the spirit and scope of the technical solutions of the present invention, and all such modifications or substitutions should be covered within the scope of the claims of the present invention.
[0066] Example 3, referring to Figure 3 This is the third embodiment of the present invention, which provides a fast prediction system for static voltage stability margin, including a dataset generation module, a data preprocessing module, a model building and training module, and an online prediction and verification module.
[0067] The dataset generation module is used to generate an initial mode set containing different load levels using a node load growth strategy, perform standard power flow calculation and continuous power flow calculation on the initial modes, calculate the collapse point and static voltage stability margin, and generate a dataset.
[0068] The data preprocessing module is used to divide the dataset according to the static voltage stability margin of the samples, adopt a stratified sampling method to divide the training set and test set according to the proportion, and keep the distribution of each margin layer in the training set and test set consistent with the original dataset. It also uses a robust standardization method based on median and interquartile range to standardize the input features and output labels.
[0069] The model building and training module is used to build a lightweight fully connected neural network using a preprocessed training set. During training, it improves the fitting ability to key safety boundaries by assigning a weighted loss function to the prediction error of low-margin samples. The module is then optimized and trained using an adaptive optimizer, a cosine annealing learning rate scheduler, and early stopping to generate a prediction model.
[0070] The online prediction and verification module is used to input the real-time state parameters of the operating mode to be evaluated into the trained prediction model after robust standardization, perform millisecond-level margin prediction, destandardize the model output to obtain a margin value with actual physical meaning, set a safety threshold for real-time early warning, and automatically trigger continuous power flow calculation for scenarios where the prediction error exceeds the limit to verify the results.
[0071] It should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and not to limit it. Although the present invention has been described in detail with reference to preferred embodiments, those skilled in the art should understand that modifications or equivalent substitutions can be made to the technical solutions of the present invention without departing from the spirit and scope of the technical solutions of the present invention, and all such modifications or substitutions should be covered within the scope of the claims of the present invention.
[0072] Example 4, the fourth embodiment of the present invention, differs from the previous three embodiments in that: If the aforementioned functions are implemented as software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this invention, essentially, or the part that contributes to the prior art, or a portion of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this invention. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.
[0073] The logic and / or steps represented in the flowchart or otherwise described herein, for example, can be considered as a sequenced list of executable instructions for implementing logical functions, and can be embodied in any computer-readable medium for use by, or in conjunction with, an instruction execution system, apparatus, or device (such as a computer-based system, a processor-including system, or other system that can fetch and execute instructions from, an instruction execution system, apparatus, or device). For the purposes of this specification, "computer-readable medium" can be any means that can contain, store, communicate, propagate, or transmit programs for use by, or in conjunction with, an instruction execution system, apparatus, or device.
[0074] More specific examples of computer-readable media (a non-exhaustive list) include: electrical connections (electronic devices) having one or more wires, portable computer disk drives (magnetic devices), random access memory (RAM), read-only memory (ROM), erasable and editable read-only memory (EPROM or flash memory), fiber optic devices, and portable optical disc read-only memory (CDROM). Furthermore, computer-readable media can even be paper or other suitable media on which the program can be printed, because the program can be obtained electronically, for example, by optically scanning the paper or other medium, followed by editing, interpreting, or otherwise processing as necessary, and then stored in computer memory.
[0075] It should be understood that various parts of the present invention can be implemented in hardware, software, firmware, or a combination thereof. In the above embodiments, multiple steps or methods can be implemented in software or firmware stored in memory and executed by a suitable instruction execution system. For example, if implemented in hardware, as in another embodiment, it can be implemented using any one or a combination of the following techniques known in the art: discrete logic circuits having logic gates for implementing logical functions on data signals, application-specific integrated circuits (ASICs) having suitable combinational logic gates, programmable gate arrays (PGAs), field-programmable gate arrays (FPGAs), etc.
Claims
1. A method for rapid prediction of static voltage stability margin, characterized in that: include, Based on a standard power system, a dataset of output characteristics is generated through systemic load growth and continuous power flow calculations. The dataset is stratified and divided into training and test sets, and a robust standardization method is used to standardize the input and output features respectively. Based on the standardized training set, a fully connected neural network model is constructed. The model is trained using a weighted loss function, an adaptive optimizer, a dynamic learning rate scheduler, and an early stopping mechanism to obtain a static voltage stability margin prediction model. The real-time state parameters of the operating mode to be evaluated are processed by a robust normalization method, input into the prediction model, and the model output values are denormalized to obtain the final static voltage stability margin prediction value.
2. The method for rapid prediction of static voltage stability margin as described in claim 1, characterized in that: The dataset for generating output features includes, for all nodes with initial load, synchronously adjusting active and reactive loads in the same proportion to generate a set of initial operating modes covering different load levels. For each initial operating mode, a continuous power flow analysis is performed to determine the voltage collapse point. Based on the initial total active load and the total active load at the collapse point, the static voltage stability margin of the current mode is calculated.
3. The method for rapid prediction of static voltage stability margin as described in claim 2, characterized in that: The stratified sampling includes dividing the entire dataset into low-margin, medium-margin, and high-margin layers based on the calculated static voltage stability margin value; when dividing the training set and the test set, it is necessary to ensure that the proportion of samples in the training set and the test set of each margin layer is the same as the proportion in the original dataset. The standardization process includes using a standardization method based on the median and interquartile range to standardize the input and output features of all samples in the dataset, thereby obtaining standardized training and test sets.
4. The method for rapid prediction of static voltage stability margin as described in claim 3, characterized in that: The construction of the fully connected neural network model includes constructing a fully connected neural network comprising an input layer, a hidden layer, and an output layer, wherein the hidden layer comprises linear transformation, batch normalization, and a nonlinear activation function; The weighted loss function includes constructing a weighted mean square error loss function and, by introducing a weight allocation mechanism, assigning penalty weights to the sample prediction errors of the low static voltage stability margin layer.
5. The method for rapid prediction of static voltage stability margin as described in claim 4, characterized in that: The training of the model includes using an adaptive moment estimation algorithm as an optimizer and configuring a cosine annealing strategy as a learning rate scheduler to dynamically adjust the learning rate during the training process, setting an early stopping mechanism to terminate training when the model performance no longer improves, and saving the optimal model parameters to obtain a trained static voltage stability margin prediction model.
6. The method for rapid prediction of static voltage stability margin as described in claim 5, characterized in that: The de-standardization process includes performing the inverse operation of robust standardization, using the same standardization parameters as in preprocessing, based on the median and interquartile range of the data, to restore the standardized prediction values output by the model to their original physical dimensions.
7. The method for rapid prediction of static voltage stability margin as described in claim 6, characterized in that: The process of updating the prediction to obtain the final static voltage stability margin prediction value includes comparing the prediction value with a preset safety threshold, issuing an early warning when the prediction value is less than the threshold, and initiating a standard continuous power flow calculation for accurate verification of the operating mode where the prediction error exceeds the set tolerance.
8. A fast prediction system for static voltage stability margin, employing the fast prediction method for static voltage stability margin as described in any one of claims 1 to 7, characterized in that, It includes a dataset generation module, a data preprocessing module, a model building and training module, and an online prediction and validation module; The dataset generation module is used to generate a set of initial operating modes covering different load levels through node load growth strategies, perform standard power flow calculations and continuous power flow analysis on each initial mode, determine the voltage collapse point, calculate the corresponding static voltage stability margin, and construct the dataset. The data preprocessing module is used to divide the dataset according to the static voltage stability margin of the samples, adopt a stratified sampling method to divide the training set and test set according to the proportion, and keep the distribution of each margin layer in the training set and test set consistent with the original dataset. It also uses a robust standardization method based on median and interquartile range to standardize the input features and output labels. The model building and training module is used to build a lightweight fully connected neural network based on the preprocessed training set. During the training process, a weighted loss function is used to assign prediction errors of low-margin samples, and an adaptive optimizer, a cosine annealing learning rate scheduler and an early stopping mechanism are combined to optimize and train the model to obtain a prediction model. The online prediction and verification module is used to input the real-time state parameters of the operating mode to be evaluated into the trained prediction model after robust standardization, perform millisecond-level margin prediction, destandardize the model output to obtain a margin value with actual physical meaning, set a safety threshold for real-time early warning, and automatically trigger continuous power flow calculation for scenarios where the prediction error exceeds the limit to verify the results.
9. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that, When the processor executes the computer program, it implements the steps of the fast prediction method for static voltage stability margin according to any one of claims 1 to 7.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by the processor, it implements the steps of the fast prediction method for static voltage stability margin according to any one of claims 1 to 7.