Self-Supervised Learning for Large-Scale Preventive Security Constrained DC Optimal Power Flow

Seonho Park, Pascal Van Hentenryck

TL;DR

This paper introduces PDL-SCOPF, a self-supervised learning framework that solves large-scale Security-Constrained Optimal Power Flow (SCOPF) problems in milliseconds. By integrating differentiable "repair" and "binary search" layers into a primal-dual learning architecture, the model produces near-optimal, feasible dispatch solutions for grids with over 6,500 buses without requiring any pre-computed optimal labels for training.

What Problem Does This Paper Address?

Modern power grid operations rely on the Security-Constrained Optimal Power Flow (SCOPF) to ensure the system remains stable even if a single component (a generator or transmission line) fails—the "N-1" reliability criterion.

As grids grow larger and more volatile due to renewable energy, solving SCOPF becomes a computational nightmare. Traditional methods use Mixed-Integer Linear Programming (MILP), which suffers from a combinatorial explosion of binary variables as the number of possible contingencies increases. For a grid with thousands of buses, finding an optimal solution can take hours. While Machine Learning (ML) offers a faster alternative, standard supervised learning requires thousands of "ground truth" optimal solutions to train, which are themselves too expensive to compute for large-scale systems.

Methods

The authors propose PDL-SCOPF, which stands for Primal-Dual Learning for SCOPF. The framework is "self-supervised," meaning it learns directly from the physical constraints and objective functions of the power grid rather than from labeled examples.

Key technical innovations include:

  • Primal-Dual Architecture: The framework uses two neural networks. The Primal Network predicts the generator dispatches, while the Dual Network estimates the Lagrangian multipliers (shadow prices). This setup mimics the Augmented Lagrangian Method (ALM) used in classical optimization.
  • Power Balance Repair Layer: A specialized differentiable layer that mathematically adjusts the predicted base-case dispatch to ensure that total generation exactly matches total demand, satisfying the fundamental physics of the grid.
  • Differentiable Binary Search Layer: To handle generator failures, the model must account for the Automatic Primary Response (APR)—how other generators ramp up to fill the gap. The authors implemented a differentiable binary search within the neural network to simulate this response during training.
  • End-to-End Training: Because all components (including the repair and binary search layers) are differentiable, the entire system can be trained using backpropagation to minimize costs and constraint violations simultaneously.

Datasets

The model was evaluated using the Power Grid Library (PGLIB) benchmarks, specifically targeting large-scale cases:

  • Standard Cases: 300_ieee, 1354_peg, 1888_rte.
  • Large-Scale Cases: 3022_goc, 4917_goc, and the 6515_rte (representing a grid with 6,515 buses and nearly 700 generators).
  • Data Perturbation: To create a robust training set, the authors perturbed load demands (up to ±50%), cost coefficients, and generator capacities to simulate a wide variety of operating conditions.

Key Insights and Ideas

  • Bypassing the Label Bottleneck: By using self-supervision, the authors proved that you don't need to solve the MILP thousands of times to train a model. The physics of the problem provides enough signal for the network to learn.
  • Physics-Informed Inductive Bias: Instead of letting the neural network "guess" how to satisfy constraints, the authors hard-coded the logic (like the APR response) into differentiable layers. This ensures the model's outputs are physically meaningful.
  • Scalability via Duality: Predicting dual variables (multipliers) allows the model to navigate the complex "landscape" of constraints much more effectively than simple penalty-based methods, which often struggle to reach feasibility in high-dimensional spaces.

Key Results

  • Massive Speedup: On the largest test case (6515_rte), PDL-SCOPF provided solutions in roughly 10–50 milliseconds. In comparison, the traditional CCGA solver took an average of 9,560 seconds (over 2.5 hours) for a single instance. This represents a speedup of roughly four orders of magnitude.
  • Near-Optimality: The "optimality gap" (how much more expensive the ML solution is compared to the true mathematical optimum) was consistently below 1% for the largest cases.
  • Feasibility: Unlike standard supervised ML baselines, which often failed to satisfy hard power balance constraints, PDL-SCOPF achieved zero or negligible violations across all tested contingencies.

Limitations and Future Work

  • DC vs. AC: This work uses the DC approximation, which simplifies the physics of power flow (ignoring reactive power and voltage magnitudes). Real-world operations eventually require AC-SCOPF, which is non-linear and significantly more complex.
  • Fixed Topology: The current model assumes a fixed grid structure. Future work could incorporate Graph Neural Networks (GNNs) to handle changes in grid topology (e.g., line maintenance or permanent outages).
  • Stochasticity: The authors suggest extending the framework to handle Stochastic SCOPF, which accounts for the uncertainty of wind and solar generation directly within the optimization.

Summary updated

BibTeX
@article{park2024self,
  author = {Seonho Park and Pascal Van Hentenryck},
  title = {{Self-Supervised Learning for Large-Scale Preventive Security Constrained DC Optimal Power Flow}},
  journal = {IEEE Transactions on Power Systems},
  year = {2024},
  doi = {10.1109/tpwrs.2024.3498705},
}
Figure