# Loop-OPF: Solver-Informed Learning for Optimal Power Flow with Inference-Time Topology Adaptivity

arXiv: https://arxiv.org/abs/2611.27013 · HTML: https://mlsanity.com/paper/2611.27013/

## Key facts

- No citing papers in the map yet (data through 24 Nov 2026).
- Builds on 38 of its 70 references that are in the map.
- Submitted 20 Nov 2026, announced 23 Nov 2026.

## Builds on (most cited first, 30 of 38)

- [Adam: A Method for Stochastic Optimization](https://mlsanity.com/paper/1412.6980/) (2014)
- [PyTorch: An Imperative Style, High-Performance Deep Learning Library](https://mlsanity.com/paper/1912.01703/) (2019)
- [Model-Agnostic Meta-Learning for Fast Adaptation of Deep Networks](https://mlsanity.com/paper/1703.03400/) (2017)
- [Convex optimization](https://mlsanity.com/paper/2106.01946/) (2021)
- [Deep Equilibrium Models](https://mlsanity.com/paper/1909.01377/) (2019)
- [Learning to learn by gradient descent by gradient descent](https://mlsanity.com/paper/1606.04474/) (2016)
- [Algorithm Unrolling: Interpretable, Efficient Deep Learning for Signal and Image Processing](https://mlsanity.com/paper/1912.10557/) (2019)
- [Learning to Optimize: A Primer and A Benchmark](https://mlsanity.com/paper/2103.12828/) (2021)
- [DC3: A learning method for optimization with hard constraints](https://mlsanity.com/paper/2104.12225/) (2021)
- [Looped Transformers are Better at Learning Learning Algorithms](https://mlsanity.com/paper/2311.12424/) (2023)
- [End-to-End Constrained Optimization Learning: A Survey](https://mlsanity.com/paper/2103.16378/) (2021)
- [Predicting AC Optimal Power Flows: Combining Deep Learning and Lagrangian Dual Methods](https://mlsanity.com/paper/1909.10461/) (2019)
- [pandapower - an Open Source Python Tool for Convenient Modeling, Analysis and Optimization of Electric Power Systems](https://mlsanity.com/paper/1709.06743/) (2017)
- [The Power Grid Library for Benchmarking AC Optimal Power Flow Algorithms](https://mlsanity.com/paper/1908.02788/) (2019)
- [Optimal Power Flow Using Graph Neural Networks](https://mlsanity.com/paper/1910.09658/) (2019)
- [Self-Supervised Primal-Dual Learning for Constrained Optimization](https://mlsanity.com/paper/2208.09046/) (2022)
- [Physics-Informed Neural Networks for AC Optimal Power Flow](https://mlsanity.com/paper/2110.02672/) (2021)
- [DeepOPF: A Deep Neural Network Approach for Security-Constrained DC Optimal Power Flow](https://mlsanity.com/paper/1910.14448/) (2019)
- [Learning for Constrained Optimization: Identifying Optimal Active Constraint Sets](https://mlsanity.com/paper/1802.09639/) (2018)
- [End-to-End Feasible Optimization Proxies for Large-Scale Economic Dispatch](https://mlsanity.com/paper/2304.11726/) (2023)
- [Practical Large-Scale Linear Programming using Primal-Dual Hybrid Gradient](https://mlsanity.com/paper/2106.04756/) (2021)
- [Learning for DC-OPF: Classifying active sets using neural nets](https://mlsanity.com/paper/1902.05607/) (2019)
- [Topology-aware Graph Neural Networks for Learning Feasible and Adaptive ac-OPF Solutions](https://mlsanity.com/paper/2205.10129/) (2022)
- [Verification of Neural Network Behaviour: Formal Guarantees for Power System Applications](https://mlsanity.com/paper/1910.01624/) (2019)
- [Learning to Solve the AC-OPF using Sensitivity-Informed Deep Neural Networks](https://mlsanity.com/paper/2103.14779/) (2021)
- [Leveraging power grid topology in machine learning assisted optimal power flow](https://mlsanity.com/paper/2110.00306/) (2021)
- [PDHG-Unrolled Learning-to-Optimize Method for Large-Scale Linear Programming](https://mlsanity.com/paper/2406.01908/) (2024)
- [DeepOPF-V: Solving AC-OPF Problems Efficiently](https://mlsanity.com/paper/2103.11793/) (2021)
- [AC Power Flow Data in MATPOWER and QCQP Format: iTesla, RTE Snapshots, and PEGASE](https://mlsanity.com/paper/1603.01533/) (2016)
- [Spatial Network Decomposition for Fast and Scalable AC-OPF Learning](https://mlsanity.com/paper/2101.06768/) (2021)

## Abstract (arXiv)

Learning for optimal power flow (OPF) has recently been advocated to accelerate OPF solutions by using a pre-trained neural network (NN) to predict directly from given inputs such as the load demand. However, existing learning-for-OPF methods largely fall short of ensuring the optimality and feasibility of their predictions. They also struggle to adapt at inference time to unseen topology scenarios, such as those caused by line or generator outages. This work puts forth Loop-OPF, a solver-informed NN that builds its layers from the iterations of the primal-dual hybrid gradient (PDHG) method. Under standard convexity and regularity conditions on DC-OPF, the resultant fixed-point output of Loop-OPF is thus optimal and feasible. To speed up PDHG across diverse OPF scenarios, Loop-OPF learns certain PDHG parameters in a self-supervised manner, without any OPF solution labels. We adopt the deep equilibrium (DEQ) framework for training so that the memory cost does not grow with the number of layers. As the grid topology enters every layer as an input, the same trained Loop-OPF directly adapts to unseen contingencies without retraining. Numerical tests on the IEEE 300-bus and PEGASE 1354-, 2869-, and 9241-bus networks have demonstrated the accuracy and topology adaptivity of the proposed Loop-OPF over competing learning-for-OPF methods.
