casa  5.7.0-16
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Member Functions | Protected Member Functions | Private Member Functions | Private Attributes | Friends | List of all members
casa::VisJones Class Referenceabstract


VisJones More...

#include <VisCal.h>

Inheritance diagram for casa::VisJones:
casa::VisMueller casa::VisCal casa::PJones casa::SolvableVisJones casa::AccorJones casa::DJones casa::EGainCurve casa::EPJones casa::FJones casa::GJones casa::JJones casa::LJJones casa::TJones casa::XJones casa::XJones

Public Member Functions

 VisJones (VisSet &vs)
 Constructor. More...
 
 VisJones (casacore::String msname, casacore::Int MSnAnt, casacore::Int MSnSpw)
 
 VisJones (const MSMetaInfoForCal &msmc)
 
 VisJones (const casacore::Int &nAnt)
 
virtual ~VisJones ()
 
virtual VisCalEnum::MatrixType matrixType ()
 Return casacore::Matrix type. More...
 
virtual Mueller::MuellerType muellerType ()
 What kind of Mueller matrices should we use? (A function of the jonesType and target data shape) More...
 
virtual Jones::JonesType jonesType ()=0
 What kind of Jones matrix are we? (Must be implemented in specializations!) More...
 
virtual void state ()
 Report the state. More...
 
- Public Member Functions inherited from casa::VisMueller
 VisMueller (VisSet &vs)
 Constructor. More...
 
 VisMueller (casacore::String msname, casacore::Int MSnAnt, casacore::Int MSnSpw)
 
 VisMueller (const MSMetaInfoForCal &msmc)
 
 VisMueller (const casacore::Int &nAnt)
 
virtual ~VisMueller ()
 
- Public Member Functions inherited from casa::VisCal
 VisCal (VisSet &vs)
 
 VisCal (casacore::String msname, casacore::Int MSnAnt, casacore::Int MSnSpw)
 
 VisCal (const MSMetaInfoForCal &msmc)
 
 VisCal (const casacore::Int &nAnt)
 
virtual ~VisCal ()
 
virtual Type type ()=0
 Return the type of this calibration matrix (actual type of derived class). More...
 
virtual casacore::String typeName ()
 Return type name as string. More...
 
virtual casacore::String longTypeName ()
 
virtual VisCalEnum::VCParType parType ()
 Return the parameter type (nominally complex) More...
 
virtual casacore::Int nPar ()=0
 Number of pars per ant/bln (Must be implemented in specializations!) More...
 
virtual casacore::Vector
< casacore::Bool
spwOK ()
 Report calibration availability per spw (always true for non-tabular?) More...
 
virtual casacore::Bool spwOK (casacore::Int)
 
virtual casacore::Bool calAvailable (vi::VisBuffer2 &)
 Calibration available? (always true for non-tabular) More...
 
virtual casacore::Bool VBOKforCalApply (vi::VisBuffer2 &)
 Calibration expected AND available? (always assume true for non-tabular) More...
 
virtual casacore::Bool freqDepPar ()
 Frequency-dependent Parameters? Nominally not. More...
 
const casacore::IntnChanPar () const
 Number of par channels in current spw. More...
 
virtual casacore::Bool freqDepMat ()
 Frequency-dependent Matrices? Nominally same as freqDepPar. More...
 
virtual casacore::Bool freqDepCalWt ()
 Freq-dep Weight scaling? // almost always false. More...
 
virtual casacore::Bool timeDepMat ()
 Matrices time-dependent per parameter set (nominally no) More...
 
casacore::Bool isApplied ()
 Is this calibration matrix to be applied? More...
 
virtual casacore::Bool isSolvable ()
 Is this solveable? (never via this interface) More...
 
virtual casacore::Doubleinterval ()
 Return the time interval over which this calibration is constant. More...
 
virtual void setApply ()
 Set the application parameters. More...
 
virtual void setApply (const casacore::Record &apply)
 
virtual void setCallib (const casacore::Record &callib, const casacore::MeasurementSet &selms)
 
virtual casacore::String applyinfo ()
 Apply info/params, suitable for logging. More...
 
virtual casacore::String siminfo ()
 simulation params - for a VC, sim is apply; for a SVC this will get overriden More...
 
casacore::BoolcalWt ()
 Trigger calibration of weights. More...
 
virtual void correct (VisBuffer &vb, casacore::Bool trial=false)
 Apply calibration to data in VisBuffer (correct casacore::Data or corrupt Model) (in-place versions) More...
 
virtual void correct2 (vi::VisBuffer2 &vb, casacore::Bool trial=false, casacore::Bool doWtSp=false, casacore::Bool dosync=true)
 
virtual void corrupt (VisBuffer &vb)
 
virtual void corrupt2 (vi::VisBuffer2 &vb)
 
virtual void correct (VisBuffer &vb, casacore::Cube< casacore::Complex > &Vout, casacore::Bool trial=false)
 Apply calibration to data in VisBuffer; (alternate output versions) More...
 
virtual void corrupt (VisBuffer &vb, casacore::Cube< casacore::Complex > &Mout)
 
virtual void corrupt2 (vi::VisBuffer2 &vb, casacore::Cube< casacore::Complex > &Mout)
 
virtual void initCalFlagCount ()
 Flag counting. More...
 
virtual casacore::Record actionRec ()
 
virtual void currMetaNote ()
 
void setPrtlev (const casacore::Int &prtlev)
 Set the print level. More...
 
casacore::Int blnidx (const casacore::Int &a1, const casacore::Int &a2)
 Baseline index from antenna indices: (assumes a1<=a2 !!) More...
 
casacore::StringextraTag ()
 
virtual void setMeta (int obs, int scan, double time, int spw, const casacore::Vector< double > &freq, int fld)
 VI2-related refactor-----------------------------------—. More...
 
virtual void sizeApplyParCurrSpw (int nVisChan)
 Reshape solvePar* arrays for the currSpw() (sensitive to freqDepPar()) More...
 
virtual void setDefApplyParCurrSpw (bool sync=false, bool doInv=false)
 Set parameters to def values in the currSpw(), and optionally sync everything. More...
 
virtual void setApplyParCurrSpw (const casacore::Cube< casacore::Complex > cpar, bool sync=false, bool doInv=false)
 Set parameters to specified values in the currSpw(), and optionally sync matrices. More...
 
virtual void setApplyParCurrSpw (const casacore::Cube< float > rpar, bool sync=false, bool doInv=false)
 
virtual casacore::Cube
< casacore::Complex > & 
currCPar ()
 Access (public) to current solution parameters and matrices. More...
 
virtual casacore::Cube
< casacore::Float > & 
currRPar ()
 
virtual casacore::Cube
< casacore::Bool > & 
currParOK ()
 

Protected Member Functions

virtual casacore::IntnElem ()
 Number of parameter sets is number of antennas. More...
 
virtual casacore::Int nCalMat ()
 Number of Cal Matrices to form on antenna axis (Jones, apply context: nAnt()) More...
 
virtual casacore::Bool trivialMuellerElem ()
 Jones matrices can never be trivial Muellers! More...
 
virtual casacore::Bool trivialJonesElem ()=0
 Are the parameters the Jones matrix elements? (or is a non-trivial calculation required?) (Must be implemented in specializations!) More...
 
virtual casacore::Bool applyByMueller ()
 Are we applying via Mueller or Jones multiplication? (probably by Jones for native Jones?) More...
 
virtual casacore::Bool applyByJones ()
 
JonesJ1 ()
 Access to matrix renderings of Jones matrices. More...
 
JonesJ2 ()
 
casacore::Cube
< casacore::Complex > & 
currJElem ()
 Access to Jones matrix element array. More...
 
casacore::Cube< casacore::Bool > & currJElemOK ()
 
virtual void invalidateCalMat ()
 Invalidate cal matrices generically (at this level, both Mueller and Jones) More...
 
void invalidateJ ()
 Validation of Jones matrices. More...
 
void validateJ ()
 
casacore::Bool JValid ()
 
virtual void applyCal (VisBuffer &vb, casacore::Cube< casacore::Complex > &Vout, casacore::Bool trial=false)
 Row-by-row apply to a casacore::Cube<casacore::Complex> (applyByJones override) More...
 
virtual void applyCal2 (vi::VisBuffer2 &vb, casacore::Cube< casacore::Complex > &Vout, casacore::Cube< casacore::Float > &Wout, casacore::Bool trial=false)
 
virtual void syncCalMat (const casacore::Bool &doInv=false)
 Sync matrices for current meta data (VisJones override) More...
 
virtual void calcAllMueller ()
 Calculate an ensemble of Mueller matrices (all baselines, channels) (only meaningful if applyByMueller()=T) More...
 
virtual void syncJones (const casacore::Bool &doInv=false)
 Synchronize current Jones matrices. More...
 
virtual void calcAllJones ()
 Calculate an ensemble of Jones matrices (all antennas, channels) More...
 
virtual void calcOneJones (casacore::Vector< casacore::Complex > &mat, casacore::Vector< casacore::Bool > &mOk, const casacore::Vector< casacore::Complex > &par, const casacore::Vector< casacore::Bool > &pOk)
 Calculate a single Jones matrix by some means from parameters. More...
 
virtual void invJones ()
 Invert Jones matrices. More...
 
virtual void setMatByOk ()
 Set matrix elements according to their ok flags (e.g., makes a unit matrix if everything flagged, so we don't have to make atomic ok checks in apply) More...
 
void createJones ()
 Create Jones interface. More...
 
virtual void syncWtScale ()
 Synchronize weight scale factors. More...
 
virtual void calcWtScale ()
 Perform weight scale calculation (specializable) More...
 
virtual void updateWt (casacore::Vector< casacore::Float > &wt, const casacore::Int &a1, const casacore::Int &a2)
 Update the wt vector for a baseline. More...
 
virtual void updateWt2 (casacore::Matrix< casacore::Float > &wt, const casacore::Int &a1, const casacore::Int &a2)
 
- Protected Member Functions inherited from casa::VisMueller
MuellerM ()
 Access to matrix renderings of Muellers. More...
 
casacore::Cube
< casacore::Complex > & 
currMElem ()
 Access to current matrices. More...
 
casacore::Cube< casacore::Bool > & currMElemOK ()
 
void invalidateM ()
 Validation of Mueller matrices (for currSpw) More...
 
void validateM ()
 
casacore::Bool MValid ()
 
virtual void syncMueller (const casacore::Bool &doInv=false)
 Sync Mueller matrix elements for current parameters. More...
 
virtual void calcOneMueller (casacore::Vector< casacore::Complex > &mat, casacore::Vector< casacore::Bool > &mOk, const casacore::Vector< casacore::Complex > &par, const casacore::Vector< casacore::Bool > &pOk)
 Calculate a single Mueller matrix by some means. More...
 
virtual void invMueller ()
 Invert Mueller matrices. More...
 
void createMueller ()
 Create Mueller matrix algebra interface. More...
 
- Protected Member Functions inherited from casa::VisCal
void setApplied (const casacore::Bool &flag)
 Set applied state flag. More...
 
casacore::StringmsName ()
 
casacore::IntnSpw ()
 General Shape Info. More...
 
casacore::IntnAnt ()
 
casacore::IntnBln ()
 
casacore::IntcurrSpw ()
 Current in-focus spw. More...
 
casacore::DoublelastTime ()
 Current coords. More...
 
casacore::DoublecurrTime ()
 
casacore::IntcurrScan ()
 
casacore::IntcurrObs ()
 
casacore::IntcurrField ()
 
casacore::IntcurrIntent ()
 
casacore::Vector
< casacore::Double > & 
currFreq ()
 
casacore::DoublerefTime ()
 
casacore::DoublerefFreq ()
 
casacore::IntnChanPar ()
 Current spectral shapes. More...
 
casacore::IntnChanMat ()
 
casacore::IntstartChan ()
 
casacore::Vector< casacore::Int > & nChanParList ()
 
casacore::Vector< casacore::Int > & nChanMatList ()
 
casacore::Vector< casacore::Int > & startChanList ()
 
VisVectorV ()
 Access to matrix renderings of Visibilities. More...
 
void invalidateP ()
 Validation of calibration parameters. More...
 
void validateP ()
 
casacore::Bool PValid ()
 
casacore::Cube< casacore::Float > & currWtScale ()
 Access to weight-scaling factors. More...
 
virtual void countInFlag (const VisBuffer &vb)
 Flag counting. More...
 
virtual void countInFlag2 (const vi::VisBuffer2 &vb)
 
virtual void countOutFlag (const VisBuffer &vb)
 
virtual void countOutFlag2 (const vi::VisBuffer2 &vb)
 
virtual void syncCal (const VisBuffer &vb, const casacore::Bool &doInv=false)
 Synchronize "gains" with a VisBuffer or another VisCal. More...
 
virtual void syncCal2 (const vi::VisBuffer2 &vb, const casacore::Bool &doInv=false)
 
virtual void syncCal (VisCal &vc)
 
virtual void syncMeta (const VisBuffer &vb)
 Set internal meta data from a VisBuffer or another VisCal. More...
 
virtual void syncMeta2 (const vi::VisBuffer2 &vb)
 
void syncMeta (VisCal &vc)
 
void syncMeta (const casacore::Int &spw, const casacore::Double &time, const casacore::Int &field, const casacore::Vector< casacore::Double > &freq, const casacore::Int &nchan)
 
void setCalChannelization (const casacore::Int &nChanDat)
 Set the calibration matrix channelization. More...
 
void checkCurrCal ()
 Test for need of new calibration. More...
 
virtual void syncCal (const casacore::Bool &doInv=false)
 Synchronize "gains" with current meta-data. More...
 
virtual void syncPar ()
 Sync parameters for current meta data. More...
 
virtual void calcPar ()
 Calculate Mueller parameters by some means. More...
 
casacore::Intprtlev ()
 Return print (cout) level. More...
 
void setCurrField (const casacore::Int &ifld)
 set current field index vector to given field id More...
 
const MSMetaInfoForCalmsmc () const
 Access to the MSMetaInfoForCal (throws if none) More...
 

Private Member Functions

 VisJones ()
 Default ctor is private. More...
 
void initVisJones ()
 Init VisJones pointers. More...
 
void deleteVisJones ()
 Delete the this* caches. More...
 

Private Attributes

casacore::PtrBlock< Jones * > J1_
 Jones algebra wrapper (per Spw) More...
 
casacore::PtrBlock< Jones * > J2_
 
casacore::PtrBlock
< casacore::Cube
< casacore::Complex > * > 
currJElem_
 Current Jones matrix-element arrays. More...
 
casacore::PtrBlock
< casacore::Cube
< casacore::Bool > * > 
currJElemOK_
 
casacore::Vector< casacore::BoolJValid_
 Jones validity, per spw. More...
 

Friends

class SolvableVisJones
 

Additional Inherited Members

- Public Types inherited from casa::VisCal
enum  Type {
  Test,
  ANoise,
  M,
  KAntPos,
  B,
  K,
  G,
  J,
  D,
  X,
  C,
  P,
  E,
  T,
  F,
  A,
  ALL
}
 Allowed types of VisCal matrices - 'correct' order enum Type{UVMOD,Mf,M,K,B,G,D,C,E,P,T,EP,F}; enum Type{Test=0,ANoise,M,KAntPos,K,B,G,J,D,X,C,P,E,T,F,A,ALL};. More...
 
enum  ParType {
  Co,
  Re,
  CoRe
}
 Enumeration of parameter types (casacore::Complex, Real, or Both) More...
 
- Static Public Member Functions inherited from casa::VisCal
static casacore::String nameOfType (Type type)
 

Detailed Description


VisJones

Definition at line 557 of file VisCal.h.

Constructor & Destructor Documentation

casa::VisJones::VisJones ( VisSet vs)

Constructor.

casa::VisJones::VisJones ( casacore::String  msname,
casacore::Int  MSnAnt,
casacore::Int  MSnSpw 
)
casa::VisJones::VisJones ( const MSMetaInfoForCal msmc)
casa::VisJones::VisJones ( const casacore::Int nAnt)
virtual casa::VisJones::~VisJones ( )
virtual
casa::VisJones::VisJones ( )
private

Default ctor is private.

Member Function Documentation

virtual casacore::Bool casa::VisJones::applyByJones ( )
inlineprotectedvirtual

Definition at line 608 of file VisCal.h.

virtual casacore::Bool casa::VisJones::applyByMueller ( )
inlineprotectedvirtual

Are we applying via Mueller or Jones multiplication? (probably by Jones for native Jones?)

Reimplemented from casa::VisMueller.

Definition at line 607 of file VisCal.h.

virtual void casa::VisJones::applyCal ( VisBuffer vb,
casacore::Cube< casacore::Complex > &  Vout,
casacore::Bool  trial = false 
)
protectedvirtual

Row-by-row apply to a casacore::Cube<casacore::Complex> (applyByJones override)

Reimplemented from casa::VisMueller.

virtual void casa::VisJones::applyCal2 ( vi::VisBuffer2 vb,
casacore::Cube< casacore::Complex > &  Vout,
casacore::Cube< casacore::Float > &  Wout,
casacore::Bool  trial = false 
)
protectedvirtual

Reimplemented from casa::VisMueller.

virtual void casa::VisJones::calcAllJones ( )
protectedvirtual
virtual void casa::VisJones::calcAllMueller ( )
protectedvirtual

Calculate an ensemble of Mueller matrices (all baselines, channels) (only meaningful if applyByMueller()=T)

Reimplemented from casa::VisMueller.

virtual void casa::VisJones::calcOneJones ( casacore::Vector< casacore::Complex > &  mat,
casacore::Vector< casacore::Bool > &  mOk,
const casacore::Vector< casacore::Complex > &  par,
const casacore::Vector< casacore::Bool > &  pOk 
)
protectedvirtual

Calculate a single Jones matrix by some means from parameters.

Reimplemented in casa::DJones, and casa::PJones.

virtual void casa::VisJones::calcWtScale ( )
protectedvirtual

Perform weight scale calculation (specializable)

Reimplemented from casa::VisMueller.

Reimplemented in casa::BJones, and casa::StandardTsys.

void casa::VisJones::createJones ( )
protected

Create Jones interface.

casacore::Cube<casacore::Complex>& casa::VisJones::currJElem ( )
inlineprotected

Access to Jones matrix element array.

Definition at line 615 of file VisCal.h.

References currJElem_, and casa::VisCal::currSpw().

casacore::Cube<casacore::Bool>& casa::VisJones::currJElemOK ( )
inlineprotected

Definition at line 616 of file VisCal.h.

References currJElemOK_, and casa::VisCal::currSpw().

void casa::VisJones::deleteVisJones ( )
private

Delete the this* caches.

void casa::VisJones::initVisJones ( )
private

Init VisJones pointers.

virtual void casa::VisJones::invalidateCalMat ( )
inlineprotectedvirtual

Invalidate cal matrices generically (at this level, both Mueller and Jones)

Reimplemented from casa::VisMueller.

Definition at line 619 of file VisCal.h.

References invalidateJ(), and casa::VisMueller::invalidateM().

void casa::VisJones::invalidateJ ( )
inlineprotected

Validation of Jones matrices.

Definition at line 622 of file VisCal.h.

References casa::VisCal::currSpw(), and JValid_.

Referenced by invalidateCalMat(), and casa::SolvableVisJones::invalidateDiffCalMat().

virtual void casa::VisJones::invJones ( )
protectedvirtual

Invert Jones matrices.

Jones& casa::VisJones::J1 ( )
inlineprotected

Access to matrix renderings of Jones matrices.

Definition at line 611 of file VisCal.h.

References casa::VisCal::currSpw(), and J1_.

Jones& casa::VisJones::J2 ( )
inlineprotected

Definition at line 612 of file VisCal.h.

References casa::VisCal::currSpw(), and J2_.

virtual Jones::JonesType casa::VisJones::jonesType ( )
pure virtual
casacore::Bool casa::VisJones::JValid ( )
inlineprotected

Definition at line 624 of file VisCal.h.

References casa::VisCal::currSpw(), and JValid_.

virtual VisCalEnum::MatrixType casa::VisJones::matrixType ( )
inlinevirtual

Return casacore::Matrix type.

Reimplemented from casa::VisMueller.

Definition at line 575 of file VisCal.h.

References casa::VisCalEnum::JONES.

virtual Mueller::MuellerType casa::VisJones::muellerType ( )
virtual

What kind of Mueller matrices should we use? (A function of the jonesType and target data shape)

Implements casa::VisMueller.

virtual casacore::Int casa::VisJones::nCalMat ( )
inlineprotectedvirtual

Number of Cal Matrices to form on antenna axis (Jones, apply context: nAnt())

Reimplemented from casa::VisMueller.

Reimplemented in casa::SolvableVisJones.

Definition at line 595 of file VisCal.h.

References casa::VisCal::nAnt().

virtual casacore::Int& casa::VisJones::nElem ( )
inlineprotectedvirtual

Number of parameter sets is number of antennas.

Reimplemented from casa::VisMueller.

Definition at line 591 of file VisCal.h.

References casa::VisCal::nAnt().

virtual void casa::VisJones::setMatByOk ( )
protectedvirtual

Set matrix elements according to their ok flags (e.g., makes a unit matrix if everything flagged, so we don't have to make atomic ok checks in apply)

Reimplemented from casa::VisMueller.

Reimplemented in casa::SolvableVisJones.

Referenced by casa::SolvableVisJones::setMatByOk().

virtual void casa::VisJones::state ( )
virtual

Report the state.

Reimplemented from casa::VisMueller.

Reimplemented in casa::SolvableVisJones.

virtual void casa::VisJones::syncCalMat ( const casacore::Bool doInv = false)
protectedvirtual

Sync matrices for current meta data (VisJones override)

Reimplemented from casa::VisMueller.

virtual void casa::VisJones::syncJones ( const casacore::Bool doInv = false)
protectedvirtual

Synchronize current Jones matrices.

Reimplemented in casa::StandardTsys.

Referenced by casa::StandardTsys::syncJones().

virtual void casa::VisJones::syncWtScale ( )
protectedvirtual

Synchronize weight scale factors.

Reimplemented from casa::VisMueller.

Reimplemented in casa::StandardTsys, casa::EVLASwPow, and casa::SDDoubleCircleGainCal.

virtual casacore::Bool casa::VisJones::trivialJonesElem ( )
protectedpure virtual

Are the parameters the Jones matrix elements? (or is a non-trivial calculation required?) (Must be implemented in specializations!)

Implemented in casa::XJones, casa::JJones, casa::PosAngJones, casa::KAntPosJones, casa::GJones, casa::FringeJones, casa::KJones, casa::XJones, casa::LJJones, casa::EPJones, casa::TJones, casa::DJones, casa::EVLASwPow, casa::StandardTsys, casa::EGainCurve, casa::FJones, casa::AccorJones, and casa::PJones.

virtual casacore::Bool casa::VisJones::trivialMuellerElem ( )
inlineprotectedvirtual

Jones matrices can never be trivial Muellers!

Implements casa::VisMueller.

Definition at line 598 of file VisCal.h.

virtual void casa::VisJones::updateWt ( casacore::Vector< casacore::Float > &  wt,
const casacore::Int a1,
const casacore::Int a2 
)
protectedvirtual

Update the wt vector for a baseline.

Reimplemented from casa::VisMueller.

virtual void casa::VisJones::updateWt2 ( casacore::Matrix< casacore::Float > &  wt,
const casacore::Int a1,
const casacore::Int a2 
)
protectedvirtual
void casa::VisJones::validateJ ( )
inlineprotected

Definition at line 623 of file VisCal.h.

References casa::VisCal::currSpw(), and JValid_.

Friends And Related Function Documentation

friend class SolvableVisJones
friend

Definition at line 559 of file VisCal.h.

Member Data Documentation

casacore::PtrBlock<casacore::Cube<casacore::Complex>*> casa::VisJones::currJElem_
private

Current Jones matrix-element arrays.

Definition at line 686 of file VisCal.h.

Referenced by currJElem().

casacore::PtrBlock<casacore::Cube<casacore::Bool>*> casa::VisJones::currJElemOK_
private

Definition at line 687 of file VisCal.h.

Referenced by currJElemOK().

casacore::PtrBlock<Jones*> casa::VisJones::J1_
private

Jones algebra wrapper (per Spw)

Definition at line 682 of file VisCal.h.

Referenced by J1().

casacore::PtrBlock<Jones*> casa::VisJones::J2_
private

Definition at line 683 of file VisCal.h.

Referenced by J2().

casacore::Vector<casacore::Bool> casa::VisJones::JValid_
private

Jones validity, per spw.

Definition at line 690 of file VisCal.h.

Referenced by invalidateJ(), JValid(), and validateJ().


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