Bucketized Active Sampling for learning ACOPF

Michael Klamkin, Mathieu Tanneau, Terrence W. K. Mak, Pascal Van Hentenryck

TL;DR

This paper introduces Bucketized Active Sampling (BAS), a novel active learning framework designed to efficiently train machine learning models for approximating Optimal Power Flow (ACOPF) solutions. BAS addresses the challenge of rapidly acquiring high-fidelity ACOPF models in dynamic power systems by intelligently selecting data points for training, significantly reducing the computational burden compared to existing methods.

What Problem Does This Paper Address?

The AC Optimal Power Flow (ACOPF) is a critical but computationally intensive problem in power systems, determining the most economical generation dispatch while respecting physical constraints. For real-time applications, especially with the increasing integration of renewables and demand response, ACOPF solutions need to be updated very frequently (every 5-15 minutes). Traditional methods of training machine learning models (optimization proxies) for ACOPF require solving numerous ACOPF instances, which is time-consuming and expensive. Existing active learning methods, while aiming to reduce data labeling costs, often focus on individual data points and can be inefficient in dynamic environments where the underlying system (e.g., grid topology, generation commitments) changes frequently. This paper tackles the problem of efficiently training accurate ACOPF proxies in a "Just-in-Time" (JIT) manner, minimizing the computational resources and time required for data acquisition and model training.

Methods

The core innovation of this paper is the Bucketized Active Sampling (BAS) framework. Unlike traditional active learning that queries individual data points, BAS partitions the input domain (e.g., based on load factors) into "buckets." It then uses a dedicated "bucket-validation set" to score these buckets, identifying which ones are most in need of additional training data. This approach decouples the assessment of where to sample from the actual sample generation.

Key components of BAS include:

  • Bucketization: The input domain is divided into several buckets. For this work, a one-dimensional base load factor was used for partitioning.
  • Acquisition Functions: These functions score each bucket based on the performance of the current model (DNN) on the labeled validation samples within that bucket. Several acquisition functions are explored, including Loss Error (LE), Input Gradient (IG), and Monte-Carlo Variance (MCV-P, MCV-L). The paper highlights that IG, which uses gradients with respect to input features, is particularly effective.
  • Distributor Function: Based on the bucket scores, this function determines how many new samples to draw from each bucket. A simple proportional distributor is used.
  • Patience-based Scheduling: A novel learning rate adjustment scheme is introduced, which can both decrease (like traditional methods) and increase the learning rate. This helps avoid premature termination and adapts to the addition of new samples.

Datasets

The experiments are conducted on three benchmark power networks:

  • 300_ieee: A public benchmark from PGLib.
  • 1354_pegase: Another public benchmark from PGLib.
  • France-EHV: An industrial proprietary benchmark with 1737 buses, 1731 loads, 290 generators, and 2350 lines/transformers.

Data for training and validation is generated using Algorithm 1 (ACOPF Load Perturbation), which perturbs load values from a nominal point. The bucket-validation set is constructed using a projection from the original sampling distribution onto the feasible space of each bucket.

Key Insights and Ideas

  • Bucketization is Key: Partitioning the input domain into buckets and scoring these buckets, rather than individual points, allows BAS to intelligently allocate computational resources. This is crucial for avoiding wasted effort on regions that are consistently infeasible or less informative.
  • Decoupling Assessment and Sampling: BAS separates the decision of where to sample from the process of how to sample. This allows for more strategic selection of data points.
  • Input Gradients are Powerful: The Input Gradient (IG) acquisition function proved particularly effective because it captures information from both forward evaluations and backward propagations, isolating highly sensitive regions of the input space.
  • Adaptive Learning Rates Help: The ability to both increase and decrease the learning rate (patience-based scheduling) prevents premature convergence and better adapts to the dynamic nature of active learning.
  • Feasibility-Aware Sampling: BAS, particularly with the IG acquisition function, tends to sample more feasible and informative data points, leading to better model performance and efficiency compared to methods that might prioritize uncertainty (like MCDUE) which can lead to sampling infeasible points.

Key Results

  • BAS consistently achieves lower prediction errors (L1-loss) on test sets compared to baseline methods like Inactive Sampling (IS), Random Active Sampling (RAD), and Monte-Carlo Dropout Uncertainty Estimation (MCDUE).
  • BAS, especially with the IG acquisition function, converges significantly faster in terms of prediction accuracy.
  • BAS generates a more balanced distribution of training samples across the input domain, avoiding over-concentration in specific regions.
  • Table II shows that BAS, particularly BAS:IG, generates a much higher proportion of feasible samples compared to MCDUE, indicating more efficient use of computational resources for labeling.

Limitations and Future Work

  • Limitations: The paper acknowledges that while BAS is effective, further improvements can be made. The current implementation uses a fixed partitioning strategy and a simple proportional distributor. The evaluation of acquisition functions was limited to specific types.
  • Future Work: The authors suggest exploring dynamic schemes for:
  • Validation Set Selection: Dynamically choosing the validation set to better reflect the current learning needs.
  • Bucket Partitioning: Developing more adaptive or data-driven methods for partitioning the input domain.
  • Cost-Aware Acquisition Functions: Incorporating explicit costs associated with sampling or solving ACOPF instances into the acquisition function.

Summary updated

BibTeX
@inproceedings{klamkin2024bucketized,
  author = {Michael Klamkin and Mathieu Tanneau and Terrence W. K. Mak and Pascal Van Hentenryck},
  title = {{Bucketized Active Sampling for learning ACOPF}},
  booktitle = {Electric},
  year = {2024},
  doi = {10.1016/j.epsr.2024.110697},
}
Figure