IODA Bundle
oops::ObsVector< OBS > Class Template Reference

#include <ObsVector.h>

Inheritance diagram for oops::ObsVector< OBS >:
[legend]
Collaboration diagram for oops::ObsVector< OBS >:
[legend]

Public Member Functions

 ObsVector (const ObsSpace< OBS > &obsspace, const std::string name="")
 
 ObsVector (std::unique_ptr< ObsVector_ > obsvector, const eckit::mpi::Comm &timeComm)
 
 ObsVector (const ObsVector &)
 
 ~ObsVector ()
 
ObsVector_obsvector ()
 Interfacing. More...
 
const ObsVector_obsvector () const
 
ObsVectoroperator= (const ObsVector &)
 
ObsVectoroperator*= (const double &)
 
ObsVectoroperator+= (const ObsVector &)
 
ObsVectoroperator-= (const ObsVector &)
 
ObsVectoroperator*= (const ObsVector &)
 
ObsVectoroperator/= (const ObsVector &)
 
Eigen::VectorXd packEigen (const ObsVector &mask) const
 
size_t packEigenSize (const ObsVector &mask) const
 
void zero ()
 
void ones ()
 Set this ObsVector to ones (used in tests) More...
 
void axpy (const double &, const ObsVector &)
 
void invert ()
 
void random ()
 
double dot_product_with (const ObsVector &) const
 
double rms () const
 
void mask (const ObsDataVector< OBS, int > &mask)
 Mask out elements of the vector where mask is > 0. More...
 
void mask (const ObsVector &mask)
 Mask out elements of the vector where mask is a missing value. More...
 
ObsVectoroperator= (const ObsDataVector< OBS, float > &)
 
void save (const std::string &) const
 
void read (const std::string &)
 
unsigned int nobs () const
 number of non-masked out observations (across all MPI tasks) More...
 

Static Public Member Functions

static const std::string classname ()
 

Private Types

typedef OBS::ObsVector ObsVector_
 

Private Member Functions

void print (std::ostream &) const
 

Private Attributes

std::unique_ptr< ObsVector_data_
 
const eckit::mpi::Comm & commTime_
 

Detailed Description

template<typename OBS>
class oops::ObsVector< OBS >

Definition at line 42 of file oops/src/oops/interface/ObsVector.h.

Member Typedef Documentation

◆ ObsVector_

template<typename OBS >
typedef OBS::ObsVector oops::ObsVector< OBS >::ObsVector_
private

Definition at line 44 of file oops/src/oops/interface/ObsVector.h.

Constructor & Destructor Documentation

◆ ObsVector() [1/3]

template<typename OBS >
oops::ObsVector< OBS >::ObsVector ( const ObsSpace< OBS > &  obsspace,
const std::string  name = "" 
)
explicit

Creates vector from obsspace. If name is specified, reads the specified name variable from obsspace. Otherwise, zero vector is created.

Definition at line 110 of file oops/src/oops/interface/ObsVector.h.

Here is the call graph for this function:

◆ ObsVector() [2/3]

template<typename OBS >
oops::ObsVector< OBS >::ObsVector ( std::unique_ptr< ObsVector_ obsvector,
const eckit::mpi::Comm &  timeComm 
)

Wraps an existing ObsVector_.

Parameters
obsvectorThe vector to wrap.
timeCommTime communicator.

Definition at line 120 of file oops/src/oops/interface/ObsVector.h.

Here is the call graph for this function:

◆ ObsVector() [3/3]

template<typename OBS >
oops::ObsVector< OBS >::ObsVector ( const ObsVector< OBS > &  other)

Definition at line 129 of file oops/src/oops/interface/ObsVector.h.

Here is the call graph for this function:

◆ ~ObsVector()

template<typename OBS >
oops::ObsVector< OBS >::~ObsVector

Definition at line 138 of file oops/src/oops/interface/ObsVector.h.

Member Function Documentation

◆ axpy()

template<typename OBS >
void oops::ObsVector< OBS >::axpy ( const double &  zz,
const ObsVector< OBS > &  rhs 
)

Definition at line 232 of file oops/src/oops/interface/ObsVector.h.

◆ classname()

template<typename OBS >
static const std::string oops::ObsVector< OBS >::classname ( )
inlinestatic

Definition at line 47 of file oops/src/oops/interface/ObsVector.h.

Here is the caller graph for this function:

◆ dot_product_with()

template<typename OBS >
double oops::ObsVector< OBS >::dot_product_with ( const ObsVector< OBS > &  other) const

Definition at line 262 of file oops/src/oops/interface/ObsVector.h.

◆ invert()

template<typename OBS >
void oops::ObsVector< OBS >::invert

Definition at line 242 of file oops/src/oops/interface/ObsVector.h.

Here is the caller graph for this function:

◆ mask() [1/2]

template<typename OBS >
void oops::ObsVector< OBS >::mask ( const ObsDataVector< OBS, int > &  mask)

Mask out elements of the vector where mask is > 0.

Definition at line 274 of file oops/src/oops/interface/ObsVector.h.

Here is the caller graph for this function:

◆ mask() [2/2]

template<typename OBS >
void oops::ObsVector< OBS >::mask ( const ObsVector< OBS > &  mask)

Mask out elements of the vector where mask is a missing value.

Definition at line 282 of file oops/src/oops/interface/ObsVector.h.

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

◆ nobs()

template<typename OBS >
unsigned int oops::ObsVector< OBS >::nobs

number of non-masked out observations (across all MPI tasks)

Definition at line 318 of file oops/src/oops/interface/ObsVector.h.

Here is the caller graph for this function:

◆ obsvector() [1/2]

template<typename OBS >
ObsVector_& oops::ObsVector< OBS >::obsvector ( )
inline

Interfacing.

Definition at line 63 of file oops/src/oops/interface/ObsVector.h.

Here is the caller graph for this function:

◆ obsvector() [2/2]

template<typename OBS >
const ObsVector_& oops::ObsVector< OBS >::obsvector ( ) const
inline

Definition at line 64 of file oops/src/oops/interface/ObsVector.h.

◆ ones()

template<typename OBS >
void oops::ObsVector< OBS >::ones

Set this ObsVector to ones (used in tests)

Definition at line 222 of file oops/src/oops/interface/ObsVector.h.

◆ operator*=() [1/2]

template<typename OBS >
ObsVector< OBS > & oops::ObsVector< OBS >::operator*= ( const double &  zz)

Definition at line 157 of file oops/src/oops/interface/ObsVector.h.

◆ operator*=() [2/2]

template<typename OBS >
ObsVector< OBS > & oops::ObsVector< OBS >::operator*= ( const ObsVector< OBS > &  rhs)

Definition at line 190 of file oops/src/oops/interface/ObsVector.h.

◆ operator+=()

template<typename OBS >
ObsVector< OBS > & oops::ObsVector< OBS >::operator+= ( const ObsVector< OBS > &  rhs)

Definition at line 168 of file oops/src/oops/interface/ObsVector.h.

◆ operator-=()

template<typename OBS >
ObsVector< OBS > & oops::ObsVector< OBS >::operator-= ( const ObsVector< OBS > &  rhs)

Definition at line 179 of file oops/src/oops/interface/ObsVector.h.

◆ operator/=()

template<typename OBS >
ObsVector< OBS > & oops::ObsVector< OBS >::operator/= ( const ObsVector< OBS > &  rhs)

Definition at line 201 of file oops/src/oops/interface/ObsVector.h.

◆ operator=() [1/2]

template<typename OBS >
ObsVector< OBS > & oops::ObsVector< OBS >::operator= ( const ObsDataVector< OBS, float > &  rhs)

Definition at line 290 of file oops/src/oops/interface/ObsVector.h.

Here is the call graph for this function:

◆ operator=() [2/2]

template<typename OBS >
ObsVector< OBS > & oops::ObsVector< OBS >::operator= ( const ObsVector< OBS > &  rhs)

Definition at line 146 of file oops/src/oops/interface/ObsVector.h.

◆ packEigen()

template<typename OBS >
Eigen::VectorXd oops::ObsVector< OBS >::packEigen ( const ObsVector< OBS > &  mask) const

Pack observations local to this MPI task into an Eigen vector (excluding vector elements that are masked out: where mask is a missing value)

Definition at line 347 of file oops/src/oops/interface/ObsVector.h.

Here is the call graph for this function:

◆ packEigenSize()

template<typename OBS >
size_t oops::ObsVector< OBS >::packEigenSize ( const ObsVector< OBS > &  mask) const

Number of non-masked out observations local to this MPI task (size of an Eigen vector returned by packEigen)

Definition at line 358 of file oops/src/oops/interface/ObsVector.h.

Here is the call graph for this function:

◆ print()

template<typename OBS >
void oops::ObsVector< OBS >::print ( std::ostream &  os) const
private

Definition at line 325 of file oops/src/oops/interface/ObsVector.h.

◆ random()

template<typename OBS >
void oops::ObsVector< OBS >::random

Definition at line 252 of file oops/src/oops/interface/ObsVector.h.

Here is the caller graph for this function:

◆ read()

template<typename OBS >
void oops::ObsVector< OBS >::read ( const std::string &  name)

Definition at line 369 of file oops/src/oops/interface/ObsVector.h.

◆ rms()

template<typename OBS >
double oops::ObsVector< OBS >::rms

Definition at line 299 of file oops/src/oops/interface/ObsVector.h.

Here is the caller graph for this function:

◆ save()

template<typename OBS >
void oops::ObsVector< OBS >::save ( const std::string &  name) const

Definition at line 337 of file oops/src/oops/interface/ObsVector.h.

Here is the caller graph for this function:

◆ zero()

template<typename OBS >
void oops::ObsVector< OBS >::zero

Definition at line 212 of file oops/src/oops/interface/ObsVector.h.

Member Data Documentation

◆ commTime_

template<typename OBS >
const eckit::mpi::Comm& oops::ObsVector< OBS >::commTime_
private

Definition at line 105 of file oops/src/oops/interface/ObsVector.h.

◆ data_

template<typename OBS >
std::unique_ptr<ObsVector_> oops::ObsVector< OBS >::data_
private

Definition at line 104 of file oops/src/oops/interface/ObsVector.h.


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