KratosMultiphysics
KRATOS Multiphysics (Kratos) is a framework for building parallel, multi-disciplinary simulation software, aiming at modularity, extensibility, and high performance. Kratos is written in C++, and counts with an extensive Python interface.
|
This function recomputes the communication plan for MPI. More...
#include <parallel_fill_communicator.h>
Public Member Functions | |
Type Definitions | |
KRATOS_CLASS_POINTER_DEFINITION (ParallelFillCommunicator) | |
Pointer definition of ParallelFillCommunicator. More... | |
Life Cycle | |
ParallelFillCommunicator (ModelPart &rModelPart) | |
Constructor (deprecated) More... | |
ParallelFillCommunicator (ModelPart &rModelPart, const DataCommunicator &rDataCommunicator) | |
Constructor. More... | |
virtual | ~ParallelFillCommunicator ()=default |
Destructor. More... | |
Operations | |
void | Execute () override |
Execute the communicator fill. More... | |
void | PrintModelPartDebugInfo (const ModelPart &rModelPart) override |
Function to print mesh information of the provided model part. More... | |
Input and output | |
std::string | Info () const override |
Turn back information as a string. More... | |
void | PrintInfo (std::ostream &rOStream) const override |
Print information about this object. More... | |
void | PrintData (std::ostream &rOStream) const override |
Print object's data. More... | |
Public Member Functions inherited from Kratos::FillCommunicator | |
KRATOS_CLASS_POINTER_DEFINITION (FillCommunicator) | |
Pointer definition of FillCommunicator. More... | |
FillCommunicator (ModelPart &rModelPart) | |
Constructor (deprecated) More... | |
FillCommunicator (ModelPart &rModelPart, const DataCommunicator &rDataCommunicator) | |
Constructor. More... | |
FillCommunicator (FillCommunicator const &rOther)=delete | |
Copy constructor. More... | |
virtual | ~FillCommunicator ()=default |
Destructor. More... | |
FillCommunicator & | operator= (FillCommunicator const &rOther)=delete |
Assignment operator. More... | |
void | PrintDebugInfo () |
Function to print DETAILED mesh information WARNING: to be used for debugging only as many information are plotted. More... | |
void | SetEchoLevel (const FillCommunicatorEchoLevel EchoLevel) |
Set the echo level. More... | |
FillCommunicatorEchoLevel | GetEchoLevel () const |
Get the echo level. More... | |
Protected Member Functions | |
Protected Operations | |
void | ComputeCommunicationPlan (ModelPart &rModelPart) |
This function computes the communication plan. More... | |
void | InitializeParallelCommunicationMeshes (ModelPart &rModelPart, const std::vector< int > &rColors, const int MyRank) |
Initialize the communicator's ghost, local and interface meshes for all communication pairs (colors). More... | |
void | GenerateMeshes (const int NeighbourPID, const int MyPID, const unsigned int Color, ModelPart &rModelPart) |
Generate the ghost, local and interface meshes for processes of a communication pair (color). More... | |
Protected Member Functions inherited from Kratos::FillCommunicator | |
ModelPart & | GetBaseModelPart () |
Get the base model part. More... | |
Additional Inherited Members | |
Public Types inherited from Kratos::FillCommunicator | |
enum class | FillCommunicatorEchoLevel { NO_PRINTING = 0 , INFO = 1 , DEBUG_INFO = 2 } |
Protected Attributes inherited from Kratos::FillCommunicator | |
const DataCommunicator & | mrDataComm |
FillCommunicatorEchoLevel | mEchoLevel = FillCommunicatorEchoLevel::NO_PRINTING |
Data communicator reference. More... | |
This function recomputes the communication plan for MPI.
The objective of this class is to read the mesh owned by each node in a distributed context and to fill the communication plan (coloring) so to allow the communication to be performed correctly It fills the Ghost and Local lists and performs the coloring, then it updates the MPI communicator
Kratos::ParallelFillCommunicator::ParallelFillCommunicator | ( | ModelPart & | rModelPart | ) |
Constructor (deprecated)
rModelPart | The model part to recompute the communication plan for MPI |
Kratos::ParallelFillCommunicator::ParallelFillCommunicator | ( | ModelPart & | rModelPart, |
const DataCommunicator & | rDataCommunicator | ||
) |
Constructor.
rModelPart | The model part to recompute the communication plan for MPI |
rDataCommunicator | The communicator to recompute the communication plan for MPI |
|
virtualdefault |
Destructor.
|
protected |
This function computes the communication plan.
rModelPart | The model part to compute the communication plan |
@TODO for large problems, this should use a compressed matrix.
|
overridevirtual |
Execute the communicator fill.
This method is intended to perform the communicator filling
Reimplemented from Kratos::FillCommunicator.
|
protected |
Generate the ghost, local and interface meshes for processes of a communication pair (color).
|
overridevirtual |
Turn back information as a string.
Reimplemented from Kratos::FillCommunicator.
|
protected |
Initialize the communicator's ghost, local and interface meshes for all communication pairs (colors).
Kratos::ParallelFillCommunicator::KRATOS_CLASS_POINTER_DEFINITION | ( | ParallelFillCommunicator | ) |
Pointer definition of ParallelFillCommunicator.
|
overridevirtual |
Print object's data.
Reimplemented from Kratos::FillCommunicator.
|
overridevirtual |
Print information about this object.
Reimplemented from Kratos::FillCommunicator.
|
overridevirtual |
Function to print mesh information of the provided model part.
This function is intended to check and print some mesh information
rModelPart | Reference to the model part to be checked |
Reimplemented from Kratos::FillCommunicator.