ug4
ug::IPartitioner Class Referenceabstract

Partitioners can be used inside a LoadBalancer or separately to create partition maps. More...

#include <partitioner.h>

+ Inheritance diagram for ug::IPartitioner:

Public Member Functions

virtual ConstSPProcessHierarchy current_process_hierarchy () const =0
 
virtual void enable_static_partitioning (bool)
 
virtual SubsetHandlerget_partitions ()=0
 
virtual const std::vector< int > * get_process_map () const =0
 returns the processes map. Updated during partitioning. may be NULL. More...
 
 IPartitioner ()
 
virtual ConstSPProcessHierarchy next_process_hierarchy () const =0
 
virtual bool partition (size_t baseLvl, size_t elementThreshold)=0
 
virtual bool problems_occurred ()
 indicates whether problems occurred during the last partitioning More...
 
virtual void set_balance_weights (SPBalanceWeights balanceWeights)
 
virtual void set_communication_weights (SPCommunicationWeights commWeights)
 
virtual void set_next_process_hierarchy (SPProcessHierarchy procHierarchy)=0
 
virtual void set_partition_post_processor (SPPartitionPostProcessor)
 
virtual void set_partition_pre_processor (SPPartitionPreProcessor)
 
virtual void set_subset_handler (SmartPtr< SubsetHandler >)
 
void set_verbose (bool verbose)
 
virtual bool supports_balance_weights () const
 
virtual bool supports_communication_weights () const
 
virtual bool supports_repartitioning () const
 
bool verbose () const
 
virtual ~IPartitioner ()
 
virtual void enable_clustered_siblings (bool bEnable)
 
virtual bool clustered_siblings_enabled ()
 

Protected Attributes

bool m_problemsOccurred
 

Private Attributes

bool m_clusteredSiblings
 
bool m_verbose
 

Detailed Description

Partitioners can be used inside a LoadBalancer or separately to create partition maps.

This is the abstract base class for partitioners.

Constructor & Destructor Documentation

◆ IPartitioner()

ug::IPartitioner::IPartitioner ( )
inline

◆ ~IPartitioner()

virtual ug::IPartitioner::~IPartitioner ( )
inlinevirtual

Member Function Documentation

◆ clustered_siblings_enabled()

virtual bool ug::IPartitioner::clustered_siblings_enabled ( )
inlinevirtual

clustered siblings help to ensure that all vertices which are connected to a constrained vertex through are on the same process as the constrained vertex. If only refinement is performed, it would be sufficient to only cluster constrained siblings. However, coarsening would be rather complicated in that case, since it is rather complicated to introduce constrained sibling elements if a previously unconstrained sibling is not located on the same process...

If you only perform global refinement, you may safely disable clustered siblings. The distribution quality is most likely better in this case.

Note
enabled by default

References m_clusteredSiblings.

◆ current_process_hierarchy()

virtual ConstSPProcessHierarchy ug::IPartitioner::current_process_hierarchy ( ) const
pure virtual

◆ enable_clustered_siblings()

virtual void ug::IPartitioner::enable_clustered_siblings ( bool  bEnable)
inlinevirtual

clustered siblings help to ensure that all vertices which are connected to a constrained vertex through are on the same process as the constrained vertex. If only refinement is performed, it would be sufficient to only cluster constrained siblings. However, coarsening would be rather complicated in that case, since it is rather complicated to introduce constrained sibling elements if a previously unconstrained sibling is not located on the same process...

If you only perform global refinement, you may safely disable clustered siblings. The distribution quality is most likely better in this case.

Note
enabled by default

References m_clusteredSiblings.

◆ enable_static_partitioning()

virtual void ug::IPartitioner::enable_static_partitioning ( bool  )
inlinevirtual

◆ get_partitions()

virtual SubsetHandler& ug::IPartitioner::get_partitions ( )
pure virtual

◆ get_process_map()

virtual const std::vector<int>* ug::IPartitioner::get_process_map ( ) const
pure virtual

returns the processes map. Updated during partitioning. may be NULL.

If NULL is returned, this means that each subset index correspons to a global proc-rank.

Implemented in ug::Partitioner_DynamicBisection< TElem, dim >.

◆ next_process_hierarchy()

virtual ConstSPProcessHierarchy ug::IPartitioner::next_process_hierarchy ( ) const
pure virtual

◆ partition()

virtual bool ug::IPartitioner::partition ( size_t  baseLvl,
size_t  elementThreshold 
)
pure virtual

If the partitioner returns false, no partition-map has been created and no redistribution should be performed. Note, that returning false is not a sign of an error - it may even be a feature of a particular partitioner.

Implemented in ug::Partitioner_DynamicBisection< TElem, dim >.

◆ problems_occurred()

virtual bool ug::IPartitioner::problems_occurred ( )
inlinevirtual

indicates whether problems occurred during the last partitioning

Note
if partition(...) returns true, the partition map is valid, even if problems occured. It may however not be optimal.

References m_problemsOccurred.

◆ set_balance_weights()

virtual void ug::IPartitioner::set_balance_weights ( SPBalanceWeights  balanceWeights)
inlinevirtual

◆ set_communication_weights()

virtual void ug::IPartitioner::set_communication_weights ( SPCommunicationWeights  commWeights)
inlinevirtual

◆ set_next_process_hierarchy()

virtual void ug::IPartitioner::set_next_process_hierarchy ( SPProcessHierarchy  procHierarchy)
pure virtual

◆ set_partition_post_processor()

virtual void ug::IPartitioner::set_partition_post_processor ( SPPartitionPostProcessor  )
inlinevirtual

◆ set_partition_pre_processor()

virtual void ug::IPartitioner::set_partition_pre_processor ( SPPartitionPreProcessor  )
inlinevirtual

◆ set_subset_handler()

virtual void ug::IPartitioner::set_subset_handler ( SmartPtr< SubsetHandler )
inlinevirtual

◆ set_verbose()

void ug::IPartitioner::set_verbose ( bool  verbose)
inline

References m_verbose, and verbose().

◆ supports_balance_weights()

virtual bool ug::IPartitioner::supports_balance_weights ( ) const
inlinevirtual

◆ supports_communication_weights()

virtual bool ug::IPartitioner::supports_communication_weights ( ) const
inlinevirtual

◆ supports_repartitioning()

virtual bool ug::IPartitioner::supports_repartitioning ( ) const
inlinevirtual

◆ verbose()

bool ug::IPartitioner::verbose ( ) const
inline

References m_verbose.

Referenced by set_verbose().

Member Data Documentation

◆ m_clusteredSiblings

bool ug::IPartitioner::m_clusteredSiblings
private

◆ m_problemsOccurred

bool ug::IPartitioner::m_problemsOccurred
protected

Referenced by problems_occurred().

◆ m_verbose

bool ug::IPartitioner::m_verbose
private

Referenced by set_verbose(), and verbose().


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