casa::MSUVBin Class Reference

#include <MSUVBin.h>

List of all members.

Public Member Functions

 MSUVBin ()
 MSUVBin (const MDirection &phaseCenter, const Int nx, const Int ny, const Int nchan, const Int npol, Quantity cellx, Quantity celly, Quantity freqStart, Quantity freqStep, Float memFraction=0.5, Bool dow=False, Bool doflag=False)
 npol should be only 1, 2 (parallel hands) or 4
 MSUVBin (MeasurementSet &ms)
 Constructor to bin into an existing gridded ms.
virtual Bool selectData (const String &msname, const String &spw="", const String &field="", const String &baseline="", const String &scan="", const String &uvrange="", const String &taql="", const String &subarray="", const String &correlation="", const String &intent="", const String &obs="")
 The following can be called multiple times to setup multiple input MS.
void setOutputMS (const String &msname)
 void setInputMS(const MeasurementSet& ms); void setInputMS(const Block<const MeasurementSet*> mssPtr);
Bool fillOutputMS ()
 forceDiskUsage is to avoid using in memory gridding even if there is
virtual ~MSUVBin ()

Static Public Member Functions

static Bool String2MDirection (const String &theString, MDirection &theMeas, const String msname="")
 Helper function for creating MDirection from a string.

Private Member Functions

Bool fillSmallOutputMS ()
Bool fillNewBigOutputMS ()
Bool fillBigOutputMS ()
Int recoverGridInfo (const String &msname)
void storeGridInfo ()
void createOutputMS (const Int nrrows)
Int makeUVW (const Double reffreq, Vector< Double > &incr, Vector< Int > &cent, Matrix< Double > &uvw)
void locateuvw (Matrix< Int > &locuv, const Vector< Double > &increment, const Vector< Int > &center, const Matrix< Double > &uvw)
void gridData (const vi::VisBuffer2 &vb, Cube< Complex > &grid, Matrix< Float > &wght, Cube< Float > &wghtSpec, Cube< Bool > &flag, Vector< Bool > &rowFlag, Matrix< Double > &uvw, Vector< Int > &ant1, Vector< Int > &ant2, Vector< Double > &time, const Matrix< Int > &locuv)
void gridData (const vi::VisBuffer2 &vb, Cube< Complex > &grid, Matrix< Float > &wght, Cube< Float > &wghtSpec, Cube< Bool > &flag, Vector< Bool > &rowFlag, Matrix< Double > &uvw, Vector< Int > &ant1, Vector< Int > &ant2, Vector< Double > &time, const Int startchan, const Int endchan)
void gridDataConv (const vi::VisBuffer2 &vb, Cube< Complex > &grid, Matrix< Float > &, Cube< Complex > &wghtSpec, Cube< Bool > &flag, Vector< Bool > &rowFlag, Matrix< Double > &uvw, Vector< Int > &ant1, Vector< Int > &ant2, Vector< Double > &timeCen, const Int startchan, const Int endchan, const Cube< Complex > &convFunc, const Vector< Int > &convSupport, const Double wScale, const Int convSampling)
void gridDataConvThr (const vi::VisBuffer2 &vb, Cube< Complex > &grid, Cube< Complex > &wghtSpec, Cube< Bool > &flag, Vector< Bool > &rowFlag, Matrix< Double > &uvw, Vector< Int > &ant1, Vector< Int > &ant2, Vector< Double > &timeCen, const Int startchan, const Int endchan, const Cube< Complex > &convFunc, const Vector< Int > &convSupport, const Double wScale, const Int convSampling)
void inplaceGridData (const vi::VisBuffer2 &vb)
void inplaceLargeBW (const vi::VisBuffer2 &vb)
void inplaceSmallBW (const vi::VisBuffer2 &vb)
void makeCoordsys ()
void weightSync ()
void multiThrLoop (const Int outchan, const vi::VisBuffer2 &vb, Double refFreq, Vector< Float > scale, Bool hasCorrected, Bool needRot, const Vector< Double > &phasor, const Vector< Double > &visFreq, const Double &fracbw, Complex *&grid, Complex *&wghtSpec, Bool *&flag, Bool *&rowFlag, Double *&uvw, Int *&ant1, Int *&ant2, Double *&timeCen, Double *&sumWeight, Double *&numvis, const Int startchan, const Int endchan, const Cube< Complex > &convFunc, const Vector< Int > &convSupport, const Double wScale, const Int convSampling)
void locateFlagFromGrid (vi::VisBuffer2 &vb, Cube< Bool > &datFlag, Cube< Float > &wghtSpec, Cube< Bool > &flag, Vector< Bool > &rowFlag, Matrix< Double > &uvw, Vector< Int > &ant1, Vector< Int > &ant2, Vector< Double > &timeCen, const Int startchan, const Int endchan)
Bool datadescMap (const vi::VisBuffer2 &vb, Double &fracbw)
 returns a false if either no channel map or pol map onto grid
Bool datadescMap (const VisBuffer &vb)
Bool saveData (const Cube< Complex > &grid, const Cube< Bool > &flag, const Vector< Bool > &rowFlag, const Cube< Float > &wghtSpec, const Matrix< Float > &wght, const Matrix< Double > &uvw, const Vector< Int > &ant1, const Vector< Int > &ant2, const Vector< Double > &time)
Bool saveData (const Cube< Complex > &grid, const Cube< Bool > &flag, const Vector< Bool > &rowFlag, const Cube< Float > &wghtSpec, const Matrix< Double > &uvw, const Vector< Int > &ant1, const Vector< Int > &ant2, const Vector< Double > &time, const Int startchan, const Int endchan, const Cube< Float > &imagwghtSpec=Cube< Float >())
void fillSubTables ()
void fillFieldTable ()
void copySubtable (const String &tabName, const Table &inTab, const Bool noRows=False)
void fillDDTables ()
void setTileCache ()
void makeSFConv (Cube< Complex > &convFunc, Vector< Int > &convSupport, Double &wScale, Int &convSampling, Int &convSize)
void makeWConv (vi::VisibilityIterator2 &iter, Cube< Complex > &convFunc, Vector< Int > &convSupport, Double &wScale, Int &convSampling, Int &convSize)

Static Private Member Functions

static Int sepCommaEmptyToVectorStrings (Vector< String > &retStr, const String &str)

Private Attributes

CoordinateSystem csys_p
Int nx_p
Int ny_p
Int nchan_p
Int npol_p
Double freqStart_p
Double freqStep_p
Vector< Int > chanMap_p
Vector< Int > polMap_p
Vector< Vector< Int > > chanMapRev_p
MDirection phaseCenter_p
Vector< Double > deltas_p
Vector< Int > whichStokes_p
Bool existOut_p
String outMSName_p
CountedPtr< MeasurementSet > outMsPtr_p
Block< const MeasurementSet * > mss_p
VisBufferUtil vbutil_p
Float memFraction_p
Bool doW_p
Bool doFlag_p
Matrix< Double > numVis_p
Matrix< Double > sumWeight_p

Detailed Description

Definition at line 46 of file MSUVBin.h.


Constructor & Destructor Documentation

casa::MSUVBin::MSUVBin (  ) 
casa::MSUVBin::MSUVBin ( const MDirection &  phaseCenter,
const Int  nx,
const Int  ny,
const Int  nchan,
const Int  npol,
Quantity  cellx,
Quantity  celly,
Quantity  freqStart,
Quantity  freqStep,
Float  memFraction = 0.5,
Bool  dow = False,
Bool  doflag = False 
)

npol should be only 1, 2 (parallel hands) or 4

casa::MSUVBin::MSUVBin ( MeasurementSet &  ms  ) 

Constructor to bin into an existing gridded ms.

virtual casa::MSUVBin::~MSUVBin (  )  [virtual]

Member Function Documentation

void casa::MSUVBin::copySubtable ( const String &  tabName,
const Table &  inTab,
const Bool  noRows = False 
) [private]
void casa::MSUVBin::createOutputMS ( const Int  nrrows  )  [private]
Bool casa::MSUVBin::datadescMap ( const VisBuffer vb  )  [private]
Bool casa::MSUVBin::datadescMap ( const vi::VisBuffer2 vb,
Double &  fracbw 
) [private]

returns a false if either no channel map or pol map onto grid

Bool casa::MSUVBin::fillBigOutputMS (  )  [private]
void casa::MSUVBin::fillDDTables (  )  [private]
void casa::MSUVBin::fillFieldTable (  )  [private]
Bool casa::MSUVBin::fillNewBigOutputMS (  )  [private]
Bool casa::MSUVBin::fillOutputMS (  ) 

forceDiskUsage is to avoid using in memory gridding even if there is

Bool casa::MSUVBin::fillSmallOutputMS (  )  [private]
void casa::MSUVBin::fillSubTables (  )  [private]
void casa::MSUVBin::gridData ( const vi::VisBuffer2 vb,
Cube< Complex > &  grid,
Matrix< Float > &  wght,
Cube< Float > &  wghtSpec,
Cube< Bool > &  flag,
Vector< Bool > &  rowFlag,
Matrix< Double > &  uvw,
Vector< Int > &  ant1,
Vector< Int > &  ant2,
Vector< Double > &  time,
const Int  startchan,
const Int  endchan 
) [private]
void casa::MSUVBin::gridData ( const vi::VisBuffer2 vb,
Cube< Complex > &  grid,
Matrix< Float > &  wght,
Cube< Float > &  wghtSpec,
Cube< Bool > &  flag,
Vector< Bool > &  rowFlag,
Matrix< Double > &  uvw,
Vector< Int > &  ant1,
Vector< Int > &  ant2,
Vector< Double > &  time,
const Matrix< Int > &  locuv 
) [private]
void casa::MSUVBin::gridDataConv ( const vi::VisBuffer2 vb,
Cube< Complex > &  grid,
Matrix< Float > &  ,
Cube< Complex > &  wghtSpec,
Cube< Bool > &  flag,
Vector< Bool > &  rowFlag,
Matrix< Double > &  uvw,
Vector< Int > &  ant1,
Vector< Int > &  ant2,
Vector< Double > &  timeCen,
const Int  startchan,
const Int  endchan,
const Cube< Complex > &  convFunc,
const Vector< Int > &  convSupport,
const Double  wScale,
const Int  convSampling 
) [private]
void casa::MSUVBin::gridDataConvThr ( const vi::VisBuffer2 vb,
Cube< Complex > &  grid,
Cube< Complex > &  wghtSpec,
Cube< Bool > &  flag,
Vector< Bool > &  rowFlag,
Matrix< Double > &  uvw,
Vector< Int > &  ant1,
Vector< Int > &  ant2,
Vector< Double > &  timeCen,
const Int  startchan,
const Int  endchan,
const Cube< Complex > &  convFunc,
const Vector< Int > &  convSupport,
const Double  wScale,
const Int  convSampling 
) [private]
void casa::MSUVBin::inplaceGridData ( const vi::VisBuffer2 vb  )  [private]
void casa::MSUVBin::inplaceLargeBW ( const vi::VisBuffer2 vb  )  [private]
void casa::MSUVBin::inplaceSmallBW ( const vi::VisBuffer2 vb  )  [private]
void casa::MSUVBin::locateFlagFromGrid ( vi::VisBuffer2 vb,
Cube< Bool > &  datFlag,
Cube< Float > &  wghtSpec,
Cube< Bool > &  flag,
Vector< Bool > &  rowFlag,
Matrix< Double > &  uvw,
Vector< Int > &  ant1,
Vector< Int > &  ant2,
Vector< Double > &  timeCen,
const Int  startchan,
const Int  endchan 
) [private]
void casa::MSUVBin::locateuvw ( Matrix< Int > &  locuv,
const Vector< Double > &  increment,
const Vector< Int > &  center,
const Matrix< Double > &  uvw 
) [private]
void casa::MSUVBin::makeCoordsys (  )  [private]
void casa::MSUVBin::makeSFConv ( Cube< Complex > &  convFunc,
Vector< Int > &  convSupport,
Double &  wScale,
Int &  convSampling,
Int &  convSize 
) [private]
Int casa::MSUVBin::makeUVW ( const Double  reffreq,
Vector< Double > &  incr,
Vector< Int > &  cent,
Matrix< Double > &  uvw 
) [private]
void casa::MSUVBin::makeWConv ( vi::VisibilityIterator2 iter,
Cube< Complex > &  convFunc,
Vector< Int > &  convSupport,
Double &  wScale,
Int &  convSampling,
Int &  convSize 
) [private]
void casa::MSUVBin::multiThrLoop ( const Int  outchan,
const vi::VisBuffer2 vb,
Double  refFreq,
Vector< Float >  scale,
Bool  hasCorrected,
Bool  needRot,
const Vector< Double > &  phasor,
const Vector< Double > &  visFreq,
const Double &  fracbw,
Complex *&  grid,
Complex *&  wghtSpec,
Bool *&  flag,
Bool *&  rowFlag,
Double *&  uvw,
Int *&  ant1,
Int *&  ant2,
Double *&  timeCen,
Double *&  sumWeight,
Double *&  numvis,
const Int  startchan,
const Int  endchan,
const Cube< Complex > &  convFunc,
const Vector< Int > &  convSupport,
const Double  wScale,
const Int  convSampling 
) [private]
Int casa::MSUVBin::recoverGridInfo ( const String &  msname  )  [private]
Bool casa::MSUVBin::saveData ( const Cube< Complex > &  grid,
const Cube< Bool > &  flag,
const Vector< Bool > &  rowFlag,
const Cube< Float > &  wghtSpec,
const Matrix< Double > &  uvw,
const Vector< Int > &  ant1,
const Vector< Int > &  ant2,
const Vector< Double > &  time,
const Int  startchan,
const Int  endchan,
const Cube< Float > &  imagwghtSpec = Cube< Float >() 
) [private]
Bool casa::MSUVBin::saveData ( const Cube< Complex > &  grid,
const Cube< Bool > &  flag,
const Vector< Bool > &  rowFlag,
const Cube< Float > &  wghtSpec,
const Matrix< Float > &  wght,
const Matrix< Double > &  uvw,
const Vector< Int > &  ant1,
const Vector< Int > &  ant2,
const Vector< Double > &  time 
) [private]
virtual Bool casa::MSUVBin::selectData ( const String &  msname,
const String &  spw = "",
const String &  field = "",
const String &  baseline = "",
const String &  scan = "",
const String &  uvrange = "",
const String &  taql = "",
const String &  subarray = "",
const String &  correlation = "",
const String &  intent = "",
const String &  obs = "" 
) [virtual]

The following can be called multiple times to setup multiple input MS.

static Int casa::MSUVBin::sepCommaEmptyToVectorStrings ( Vector< String > &  retStr,
const String &  str 
) [static, private]
void casa::MSUVBin::setOutputMS ( const String &  msname  ) 

void setInputMS(const MeasurementSet& ms); void setInputMS(const Block<const MeasurementSet*> mssPtr);

void casa::MSUVBin::setTileCache (  )  [private]
void casa::MSUVBin::storeGridInfo (  )  [private]
static Bool casa::MSUVBin::String2MDirection ( const String &  theString,
MDirection &  theMeas,
const String  msname = "" 
) [static]

Helper function for creating MDirection from a string.

void casa::MSUVBin::weightSync (  )  [private]

Member Data Documentation

Vector<Int> casa::MSUVBin::chanMap_p [private]

Definition at line 145 of file MSUVBin.h.

Vector<Vector<Int> > casa::MSUVBin::chanMapRev_p [private]

Definition at line 146 of file MSUVBin.h.

CoordinateSystem casa::MSUVBin::csys_p [private]

Definition at line 142 of file MSUVBin.h.

Vector<Double> casa::MSUVBin::deltas_p [private]

Definition at line 148 of file MSUVBin.h.

Bool casa::MSUVBin::doFlag_p [private]

Definition at line 156 of file MSUVBin.h.

Bool casa::MSUVBin::doW_p [private]

Definition at line 156 of file MSUVBin.h.

Bool casa::MSUVBin::existOut_p [private]

Definition at line 150 of file MSUVBin.h.

Double casa::MSUVBin::freqStart_p [private]

Definition at line 144 of file MSUVBin.h.

Double casa::MSUVBin::freqStep_p [private]

Definition at line 144 of file MSUVBin.h.

Definition at line 155 of file MSUVBin.h.

Block<const MeasurementSet *> casa::MSUVBin::mss_p [private]

Definition at line 153 of file MSUVBin.h.

Int casa::MSUVBin::nchan_p [private]

Definition at line 143 of file MSUVBin.h.

Int casa::MSUVBin::npol_p [private]

Definition at line 143 of file MSUVBin.h.

Matrix<Double> casa::MSUVBin::numVis_p [private]

Definition at line 157 of file MSUVBin.h.

Int casa::MSUVBin::nx_p [private]

Definition at line 143 of file MSUVBin.h.

Int casa::MSUVBin::ny_p [private]

Definition at line 143 of file MSUVBin.h.

String casa::MSUVBin::outMSName_p [private]

Definition at line 151 of file MSUVBin.h.

CountedPtr<MeasurementSet> casa::MSUVBin::outMsPtr_p [private]

Definition at line 152 of file MSUVBin.h.

MDirection casa::MSUVBin::phaseCenter_p [private]

Definition at line 147 of file MSUVBin.h.

Vector<Int> casa::MSUVBin::polMap_p [private]

Definition at line 145 of file MSUVBin.h.

Matrix<Double> casa::MSUVBin::sumWeight_p [private]

Definition at line 158 of file MSUVBin.h.

Definition at line 154 of file MSUVBin.h.

Vector<Int> casa::MSUVBin::whichStokes_p [private]

Definition at line 149 of file MSUVBin.h.


The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

Generated on 31 Aug 2016 for casa by  doxygen 1.6.1