casa::AWProjectWBFT Class Reference

#include <AWProjectWBFT.h>

Inheritance diagram for casa::AWProjectWBFT:
casa::AWProjectFT casa::FTMachine casa::AWProjectWBFTNew casa::MultiTermAWProjectWBFT

List of all members.

Public Member Functions

 AWProjectWBFT (Int nFacets, Long cachesize, CountedPtr< CFCache > &cfcache, CountedPtr< ConvolutionFunction > &cf, CountedPtr< VisibilityResamplerBase > &visResampler, Bool applyPointingOffset=True, Bool doPBCorr=True, Int tilesize=16, Float paSteps=5.0, Float pbLimit=5e-4, Bool usezero=False, Bool conjBeams_p=True, Bool doublePrecGrid=False)
 Constructor: cachesize is the size of the cache in words (e.g.
 AWProjectWBFT (const RecordInterface &stateRec)
 Construct from a Record containing the AWProjectWBFT state.
 AWProjectWBFT (const AWProjectWBFT &other)
 Copy constructor.
AWProjectWBFToperator= (const AWProjectWBFT &other)
 Assignment operator.
 ~AWProjectWBFT ()
virtual String name () const
 Return the name of the machine.
Int findPointingOffsets (const VisBuffer &vb, Array< Float > &l_off, Array< Float > &m_off, Bool Evaluate)
 Bool changed(const VisBuffer& vb) {return vpSJ->changed(vb,1);}; Bool changed(const VisBuffer& vb) {return False;}.
void normalizeAvgPB ()
 ----------------------------------------------------------------------
void normalizeAvgPB (ImageInterface< Complex > &, ImageInterface< Float > &)
virtual void makeSensitivityImage (const VisBuffer &vb, const ImageInterface< Complex > &imageTemplate, ImageInterface< Float > &sensitivityImage)
 This method is called from AWProjectFT to compute the sensitivity image by accumulating in the image domain (i.e.
virtual void makeSensitivityImage (Lattice< Complex > &wtImage, ImageInterface< Float > &sensitivityImage, const Matrix< Float > &sumWt=Matrix< Float >(), const Bool &doFFTNorm=True)
 In AWProjectWBFT and its derivatives, sensitivity image is computed by accumulating weight functions (images) during the first gridding cycle.
virtual void makeSensitivitySqImage (Lattice< Complex > &wtImage, ImageInterface< Complex > &sensitivitySqImage, const Matrix< Float > &sumWt=Matrix< Float >(), const Bool &doFFTNorm=True)
virtual ImageInterface< Complex > & getImage (Matrix< Float > &, Bool normalize=True)
 Method used to make normalized image from gridded visibilites.
virtual Float pbFunc (const Float &, const Float &)
 Method used to convert the pixel value of the PB image, passed as pbPixValue, to a value used for PB-normalization.
virtual void finalizeToSky ()
 {Float tt=(pbPixValue);return (abs(tt) >= pbLimit)?tt:1.0;};
virtual void initializeToSky (ImageInterface< Complex > &image, Matrix< Float > &weight, const VisBuffer &vb)
 Initialize transform to Sky plane: initializes the image.
void setObservatoryLocation (const MPosition &mLocation)
 Initialize transform to Visibility plane using the image as a template.
virtual Bool verifyShapes (IPosition shape0, IPosition shape1)
virtual Bool computeAvgPB (const Double &, const Double &)
 Returns True if accumulation during gridding to compute the average PB must be done.
virtual void setCFCache (CountedPtr< CFCache > &cfc, const Bool resetCFC=True)
 virtual void setMiscInfo(const Int qualifier) {sensitivityPatternQualifier_p=qualifier;} {qualifier_p = qualifier;taylorQualifier_p = "_MFS_"+StringtoString(qualifier_p)+"_";};

Protected Member Functions

virtual void ftWeightImage (Lattice< Complex > &wtImage, const Matrix< Float > &sumWt, const Bool &doFFTNorm)
virtual void resampleDataToGrid (Array< Complex > &griddedData, VBStore &vbs, const VisBuffer &vb, Bool &dopsf)
virtual void resampleDataToGrid (Array< DComplex > &griddedData, VBStore &vbs, const VisBuffer &vb, Bool &dopsf)
void resampleCFToGrid (Array< Complex > &wtsGrid, VBStore &vbs, const VisBuffer &vb)
 virtual void resampleGridToData(VBStore& vbs, const VisBuffer& vb);

Protected Attributes

Bool avgPBReady_p
Bool resetPBs_p
Bool wtImageFTDone_p

Private Attributes

String tt_pp
Vector< Int > fieldIds_p
TempImage< Complex > griddedWeights
TempImage< Complex > griddedConjWeights
CFStore rotatedCFWts_p
Float pbNorm
CountedPtr
< VisibilityResamplerBase
visResamplerWt_p
Bool oneTimeMessage_p
 // These ugly methods (ugly due to their flirtation with FORTRAN) should go!

Detailed Description

Definition at line 41 of file AWProjectWBFT.h.


Constructor & Destructor Documentation

casa::AWProjectWBFT::AWProjectWBFT ( Int  nFacets,
Long  cachesize,
CountedPtr< CFCache > &  cfcache,
CountedPtr< ConvolutionFunction > &  cf,
CountedPtr< VisibilityResamplerBase > &  visResampler,
Bool  applyPointingOffset = True,
Bool  doPBCorr = True,
Int  tilesize = 16,
Float  paSteps = 5.0,
Float  pbLimit = 5e-4,
Bool  usezero = False,
Bool  conjBeams_p = True,
Bool  doublePrecGrid = False 
)

Constructor: cachesize is the size of the cache in words (e.g.

a few million is a good number), tilesize is the size of the tile used in gridding (cannot be less than 12, 16 works in most cases).

casa::AWProjectWBFT::AWProjectWBFT ( const RecordInterface &  stateRec  ) 

Construct from a Record containing the AWProjectWBFT state.

casa::AWProjectWBFT::AWProjectWBFT ( const AWProjectWBFT other  )  [inline]

Copy constructor.

Definition at line 69 of file AWProjectWBFT.h.

References operator=().

casa::AWProjectWBFT::~AWProjectWBFT (  )  [inline]

Definition at line 74 of file AWProjectWBFT.h.


Member Function Documentation

virtual Bool casa::AWProjectWBFT::computeAvgPB ( const Double &  ,
const Double &   
) [inline, virtual]

Returns True if accumulation during gridding to compute the average PB must be done.

Reimplemented in casa::MultiTermAWProjectWBFT.

Definition at line 159 of file AWProjectWBFT.h.

References avgPBReady_p, and casacore::False.

virtual void casa::AWProjectWBFT::finalizeToSky (  )  [virtual]

{Float tt=(pbPixValue);return (abs(tt) >= pbLimit)?tt:1.0;};

{Float tt=sqrt(pbPixValue);return (abs(tt) >= pbLimit)?tt:1.0;};

Reimplemented from casa::AWProjectFT.

Int casa::AWProjectWBFT::findPointingOffsets ( const VisBuffer ,
Array< Float > &  ,
Array< Float > &  ,
Bool  Evaluate 
) [virtual]

Bool changed(const VisBuffer& vb) {return vpSJ->changed(vb,1);}; Bool changed(const VisBuffer& vb) {return False;}.

Reimplemented from casa::AWProjectFT.

virtual void casa::AWProjectWBFT::ftWeightImage ( Lattice< Complex > &  wtImage,
const Matrix< Float > &  sumWt,
const Bool &  doFFTNorm 
) [protected, virtual]

Reimplemented in casa::AWProjectWBFTNew.

virtual ImageInterface<Complex>& casa::AWProjectWBFT::getImage ( Matrix< Float > &  ,
Bool  normalize = True 
) [virtual]

Method used to make normalized image from gridded visibilites.

This calls makeSensitivityImage() to make the sensitivity image and AWProjectFT::getImage() to make the image from gridded visibilites. AWProjectFT::getImage() internally calls normalizeImage() which uses the sensitivty image computed by makeSensitivtyImage().

Reimplemented from casa::AWProjectFT.

Reimplemented in casa::MultiTermAWProjectWBFT.

virtual void casa::AWProjectWBFT::initializeToSky ( ImageInterface< Complex > &  image,
Matrix< Float > &  weight,
const VisBuffer vb 
) [virtual]

Initialize transform to Sky plane: initializes the image.

Reimplemented from casa::AWProjectFT.

virtual void casa::AWProjectWBFT::makeSensitivityImage ( Lattice< Complex > &  wtImage,
ImageInterface< Float > &  sensitivityImage,
const Matrix< Float > &  sumWt = Matrix< Float >(),
const Bool &  doFFTNorm = True 
) [virtual]

In AWProjectWBFT and its derivatives, sensitivity image is computed by accumulating weight functions (images) during the first gridding cycle.

AWProjectFT::makeSensitivityImage() is overloaded in AWProjectWBFT and only issues a log message.

The following method is used to Fourier transform normalize the accumulated weight images. doFFTNorm when True, the FFT normalization (by pixel volume) is also done.

Reimplemented from casa::AWProjectFT.

Reimplemented in casa::MultiTermAWProjectWBFT.

virtual void casa::AWProjectWBFT::makeSensitivityImage ( const VisBuffer vb,
const ImageInterface< Complex > &  imageTemplate,
ImageInterface< Float > &  sensitivityImage 
) [virtual]

This method is called from AWProjectFT to compute the sensitivity image by accumulating in the image domain (i.e.

directly accumulate the Primay Beam functions). This is called from findConvFunction() so that sensitivity pattern is also pre-computed along with the convolution functions. This in-turn calls the ATerm::makeAverageResponse().

For AWProjectWBFT class of FTMachines, this just issues a log message indicating that this is only setting up things for accumulation of weight images in the first gridding cycle. The actual sensitivity patterns are computed by overloaded function below.

Reimplemented from casa::AWProjectFT.

virtual void casa::AWProjectWBFT::makeSensitivitySqImage ( Lattice< Complex > &  wtImage,
ImageInterface< Complex > &  sensitivitySqImage,
const Matrix< Float > &  sumWt = Matrix< Float >(),
const Bool &  doFFTNorm = True 
) [virtual]
virtual String casa::AWProjectWBFT::name (  )  const [inline, virtual]

Return the name of the machine.

Reimplemented from casa::AWProjectFT.

Reimplemented in casa::AWProjectWBFTNew, and casa::MultiTermAWProjectWBFT.

Definition at line 76 of file AWProjectWBFT.h.

void casa::AWProjectWBFT::normalizeAvgPB ( ImageInterface< Complex > &  ,
ImageInterface< Float > &   
) [inline, virtual]

Reimplemented from casa::AWProjectFT.

Reimplemented in casa::MultiTermAWProjectWBFT.

Definition at line 82 of file AWProjectWBFT.h.

void casa::AWProjectWBFT::normalizeAvgPB (  )  [virtual]

----------------------------------------------------------------------

Reimplemented from casa::AWProjectFT.

AWProjectWBFT& casa::AWProjectWBFT::operator= ( const AWProjectWBFT other  ) 

Assignment operator.

Reimplemented from casa::AWProjectFT.

Reimplemented in casa::MultiTermAWProjectWBFT.

Referenced by AWProjectWBFT().

virtual Float casa::AWProjectWBFT::pbFunc ( const Float &  ,
const Float &   
) [inline, virtual]

Method used to convert the pixel value of the PB image, passed as pbPixValue, to a value used for PB-normalization.

Typically, this will depend on the units of the "PB image" constructed by the makeSensitivtyImage() methods. pbLimit is the fractional pb-gain below which imaging is not required (this value is typically the user-defined parameter in the private member variable pbLimit_p).

Reimplemented from casa::AWProjectFT.

Definition at line 139 of file AWProjectWBFT.h.

void casa::AWProjectWBFT::resampleCFToGrid ( Array< Complex > &  wtsGrid,
VBStore vbs,
const VisBuffer vb 
) [protected]

virtual void resampleGridToData(VBStore& vbs, const VisBuffer& vb);

virtual void casa::AWProjectWBFT::resampleDataToGrid ( Array< DComplex > &  griddedData,
VBStore vbs,
const VisBuffer vb,
Bool &  dopsf 
) [protected, virtual]

Reimplemented from casa::AWProjectFT.

virtual void casa::AWProjectWBFT::resampleDataToGrid ( Array< Complex > &  griddedData,
VBStore vbs,
const VisBuffer vb,
Bool &  dopsf 
) [protected, virtual]

Reimplemented from casa::AWProjectFT.

virtual void casa::AWProjectWBFT::setCFCache ( CountedPtr< CFCache > &  cfc,
const Bool  resetCFC = True 
) [virtual]

virtual void setMiscInfo(const Int qualifier) {sensitivityPatternQualifier_p=qualifier;} {qualifier_p = qualifier;taylorQualifier_p = "_MFS_"+StringtoString(qualifier_p)+"_";};

virtual void ComputeResiduals(VisBuffer&vb, Bool useCorrected) {};

Reimplemented from casa::FTMachine.

void casa::AWProjectWBFT::setObservatoryLocation ( const MPosition &  mLocation  )  [inline]

Initialize transform to Visibility plane using the image as a template.

The image is loaded and Fourier transformed.

Reimplemented from casa::AWProjectFT.

Definition at line 150 of file AWProjectWBFT.h.

References casa::FTMachine::mLocation_p.

virtual Bool casa::AWProjectWBFT::verifyShapes ( IPosition  shape0,
IPosition  shape1 
) [inline, virtual]

Reimplemented from casa::AWProjectFT.

Definition at line 152 of file AWProjectWBFT.h.

References casacore::False.


Member Data Documentation

Definition at line 182 of file AWProjectWBFT.h.

Referenced by casa::MultiTermAWProjectWBFT::computeAvgPB(), and computeAvgPB().

Vector<Int> casa::AWProjectWBFT::fieldIds_p [private]

Definition at line 186 of file AWProjectWBFT.h.

TempImage<Complex> casa::AWProjectWBFT::griddedConjWeights [private]

Definition at line 187 of file AWProjectWBFT.h.

TempImage<Complex> casa::AWProjectWBFT::griddedWeights [private]

Definition at line 187 of file AWProjectWBFT.h.

// These ugly methods (ugly due to their flirtation with FORTRAN) should go!

virtual void runFortranGet(Matrix<Double>& uvw,Vector<Double>& dphase, Cube<Complex>& visdata, IPosition& s, Int& Conj, Cube<Int>& flags,Vector<Int>& rowFlags, Int& rownr,Vector<Double>& actualOffset, Array<Complex>* dataPtr, Int& aNx, Int& aNy, Int& npol, Int& nchan, VisBuffer& vb,Int& Nant_p, Int& scanNo, Double& sigma, Array<Float>& raoffsets, Array<Float>& decoffsets, Double area, Int& doGrad,Int paIndex); virtual void runFortranPut(Matrix<Double>& uvw,Vector<Double>& dphase, const Complex& visdata_p, IPosition& s, Int& Conj, Cube<Int>& flags,Vector<Int>& rowFlags, const Matrix<Float>& weight, Int& rownr,Vector<Double>& actualOffset, Array<Complex>& dataPtr, Int& aNx, Int& aNy, Int& npol, Int& nchan, const VisBuffer& vb,Int& Nant_p, Int& scanNo, Double& sigma, Array<Float>& raoffsets, Array<Float>& decoffsets, Matrix<Double>& sumWeight, Double& area, Int& doGrad, Int& doPSF,Int paIndex); virtual void runFortranGetGrad(Matrix<Double>& uvw,Vector<Double>& dphase, Cube<Complex>& visdata, IPosition& s, Cube<Complex>& gradVisAzData, Cube<Complex>& gradVisElData, Int& Conj, Cube<Int>& flags,Vector<Int>& rowFlags, Int& rownr,Vector<Double>& actualOffset, Array<Complex>* dataPtr, Int& aNx, Int& aNy, Int& npol, Int& nchan, VisBuffer& vb,Int& Nant_p, Int& scanNo, Double& sigma, Array<Float>& l_off, Array<Float>& m_off, Double area, Int& doGrad, Int paIndex);

Definition at line 242 of file AWProjectWBFT.h.

Float casa::AWProjectWBFT::pbNorm [private]

Definition at line 189 of file AWProjectWBFT.h.

Definition at line 182 of file AWProjectWBFT.h.

Definition at line 188 of file AWProjectWBFT.h.

String casa::AWProjectWBFT::tt_pp [private]

Definition at line 185 of file AWProjectWBFT.h.

Definition at line 190 of file AWProjectWBFT.h.

Definition at line 182 of file AWProjectWBFT.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