Arcane  4.1.12.0
Developer documentation
Loading...
Searching...
No Matches
Arcane::MetisGraphDigest Class Reference

Calculates a global checksum of Metis inputs/outputs. More...

#include <arcane/std/internal/MetisGraphDigest.h>

Inheritance diagram for Arcane::MetisGraphDigest:
Collaboration diagram for Arcane::MetisGraphDigest:

Public Member Functions

 MetisGraphDigest (IParallelMng *pm)
String computeInputDigest (const bool need_part, const int nb_options, const MetisGraphView &my_graph, const idx_t *vtxdist, const idx_t *wgtflag, const idx_t *numflag, const idx_t *ncon, const idx_t *nparts, const real_t *tpwgts, const real_t *ubvec, const real_t *ipc2redist, const idx_t *options)
String computeOutputDigest (const MetisGraphView &my_graph, const idx_t *edgecut)
Public Member Functions inherited from Arcane::TraceAccessor
 TraceAccessor (ITraceMng *m)
 Constructs an accessor via the trace manager m.
 TraceAccessor (const TraceAccessor &rhs)
 Copy constructor.
TraceAccessoroperator= (const TraceAccessor &rhs)
 Copy assignment operator.
virtual ~TraceAccessor ()
 Frees resources.
ITraceMngtraceMng () const
 Trace manager.
TraceMessage info () const
 Flow for an information message.
TraceMessage pinfo () const
 Flow for a parallel information message.
TraceMessage info (char category) const
 Flow for an information message of a given category.
TraceMessage pinfo (char category) const
 Flow for a parallel information message of a given category.
TraceMessage info (bool v) const
 Flow for an information message.
TraceMessage warning () const
 Flow for a warning message.
TraceMessage pwarning () const
TraceMessage error () const
 Flow for an error message.
TraceMessage perror () const
TraceMessage log () const
 Flow for a log message.
TraceMessage plog () const
 Flow for a log message.
TraceMessage logdate () const
 Flow for a log message preceded by the date.
TraceMessage fatal () const
 Flow for a fatal error message.
TraceMessage pfatal () const
 Flow for a parallel fatal error message.
TraceMessageDbg debug (Trace::eDebugLevel=Trace::Medium) const
 Flow for a debug message.
Trace::eDebugLevel configDbgLevel () const
 Debug level of the configuration file.
TraceMessage info (Int32 verbose_level) const
 Flow for an information message of a given level.
TraceMessage linfo () const
 Flow for an information message with the local information level of this instance.
TraceMessage linfo (Int32 relative_level) const
 Flow for an information message with the local information level of this instance.
void fatalMessage (const StandaloneTraceMessage &o) const

Private Member Functions

void _computeHash (Span< const idx_t > data, ByteArray &output, const char *name)
void _computeHash (Span< const real_t > data, ByteArray &output, const char *name)
String _digestString (ConstArrayView< Byte > my_digest)
 From the local sum, calculates the global sum and returns a string representing this sum (only on processor 0; other processors have an empty string).

Private Attributes

IParallelMngm_parallel_mng = nullptr
Int32 m_my_rank = A_NULL_RANK
Int32 m_nb_rank = 0

Additional Inherited Members

Protected Member Functions inherited from Arcane::TraceAccessor
void _setLocalVerboseLevel (Int32 v)
Int32 _localVerboseLevel () const

Detailed Description

Calculates a global checksum of Metis inputs/outputs.

Definition at line 38 of file MetisGraphDigest.h.

Constructor & Destructor Documentation

◆ MetisGraphDigest()

Arcane::MetisGraphDigest::MetisGraphDigest ( IParallelMng * pm)
explicit

Definition at line 41 of file MetisGraphDigest.cc.

Member Function Documentation

◆ _computeHash() [1/2]

void Arcane::MetisGraphDigest::_computeHash ( Span< const idx_t > data,
ByteArray & output,
const char * name )
private

Definition at line 82 of file MetisGraphDigest.cc.

◆ _computeHash() [2/2]

void Arcane::MetisGraphDigest::_computeHash ( Span< const real_t > data,
ByteArray & output,
const char * name )
private

Definition at line 94 of file MetisGraphDigest.cc.

◆ _digestString()

String Arcane::MetisGraphDigest::_digestString ( ConstArrayView< Byte > my_digest)
private

From the local sum, calculates the global sum and returns a string representing this sum (only on processor 0; other processors have an empty string).

Definition at line 57 of file MetisGraphDigest.cc.

References Arcane::TraceAccessor::info(), and Arcane::Convert::toHexaString().

Referenced by computeInputDigest(), and computeOutputDigest().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ computeInputDigest()

String Arcane::MetisGraphDigest::computeInputDigest ( const bool need_part,
const int nb_options,
const MetisGraphView & my_graph,
const idx_t * vtxdist,
const idx_t * wgtflag,
const idx_t * numflag,
const idx_t * ncon,
const idx_t * nparts,
const real_t * tpwgts,
const real_t * ubvec,
const real_t * ipc2redist,
const idx_t * options )

Calculates a "global" checksum of Metis inputs and returns it only for the rank 0 processor in the communicator comm. For other processors, the returned string is empty. The checksum is global in the sense that all processors participate in its construction.

Definition at line 109 of file MetisGraphDigest.cc.

References _digestString().

Referenced by Arcane::MetisWrapper::callAdaptiveRepart(), and Arcane::MetisWrapper::callPartKway().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ computeOutputDigest()

String Arcane::MetisGraphDigest::computeOutputDigest ( const MetisGraphView & my_graph,
const idx_t * edgecut )

Calculates a "global" checksum of Metis outputs and returns it only for the rank 0 processor in the communicator comm. For other processors, the returned string is empty. The checksum is global in the sense that all processors participate in its construction.

Definition at line 163 of file MetisGraphDigest.cc.

References _digestString().

Referenced by Arcane::MetisWrapper::callAdaptiveRepart(), and Arcane::MetisWrapper::callPartKway().

Here is the call graph for this function:
Here is the caller graph for this function:

Member Data Documentation

◆ m_my_rank

Int32 Arcane::MetisGraphDigest::m_my_rank = A_NULL_RANK
private

Definition at line 70 of file MetisGraphDigest.h.

◆ m_nb_rank

Int32 Arcane::MetisGraphDigest::m_nb_rank = 0
private

Definition at line 71 of file MetisGraphDigest.h.

◆ m_parallel_mng

IParallelMng* Arcane::MetisGraphDigest::m_parallel_mng = nullptr
private

Definition at line 69 of file MetisGraphDigest.h.


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