CkPttn 1.2.4
Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | List of all members
MLPartMgr Class Reference

Multilevel Partition Manager. More...

#include <MLPartMgr.hpp>

Public Member Functions

 MLPartMgr (double bal_tol)
 Constructs a new MLPartMgr object with the given balance tolerance and a default number of partitions (2).
 
 MLPartMgr (double bal_tol, std::uint8_t num_parts)
 Constructs a new MLPartMgr object with the given balance tolerance and number of partitions.
 
void set_limitsize (size_t limit)
 Sets the limit size for the partitioning.
 
template<typename Gnl , typename PartMgr >
auto run_Partition (const Gnl &hyprgraph, std::span< std::uint8_t > part) -> LegalCheck
 Runs the Fiduccia-Mattheyses (FM) partitioning algorithm on the given hypergraph.
 

Public Attributes

int total_cost {}
 Total cost of the current partitioning solution.
 

Detailed Description

Multilevel Partition Manager.

Constructor & Destructor Documentation

◆ MLPartMgr() [1/2]

MLPartMgr::MLPartMgr ( double  bal_tol)
inlineexplicit

Constructs a new MLPartMgr object with the given balance tolerance and a default number of partitions (2).

Parameters
[in]bal_tolThe balance tolerance for the partitioning.

◆ MLPartMgr() [2/2]

MLPartMgr::MLPartMgr ( double  bal_tol,
std::uint8_t  num_parts 
)
inline

Constructs a new MLPartMgr object with the given balance tolerance and number of partitions.

Parameters
[in]bal_tolThe balance tolerance for the partitioning.
[in]num_partsThe number of partitions to create.

Member Function Documentation

◆ run_Partition()

template<typename Gnl , typename PartMgr >
auto MLPartMgr::run_Partition ( const Gnl &  hyprgraph,
std::span< std::uint8_t >  part 
) -> LegalCheck

Runs the Fiduccia-Mattheyses (FM) partitioning algorithm on the given hypergraph.

Template Parameters
GnlThe type of the hypergraph.
PartMgrThe type of the partition manager.
Parameters
[in]hyprgraphThe input hypergraph to partition.
[in,out]partThe partition vector to store the partitioning results.
Returns
LegalCheck The legality check result of the partitioning.

◆ set_limitsize()

void MLPartMgr::set_limitsize ( size_t  limit)
inline

Sets the limit size for the partitioning.

Parameters
[in]limitThe new limit size for the partitioning.

Member Data Documentation

◆ total_cost

int MLPartMgr::total_cost {}

Total cost of the current partitioning solution.


The documentation for this class was generated from the following file: