Most ParMETIS V3 functions accept anDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/KarypisLab/ParMETIS/llms.txt
Use this file to discover all available pages before exploring further.
options array of type idx_t[] as a parameter. This array provides a lightweight mechanism for controlling runtime behavior — such as enabling debug output or fixing the random seed — without recompiling the library. The array has a fixed layout: index 0 acts as a master switch, and indices 1 through 3 carry specific settings when that switch is active.
Enabling and disabling custom options
options[0] value | Behavior |
|---|---|
0 | Use all defaults. Remaining entries in the array are ignored. |
1 | Read custom values from options[1], options[2], and options[3]. |
Options indices
The following constants are defined inlibparmetis/defs.h:
Debug level.
PMV3_OPTION_DBGLVL equals 1. OR together any combination of the PARMETIS_DBGLVL_* flags described below to select the diagnostic output you want.Random number seed.
PMV3_OPTION_SEED equals 2. Setting a fixed seed makes runs reproducible. The default internal seed is 15.Initial partitioning type, used by
ParMETIS_V3_PartKway. PMV3_OPTION_IPART equals 3.Partition-to-subdomain relationship, used by
ParMETIS_V3_RefineKway and ParMETIS_V3_AdaptiveRepart. PMV3_OPTION_PSR also equals 3 — it occupies the same slot as PMV3_OPTION_IPART but applies to different functions.PARMETIS_PSR_COUPLED(1): the number of partitions equals the number of MPI processes.PARMETIS_PSR_UNCOUPLED(2): the number of partitions does not equal the number of MPI processes.
Debug levels
ThePARMETIS_DBGLVL_* constants are defined in include/parmetis.h. They are bit flags and can be combined with the bitwise OR operator (|).
| Constant | Value | Description |
|---|---|---|
PARMETIS_DBGLVL_TIME | 1 | Timing analysis |
PARMETIS_DBGLVL_INFO | 2 | General information |
PARMETIS_DBGLVL_PROGRESS | 4 | Coarsening progress |
PARMETIS_DBGLVL_REFINEINFO | 8 | Refinement information |
PARMETIS_DBGLVL_MATCHINFO | 16 | Matching information |
PARMETIS_DBGLVL_RMOVEINFO | 32 | Vertex move information |
PARMETIS_DBGLVL_REMAP | 64 | Remapping control |
PARMETIS_DBGLVL_TWOHOP | 128 | 2-hop matching |
PARMETIS_DBGLVL_DROPEDGES | 256 | Drop edges during coarsening |
PARMETIS_DBGLVL_FAST | 512 | Reduce trials for speed |
PARMETIS_DBGLVL_ONDISK | 1024 | Save non-active graphs to disk |
PARMETIS_DBGLVL_REMAP (64) controls whether remapping takes place rather than printing a message — setting it alters algorithmic behavior, not just output verbosity.Code examples
Use all defaults (no custom options):ParMETIS_V3_RefineKway in uncoupled mode (partitions ≠ processes):