Power-grid simulation data factory for PF, DC-OPF, AC-OPF, and SCOPF campaigns with full provenance and preservation.
This repository is initialized from the planning document:
Power_Grid_Foundation_Model_Data_Generation_and_Preservation_Plan.docx.
docs/README.mddocs/project_scope.mddocs/architecture.mddocs/setup.mddocs/external_sources.mddocs/reproducibility.mddocs/scripts_reference.mddocs/production_readiness_checklist.mddocs/first_reproducible_run.mddocs/first_real_case_run.md
GO Challenge duplicate-audit documentation is available at docs/go_challenge_duplicate_audit.md.
- Keep task outputs separated under
data/runs/pf,data/runs/dc_opf,data/runs/ac_opf, anddata/runs/scopf. - Preserve complete attempt artifacts (inputs, raw outputs, logs, intermediate files, normalized outputs, validation, manifests, checksums).
- Never overwrite attempts; append immutable
attempt_<six-digit-index>directories. - Keep DC outputs explicitly marked as approximations (
physical_fidelity: dc_approximation). - Do not use pandapower in production paths.
The default strategy is an adaptive, coverage-constrained, multi-fidelity campaign.
- Candidate selection uses independent acquisition queues with explicit quota budgets.
- DC calculations are treated as screening features, not unilateral accept/reject gates.
- Screening rejects are audited with stratified AC samples.
- Post-solve diversity, active-constraint, and security-boundary ledgers are first-class artifacts.
See docs/adaptive_campaign_strategy.md and configs/campaign_default.yaml.
This initial codebase provides:
- Deterministic naming and run-layout APIs.
- Attempt directory creation with atomic finalization conventions.
- Artifact manifest and checksum generation.
- Integrity verification and preservation audit scripts.
- Global run registry append interface.
- Solver interface with adapters:
PowerModelsAdapter(implemented as process wrapper stub)ExaGOAdapter(stub)
- Julia project skeleton for PowerModels runners.
MATPOWER is used in this project as a case-data format and external reference source, not as an active solver backend.
cd /lustre/orion/lrn070/proj-shared/mlupopa/OPF/power_grid_data_factory
python -m venv .venv
source .venv/bin/activate
pip install -e .
python scripts/validate_run_layout.py --runs-root data/runsdata/runs/<task>/<case_id>/topologies/<topology_id>/operating_points/<operating_point_id>/solvers/<solver_id>/attempts/<attempt_id>/- SCOPF inserts
contingency_sets/<contingency_set_id>/before solver level.
Exactly one marker file must exist per finalized attempt:
SUCCESSFAILEDTIMEOUTCANCELEDNODE_FAILUREINFEASIBLENONCONVERGENTINVALID_INPUTISLANDEDSOLVER_SUCCESS_PRESERVATION_FAILED
scripts/finalize_attempt.pyscripts/verify_attempt_integrity.pyscripts/archive_attempt.pyscripts/verify_archive.pyscripts/audit_preservation.pyscripts/validate_run_layout.py
- Solver execution wrappers are intentionally conservative and preservation-first.
- Add site-specific HPC launch logic in
configs/slurm/andsrc/grid_data_factory/solvers/. - Keep all schema/data model changes backward-compatible and versioned.
- ExaGO cloned under
external/ExaGO - Remote:
https://github.com/ORNL/ExaGO - Current commit:
545a8deb6fa35552f0ee402ca83672fe1255f61a
- GO Challenge Challenge 1 zip archives under
external/go_challenge1/raw/are preserved original downloads from the official DOE Data Catalog entry: - These archives are converted into MATPOWER
.mfiles viascripts/convert_go_challenge_to_matpower.py. - Conversion diagnostics and summary counts are written to
data/analysis/go_challenge1_conversion_report.json.