A class to average VisBuffers for PlotMS. More...
#include <PlotMSVBAverager.h>
Public Member Functions | |
PlotMSVBAverager (Int nAnt) | |
Construct from the number of antennas, the averaging interval and the pre-normalization flag. | |
~PlotMSVBAverager () | |
Null destructor. | |
void | setBlnAveraging (Bool doBln) |
Set up baseline averaging. | |
void | setAntAveraging (Bool doAnt) |
Set up antenna averaging. | |
void | setScalarAve (Bool doScalar) |
Set scalar averaging flag. | |
void | setNoData () |
Control which data column to average. | |
void | setDoVC () |
void | setDoMVC () |
void | setDoCVC () |
void | setDoFC () |
void | setDoUVW () |
void | accumulate (vi::VisBuffer2 &vb) |
Accumulate a VisBuffer. | |
void | finalizeAverage () |
Finalize averaging. | |
vi::VisBuffer2 & | aveVisBuff () |
Return a reference to the result. | |
Private Member Functions | |
PlotMSVBAverager () | |
Prohibit null constructor, copy constructor and assignment for now. | |
PlotMSVBAverager & | operator= (const PlotMSVBAverager &) |
PlotMSVBAverager (const PlotMSVBAverager &) | |
Int & | prtlev () |
Diagnostic printing level. | |
void | initialize (vi::VisBuffer2 &vb) |
Initialize the next accumulation interval. | |
void | simpAccumulate (vi::VisBuffer2 &vb) |
Different accumulate versions. | |
void | antAccumulate (vi::VisBuffer2 &vb) |
void | verifyCrosshands (vi::VisBuffer2 &vb) |
Verify zero or two crosshands present (if antAve_p). | |
Int | baseline (const Int &ant1, const Int &ant2) |
Hash function to return the row offset for an interferometer (ant1, ant2). | |
void | convertToAP (Cube< Complex > &d) |
Convert r/i to a/p. | |
void | fillIds (Int nrows) |
fill vector that is resized larger | |
Private Attributes | |
Int | nAnt_p |
Number of antennas, correlations, and channels. | |
Int | nCorr_p |
Int | nChan_p |
Int | nBlnMax_p |
Bool | chanIndepWt_p |
Weights in input VBs are chan-independent. | |
Vector< Bool > | blnOK_p |
Validation by baseline (if False, no attempt to accumulate this baseline). | |
Bool | blnAve_p |
Are we averaging baselines together? | |
Bool | antAve_p |
Are we averaging antennas together? | |
Bool | inCoh_p |
Are we incoherently (scalar) averaging? | |
Double | timeRef_p |
Accumulation helpers. | |
Double | minTime_p |
Double | maxTime_p |
Double | aveTime_p |
Double | aveInterval_p |
Vector< Double > | blnWtSum_p |
Double | vbWtSum_p |
Int | aveScan_p |
Bool | doVC_p |
Optional averaging triggers. | |
Bool | doMVC_p |
Bool | doCVC_p |
Bool | doFC_p |
Bool | doUVW_p |
Bool | doWC_p |
vi::VisBuffer2 * | avBuf_p |
Accumulation buffer. | |
Bool | initialized_p |
Keep track of initialization state. | |
Vector< Int > | jcor_p |
Correlation list for cross-hand swapping. | |
Int | prtlev_ |
Diagnostic print level. | |
Cube< Complex > | avgVisCube_ |
Mutable arrays, set in avBuf_p when finalized. | |
Cube< Complex > | avgModelCube_ |
Cube< Complex > | avgCorrectedCube_ |
Cube< Float > | avgFloatCube_ |
Cube< Bool > | avgFlagCube_ |
Vector< Bool > | avgFlagRow_ |
Cube< Float > | avgWeight_ |
Matrix< Double > | avgUvw_ |
Vector< Int > | avgAntenna1_ |
Vector< Int > | avgAntenna2_ |
Vector< Double > | avgTime_ |
Vector< Double > | avgTimeInterval_ |
Vector< Int > | avgScan_ |
Vector< Int > | fieldid_ |
Need to resize these in final avBuf. | |
Vector< Int > | spw_ |
Vector< Int > | obsid_ |
Vector< Int > | stateid_ |
A class to average VisBuffers for PlotMS.
Public interface
This class averages VisBuffers together for PlotMS
Definition at line 74 of file PlotMSVBAverager.h.
casa::PlotMSVBAverager::PlotMSVBAverager | ( | Int | nAnt | ) |
Construct from the number of antennas, the averaging interval and the pre-normalization flag.
casa::PlotMSVBAverager::~PlotMSVBAverager | ( | ) |
Null destructor.
casa::PlotMSVBAverager::PlotMSVBAverager | ( | ) | [private] |
Prohibit null constructor, copy constructor and assignment for now.
casa::PlotMSVBAverager::PlotMSVBAverager | ( | const PlotMSVBAverager & | ) | [private] |
void casa::PlotMSVBAverager::accumulate | ( | vi::VisBuffer2 & | vb | ) | [inline] |
Accumulate a VisBuffer.
Definition at line 105 of file PlotMSVBAverager.h.
References antAccumulate(), antAve_p, and simpAccumulate().
void casa::PlotMSVBAverager::antAccumulate | ( | vi::VisBuffer2 & | vb | ) | [private] |
Referenced by accumulate().
vi::VisBuffer2& casa::PlotMSVBAverager::aveVisBuff | ( | ) | [inline] |
Return a reference to the result.
Definition at line 111 of file PlotMSVBAverager.h.
References avBuf_p.
Int casa::PlotMSVBAverager::baseline | ( | const Int & | ant1, | |
const Int & | ant2 | |||
) | [private] |
Hash function to return the row offset for an interferometer (ant1, ant2).
void casa::PlotMSVBAverager::convertToAP | ( | Cube< Complex > & | d | ) | [private] |
Convert r/i to a/p.
void casa::PlotMSVBAverager::fillIds | ( | Int | nrows | ) | [private] |
fill vector that is resized larger
void casa::PlotMSVBAverager::finalizeAverage | ( | ) |
Finalize averaging.
void casa::PlotMSVBAverager::initialize | ( | vi::VisBuffer2 & | vb | ) | [private] |
Initialize the next accumulation interval.
PlotMSVBAverager& casa::PlotMSVBAverager::operator= | ( | const PlotMSVBAverager & | ) | [private] |
Int& casa::PlotMSVBAverager::prtlev | ( | ) | [inline, private] |
void casa::PlotMSVBAverager::setAntAveraging | ( | Bool | doAnt | ) | [inline] |
Set up antenna averaging.
Definition at line 88 of file PlotMSVBAverager.h.
References antAve_p, casacore::False, and setBlnAveraging().
Referenced by setBlnAveraging().
void casa::PlotMSVBAverager::setBlnAveraging | ( | Bool | doBln | ) | [inline] |
Set up baseline averaging.
Definition at line 85 of file PlotMSVBAverager.h.
References blnAve_p, casacore::False, and setAntAveraging().
Referenced by setAntAveraging().
void casa::PlotMSVBAverager::setDoCVC | ( | ) | [inline] |
Definition at line 100 of file PlotMSVBAverager.h.
References doCVC_p, doWC_p, and casacore::True.
void casa::PlotMSVBAverager::setDoFC | ( | ) | [inline] |
Definition at line 101 of file PlotMSVBAverager.h.
References doFC_p, doWC_p, and casacore::True.
void casa::PlotMSVBAverager::setDoMVC | ( | ) | [inline] |
Definition at line 99 of file PlotMSVBAverager.h.
References doMVC_p, doWC_p, and casacore::True.
void casa::PlotMSVBAverager::setDoUVW | ( | ) | [inline] |
Definition at line 102 of file PlotMSVBAverager.h.
References doUVW_p, and casacore::True.
void casa::PlotMSVBAverager::setDoVC | ( | ) | [inline] |
Definition at line 98 of file PlotMSVBAverager.h.
References doVC_p, doWC_p, and casacore::True.
void casa::PlotMSVBAverager::setNoData | ( | ) | [inline] |
Control which data column to average.
Definition at line 96 of file PlotMSVBAverager.h.
References doCVC_p, doFC_p, doMVC_p, doUVW_p, doVC_p, doWC_p, and casacore::False.
void casa::PlotMSVBAverager::setScalarAve | ( | Bool | doScalar | ) | [inline] |
Set scalar averaging flag.
cout << "Using " << (doScalar ? "SCALAR" : "VECTOR") << " averaging." << endl;
Definition at line 91 of file PlotMSVBAverager.h.
References inCoh_p.
void casa::PlotMSVBAverager::simpAccumulate | ( | vi::VisBuffer2 & | vb | ) | [private] |
Different accumulate versions.
Referenced by accumulate().
void casa::PlotMSVBAverager::verifyCrosshands | ( | vi::VisBuffer2 & | vb | ) | [private] |
Verify zero or two crosshands present (if antAve_p).
Bool casa::PlotMSVBAverager::antAve_p [private] |
Are we averaging antennas together?
Definition at line 154 of file PlotMSVBAverager.h.
Referenced by accumulate(), and setAntAveraging().
vi::VisBuffer2* casa::PlotMSVBAverager::avBuf_p [private] |
Double casa::PlotMSVBAverager::aveInterval_p [private] |
Definition at line 164 of file PlotMSVBAverager.h.
Int casa::PlotMSVBAverager::aveScan_p [private] |
Definition at line 167 of file PlotMSVBAverager.h.
Double casa::PlotMSVBAverager::aveTime_p [private] |
Definition at line 163 of file PlotMSVBAverager.h.
Vector<Int> casa::PlotMSVBAverager::avgAntenna1_ [private] |
Definition at line 193 of file PlotMSVBAverager.h.
Vector<Int> casa::PlotMSVBAverager::avgAntenna2_ [private] |
Definition at line 194 of file PlotMSVBAverager.h.
Cube<Complex> casa::PlotMSVBAverager::avgCorrectedCube_ [private] |
Definition at line 187 of file PlotMSVBAverager.h.
Cube<Bool> casa::PlotMSVBAverager::avgFlagCube_ [private] |
Definition at line 189 of file PlotMSVBAverager.h.
Vector<Bool> casa::PlotMSVBAverager::avgFlagRow_ [private] |
Definition at line 190 of file PlotMSVBAverager.h.
Cube<Float> casa::PlotMSVBAverager::avgFloatCube_ [private] |
Definition at line 188 of file PlotMSVBAverager.h.
Cube<Complex> casa::PlotMSVBAverager::avgModelCube_ [private] |
Definition at line 186 of file PlotMSVBAverager.h.
Vector<Int> casa::PlotMSVBAverager::avgScan_ [private] |
Definition at line 197 of file PlotMSVBAverager.h.
Vector<Double> casa::PlotMSVBAverager::avgTime_ [private] |
Definition at line 195 of file PlotMSVBAverager.h.
Vector<Double> casa::PlotMSVBAverager::avgTimeInterval_ [private] |
Definition at line 196 of file PlotMSVBAverager.h.
Matrix<Double> casa::PlotMSVBAverager::avgUvw_ [private] |
Definition at line 192 of file PlotMSVBAverager.h.
Cube<Complex> casa::PlotMSVBAverager::avgVisCube_ [private] |
Mutable arrays, set in avBuf_p when finalized.
Definition at line 185 of file PlotMSVBAverager.h.
Cube<Float> casa::PlotMSVBAverager::avgWeight_ [private] |
Definition at line 191 of file PlotMSVBAverager.h.
Bool casa::PlotMSVBAverager::blnAve_p [private] |
Are we averaging baselines together?
Definition at line 151 of file PlotMSVBAverager.h.
Referenced by setBlnAveraging().
Vector<Bool> casa::PlotMSVBAverager::blnOK_p [private] |
Validation by baseline (if False, no attempt to accumulate this baseline).
Definition at line 148 of file PlotMSVBAverager.h.
Vector<Double> casa::PlotMSVBAverager::blnWtSum_p [private] |
Definition at line 165 of file PlotMSVBAverager.h.
Bool casa::PlotMSVBAverager::chanIndepWt_p [private] |
Weights in input VBs are chan-independent.
Definition at line 145 of file PlotMSVBAverager.h.
Bool casa::PlotMSVBAverager::doCVC_p [private] |
Definition at line 170 of file PlotMSVBAverager.h.
Referenced by setDoCVC(), and setNoData().
Bool casa::PlotMSVBAverager::doFC_p [private] |
Definition at line 170 of file PlotMSVBAverager.h.
Referenced by setDoFC(), and setNoData().
Bool casa::PlotMSVBAverager::doMVC_p [private] |
Definition at line 170 of file PlotMSVBAverager.h.
Referenced by setDoMVC(), and setNoData().
Bool casa::PlotMSVBAverager::doUVW_p [private] |
Definition at line 170 of file PlotMSVBAverager.h.
Referenced by setDoUVW(), and setNoData().
Bool casa::PlotMSVBAverager::doVC_p [private] |
Optional averaging triggers.
Definition at line 170 of file PlotMSVBAverager.h.
Referenced by setDoVC(), and setNoData().
Bool casa::PlotMSVBAverager::doWC_p [private] |
Definition at line 170 of file PlotMSVBAverager.h.
Referenced by setDoCVC(), setDoFC(), setDoMVC(), setDoVC(), and setNoData().
Vector<Int> casa::PlotMSVBAverager::fieldid_ [private] |
Need to resize these in final avBuf.
Definition at line 199 of file PlotMSVBAverager.h.
Bool casa::PlotMSVBAverager::inCoh_p [private] |
Are we incoherently (scalar) averaging?
Definition at line 157 of file PlotMSVBAverager.h.
Referenced by setScalarAve().
Bool casa::PlotMSVBAverager::initialized_p [private] |
Keep track of initialization state.
Definition at line 176 of file PlotMSVBAverager.h.
Vector<Int> casa::PlotMSVBAverager::jcor_p [private] |
Correlation list for cross-hand swapping.
Definition at line 179 of file PlotMSVBAverager.h.
Double casa::PlotMSVBAverager::maxTime_p [private] |
Definition at line 162 of file PlotMSVBAverager.h.
Double casa::PlotMSVBAverager::minTime_p [private] |
Definition at line 161 of file PlotMSVBAverager.h.
Int casa::PlotMSVBAverager::nAnt_p [private] |
Number of antennas, correlations, and channels.
Definition at line 142 of file PlotMSVBAverager.h.
Int casa::PlotMSVBAverager::nBlnMax_p [private] |
Definition at line 142 of file PlotMSVBAverager.h.
Int casa::PlotMSVBAverager::nChan_p [private] |
Definition at line 142 of file PlotMSVBAverager.h.
Int casa::PlotMSVBAverager::nCorr_p [private] |
Definition at line 142 of file PlotMSVBAverager.h.
Vector<Int> casa::PlotMSVBAverager::obsid_ [private] |
Definition at line 201 of file PlotMSVBAverager.h.
Int casa::PlotMSVBAverager::prtlev_ [private] |
Vector<Int> casa::PlotMSVBAverager::spw_ [private] |
Definition at line 200 of file PlotMSVBAverager.h.
Vector<Int> casa::PlotMSVBAverager::stateid_ [private] |
Definition at line 202 of file PlotMSVBAverager.h.
Double casa::PlotMSVBAverager::timeRef_p [private] |
Double casa::PlotMSVBAverager::vbWtSum_p [private] |
Definition at line 166 of file PlotMSVBAverager.h.