CkPttn 1.2.4
Loading...
Searching...
No Matches
MLMidLvlPartMgr.hpp
Go to the documentation of this file.
1
6#pragma once
7
8#include <cstdint>
9#include <span>
10
11enum class LegalCheck;
12
23 public:
26
32 explicit MLMidLvlPartMgr(double bal_tol);
33
40 MLMidLvlPartMgr(double bal_tol, std::uint8_t num_parts);
41
47 void set_limitsize(size_t limit) { this->limitsize = limit; }
48
57 template <typename Gnl> auto run_Partition(const Gnl& hyprgraph, std::span<std::uint8_t> part)
58 -> LegalCheck;
59
60 private:
62 double bal_tol;
64 size_t limitsize{50U};
66 static constexpr size_t exhaustive_limit{25U};
67};
LegalCheck
Check if the move of v can satisfied, GetBetter, or NotSatisfied.
Definition FMConstrMgr.hpp:22
Multi-Level Mid-Level Partition Manager (2-way)
Definition MLMidLvlPartMgr.hpp:22
MLMidLvlPartMgr(double bal_tol, std::uint8_t num_parts)
Constructs a new MLMidLvlPartMgr object.
MLMidLvlPartMgr(double bal_tol)
Constructs a new MLMidLvlPartMgr object (default 2 partitions)
int total_cost
Total cost of the current partitioning solution.
Definition MLMidLvlPartMgr.hpp:25
auto run_Partition(const Gnl &hyprgraph, std::span< std::uint8_t > part) -> LegalCheck
Runs the multi-level mid-level partitioning algorithm.
void set_limitsize(size_t limit)
Sets the size limit for multi-level coarsening.
Definition MLMidLvlPartMgr.hpp:47