GridPACK separates network input from simulation output into two distinct subsystems. On the input side, a family of PSS/E RAW parsers (and a MATPOWER parser) read industry-standard files and populate distributedDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/GridOPTICS/GridPACK/llms.txt
Use this file to discover all available pages before exploring further.
DataCollection objects on each MPI rank. On the output side, SerialBusIO and SerialBranchIO gather result strings from all ranks to process 0 for ordered, sequential output. Results can also be exported in JSON or CSV format through ResultsExporter.
PSS/E RAW parsers
GridPACK ships six PTI/PSS/E parsers covering format versions 23 through 36. Each is a header-only template class parameterized by the application network type.| Class | Header | PSS/E version |
|---|---|---|
PTI23Parser | PTI23_parser.hpp | v23 (legacy PTI) |
PTI33Parser | PTI33_parser.hpp | v33 |
PTI34Parser | PTI34_parser.hpp | v34 |
PTI35Parser | PTI35_parser.hpp | v35 |
PTI36Parser | PTI36_parser.hpp | v36 |
Selecting a parser
Parsing a RAW file
Each PTI parser populates a
DataCollection for every bus and branch. The factory’s load() method then transfers those values into the strongly-typed bus and branch component objects.MATPOWER parser
For MATPOWER.mat case files, use MAT_parser:
DataCollection keys used by the PSS/E parsers, so the rest of the application pipeline is format-agnostic.
XML input file structure
Every GridPACK application is driven by an XML configuration file. ThenetworkConfiguration field inside the application block points to the network RAW file:
SerialBusIO
gridpack::serial_io::SerialBusIO<_network> gathers formatted strings from every active bus across all MPI ranks and writes them in global bus index order from process 0.
Component interface required
Each bus class must implement:"voltages", "generation", or "mismatch".
SerialBranchIO
gridpack::serial_io::SerialBranchIO<_network> works identically to SerialBusIO but gathers output from branch components, ordered by global branch index.
Gathering structured data
Both IO classes providegatherData for retrieving typed data (not just strings) to process 0:
ResultsExporter (JSON and CSV)
As of GridPACK 3.6, power flow and contingency analysis results can be exported to JSON or CSV viaResultsExporter. This enables post-processing by downstream tools without parsing fixed-width text files.
Switching between PSS/E versions
Check the RAW file header
Open the
.raw file and read the first line. The version number appears in the metadata string, for example 0, 100, 33, 0, 0, 60.0 / PSS/E-33.Select the matching parser class
Replace
PTI33Parser with PTI34Parser, PTI35Parser, or PTI36Parser in your application source to match the file version.XML configuration system
Detailed reference for the XML file format consumed by all GridPACK parsers.
Factory pattern
How factory.load() transfers parsed DataCollection values into network components.