genco-opfdata / README.md
albanpuech's picture
Include the main-branch install and downloads in the evaluate block.
74e19e1 verified
|
Raw History Blame Contribute Delete
2.03 kB
---
library_name: gridfm-graphkit
pipeline_tag: tabular-regression
license: apache-2.0
tags:
- power-systems
- optimal-power-flow
- genco
- opfdata
---
GENCO optimal-power-flow checkpoints on OPFData ([paper](https://arxiv.org/abs/2608.09921)): IEEE 14, 30, 57, and 118, and GOC 500 and 2000, seeds 42, 3, and 17.
Evaluate on the paper branch by following [GENCO §5.2](https://github.com/gridfm/gridfm-paper-genco/blob/main/repro_instructions/5.2_OPF_on_opfdata.md). That guide uses graphkit [genco-paper-repro](https://github.com/gridfm/gridfm-graphkit/tree/genco-paper-repro) and is how the paper numbers were produced.
Or evaluate the same checkpoints on graphkit [main](https://github.com/gridfm/gridfm-graphkit/tree/main). `main` is under development, so the same numbers are not guaranteed. They matched the paper-branch result at commit [`f104900`](https://github.com/gridfm/gridfm-graphkit/commit/f104900245cba26d1380037eea562cf633a97484) (1 October 2026).
```bash
git clone https://github.com/gridfm/gridfm-graphkit.git
cd gridfm-graphkit
pip install -e .
pip install "huggingface_hub[cli]"
TORCH_CUDA_VERSION=$(python -c "import torch; print(torch.__version__ + ('+cpu' if torch.version.cuda is None else ''))")
pip install torch-scatter -f https://data.pyg.org/whl/torch-${TORCH_CUDA_VERSION}.html
export MLFLOW_ALLOW_FILE_STORE=true
mkdir -p data/case118_ieee/raw scripts/opfdata/splits
hf download gridfm/opfdata_case118_ieee --repo-type dataset --local-dir data/case118_ieee/raw
hf download gridfm/genco-opfdata --include "splits/*" --include "case118_ieee/seed42/**" --local-dir genco-opfdata
cp genco-opfdata/splits/*.pt scripts/opfdata/splits/
gridfm_graphkit evaluate \
--config_conversion auto_inline \
--config genco-opfdata/case118_ieee/seed42/HGNSQ_penalty_11_OPFData_case118_default.yaml \
--data_path data \
--model_path genco-opfdata/case118_ieee/seed42/best_model_state_dict.pt \
--normalizer_stats genco-opfdata/case118_ieee/seed42/normalizer_stats.pt \
--batch_size 512
```