23 #ifndef FlagCalTableHandler_H_
24 #define FlagCalTableHandler_H_
45 #if !defined(__clang__) && defined(__GNUC__) && defined(__GNUC_MINOR__) && \
46 (__GNUC__ >= 5 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 6))
47 #pragma GCC diagnostic push
48 #pragma GCC diagnostic ignored "-Wunused-parameter"
49 #define CASA_WPOP_UNUSED
104 virtual vi::Subchunk
getSubchunk ()
const {vi::Subchunk dummy;
return dummy;}
237 #pragma GCC diagnostic pop
346 ||
id == VisBufferComponent2::VisibilityCubeObserved
347 ||
id == VisBufferComponent2::VisibilityCubeCorrected
348 ||
id == VisBufferComponent2::VisibilityCubeModel
virtual const casacore::Cube< casacore::Float > & visCubeFloat() const
virtual const casacore::Matrix<CStokesVector> & visCorrected () const = 0; // [nF,nR] virtual void setVisCorrected (const casacore::Matrix<CStokesVector> &) = 0; // [nF,nR]
virtual const casacore::Matrix< CStokesVector > & vis() const
A Vector of integers, for indexing into Array<T> objects.
virtual const casacore::Matrix< CStokesVector > & visModel() const
void invalidate()
Methods for efficient synchronization with CTIter.
virtual casacore::Bool isAttached() const
A Measure: astronomical direction.
virtual void normalize()
casacore::Sort/unsort the correlations, if necessary (Rudimentary handling of non-canonically sorted ...
const casacore::Vector< casacore::Int > & scan() const
virtual void setVisCorrected(const casacore::Matrix< CStokesVector > &)
bool selectData()
Generate selected CalTable.
virtual void setSigmaSpectrum(const casacore::Cube< float > &)
virtual void setTimeInterval(const casacore::Vector< casacore::Double > &)
casacore::Vector< casacore::Int > scan_p
virtual const casacore::Matrix< casacore::Float > & weight() const
virtual void dirtyComponentsAdd(const VisBufferComponents2 &)
casacore::Int nCorrelations()
virtual void setWeightSpectrum(const casacore::Cube< casacore::Float > &)
virtual void initWeightSpectrum(const casacore::Cube< casacore::Float > &)
virtual const casacore::Vector< casacore::Double > & time() const
virtual const casacore::Vector< casacore::Int > & scan() const
const casacore::Cube< casacore::Complex > & visCubeModel() const
std::complex< Float > Complex
virtual void dirtyComponentsSet(const VisBufferComponents2 &)
A top level class defining the data handling interface for the flagging module.
virtual const casacore::Matrix< casacore::Float > & imagingWeight() const
This method returns the imagin g If an imaging weight generator has not been supplied to the associat...
VisibilityIterator2 iterates through one or more readonly MeasurementSets.
virtual casacore::Float getWeightScaled(casacore::Int, casacore::Int) const
casacore::Bool CTcorrectedVisCubeOK_p
casacore::Cube< casacore::Complex > snr_p
virtual casacore::Bool existsColumn(VisBufferComponent2 id) const
casacore::Bool CTnCorrOK_p
void invalidate()
Methods for efficient synchronization with CTIter.
casacore::Cube< casacore::Complex > & visCube()
virtual const casacore::Vector< casacore::MDirection > & direction2() const
casacore::Bool CTVisCubeOK_p
casacore::Bool CTscanOK_p
casacore::Vector< casacore::Int > antenna2_p
Flag casacore::Data Handler class definition.
virtual const casacore::Array< casacore::Bool > & flagCategory() const
virtual const casacore::Matrix<casacore::Bool> & flag () const = 0; // [nF,nR] virtual void setFlag (...
casacore::Cube< std::complex< float > > & visCubeCorrectedRef()
virtual const casacore::Matrix< casacore::Bool > & flag() const
casacore::Bool CTchannelOK_p
casacore::Int nRowChunk_p
virtual const casacore::Vector< casacore::SquareMatrix< casacore::Complex, 2 > > & cjones() const
Returns the Jones C matrix for each antenna.
bool close()
Close CalTable.
casacore::Vector< casacore::Int > fieldId_p
casacore::Vector< casacore::Int > & observationId()
Convenient public methods for compatibility with casacore::MS-like interface.
virtual void initSigmaSpectrum(const casacore::Cube< casacore::Float > &)
void generateScanStartStopMap()
Mapping functions.
casacore::Bool CTnRowOK_p
virtual casacore::Int polarizationFrame() const
Returns the polarization frame for the specified row.
bool generateIterator()
Generate CalIter.
const casacore::Vector< casacore::Int > & correlationTypes() const
Returns the correlation type of each correlation in the VisCube.
casacore::Vector< casacore::Double > & getFrequencies(casacore::Int rowInBuffer, casacore::Int frame=vi::VisBuffer2::FrameNotSpecified)
virtual void setVisCube(const casacore::Cube< casacore::Complex > &)
virtual const casacore::Cube< casacore::Complex > & visCube() const
Visibility data accessors in order of observed, corrected, float, & model
virtual casacore::Float parang0(casacore::Double) const
Calculates the parallactic angle of the array as a whole at the specified time.
virtual casacore::Vector< casacore::MDirection > & azel(casacore::Double) const
Returns the pointing angle for each antenna in the array at the specified time.
virtual const casacore::Cube< casacore::Complex > & visCubeModel() const
virtual casacore::String msName(casacore::Bool=false) const
virtual void setObservationId(const casacore::Vector< casacore::Int > &)
casacore::Bool CTobservationIdOK_p
virtual void setDataDescriptionIds(const casacore::Vector< int > &)
const casacore::Vector< casacore::Int > & arrayId() const
virtual casacore::Int nChannels() const
virtual void copy(const VisBuffer2 &, casacore::Bool)
const casacore::Cube< casacore::Bool > & flagCube() const
casacore::Bool CTmodelVisCubeOK_p
casacore::Int & fillSpectralWindow()
Convenience methods and members to by-pass const methods issues.
const casacore::Vector< casacore::Int > & fieldId() const
virtual const casacore::Vector< casacore::Int > & arrayId() const
casacore::Int nRowChunk()
casacore::Bool CTnRowChunkOK_p
virtual const casacore::Cube< float > & sigmaSpectrum() const
const casacore::Vector< casacore::Int > & spectralWindows() const
Returns the spectral window ID for the specified row.
casacore::Bool CTflagCubeOk_p
NewCalTable * originalCalTable_p
casacore::Cube< std::complex< float > > & visCubeRef()
const casacore::Vector< casacore::Double > & getFrequencies(casacore::Int rowInBuffer, casacore::Int=vi::VisBuffer2::FrameNotSpecified) const
virtual const casacore::Vector< casacore::Double > & timeCentroid() const
virtual const casacore::Vector< casacore::Int > & observationId() const
bool nextChunk()
Move to next chunk.
casacore::Vector< casacore::Double > frequency_p
void setImagingWeight(const casacore::Matrix< float > &)
CTInterface * calTableInterface_p
casacore::Vector< casacore::Int > arrayId_p
virtual const casacore::Cube< casacore::Float > & weightSpectrum() const
virtual const casacore::Matrix<casacore::Float> & weightMat () const = 0; // [nC,nR] virtual void set...
casacore::Bool CTfieldIdOK_p
Members for efficient synchronization with CTIter.
virtual casacore::Vector< casacore::Int > getCorrelationTypes() const
casacore::Cube< casacore::Complex > & visCubeModel()
casacore::Bool CTantenna1OK_p
virtual void setSigma(const casacore::Matrix< casacore::Float > &)
virtual void setFeed2(const casacore::Vector< casacore::Int > &)
casacore::Vector< bool > & flagRowRef()
const casacore::Vector< casacore::Int > & getChannelNumbers(casacore::Int rowInBuffer) const
virtual void setSpectralWindows(const casacore::Vector< casacore::Int > &)
virtual const casacore::MDirection & phaseCenter() const
Returns the phase center of the array for the specified row.
casacore::Vector< casacore::Int > & getChannelNumbers(casacore::Int rowInBuffer)
casacore::Int nChannels()
virtual casacore::Bool isNewMs() const
virtual void setVisCubeCorrected(const casacore::Cube< casacore::Complex > &)
virtual casacore::Float getWeightScaled(casacore::Int) const
virtual const casacore::Matrix<CStokesVector> & visModel () const = 0; // [nF,nR] virtual void setVis...
casacore::Int spectralWindow() const
CTCache * ctCache_p
CTIter *calIter_p;.
const casacore::Cube< casacore::Complex > & visCube() const
Visibility data accessors in order of observed, corrected, float, & model
casacore::Int nRows() const
Returns the number of rows in this VisBuffer.
virtual const casacore::Vector< casacore::Int > & processorId() const
casacore::Vector< casacore::Int > channel_p
virtual casacore::Int dataDescriptionId() const
virtual void setFlagCategory(const casacore::Array< casacore::Bool > &)
virtual casacore::Float getSigmaScaled(casacore::Int) const
virtual void setAntenna2(const casacore::Vector< casacore::Int > &)
virtual void invalidate()
casacore::Vector< casacore::Int > & antenna1()
virtual const casacore::Matrix< casacore::Float > & sigma() const
casacore::Cube< casacore::Bool > flagCube_p
virtual void setExposure(const casacore::Vector< casacore::Double > &)
virtual const casacore::Vector< casacore::Int > & dataDescriptionIds() const
virtual casacore::Int dataDescriptionId () const = 0; virtual void setDataDescriptionId (casacore::In...
casacore::Int & fillFieldId()
virtual void setShape(casacore::Int, casacore::Int, casacore::Int, casacore::Bool)
casacore::Vector< casacore::Int > field_p
virtual void validateShapes() const
casacore::Int nChannels() const
virtual void setVisCubeModel(const casacore::Cube< casacore::Complex > &)
virtual void setVisCubeModel(const casacore::Vector< casacore::Float > &)
virtual casacore::Float getSigmaScaled(casacore::Int, casacore::Int, casacore::Int) const
virtual casacore::MDirection azel0(casacore::Double) const
virtual const casacore::Vector< casacore::Double > & timeInterval() const
Referenced counted pointer for constant data.
virtual const casacore::Vector< casacore::uInt > & rowIds() const
The returned casacore::Vector serves as a map between the rows in the VisBuffer and the row IDs in th...
casacore::Cube< float > & weightSpectrumRef()
virtual const casacore::Vector< casacore::Int > & correlationTypes() const
Returns the correlation type of each correlation in the VisCube.
virtual void dirtyComponentsClear()
virtual void setVis(casacore::Matrix< CStokesVector > &)
virtual casacore::Int spectralWindow() const
virtual void assign(const Array< T > &other)
Assign the other array (which must be of dimension one) to this vector.
virtual casacore::Bool isNewFieldId() const
casacore::Bool CTnChannelOK_p
virtual const vi::VisibilityIterator2 * getVi() const
For attached VBs this returns the VI the VB is attached to.
virtual void setAntenna1(const casacore::Vector< casacore::Int > &)
virtual void setVisCubeFloat(const casacore::Cube< casacore::Float > &)
virtual void setFeed1(const casacore::Vector< casacore::Int > &)
virtual const casacore::Matrix< CStokesVector > & visCorrected() const
casacore::Vector< casacore::Int > & antenna2()
casacore::Vector< casacore::Int > & correlationTypes()
const casacore::Vector< casacore::Int > & antenna1() const
casacore::Cube< bool > & flagCubeRef()
bool parseExpression(casacore::MSSelection &parser)
Parse casacore::MSSelection expression.
casacore::Vector< casacore::Int > antenna1_p
casacore::Vector< casacore::Double > time_p
LatticeExprNode nelements(const LatticeExprNode &expr)
1-argument function to get the number of elements in a lattice.
virtual const casacore::Cube< casacore::Complex > & visCubeCorrected() const
virtual const casacore::Matrix<CStokesVector> & vis () const = 0; // [nF,nR] virtual void setVis (cas...
virtual const casacore::Vector< casacore::Int > & spectralWindows() const
Returns the spectral window ID for the specified row.
virtual casacore::Int nRows() const
Returns the number of rows in this VisBuffer.
casacore::Bool CTtimeOK_p
virtual void writeChangesBack()
MSSelection: Class to represent a selection on an MS.
casacore::Int nCorrelations() const
Returns the number of correlations along the visCube correlation axis.
casacore::Bool CTcorrTypeOK_p
virtual void setFlagRow(const casacore::Vector< casacore::Bool > &)
virtual const casacore::Vector< casacore::Int > & antenna1() const
virtual void setFillable(casacore::Bool)
bool Bool
Define the standard types used by Casacore.
const casacore::Vector< casacore::Int > & antenna2() const
virtual casacore::Double getFrequency(casacore::Int, casacore::Int, casacore::Int=FrameNotSpecified) const
Writable version (limited to certain 'columns')
virtual void setFlagCube(const casacore::Cube< casacore::Bool > &)
virtual void setVisCube(const casacore::Complex &)
virtual const casacore::Vector< casacore::Bool > & flagRow() const
virtual const casacore::Vector< casacore::Float > & feedPa2() const
Calculates the parallactic angle for feed 0 of the row's Antenna2.
virtual void setFieldId(const casacore::Vector< casacore::Int > &)
virtual void setFlag(const casacore::Matrix< casacore::Bool > &)
virtual casacore::Float getSigmaScaled(casacore::Int, casacore::Int) const
const casacore::Vector< casacore::Int > & observationId() const
Convenient public methods for compatibility with casacore::MS-like interface.
casacore::Vector< casacore::Double > & time()
virtual casacore::Int nCorrelations() const
Returns the number of correlations along the visCube correlation axis.
casacore::Cube< casacore::Complex > fparam_p
virtual void setWeightMat(const casacore::Matrix< casacore::Float > &)
casacore::Int & fillnRowChunk()
virtual const casacore::Vector< casacore::Double > & exposure() const
virtual const casacore::Vector< casacore::Int > & feed2() const
bool flushFlags()
Write flag cube into MS.
virtual void resetWeightsUsingSigma()
Set the weight cube using the sigma cube.
virtual casacore::Vector< casacore::Float > & feedPa(casacore::Double) const
Calculates the parallactic angle for the first receptor of each antenna at the specified time...
virtual const casacore::Vector< casacore::Int > & antenna2() const
casacore::Cube< casacore::Complex > & visCubeCorrected()
~FlagCalTableHandler()
Default destructor.
casacore::Vector< casacore::Stokes::StokesTypes > getCorrelationTypesDefined() const
casacore::Vector< casacore::Int > corrType_p
virtual void setStateId(const casacore::Vector< casacore::Int > &)
virtual casacore::CountedPtr< vi::WeightScaling > getWeightScaling() const
bool checkIfColumnExists(casacore::String column)
Check if a given column is available in the cal table.
virtual casacore::Int polarizationId() const
FlagCalTableHandler(string msname, casacore::uShort iterationApproach=SUB_INTEGRATION, casacore::Double timeInterval=0)
Default constructor NOTE: casacore::Time interval 0 groups all time steps together in one chunk...
casacore::Vector< casacore::Int > getChannelNumbersSelected(casacore::Int) const
virtual casacore::Bool isRekeyable() const
virtual void copyComponents(const VisBuffer2 &, const VisBufferComponents2 &, casacore::Bool=false, casacore::Bool=true)
Copies the specified components (or just the ones in the cache if fetchIfNeeded is false) from the sp...
virtual const casacore::Vector< casacore::Int > & getChannelNumbers(casacore::Int) const
virtual const casacore::Matrix< casacore::Double > & uvw() const
casacore::IPosition getShape() const
virtual void setTimeCentroid(const casacore::Vector< casacore::Double > &)
virtual const casacore::Matrix< casacore::Float > & sigmaMat() const
virtual casacore::Bool isWritable() const
virtual casacore::Float getWeightScaled(casacore::Int, casacore::Int, casacore::Int) const
VisBuffer2s encapsulate one chunk of visibility data for processing.
virtual casacore::Bool isNewArrayId() const
virtual const casacore::Vector< casacore::Int > & feed1() const
Base class for all Casacore library errors.
casacore::Cube< casacore::Bool > & flagCube()
NewCalTable * selectedCalTable_p
CatTable selection objects.
casacore::Cube< std::complex< float > > & visCubeModelRef()
casacore::Bool CTantenna2OK_p
virtual const casacore::Vector< casacore::Int > & fieldId() const
virtual void phaseCenterShift(casacore::Double, casacore::Double)
Rotate visibility phase for phase center offsets (arcsecs)
virtual void setTime(const casacore::Vector< casacore::Double > &)
virtual void setDataDescriptionId(casacore::Int)
casacore::Vector< casacore::Int > spw_p
virtual void phaseCenterShift(const casacore::Vector< casacore::Double > &)
Rotate visibility phase for given vector (dim = nrow of vb) of phases (metres)
virtual void setVisCubeModel(const casacore::Complex &)
casacore::Block< casacore::String > getSortColumns(casacore::Block< casacore::Int > intCols)
Convenient private methods for compatibility with casacore::MS-like interface.
virtual const casacore::Vector< casacore::Float > & feedPa1() const
Calculates the parallactic angle for feed 0 of the row's Antenna1.
virtual casacore::Double hourang(casacore::Double) const
Returns the hour angle of the array at the specified time.
virtual void setVisModel(casacore::Matrix< CStokesVector > &)
bool nextBuffer()
Move to next buffer.
virtual casacore::Int msId() const
String: the storage and methods of handling collections of characters.
bool summarySignal()
Signal true when a progress summary has to be printed.
virtual const casacore::Vector< casacore::Double > & getFrequencies(casacore::Int, casacore::Int=FrameNotSpecified) const
virtual void setScan(const casacore::Vector< casacore::Int > &)
bool open()
Open CalTable.
const casacore::Vector< casacore::Double > & time() const
virtual void setRekeyable(casacore::Bool)
virtual const casacore::Vector< casacore::MDirection > & direction1() const
virtual const casacore::Cube< casacore::Bool > & flagCube() const
virtual const casacore::Matrix< casacore::Float > & weightMat() const
This class encapsulates an enum with values corresponding to the various data components accessible v...
virtual casacore::Int getChannelNumber(casacore::Int, casacore::Int) const
virtual void copyCoordinateInfo(const VisBuffer2 *, casacore::Bool, casacore::Bool=false, casacore::Bool=true)
Copies the coordinate components (or just the ones in the cache if fetchIfNeeded is false) from the s...
virtual casacore::Vector< casacore::Float > & parang(casacore::Double) const
Calculates the parallactic angle of each antenna in the array at the specified time.
casacore::Bool CTspectralWindowOK_p
casacore::Vector< casacore::Int > observationId_p
Convenient members for compatibility with casacore::MS-like interface.
virtual vi::Subchunk getSubchunk() const
virtual void configureNewSubchunk(casacore::Int, const casacore::String &, casacore::Bool, casacore::Bool, casacore::Bool, casacore::Bool, const vi::Subchunk &, casacore::Int, casacore::Int, casacore::Int, const casacore::Vector< casacore::Int > &, const casacore::Vector< casacore::Stokes::StokesTypes > &, const casacore::Vector< casacore::Stokes::StokesTypes > &, casacore::CountedPtr< vi::WeightScaling >)
virtual void setProcessorId(const casacore::Vector< casacore::Int > &)
CTIter * calIter_p
Calibration casacore::Table iterator and buffer.
virtual casacore::Bool isNewSpectralWindow() const
virtual void dirtyComponentsAdd(VisBufferComponent2)
casacore::String getTableName()
Provide table name (for flag version)
virtual void setArrayId(const casacore::Vector< casacore::Int > &)
virtual casacore::Bool isFillable() const
virtual void dirtyComponentsSet(VisBufferComponent2)
casacore::Bool CTfrequencyOK_p
virtual const casacore::Vector< casacore::Int > & stateId() const
virtual const casacore::Matrix<casacore::Float> & sigmaMat () const = 0; // [nC,nR] ...
virtual void setUvw(const casacore::Matrix< casacore::Double > &)
const casacore::Cube< casacore::Complex > & visCubeCorrected() const
virtual const casacore::Matrix<CStokesVector> & vis () const = 0; // [nF,nR] virtual void setVis (cas...
virtual void setWeight(const casacore::Matrix< casacore::Float > &)
virtual VisBufferComponents2 dirtyComponentsGet() const
casacore::Vector< casacore::Stokes::StokesTypes > getCorrelationTypesSelected() const
casacore::Cube< casacore::Complex > cparam_p
casacore::Vector< casacore::Int > spectralWindows_p
casacore::Vector< casacore::Int > & scan()
virtual casacore::Int nAntennas() const
virtual casacore::Bool modelDataIsVirtual() const
casacore::Int spectralWindow()