Citlali
Loading...
Searching...
No Matches
Classes | Public Types | Public Member Functions | Public Attributes | Static Public Attributes | Private Types | Private Member Functions | Private Attributes | List of all members
Coordinator Struct Reference

The Coordinator struct This wraps around the config object and provides high level methods in various ways to setup the MPI runtime with node-local and cross-node environment. More...

Inheritance diagram for Coordinator:
Inheritance graph
Collaboration diagram for Coordinator:
Collaboration graph

Classes

struct  Observation
 The Observation struct This represents a single observation that contains a set of data items. More...
 

Public Types

using config_t = ConfigMixin::config_t
 
using comm_t = mpi_utils::comm
 
using index_t = predefs::index_t
 
using shape_t = predefs::shape_t
 
using payloads_buffer_data_t = predefs::data_t
 
using payloads_buffer_t = mpi_utils::Span< payloads_buffer_data_t, index_t >
 
using payloads_buffer_accessor_t = BlockAccessor< payloads_buffer_t::mat_t, 2 >
 
- Public Types inherited from ConfigMixin< Coordinator >
using config_t = YamlConfig
 

Public Member Functions

 Coordinator (const comm_t &comm_, const comm_t &comm_local_, MPI_Win &win_local_)
 
constexpr auto n_nodes () const
 
constexpr auto node_index () const
 
const auto & node_name () const
 
constexpr auto rank () const
 
constexpr auto master_rank () const
 
constexpr auto is_master () const
 
constexpr auto rank_local () const
 
constexpr auto master_rank_local () const
 
constexpr auto is_master_local () const
 
constexpr auto worker_index_local () const
 
constexpr auto n_workers_local () const
 
void sync ()
 
std::size_t io_buffer_size ()
 
constexpr auto n_inputs () const
 
const std::vector< payload_t > & collect_payloads (std::size_t input_index)
 
auto allocate_payloads_buffer ()
 
- Public Member Functions inherited from ConfigMixin< Coordinator >
 ConfigMixin ()=default
 
 ConfigMixin (Args &&... args)
 
const config_tconfig ()
 
void set_config (config_t config, bool validate=true)
 

Public Attributes

const comm_tcomm
 
const comm_tcomm_local
 
MPI_Win & win_local
 

Static Public Attributes

static constexpr index_t not_a_worker = -1
 
static constexpr auto payloads_buffer_time_axis = 0
 
static constexpr auto payloads_buffer_interface_axis = 1
 

Private Types

using input_t = Observation
 
using payload_t = Observation::DataItem
 

Private Member Functions

const std::vector< input_t > & collect_inputs ()
 

Private Attributes

std::vector< input_tm_inputs
 
std::vector< payload_tm_payloads
 

Detailed Description

The Coordinator struct This wraps around the config object and provides high level methods in various ways to setup the MPI runtime with node-local and cross-node environment.

Member Typedef Documentation

◆ comm_t

using Coordinator::comm_t = mpi_utils::comm

◆ config_t

◆ index_t

◆ input_t

◆ payload_t

◆ payloads_buffer_accessor_t

using Coordinator::payloads_buffer_accessor_t = BlockAccessor<payloads_buffer_t::mat_t, 2>

◆ payloads_buffer_data_t

◆ payloads_buffer_t

◆ shape_t

Constructor & Destructor Documentation

◆ Coordinator()

Coordinator::Coordinator ( const comm_t comm_,
const comm_t comm_local_,
MPI_Win &  win_local_ 
)
inline

Member Function Documentation

◆ allocate_payloads_buffer()

auto Coordinator::allocate_payloads_buffer ( )
inline
Here is the call graph for this function:

◆ collect_inputs()

const std::vector< input_t > & Coordinator::collect_inputs ( )
inlineprivate
Here is the call graph for this function:
Here is the caller graph for this function:

◆ collect_payloads()

const std::vector< payload_t > & Coordinator::collect_payloads ( std::size_t  input_index)
inline
Here is the call graph for this function:

◆ io_buffer_size()

std::size_t Coordinator::io_buffer_size ( )
inline

◆ is_master()

constexpr auto Coordinator::is_master ( ) const
inlineconstexpr
Here is the call graph for this function:
Here is the caller graph for this function:

◆ is_master_local()

constexpr auto Coordinator::is_master_local ( ) const
inlineconstexpr
Here is the call graph for this function:
Here is the caller graph for this function:

◆ master_rank()

constexpr auto Coordinator::master_rank ( ) const
inlineconstexpr
Here is the caller graph for this function:

◆ master_rank_local()

constexpr auto Coordinator::master_rank_local ( ) const
inlineconstexpr
Here is the caller graph for this function:

◆ n_inputs()

constexpr auto Coordinator::n_inputs ( ) const
inlineconstexpr

◆ n_nodes()

constexpr auto Coordinator::n_nodes ( ) const
inlineconstexpr
Here is the caller graph for this function:

◆ n_workers_local()

constexpr auto Coordinator::n_workers_local ( ) const
inlineconstexpr
Here is the caller graph for this function:

◆ node_index()

constexpr auto Coordinator::node_index ( ) const
inlineconstexpr
Here is the caller graph for this function:

◆ node_name()

const auto & Coordinator::node_name ( ) const
inline
Here is the caller graph for this function:

◆ rank()

constexpr auto Coordinator::rank ( ) const
inlineconstexpr
Here is the caller graph for this function:

◆ rank_local()

constexpr auto Coordinator::rank_local ( ) const
inlineconstexpr
Here is the caller graph for this function:

◆ sync()

void Coordinator::sync ( )
inline

Sync the config. This is done to the global comm.

Here is the call graph for this function:

◆ worker_index_local()

constexpr auto Coordinator::worker_index_local ( ) const
inlineconstexpr
Here is the call graph for this function:
Here is the caller graph for this function:

Member Data Documentation

◆ comm

const comm_t& Coordinator::comm

◆ comm_local

const comm_t& Coordinator::comm_local

◆ m_inputs

std::vector<input_t> Coordinator::m_inputs
private

◆ m_payloads

std::vector<payload_t> Coordinator::m_payloads
private

◆ not_a_worker

constexpr index_t Coordinator::not_a_worker = -1
staticconstexpr

◆ payloads_buffer_interface_axis

constexpr auto Coordinator::payloads_buffer_interface_axis = 1
staticconstexpr

◆ payloads_buffer_time_axis

constexpr auto Coordinator::payloads_buffer_time_axis = 0
staticconstexpr

◆ win_local

MPI_Win& Coordinator::win_local

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