Zoltan2
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
Public Member Functions | Static Public Member Functions | Static Public Attributes | List of all members
Zoltan2::ImbalanceMetrics< scalar_t > Class Template Reference

#include <Zoltan2_ImbalanceMetrics.hpp>

Inheritance diagram for Zoltan2::ImbalanceMetrics< scalar_t >:
Inheritance graph
[legend]
Collaboration diagram for Zoltan2::ImbalanceMetrics< scalar_t >:
Collaboration graph
[legend]

Public Member Functions

 ImbalanceMetrics (std::string mname)
 Constructor. More...
 
 ImbalanceMetrics ()
 Constructor. More...
 
virtual const std::string & getMetricType () const
 Get the class type of the metric. More...
 
virtual void printLine (std::ostream &os) const
 Print a standard line of data that fits under the header. More...
 
void setNorm (multiCriteriaNorm normVal)
 Set or reset the norm. More...
 
multiCriteriaNorm getNorm ()
 Get the norm. More...
 
void setLocalSum (scalar_t x)
 Set the sum on the local process. More...
 
void setGlobalSum (scalar_t x)
 Set the global sum. More...
 
void setGlobalMin (scalar_t x)
 Set the global minimum across parts. More...
 
void setGlobalMax (scalar_t x)
 Set the global maximum across parts. More...
 
void setMaxImbalance (scalar_t x)
 Set the imbalance of the worst imbalanced part. This is what we normally call the imbalance of a partition. More...
 
void setAvgImbalance (scalar_t x)
 Set the average imbalance of all parts. More...
 
scalar_t getLocalSum () const
 Get the sum on the local process. More...
 
scalar_t getGlobalSum () const
 Get the global sum for all parts. More...
 
scalar_t getGlobalMin () const
 Get the global minimum across all parts. More...
 
scalar_t getGlobalMax () const
 Get the global maximum across all parts. More...
 
scalar_t getMaxImbalance () const
 Get the imbalance of the most imbalanced part. This is what we normally call the imbalance of a partition. More...
 
scalar_t getAvgImbalance () const
 Get the average of the part imbalances. More...
 
virtual const std::vector
< std::string > & 
getMetrics () const
 
- Public Member Functions inherited from Zoltan2::BaseClassMetrics< scalar_t >
 BaseClassMetrics ()
 Constructor - for compiling but not used. More...
 
 BaseClassMetrics (int memCount, std::string mname)
 Constructor. More...
 
 BaseClassMetrics (int memCount)
 Constructor. More...
 
virtual ~BaseClassMetrics ()
 
const std::string & getName () const
 Get the name of the item measured. More...
 
void setName (std::string name)
 Set or reset the name. More...
 
bool hasMetricValue (const std::string &metric_name) const
 
scalar_t getMetricValue (const std::string &metric_name) const
 
void setMetricValue (const std::string &metric_name, scalar_t value) const
 
size_t convertMetricNameToIndex (const std::string &metric_name) const
 

Static Public Member Functions

static void printHeader (std::ostream &os)
 Print a standard header. More...
 

Static Public Attributes

static std::string static_metricTypeName_ = IMBALANCE_METRICS_TYPE_NAME
 
static std::vector< std::string > static_metricNames_
 
- Static Public Attributes inherited from Zoltan2::BaseClassMetrics< scalar_t >
static std::string static_unknown_metricTypeName_
 
static std::vector< std::string > static_metricNames_ = {}
 
static std::vector< std::string > static_allMetricNames_
 

Detailed Description

template<typename scalar_t>
class Zoltan2::ImbalanceMetrics< scalar_t >

class containing the metrics for one measurable item.

Definition at line 62 of file Zoltan2_ImbalanceMetrics.hpp.

Constructor & Destructor Documentation

template<typename scalar_t >
Zoltan2::ImbalanceMetrics< scalar_t >::ImbalanceMetrics ( std::string  mname)
inline

Constructor.

Definition at line 69 of file Zoltan2_ImbalanceMetrics.hpp.

template<typename scalar_t >
Zoltan2::ImbalanceMetrics< scalar_t >::ImbalanceMetrics ( )
inline

Constructor.

Definition at line 72 of file Zoltan2_ImbalanceMetrics.hpp.

Member Function Documentation

template<typename scalar_t >
virtual const std::string& Zoltan2::ImbalanceMetrics< scalar_t >::getMetricType ( ) const
inlinevirtual

Get the class type of the metric.

Reimplemented from Zoltan2::BaseClassMetrics< scalar_t >.

Definition at line 75 of file Zoltan2_ImbalanceMetrics.hpp.

template<typename scalar_t >
void Zoltan2::ImbalanceMetrics< scalar_t >::printHeader ( std::ostream &  os)
static

Print a standard header.

Definition at line 153 of file Zoltan2_ImbalanceMetrics.hpp.

template<typename scalar_t >
void Zoltan2::ImbalanceMetrics< scalar_t >::printLine ( std::ostream &  os) const
virtual

Print a standard line of data that fits under the header.

Reimplemented from Zoltan2::BaseClassMetrics< scalar_t >.

Definition at line 163 of file Zoltan2_ImbalanceMetrics.hpp.

template<typename scalar_t >
void Zoltan2::ImbalanceMetrics< scalar_t >::setNorm ( multiCriteriaNorm  normVal)
inline

Set or reset the norm.

Definition at line 84 of file Zoltan2_ImbalanceMetrics.hpp.

template<typename scalar_t >
multiCriteriaNorm Zoltan2::ImbalanceMetrics< scalar_t >::getNorm ( )
inline

Get the norm.

Definition at line 87 of file Zoltan2_ImbalanceMetrics.hpp.

template<typename scalar_t >
void Zoltan2::ImbalanceMetrics< scalar_t >::setLocalSum ( scalar_t  x)
inline

Set the sum on the local process.

Definition at line 90 of file Zoltan2_ImbalanceMetrics.hpp.

template<typename scalar_t >
void Zoltan2::ImbalanceMetrics< scalar_t >::setGlobalSum ( scalar_t  x)
inline

Set the global sum.

Definition at line 93 of file Zoltan2_ImbalanceMetrics.hpp.

template<typename scalar_t >
void Zoltan2::ImbalanceMetrics< scalar_t >::setGlobalMin ( scalar_t  x)
inline

Set the global minimum across parts.

Definition at line 96 of file Zoltan2_ImbalanceMetrics.hpp.

template<typename scalar_t >
void Zoltan2::ImbalanceMetrics< scalar_t >::setGlobalMax ( scalar_t  x)
inline

Set the global maximum across parts.

Definition at line 99 of file Zoltan2_ImbalanceMetrics.hpp.

template<typename scalar_t >
void Zoltan2::ImbalanceMetrics< scalar_t >::setMaxImbalance ( scalar_t  x)
inline

Set the imbalance of the worst imbalanced part. This is what we normally call the imbalance of a partition.

Definition at line 102 of file Zoltan2_ImbalanceMetrics.hpp.

template<typename scalar_t >
void Zoltan2::ImbalanceMetrics< scalar_t >::setAvgImbalance ( scalar_t  x)
inline

Set the average imbalance of all parts.

Definition at line 105 of file Zoltan2_ImbalanceMetrics.hpp.

template<typename scalar_t >
scalar_t Zoltan2::ImbalanceMetrics< scalar_t >::getLocalSum ( ) const
inline

Get the sum on the local process.

Definition at line 108 of file Zoltan2_ImbalanceMetrics.hpp.

template<typename scalar_t >
scalar_t Zoltan2::ImbalanceMetrics< scalar_t >::getGlobalSum ( ) const
inline

Get the global sum for all parts.

Definition at line 111 of file Zoltan2_ImbalanceMetrics.hpp.

template<typename scalar_t >
scalar_t Zoltan2::ImbalanceMetrics< scalar_t >::getGlobalMin ( ) const
inline

Get the global minimum across all parts.

Definition at line 114 of file Zoltan2_ImbalanceMetrics.hpp.

template<typename scalar_t >
scalar_t Zoltan2::ImbalanceMetrics< scalar_t >::getGlobalMax ( ) const
inline

Get the global maximum across all parts.

Definition at line 117 of file Zoltan2_ImbalanceMetrics.hpp.

template<typename scalar_t >
scalar_t Zoltan2::ImbalanceMetrics< scalar_t >::getMaxImbalance ( ) const
inline

Get the imbalance of the most imbalanced part. This is what we normally call the imbalance of a partition.

Definition at line 122 of file Zoltan2_ImbalanceMetrics.hpp.

template<typename scalar_t >
scalar_t Zoltan2::ImbalanceMetrics< scalar_t >::getAvgImbalance ( ) const
inline

Get the average of the part imbalances.

Definition at line 125 of file Zoltan2_ImbalanceMetrics.hpp.

template<typename scalar_t >
virtual const std::vector<std::string>& Zoltan2::ImbalanceMetrics< scalar_t >::getMetrics ( ) const
inlinevirtual

method is enforced by the base class.

Reimplemented from Zoltan2::BaseClassMetrics< scalar_t >.

Definition at line 128 of file Zoltan2_ImbalanceMetrics.hpp.

Member Data Documentation

template<typename scalar_t >
std::string Zoltan2::ImbalanceMetrics< scalar_t >::static_metricTypeName_ = IMBALANCE_METRICS_TYPE_NAME
static

a static string name indicating my class name.

class name for string - used to identify by parameter lists.

Definition at line 131 of file Zoltan2_ImbalanceMetrics.hpp.

template<typename scalar_t >
std::vector< std::string > Zoltan2::ImbalanceMetrics< scalar_t >::static_metricNames_
static
Initial value:
= {
"local sum",
"global sum",
"global minimum",
"global maximum",
"global average",
"average imbalance",
"maximum imbalance",
}

a static vector of strings.

all metrics for this class.

Definition at line 134 of file Zoltan2_ImbalanceMetrics.hpp.


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