casa  $Rev:20696$
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines
Public Types | Public Member Functions | Private Member Functions | Private Attributes
casa::CalIntpMatch Class Reference

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

#include <CalIntpMatch.h>

List of all members.

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

Private Member Functions

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

Private Attributes

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

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 by class MSSelection). The CalIntpMatch class has a match methods, 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 88 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 93 of file CalIntpMatch.h.


Constructor & Destructor Documentation

casa::CalIntpMatch::CalIntpMatch ( const MatchType matchType = MATCHING_ANT_SPW,
const 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.

Copy constructor and assignment operator.


Member Function Documentation

Vector<Int> casa::CalIntpMatch::calRows ( const Int matchIndex,
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]
Int casa::CalIntpMatch::matchIndex ( const Int row,
const uInt pos 
) [inline]

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

Definition at line 128 of file CalIntpMatch.h.

References vbIndex_p.

Int casa::CalIntpMatch::matchOrAddKey ( const 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.

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

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

Reset the mapping type.

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

Set the current visibility buffer to be used in interpolation matches


Member Data Documentation

Pointer to the current CalMainBuffer.

Definition at line 170 of file CalIntpMatch.h.

Map index assignment per calibration buffer row.

Definition at line 161 of file CalIntpMatch.h.

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

Definition at line 155 of file CalIntpMatch.h.

List of visibility and calibration match keys.

Definition at line 164 of file CalIntpMatch.h.

Index map type.

Definition at line 151 of file CalIntpMatch.h.

Pointer to the current VisBuffer.

Definition at line 167 of file CalIntpMatch.h.

Map index assignment per visibility buffer row.

Definition at line 158 of file CalIntpMatch.h.

Referenced by matchIndex().


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