IODA
ioda::NonoverlappingDistributionAccumulator< T > Class Template Reference

Implementation of the Accumulator interface suitable for the NonoverlappingDistribution. More...

#include <NonoverlappingDistributionAccumulator.h>

Inheritance diagram for ioda::NonoverlappingDistributionAccumulator< T >:
Collaboration diagram for ioda::NonoverlappingDistributionAccumulator< T >:

Public Member Functions

 NonoverlappingDistributionAccumulator (const T &, const eckit::mpi::Comm &comm)
 
void addTerm (std::size_t, const T &term) override
 Increment the sum with the contribution term of location loc held on the current PE. More...
 
computeResult () const override
 Return the sum of contributions associated with locations held on all PEs (each taken into account only once). More...
 
- Public Member Functions inherited from ioda::Accumulator< T >
virtual ~Accumulator ()
 

Private Attributes

localResult_
 
const eckit::mpi::Comm & comm_
 

Detailed Description

template<typename T>
class ioda::NonoverlappingDistributionAccumulator< T >

Implementation of the Accumulator interface suitable for the NonoverlappingDistribution.

Definition at line 21 of file NonoverlappingDistributionAccumulator.h.

Constructor & Destructor Documentation

◆ NonoverlappingDistributionAccumulator()

template<typename T >
ioda::NonoverlappingDistributionAccumulator< T >::NonoverlappingDistributionAccumulator ( const T &  ,
const eckit::mpi::Comm &  comm 
)
inline

Definition at line 23 of file NonoverlappingDistributionAccumulator.h.

Member Function Documentation

◆ addTerm()

template<typename T >
void ioda::NonoverlappingDistributionAccumulator< T >::addTerm ( std::size_t  loc,
const T &  term 
)
inlineoverridevirtual

Increment the sum with the contribution term of location loc held on the current PE.

Implements ioda::Accumulator< T >.

Definition at line 27 of file NonoverlappingDistributionAccumulator.h.

◆ computeResult()

template<typename T >
T ioda::NonoverlappingDistributionAccumulator< T >::computeResult ( ) const
inlineoverridevirtual

Return the sum of contributions associated with locations held on all PEs (each taken into account only once).

Implements ioda::Accumulator< T >.

Definition at line 31 of file NonoverlappingDistributionAccumulator.h.

Member Data Documentation

◆ comm_

template<typename T >
const eckit::mpi::Comm& ioda::NonoverlappingDistributionAccumulator< T >::comm_
private

Definition at line 39 of file NonoverlappingDistributionAccumulator.h.

◆ localResult_

template<typename T >
T ioda::NonoverlappingDistributionAccumulator< T >::localResult_
private

Definition at line 38 of file NonoverlappingDistributionAccumulator.h.


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