Abstract
Traditional methods for solvability region analysis can only have inner approximations with inconclusive conservatism and handle limited types of power flow models. In this letter, we propose a deep active learning framework for solvability prediction in power systems. Compared with passive learning where the training is performed after all instances are labeled, active learning selects most informative instances to be labeled and therefore significantly reduces the size of the labeled dataset for training. In the active learning framework, the acquisition functions, which correspond to different sampling strategies, are defined in terms of the on-the-fly posterior probability from the classifier. First, the IEEE 39-bus system is employed to validate the proposed framework, where a two-dimensional case is illustrated to visualize the effectiveness of the sampling method followed by the high-dimensional numerical experiments. Then, the Northeast Power Coordinating Council (NPCC) 140-bus system is used to validate the performance on large-scale power systems.
POWER system under the stochastic power injections of renewable energy may exceed the loadability limits and result in voltage collapse. Therefore, it is important to quickly assess if power flow has a solution (i.e., solvable) given a set of power injections. The conventional approach is to solve the power flow equations numerically using iterative methods. However, many real-time operation scenarios desire non-iterative and analytical approaches to determine the solvability. Earlier research focused on solvability conditions of decoupled power flow models [
Despite these innovative works, state-of-the-art analytical condition still cannot handle coupled full power flow models with different types of buses. The most recent work in [
Machine learning techniques have long been employed to amend the shortcomings of analytical methods. The recent success of deep learning has facilitated its application into power flow problems [
To this end, we propose to use deep active learning for solvability prediction that consists of two phases: off-line training and online prediction. In the off-line training phase, we sample power injections over all permissible ranges. This results in very high volumes of samples. Simultaneously, the labeling process requires solving the AC power flow problem of all samples and demands considerable computation resources. Therefore, we employ the active learning framework - a family of machine learning methods which query the data instances to be labeled for training by an oracle (e.g., a human annotator) - to achieve higher accuracy with much fewer labeled examples than passive learning for solvability prediction. Active learning integrates intelligent sampling and machine learning as a closed loop, and it is valuable in the problems where unlabeled data are available but obtaining training labels is expensive. Although sampling towards more informative subspaces has been studied in [
Consider an -bus power network with generator buses and load buses. Let , , and denote the set of all buses, generator buses and load buses, respectively. and represent sets of PQ and PV buses, respectively. The AC power flow equations are as follows:
(1) |
where and are the samples of generation active and reactive power injections at generator bus , respectively; and and are the samples of load active and reactive power injections at load bus , respectively; and are the line conductance and susceptance, respectively; the voltages and angles at bus i are the system state variables, and the angle difference between buses i and j is . The existence of solutions to (1) depends on the values of power injections. Note that in this letter, we relax the feasibility conditions, i.e., the limits of voltage and line flow rating are not considered, although the feasibility scenarios such as voltage violation and transmission line overloading, occur more frequently than the solvability problem. Hence, feasibility constraints are the binding ones in most cases. Nonetheless, the solvability problem could provide some insights when the system is feasible but heavily loaded. In this case, a small perturbation can change both the solvability and feasibility conditions of the power flow solution. In other words, understanding the distance from the current operating point or feasibility boundary to the solvability boundary can be significant for early warning and remedial actions. And characterizing the solvability boundary would be the first step toward such an endeavor.
Hence, the goal is to build a classifier using a multi-layer perception (MLP) model that can separate the solvable power injections from the non-solvable ones. Therefore, the inputs to the deep neural network are power injections defined as . Let , , and denote the sample index, sample numbers, and set of sample indices, respectively. Each sample in X, denoted as (the subscript [s,:] denotes the
(2) |
where indicates that sample belongs to class . We then apply probabilistic smoothing approximations to the discrete label values [
(3) |
Since the output values of the MLP are interpreted as probabilities, they each must lie in the range of (0,1), and they must sum to unity. This can be achieved by using a softmax activation function at the output layer of the MLP.
Assume that we randomly generate a feature set that is sufficiently large to represent the underlying physical features. In traditional passive supervised learning methods, we will generate labels for the entire feature set , denoted as , using the simulation software and result parser, which is regarded as the oracle. The labeling process is computationally demanding if the data set is large and becomes intractable for high-dimensional problems. This is known as the labeling bottleneck, which occurs not only in power systems but also in computer vision, natural language processing, and other machine learning tasks. The active learning framework can overcome such a labeling bottleneck. The pseudocode of the active learning algorithm is formally presented in
(4) |
where denotes the most informative sample selected by the corresponding strategy.
The query strategy aims at evaluating the informativeness of unlabeled instances. There have been many proposed ways to formulate such query strategies in the literature [
(5) |
In the case of multi-class classification, this metric omits information about the remaining labels. To compensate this omission, the margin sampling is introduced as:
(6) |
Besides the aforementioned metrics, the entropy sampling is also widely used to measure the amount of information that is encoded and can only be a metric in active learning:
(7) |
As pointed out in [
It is worth mentioning that (5)-(7) all entail only a simple sorting problem that finds the largest value from a finite set of numerical values. Therefore, the computation complexity of the sampling strategies is the same. Efficient algorithms to solve the sorting problem have been extensively studied, especially in the realm of computer science. To select the most informative samples globally, we will perform this operation on all samples. But the algorithm can be flexible to operate on randomly grouped subsets of the overall sample set to increase the computation time if the entire sample size is too large.
We use the IEEE 39-bus system and Northeast Power Coordinating Council (NPCC) 140-bus system [
Fig. 1 Structure of deep neural network.
During the training, we also face the data imbalance issue as the number of unsolvable samples is larger than that of solvable samples. The classification accuracy, which is the most-used metric for evaluating classification models, can be misguiding under this circumstance, as high metrics cannot guarantee prediction capacity for the minority class. Here, we employ the under-sampling strategy to resolve this issue. With under-sampling, we randomly remove a subset of samples from the class with more instances to match the number of samples coming from each class. In the active learning algorithm, the under-sampling step takes place after the Oracle labels all selected samples.
First, we illustrate a two-dimensional case for visualization purposes. In this case, we uniformly sample active power loads at buses 3 and 4 from MW to MW. Before the training starts, all samples are normalized. We allocate 80% samples for training and 20% samples for testing. The active learner randomly selects 100 samples from the training dataset to label for the initial training phase and queries ten instances in each iteration using the margin sampling strategy. The algorithm terminates if the averaged testing accuracy of the last four iterations is greater than 95% or the algorithm reaches 30 iterations. The margin sampling strategy terminates after seven iterations, and achieves 95.3% accuracy with only 170 labeled samples. While the random strategy fails to meet the accuracy criterion after 30 iterations, achieving only 94.6% accuracy with 400 labeled samples. Samples that are queried by the active learner are plotted as the filled dots, as shown in
Fig. 2 Queried instances by margin sampling strategy that precisely selects instances at solvability boundary.
Second, a high-dimensional scenario is illustrated. Except for the slack bus (Generator 39 at bus 10), active and reactive power outputs of all generators are sampled uniformly between the dispatchable limits. Meanwhile, active and reactive power demands of all loads are sampled using normal distributions, which use the base values as the means and admit 50% standard deviation. We have in total 57 features. All samples are normalized, among which 80% are allocated for training and 20% for testing. In the active learning, 2000 samples are randomly selected for the initial training phase followed by 2000-sample query iterations. We perform ten iterations and compare all the aforementioned sample strategies, including random (baseline), least-confident, margin, and entropy. We conduct five runs with different random seeds and illustrate the results in
Fig. 3 Testing accuracy of different sampling strategies of IEEE 39-bus system.
Fig. 4 Actual accumulated size of training dataset after under-sampling.
We employ the NPCC 140-bus system to validate the scalability of the proposed method [
Fig. 5 Out-of-sample testing accuracies of different sampling strategies of NPCC 140-bus system.
This letter proposes the deep active learning framework for solvability prediction in power systems with full AC power flow models. In this problem, sampling over the full power injection space is necessary, which results in a high volume of data to be labeled. To achieve higher labeling and training efficiency, active learning is employed, where the most informative instances are selected to be labeled. This allows to achieve higher accuracy with much fewer labeled examples.
The sampling effectiveness is first visualized in a two-dimensional case. Then, four different sampling strategies are compared in the high-dimensional solvability prediction. The results indicate that active learning significantly outperforms passive methods and can resolve the data imbalance issue.
REFERENCES
F. Wu and S. Kumagai, “Steady-state security regions of power systems,” IEEE Transactions on Circuits and Systems, vol. 29, no. 11, pp. 703-711, Nov. 1982. [Baidu Scholar]
M. Ilic, “Network theoretic conditions for existence and uniqueness of steady state solutions to electric power circuits,” in Proceedings of 1992 IEEE International Symposium on Circuits and Systems (ISCAS), San Diego, USA, May 1992, pp. 2821-2828. [Baidu Scholar]
S. Bolognani and S. Zampieri, “On the existence and linear approximation of the power flow solution in power distribution networks,” IEEE Transactions on Power Systems, vol. 31, no. 1, pp. 163-172, Feb. 2015. [Baidu Scholar]
C. Wang, A. Bernstein, J.-Y. le Boudec et al., “Explicit conditions on existence and uniqueness of load-flow solutions in distribution networks,” IEEE Tranactions on Smart Grid, vol. 9, no. 2, pp. 953-962, May 2016. [Baidu Scholar]
H. D. Nguyen, K. Dvijotham, S. Yu et al., “A framework for robust long-term voltage stability of distribution systems,” IEEE Transactions on Smart Grid, vol. 10, no. 5, pp. 4827-4837, Sept. 2019. [Baidu Scholar]
K. Dvijotham, H. Nguyen, and K. Turitsyn, “Solvability regions of affinely parameterized quadratic equations,” IEEE Control Systems Letters, vol. 2, no. 1, pp. 25-30, Jan. 2018. [Baidu Scholar]
B. Cui and X. A. Sun. (2019, Apr.). Solvability of power flow equations through existence and uniqueness of complex fixed point. [Online]. Available: https://arxiv.org/abs/1904.08855v1 [Baidu Scholar]
B. Cui and X. A. Sun, “A new voltage stability-constrained optimal power-flow model: sufficient condition, SOCP representation, and relaxation,” IEEE Transactiosn on Power Systems, vol. 33, no. 5, pp. 5092-5102, Sept. 2018. [Baidu Scholar]
F. Dörfler, M. Chertkov, and F. Bullo, “Synchronization in complex oscillator networks and smart grids,” Proceedings of the National Academy of Sciences, vol. 110, no. 6, pp. 2005-2010, Jan. 2013. [Baidu Scholar]
J. W. Simpson-Porco, “A theory of solvability for lossless power flow equations – Part I: fixed-point power flow,” IEEE Transactions on Control of Network Systems, vol. 5, no. 3, pp. 1361-1372, Sept. 2018. [Baidu Scholar]
J. W. Simpson-Porco, “A theory of solvability for lossless power flow equations – Part II: conditions for radial networks,” IEEE Transactions on Control of Network Systems, vol. 5, no. 3, pp. 1373-1385, Sept. 2018. [Baidu Scholar]
D. Cao, W. Hu, X. Xu et al., “Deep reinforcement learning based approach for optimal power flow of distribution networks embedded with renewable energy and storage devices,” Journal of Modern Power Systems and Clean Energy, vol. 9, no. 5, pp. 1101-1110, Sept. 2021. [Baidu Scholar]
Y. Zhou, W.-J. Lee, R. Diao et al., “Deep reinforcement learning based real-time AC optimal power flow considering uncertainties,” Journal of Modern Power Systems and Clean Energy, vol. 10, no. 5, pp. 1098-1109, Sept. 2022. [Baidu Scholar]
Y. Du, F. Li, J. Li et al., “Achieving 100x acceleration for [Baidu Scholar]
contingency screening with uncertain scenarios using deep convolutional neural network,” IEEE Transactions on Power Systems, vol. 34, no. 4, pp. 3303-3305, Jul. 2019. [Baidu Scholar]
X. Pan, T. Zhao, M. Chen et al., “DeepOPF: a deep neural network approach for security-constrained DC optimal power flow,” IEEE Transactions on Power Systems, vol. 36, no. 3, pp. 1725-1735, May 2021. [Baidu Scholar]
X. Hu, H. Hu, S. Verma et al.,“Physics-guided deep neural networks for power flow analysis,” IEEE Transactions on Power Systems, vol. 36, no. 3, pp. 2082-2092, May 2021. [Baidu Scholar]
X. Lei, Z. Yang, J. Yu et al., “Data-driven optimal power flow: a physics-informed machine learning approach,” IEEE Transactions on Power Systems, vol. 36, no. 1, pp. 346-354, Jan. 2021. [Baidu Scholar]
V. Krishnan and J. D. McCalley, “Importance sampling based intelligent test set generation for validating operating rules used in power system operational planning,” IEEE Transactions on Power Systems, vol. 28, no. 3, pp. 2222-2231, Aug. 2013. [Baidu Scholar]
R. A. Dunne, A Statistical Approach to Neural Networks for Pattern Recognition. Hoboken: John Wiley & Sons, 2007. [Baidu Scholar]
B. Settles, “Active learning literature survey,” Tech. Rep., Department of Computer Sciences, University of Wisconsin-Madison, Madison, USA, 2009. [Baidu Scholar]
W. Ju, “Modeling, simulation, and analysis of cascading outages in power systems,” Ph.D. dissertation, Department of Electrical Engineering and Computer Science, University of Tennessee, Knoxville, USA, 2018. [Baidu Scholar]