casa  5.7.0-16
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Types | Public Member Functions | Private Member Functions | Private Attributes | List of all members
casa::CalIntpMatch Class Reference

CalIntpMatch: a class to hold calibration interpolation index maps. More...

#include <CalIntpMatch.h>

Public Types

enum  MatchType {
  MATCHING_ANT_SPW,
  SELECTION_MATCH
}
 Basic interpolation index match type. More...
 

Public Member Functions

 CalIntpMatch (const MatchType &matchType=MATCHING_ANT_SPW, const casacore::uInt &indexDim=2)
 Construct from an index match type and an index dimension. More...
 
virtual ~CalIntpMatch ()
 Destructor. More...
 
 CalIntpMatch (const CalIntpMatch &other)
 Copy constructor and assignment operator. More...
 
virtual CalIntpMatchoperator= (const CalIntpMatch &other)
 
void setType (const MatchType &matchType, const casacore::uInt &indexDim)
 Reset the mapping type. More...
 
void setVisBuffer (VisBuffer &vb)
 Add a selection mapping (NYI) void add (const casacore::MSSelection& msIndex, const casacore::MSSelection& calIndex);. More...
 
void setCalBuffer (CalMainBuffer &cb)
 Set the current calibration buffer to be used in interpolation matches. More...
 
casacore::Int matchIndex (const casacore::Int &row, const casacore::uInt &pos)
 Return the match index for a given visibility buffer row and offset position (0,1) More...
 
casacore::Vector< casacore::IntcalRows (const casacore::Int &matchIndex, casacore::LogicalArray &calRowMask)
 Return the calibration buffer rows (and equivalent row mask) associated with a given match index. More...
 

Private Member Functions

void copy (const CalIntpMatch &other)
 Common code for the assignment operator and the copy constructor. More...
 
void free ()
 
void reset ()
 Reset functions for the local index mappings. More...
 
void resetVisIndex ()
 
void resetCalIndex ()
 
casacore::Int matchOrAddKey (const casacore::Record &key)
 Match index keys. More...
 

Private Attributes

MatchType type_p
 Index map type. More...
 
casacore::Int indexDim_p
 Index dimension (one for baseline-based calibration and two for antenna-based calibration). More...
 
casacore::Matrix< casacore::IntvbIndex_p
 casacore::Map index assignment per visibility buffer row More...
 
casacore::Block
< casacore::Vector
< casacore::Int > > 
cbIndex_p
 casacore::Map index assignment per calibration buffer row More...
 
casacore::PtrBlock
< casacore::Record * > 
matchKeys_p
 casacore::List of visibility and calibration match keys More...
 
VisBuffervb_p
 Pointer to the current VisBuffer. More...
 
CalMainBuffercb_p
 Pointer to the current CalMainBuffer. More...
 

Detailed Description

CalIntpMatch: a class to hold calibration interpolation index maps.

Intended use:

Public interface

Prerequisite

Etymology

From "calibration", "interpolation index" and "match".

Synopsis

The CalIntpMatch class holds calibration interpolation index maps. These define which subset of calibration table rows are associated with any given visibility row, i.e. which data and calibration indices need to match in selecting calibration for a given visibility record. The map type is defined in terms of an enumerated set of possibilities, including for example, requiring an exact match between the antenna and spectral window id.'s. The most general interpolation map is defined by a matching set of synthesis selections (as defined matchIndex() and calRows() which determine, for associated calibration and visibility buffers, the calibration row mapping for a given visibility.

Example

Motivation

Encapsulate match operations for calibration and visibility data indices.

Definition at line 92 of file CalIntpMatch.h.

Member Enumeration Documentation

Basic interpolation index match type.

Enumerator
MATCHING_ANT_SPW 

ANTENNA_ID and SPECTRAL_WINDOW_ID to match identically.

SELECTION_MATCH 

Custom mapping between arbitrary visibility and calibration selections.

Definition at line 97 of file CalIntpMatch.h.

Constructor & Destructor Documentation

casa::CalIntpMatch::CalIntpMatch ( const MatchType matchType = MATCHING_ANT_SPW,
const casacore::uInt indexDim = 2 
)

Construct from an index match type and an index dimension.

The index dimension is one for baseline-based calibration and two for antenna-based calibration.

virtual casa::CalIntpMatch::~CalIntpMatch ( )
virtual

Destructor.

casa::CalIntpMatch::CalIntpMatch ( const CalIntpMatch other)

Copy constructor and assignment operator.

Member Function Documentation

casacore::Vector<casacore::Int> casa::CalIntpMatch::calRows ( const casacore::Int matchIndex,
casacore::LogicalArray &  calRowMask 
)

Return the calibration buffer rows (and equivalent row mask) associated with a given match index.

void casa::CalIntpMatch::copy ( const CalIntpMatch other)
private

Common code for the assignment operator and the copy constructor.

void casa::CalIntpMatch::free ( )
private
casacore::Int casa::CalIntpMatch::matchIndex ( const casacore::Int row,
const casacore::uInt pos 
)
inline

Return the match index for a given visibility buffer row and offset position (0,1)

Definition at line 132 of file CalIntpMatch.h.

References vbIndex_p.

casacore::Int casa::CalIntpMatch::matchOrAddKey ( const casacore::Record key)
private

Match index keys.

virtual CalIntpMatch& casa::CalIntpMatch::operator= ( const CalIntpMatch other)
virtual
void casa::CalIntpMatch::reset ( )
private

Reset functions for the local index mappings.

void casa::CalIntpMatch::resetCalIndex ( )
private
void casa::CalIntpMatch::resetVisIndex ( )
private
void casa::CalIntpMatch::setCalBuffer ( CalMainBuffer cb)

Set the current calibration buffer to be used in interpolation matches.

void casa::CalIntpMatch::setType ( const MatchType matchType,
const casacore::uInt indexDim 
)

Reset the mapping type.

void casa::CalIntpMatch::setVisBuffer ( VisBuffer vb)

Add a selection mapping (NYI) void add (const casacore::MSSelection& msIndex, const casacore::MSSelection& calIndex);.

Set the current visibility buffer to be used in interpolation matches

Member Data Documentation

CalMainBuffer* casa::CalIntpMatch::cb_p
private

Pointer to the current CalMainBuffer.

Definition at line 174 of file CalIntpMatch.h.

casacore::Block<casacore::Vector<casacore::Int> > casa::CalIntpMatch::cbIndex_p
private

casacore::Map index assignment per calibration buffer row

Definition at line 165 of file CalIntpMatch.h.

casacore::Int casa::CalIntpMatch::indexDim_p
private

Index dimension (one for baseline-based calibration and two for antenna-based calibration).

Definition at line 159 of file CalIntpMatch.h.

casacore::PtrBlock<casacore::Record* > casa::CalIntpMatch::matchKeys_p
private

casacore::List of visibility and calibration match keys

Definition at line 168 of file CalIntpMatch.h.

MatchType casa::CalIntpMatch::type_p
private

Index map type.

Definition at line 155 of file CalIntpMatch.h.

VisBuffer* casa::CalIntpMatch::vb_p
private

Pointer to the current VisBuffer.

Definition at line 171 of file CalIntpMatch.h.

casacore::Matrix<casacore::Int> casa::CalIntpMatch::vbIndex_p
private

casacore::Map index assignment per visibility buffer row

Definition at line 162 of file CalIntpMatch.h.

Referenced by matchIndex().


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