|
void | ArbitrateAndCommunicate (Vector &weights, Aggregates &aggregates, const bool perturb) const |
| This method assigns unknowns to aggregates. More...
|
|
void | ArbitrateAndCommunicate (Vector &weight, LOVector &procWinner, LOMultiVector *companion, const bool perturb) const |
| This class uses a weighted rendezvous algorithm to do a global reduction on a vector that may be based on a non unique map. More...
|
|
void | NonUnique2NonUnique (const Vector &source, Vector &dest, const Xpetra::CombineMode what) const |
| Redistribute data in source to dest where both source and dest might have multiple copies of the same global id across many processors. More...
|
|
virtual | ~BaseClass () |
| Destructor. More...
|
|
VerbLevel | GetVerbLevel () const |
| Get the verbosity level. More...
|
|
void | SetVerbLevel (const VerbLevel verbLevel) |
| Set the verbosity level of this object. More...
|
|
int | GetProcRankVerbose () const |
| Get proc rank used for printing. Do not use this information for any other purpose. More...
|
|
int | SetProcRankVerbose (int procRank) const |
| Set proc rank used for printing. More...
|
|
bool | IsPrint (MsgType type, int thisProcRankOnly=-1) const |
| Find out whether we need to print out information for a specific message type. More...
|
|
Teuchos::FancyOStream & | GetOStream (MsgType type, int thisProcRankOnly=0) const |
| Get an output stream for outputting the input message type. More...
|
|
Teuchos::FancyOStream & | GetBlackHole () const |
|
| VerboseObject () |
|
virtual | ~VerboseObject () |
| Destructor. More...
|
|
| VerboseObject (const EVerbosityLevel verbLevel=VERB_DEFAULT, const RCP< FancyOStream > &oStream=Teuchos::null) |
|
virtual const VerboseObject & | setVerbLevel (const EVerbosityLevel verbLevel) const |
|
virtual const VerboseObject & | setOverridingVerbLevel (const EVerbosityLevel verbLevel) const |
|
virtual EVerbosityLevel | getVerbLevel () const |
|
TEUCHOSPARAMETERLIST_LIB_DLL_EXPORT
RCP< const ParameterList > | getValidVerboseObjectSublist () |
|
TEUCHOSPARAMETERLIST_LIB_DLL_EXPORT
void | setupVerboseObjectSublist (ParameterList *paramList) |
|
TEUCHOSPARAMETERLIST_LIB_DLL_EXPORT
void | readVerboseObjectSublist (ParameterList *paramList, RCP< FancyOStream > *oStream, EVerbosityLevel *verbLevel) |
|
void | readVerboseObjectSublist (ParameterList *paramList, VerboseObject< ObjectType > *verboseObject) |
|
virtual | ~VerboseObjectBase () |
|
| VerboseObjectBase (const RCP< FancyOStream > &oStream=Teuchos::null) |
|
virtual const VerboseObjectBase & | setOStream (const RCP< FancyOStream > &oStream) const |
|
virtual const VerboseObjectBase & | setOverridingOStream (const RCP< FancyOStream > &oStream) const |
|
virtual VerboseObjectBase & | setLinePrefix (const std::string &linePrefix) |
|
virtual RCP< FancyOStream > | getOStream () const |
|
virtual RCP< FancyOStream > | getOverridingOStream () const |
|
virtual std::string | getLinePrefix () const |
|
virtual OSTab | getOSTab (const int tabs=1, const std::string &linePrefix="") const |
|
virtual | ~Describable () |
| Destructor. More...
|
|
virtual std::string | ShortClassName () const |
| Return the class name of the object, without template parameters and without namespace. More...
|
|
virtual void | describe (Teuchos::FancyOStream &out_arg, const VerbLevel verbLevel=Default) const |
|
virtual std::string | description () const |
| Return a simple one-line description of this object. More...
|
|
void | describe (Teuchos::FancyOStream &out, const Teuchos::EVerbosityLevel verbLevel=Teuchos::Describable::verbLevel_default) const |
| Print the object with some verbosity level to an FancyOStream object. More...
|
|
void | describe (std::ostream &out, const EVerbosityLevel verbLevel=verbLevel_default) const |
|
| LabeledObject () |
|
virtual | ~LabeledObject () |
|
virtual void | setObjectLabel (const std::string &objectLabel) |
|
virtual std::string | getObjectLabel () const |
|
DescribableStreamManipulatorState | describe (const Describable &describable, const EVerbosityLevel verbLevel=Describable::verbLevel_default) |
|
std::ostream & | operator<< (std::ostream &os, const DescribableStreamManipulatorState &d) |
|
template<class LocalOrdinal = int, class GlobalOrdinal = LocalOrdinal, class Node = KokkosClassic::DefaultNode::DefaultNodeType>
class MueLu::CoupledAggregationCommHelper< LocalOrdinal, GlobalOrdinal, Node >
Helper class for providing arbitrated communication across processors.
For more details, see the comments for the ArbitrateAndCommunicate methods.
Definition at line 70 of file MueLu_CoupledAggregationCommHelper_decl.hpp.
template<class LocalOrdinal , class GlobalOrdinal , class Node >
void MueLu::CoupledAggregationCommHelper< LocalOrdinal, GlobalOrdinal, Node >::ArbitrateAndCommunicate |
( |
Vector & |
weight, |
|
|
LOVector & |
procWinner, |
|
|
LOMultiVector * |
companion, |
|
|
const bool |
perturb |
|
) |
| const |
This class uses a weighted rendezvous algorithm to do a global reduction on a vector that may be based on a non unique map.
A non-unique map is one that has at least one global ID that occurs on two or more processes. For each repeated ID \(i\), the algorithm finds the maximum value \(v[i]\) in the weight vector \(v\). This value is communicated to all processors that have \(i\) in their local map. More details are below.
For each GlobalId \(K\) associated with weight.getMap():
-# Find the maximum absolute value of \form#4 across all
processors and assign this to all local elements of weight[] (across
processors) that are associated with \form#3.
-# Set procWinner[] to the MyPid() that had the largest element.
procWinner[] is still set if only one processor owns a GlobalId.
The ONLY CASE when procWinner[i] is NOT set corresponds to when
all local weights associated with a GlobalId are zero. This allows
one to effectively skip the maximum/winner calculation for a subset
of GlobalId's. This might occur when a processor has already
claimed ownership for a GlobalId and so all local copies have
the same value. We want to skip the maximum calculation with
tiebreaking to avoid another processor claiming ownership.
-# Optionally, set companion[] (across all relevant processors) to the
local companion value associated with the procWinner[] processor.
@param weight[in,out]
- On input, vector of NONNEGATIVE weights.
- On output, \form#5
where \form#6 is processor \form#7's value for GID \form#8.
@param procWinner[in,out]
- On input, allocated but contents ignored.
- On output, \form#9 such that
\(\mbox{weight}[k_{pj}] = \max(\mbox{weight}[k_{p1}],...,\mbox{weight}[k_{pn}])\), where \( \mbox{weight}[k_{pj}] \) is processor \(pj\)'s value for GID \(k\). NOTE: If all input \(\mbox{weight}[k_{pi}]\)'s are zero, then \(\mbox{procWinner}[k]\) is left untouched.
- Parameters
-
companion[in,out] |
- On input, either NULL or allocated but contents ignored. If NULL, step 3 above is skipped.
- On output, if not null, \(\mbox{companion}[k] \Leftarrow \mbox{companion}[k_j]\) where \(\mbox{companion}[k_j]\) lives on processor \(\mbox{procWinner}[k]\). and corresponds to the same GlobalId as \(k\). NOTE: If for a particular GlobalId, no processor has a value of procWinner that matches its MyPid, the corresponding companion is not altered.
|
@param perturb[in] Optional arguments that is either true or
false (default: true). weight is perturbed
and the perturbed values are used in step 1)
above. Returned values reflect the perturbed
data. This option avoids having lots of
tiebreaks where the large MyPid() always wins.
Definition at line 73 of file MueLu_CoupledAggregationCommHelper_def.hpp.
template<class LocalOrdinal , class GlobalOrdinal , class Node >
Redistribute data in source to dest where both source and dest might have multiple copies of the same global id across many processors.
The source may not have the same value for all of these multiple copies, but on termination dest will have a unique value for each global id. When multiple copies exist in source, 'what' determines how they are combined to make a unique value in dest (see CombineMode).
Input:
- Parameters
-
[in] | source | Vector where multiple copies of some GlobalIds might exist and might have different values. |
[in,out] | dest | On input, allocated but contents ignored. On output, contains redistributed data from source where 'what' determines how multiple copies of source values associated with the same GlobalId are combined into a unique value on all processors. |
[in] | what | Determines how multiple copies of the same GlobalId are combined (see CombineMode). |
Definition at line 475 of file MueLu_CoupledAggregationCommHelper_def.hpp.