RFChunkStats.h

Classes

RFChunkStats -- RFChunkStats: vital information and flagging stats for a visibility chunk (full description)

class RFChunkStats : public FlaggerEnums

Interface

Public Members
RFChunkStats( VisibilityIterator &vi,VisBuffer &vb,RedFlagger &rf, PGPlotterInterface *pgp_scr=NULL,PGPlotterInterface *pgp_rep=NULL )
const VisibilityIterator & visIter () const
VisibilityIterator & visIter ()
VisBuffer &visBuf ()
const MeasurementSet & measSet () const
const String msName () const
const Vector<String> & antNames () const
PGPlotterInterface & pgpscr() const
PGPlotterInterface & pgprep() const
void setReportPanels (Int nx,Int ny) const
void newChunk ()
void newPass (uInt npass)
void newTime ()
uInt nchunk() const
uInt npass() const
Int iTime() const
uInt num ( StatEnums which ) const
const Vector<Double> & frequency ()
Double currentMJD () const
Double startMJD () const
Double endMJD () const
template<class T> RFlagWord getCorrMask ( const Vector<T> &corrspec )
RFlagWord fullCorrMask ()
const String & getCorrString ()
uInt ifrNum( uInt nr )
const Vector<Int> & ifrNums ()
uInt antToIfr ( uInt ant1,uInt ant2 )
void ifrToAnt ( uInt &ant1,uInt &ant2,uInt ifr )
String ifrString ( uInt ifr )
uInt nrowPerIfr ( uInt ifr )
const Vector<uInt> & nrowPerIfr () const
uInt & nfIfrTime ( uInt ifr,uInt itime )
const Matrix<uInt> & nfIfrTime () const
const Matrix<uInt> & nfChanIfr () const
uInt & nrfIfr (uInt i)
uInt & nrfTime (uInt i)
const Vector<uInt> & nrfIfr () const
const Vector<uInt> & nrfTime () const
void printStats ()

Description

Prerequisite

Etymology

Synopsis

RFChunkStats maintains various stats, derived values, and flagging counts for a single visibility chunk. Also serves as an interface to VisIter and VisBuffer.

Motivation

Vital information about an MS or a visibility chunk is spread all over three classes (MS, VisIter, VisBuffer). RFChunkStats provides a central point for flagging agents to look this info up.

To Do

Member Description

RFChunkStats( VisibilityIterator &vi,VisBuffer &vb,RedFlagger &rf, PGPlotterInterface *pgp_scr=NULL,PGPlotterInterface *pgp_rep=NULL )

constructor

const VisibilityIterator & visIter () const

accessors to VisIter

VisibilityIterator & visIter ()

VisBuffer &visBuf ()

accessor to VisBuffer

const MeasurementSet & measSet () const

accessor to MS

const String msName () const

accessor to MS

const Vector<String> & antNames () const

returns antenna names

PGPlotterInterface & pgpscr() const

accessors to plotters

PGPlotterInterface & pgprep() const

void setReportPanels (Int nx,Int ny) const

divides the pgp_report view into subpanels

void newChunk ()

loads data for new chunk, resets all flag stat counters

void newPass (uInt npass)

loads data for new pass

void newTime ()

loads data for new iteration

uInt nchunk() const

returns current chunk number

uInt npass() const

returns current pass number

Int iTime() const

returns current time slot

uInt num ( StatEnums which ) const

returns a data dimension (POL, CHAN, IFR, etc.)

const Vector<Double> & frequency ()

returns vector of frequencies (one per channel)

Double currentMJD () const

returns time of currently iterated time slot

Double startMJD () const

return first time slot in chunk

Double endMJD () const

return last time slot in chunk

template<class T> RFlagWord getCorrMask ( const Vector<T> &corrspec )

returns corr mask corresponding to specified Stokes types (templated, but only String and Int will actually work)

RFlagWord fullCorrMask ()

returns mask with all correlations

const String & getCorrString ()

returns string of correlations

uInt ifrNum( uInt nr )

returns IFR index corresponding to current VisBuffer rows

const Vector<Int> & ifrNums ()

returns IFR index corresponding to current VisBuffer rows

uInt antToIfr ( uInt ant1,uInt ant2 )

converts antenna indices into IFR index

void ifrToAnt ( uInt &ant1,uInt &ant2,uInt ifr )

converts IFR index back to antenna numbers

String ifrString ( uInt ifr )

converts IFR index to standard ID string

uInt nrowPerIfr ( uInt ifr )

data availability stats, per IFR

const Vector<uInt> & nrowPerIfr () const

uInt & nfIfrTime ( uInt ifr,uInt itime )

accessors to various flagging stats

const Matrix<uInt> & nfIfrTime () const

const Matrix<uInt> & nfChanIfr () const

uInt & nrfIfr (uInt i)

uInt & nrfTime (uInt i)

const Vector<uInt> & nrfIfr () const

const Vector<uInt> & nrfTime () const

void printStats ()

prints stats to stderr