Hypergraph Partitioner Collection
This repository contains a collection of commonly used (hyper)graph partitioners and provides scripts to simplify setup and execution.
Installation
Simply execute:
git submodule init
git submodule update
./install.sh
Execute a (Hyper)graph Partitioner
Before you can use the python interface scripts for each partitioner (see folder scripts
), please make sure that env.sh
contains the correct paths to each subprogram required for execution. If so, execute source env.sh
to make the changes visible for the python interfaces. Afterwards, you can start a partitioner by executing the following command:
Serial Partitioner:
<partitioner>.py <graph/hypergraph-file> <number-of-blocks> <epsilon> <seed> <objective> <timelimit>
Parallel Partitioner
<partitioner>.py <graph/hypergraph-file> <number-of-threads> <number-of-blocks> <epsilon> <seed> <objective> <timelimit>
Hypergraph Formats
hMetis, KaHyPar, MT-KaHyPar, and Hype require that the input hypergraph file is in hMetis format (see hMetis User Guide). Parkway uses a binary representation of an already distributed hypergraph. However, our python interface expects the hypergraph in hMetis format and the conversion to the internal Parkway format is done inside our python script. Please make sure that the helper tool HgrToParkway is built inside the MT-KaHyPar partitioner (make HgrToParkway
).
Mondriaan uses a matrix representation as input hypergraph file. You can convert a hypergraph in hMetis format to Mondriaan form via tool HgrToMondriaanMtx inside the KaHyPar partitioner (make HgrToMondriaanMtx
). Please make sure that the corresponding hMetis hypergraph file is inside the same folder than the Mondriaan hypergraph file if you execute the mondriaan python interface script.
PaToH and Zoltan also use different hypergraph file representations. You can convert a hMetis hypergraph file via HgrToPatoh (inside the KaHyPar partitioner) resp. HgrToZoltan (inside the MT-KaHyPar partitioner) to PaToH resp. Zoltan hypergraph file format. Please make sure that Zoltan hypergraph file names ends with .zoltan.hg
.