Leveraging Message Passing GNNs for High-Quality Power Flow Approximation.
PowerFlowNet's distinctiveness, compared to existing PF GNN approaches, lies in its adept utilization of the capabilities from message-passing GNNs and high-order GCNs in a unique arrangement called PowerFlowConv, for handling a trainable masked embedding of the network graph. This innovative approach renders PoweFlowNet remarkably scalable, presenting an effective solution for the PF problem.
The PowerFlowNet Paper can be found at: link
PowerFlowNet transforms the PF into a GNN node-regression problem by representing each bus as a node and each transmission line as an edge while maintaining the network's connectivity.
To train a model run train.py with the desired arguments. For example:
python3 train.py --cfg_json ./configs/standard.json\
--num-epochs 2000\
--data-dir ./data/
--batch-size 128\
--train_loss_fn mse_loss\
--lr 0.001\
--case 118v2\
--model MaskEmbdMultiMPN\
--save
Follow the links below to download the datasets and the trained models used in the paper.
runnable files:
train.py
trains the modelresults.py
plots the results- and more scripts to generate results and plots ...
First two dimensions out of seven in edge_features
are from_node
and to_node
, and they are indexed from PowerFlowData
dataset class. It is reindexed from from_node
and to_node
are removed from the edge_features
tensor.
Raw data format:
Number | Description |
---|---|
N | number of nodes |
E | number of edges |
Fn = 9 | number of features per node |
Fe = 5 | orginally 7, first two dims are from_node and to_node number of features per edge |
Fn_out = 8 | number of output features per node |
Tensor | Dimension |
---|---|
Data.x |
(batch_size*N, Fe) |
Data.edge_index |
(2, E) |
Data.edge_attr |
(E, Fe) |
Data.y |
(batch_size*N, Fn) |
If you use parts of this framework, datasets, or trained models, please cite as:
@article{LIN2024110112,
title = {PowerFlowNet: Power flow approximation using message passing Graph Neural Networks},
journal = {International Journal of Electrical Power & Energy Systems},
volume = {160},
pages = {110112},
year = {2024},
issn = {0142-0615},
doi = {https://doi.org/10.1016/j.ijepes.2024.110112},
author = {Nan Lin and Stavros Orfanoudakis and Nathan Ordonez Cardenas and Juan S. Giraldo and Pedro P. Vergara},
}