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

RFAUVBinner: flagging via UV binning. More...

#include <RFAUVBinner.h>

Inheritance diagram for casa::RFAUVBinner:
casa::RFAFlagCubeBase casa::RFDataMapper casa::RFABase casa::FlaggerEnums

Public Member Functions

 RFAUVBinner (RFChunkStats &ch, const casacore::RecordInterface &parm)
 
virtual ~RFAUVBinner ()
 
virtual casacore::uInt estimateMemoryUse ()
 This method is called before iterating over a chunk, to inquire the expected memory use. More...
 
virtual casacore::Bool newChunk (casacore::Int &maxmem)
 Called before iterating over a chunk. More...
 
virtual void endChunk ()
 Called once finished with a chunk. More...
 
virtual void startData (bool verbose)
 Called before starting a data pass on a chunk. More...
 
virtual void startDry (bool verbose)
 Called before starting a dry pass on a chunk. More...
 
virtual IterMode iterTime (casacore::uInt it)
 Iteration methods for a data pass. More...
 
virtual IterMode iterRow (casacore::uInt ir)
 iterRow() is called once per each row in the VisBuffer. More...
 
virtual IterMode iterDry (casacore::uInt it)
 Iteration method for a dry pass. More...
 
virtual IterMode endData ()
 Called after a pass is completed successfully (i.e., not stopped by start or iter methods). More...
 
virtual IterMode endDry ()
 Called after a dry pass is complete. More...
 
virtual casacore::String getDesc ()
 called to obtain a short description of this RFA More...
 
- Public Member Functions inherited from casa::RFAFlagCubeBase
 RFAFlagCubeBase (RFChunkStats &ch, const casacore::RecordInterface &parm)
 
virtual ~RFAFlagCubeBase ()
 
virtual void startFlag (bool verbose)
 Called before starting the fetch-flags pass. More...
 
virtual void iterFlag (casacore::uInt it)
 Iteration method for a flag pass. More...
 
virtual casacore::String getStats ()
 called (before endChunk()) to obtain a statistics report More...
 
virtual casacore::String getID ()
 
- Public Member Functions inherited from casa::RFABase
 RFABase (RFChunkStats &ch, const casacore::RecordInterface &parm)
 An agent is always constructed from a chunk stats accessor, and a record of parameters. More...
 
virtual ~RFABase ()
 Destructor. More...
 
virtual void init ()
 This method is called after constructing the agent. More...
 
virtual void endFlag ()
 Called after a flag pass is complete. More...
 
virtual void endRows (casacore::uInt)
 Called at end of time chunk. More...
 
virtual void printFlaggingReport ()
 
const casacore::Stringname ()
 returns the name of this RFA (set in myname) More...
 
casacore::Bool isActive ()
 returns the active status More...
 
casacore::LogIOlogSink ()
 accessor to a casacore::LogIO for this agent More...
 
virtual casacore::Record getResult ()
 
virtual void finalize ()
 
virtual void initialize ()
 Initialize chunk. More...
 
virtual void initializeIter (casacore::uInt)
 
virtual void finalizeIter (casacore::uInt)
 
virtual void setNAgent (casacore::uInt n)
 
virtual void setOnlySelector (bool only_sel)
 
- Public Member Functions inherited from casa::RFDataMapper
 RFDataMapper (const casacore::String &col, DDMapper *map)
 construct from a column and a DDMapper More...
 
 RFDataMapper (const casacore::Vector< casacore::String > &expr, const casacore::String &defcol="")
 construct from a column and an expression More...
 
 ~RFDataMapper ()
 destructor More...
 
MapperType type ()
 returns type of mapper More...
 
casacore::Double getValueCycle ()
 If the value being mapped into is cyclic (i.e. More...
 
casacore::Double getValueBase ()
 Returns base of a cyclic value (e.g. More...
 
casacore::Float mapValue (casacore::uInt ich, casacore::uInt irow)
 gets a value from the DDMapper More...
 
casacore::Float mapValue (casacore::uInt irow)
 gets a value from the row mapper More...
 
RFlagWord corrMask (const VisibilityIterator &vi)
 uses mapper to compute a correlations mask More...
 
void setVisBuffer (VisBuffer &vb)
 point the datamapper at a visbuffer - called for every new buffer More...
 
casacore::String description () const
 returns description More...
 
casacore::String descExpression () const
 returns description of expression More...
 

Static Public Member Functions

static const
casacore::RecordInterface
getDefaults ()
 
- Static Public Member Functions inherited from casa::RFAFlagCubeBase
static const
casacore::RecordInterface
getDefaults ()
 
- Static Public Member Functions inherited from casa::RFABase
static void setIndexingBase (casacore::uInt base)
 static method for setting the indexing base for agent arguments More...
 

Protected Member Functions

casacore::IPosition computeBin (casacore::Float uv, casacore::Float y, casacore::uInt ich)
 
- Protected Member Functions inherited from casa::RFABase
casacore::uInt num (StatEnums which)
 
RFlagWord corrMask ()
 
- Protected Member Functions inherited from casa::RFDataMapper
casacore::Float dummyRowMapper (casacore::uInt)
 various row mappers More...
 
casacore::Float U_RowMapper (casacore::uInt)
 
casacore::Float V_RowMapper (casacore::uInt)
 
casacore::Float W_RowMapper (casacore::uInt)
 
casacore::Float AbsU_RowMapper (casacore::uInt)
 
casacore::Float AbsV_RowMapper (casacore::uInt)
 
casacore::Float AbsW_RowMapper (casacore::uInt)
 
casacore::Float UVD_RowMapper (casacore::uInt)
 
casacore::Float UVA_RowMapper (casacore::uInt)
 
casacore::Float HA_RowMapper (casacore::uInt)
 

Protected Attributes

casacore::Double threshold
 
casacore::uInt min_population
 
casacore::uInt nbin_y
 
casacore::uInt nbin_uv
 
casacore::Bool binned
 
casacore::Vector
< casacore::RigidVector
< casacore::Double, 3 > > * 
puvw
 current UVW column More...
 
RFFloatLattice yvalue
 lattice of yvalues [NCH,NIFR,NTIME] More...
 
casacore::Matrix< casacore::Floatuvdist
 matrix of UV distances [NIFR,NTIME] More...
 
casacore::Vector< casacore::Floatymin
 ranges and bin sizes More...
 
casacore::Vector< casacore::Floatymax
 
casacore::Vector< casacore::Floatybinsize
 
casacore::Vector< casacore::Floatuvmin
 for UV, we have individual ranges/bins per each channel More...
 
casacore::Vector< casacore::Floatuvmax
 
casacore::Vector< casacore::Floatuvbinsize
 
casacore::Cube< casacore::Intbincounts
 bin counts More...
 
casacore::Vector< casacore::Inttotcounts
 
- Protected Attributes inherited from casa::RFAFlagCubeBase
RFlagWord corrmask
 mask of active correlations. More...
 
RFFlagCube flag
 flag cube lattice More...
 
- Protected Attributes inherited from casa::RFABase
casacore::uInt nAgent
 
RFChunkStatschunk
 
casacore::Record params
 
casacore::String myname
 
bool only_selector
 
RFlagWord corrmask
 Bit mask of correlations which are used & flagged by this RFA. More...
 
casacore::Bool active
 flag: agent is active for this chunk (set in newChunk) More...
 
casacore::LogIO os
 
- Protected Attributes inherited from casa::RFDataMapper
casacore::String expr_desc
 
casacore::String desc
 
DDMapperddm
 
RowMapperFunc rowmapper
 
casacore::Cube
< casacore::Complex > * 
pviscube
 
casacore::Vector
< casacore::RigidVector
< casacore::Double, 3 > > * 
puvw
 
CubeMapperFunc cubemap
 
MapperType mytype
 
casacore::Double full_cycle
 
casacore::Double cycle_base
 
casacore::Double sin_dec
 required by the HA mapper - sin(declination) of phase center; More...
 

Additional Inherited Members

- Public Types inherited from casa::RFABase
enum  IterMode {
  STOP,
  DRY,
  DATA,
  CONT
}
 iteration modes More...
 
- Public Types inherited from casa::FlaggerEnums
enum  StatEnums {
  POLZN,
  POL,
  CORR,
  CHAN,
  IFR,
  TIME,
  ROW,
  ANT,
  FEED,
  FEEDCORR,
  NONE,
  Num_StatEnums
}
 
enum  PreFlagPolicy {
  FL_HONOR,
  FL_IGNORE,
  FL_RESET
}
 
- Public Types inherited from casa::RFDataMapper
enum  MapperType {
  MAPROW,
  MAPCORR
}
 type of data mapper: row or individual correlations More...
 
typedef casacore::Cube
< casacore::Complex > *(* 
CubeMapperFunc )(VisBuffer &)
 a cube mapper function maps a visbuffer to a data cube. More...
 
- Static Protected Member Functions inherited from casa::RFABase
static casacore::uInt indexingBase ()
 global flag indicates that Glish (1-based) indexing is in use for agent arguments More...
 
- Static Protected Member Functions inherited from casa::RFDataMapper
static CubeMapperFunc getCubeMapper (const casacore::String &col, casacore::Bool throw_excp=false)
 static helper function to interpret constructor parameters into a cube mapper More...
 

Detailed Description

RFAUVBinner: flagging via UV binning.

Intended use:

Internal

Prerequisite

Synopsis

To Do

Definition at line 66 of file RFAUVBinner.h.

Constructor & Destructor Documentation

casa::RFAUVBinner::RFAUVBinner ( RFChunkStats ch,
const casacore::RecordInterface parm 
)
virtual casa::RFAUVBinner::~RFAUVBinner ( )
inlinevirtual

Definition at line 70 of file RFAUVBinner.h.

Member Function Documentation

casacore::IPosition casa::RFAUVBinner::computeBin ( casacore::Float  uv,
casacore::Float  y,
casacore::uInt  ich 
)
protected
virtual void casa::RFAUVBinner::endChunk ( )
virtual

Called once finished with a chunk.

Reimplemented from casa::RFAFlagCubeBase.

virtual IterMode casa::RFAUVBinner::endData ( )
virtual

Called after a pass is completed successfully (i.e., not stopped by start or iter methods).

Return value: STOP to stop, DATA for another data pass, DRY for another dry pass.

Reimplemented from casa::RFAFlagCubeBase.

virtual IterMode casa::RFAUVBinner::endDry ( )
virtual

Called after a dry pass is complete.

Reimplemented from casa::RFAFlagCubeBase.

virtual casacore::uInt casa::RFAUVBinner::estimateMemoryUse ( )
virtual

This method is called before iterating over a chunk, to inquire the expected memory use.

Should return the max desired memory footprint, in MB. Available physical memory is divided between agents in proportion to their requests.

Reimplemented from casa::RFAFlagCubeBase.

static const casacore::RecordInterface& casa::RFAUVBinner::getDefaults ( )
static
virtual casacore::String casa::RFAUVBinner::getDesc ( )
virtual

called to obtain a short description of this RFA

Reimplemented from casa::RFAFlagCubeBase.

virtual IterMode casa::RFAUVBinner::iterDry ( casacore::uInt  )
virtual

Iteration method for a dry pass.

Called once per each time slot. Return value: STOP to finish iterating, CONT/DRY to continue, or DATA to cancel the dry pass and request another data pass.

Reimplemented from casa::RFAFlagCubeBase.

virtual IterMode casa::RFAUVBinner::iterRow ( casacore::uInt  )
virtual

iterRow() is called once per each row in the VisBuffer.

Iterating over rows is perhaps preferrable in terms of performance, at least for data iterations.

Reimplemented from casa::RFABase.

virtual IterMode casa::RFAUVBinner::iterTime ( casacore::uInt  )
virtual

Iteration methods for a data pass.

Either or both may be implemented. iterTime() is called once for each new VisBuffer (= new time slot) Return value: STOP to finish iterating, CONT/DATA to continue, or DRY to cancel the data pass and request a dry pass.

Reimplemented from casa::RFAFlagCubeBase.

virtual casacore::Bool casa::RFAUVBinner::newChunk ( casacore::Int )
virtual

Called before iterating over a chunk.

Returns true if agent will process this chunk, or false if this the agent is unable to process it. (this can happen if, e.g., the requisite correlations are not present). The casacore::Int & maxmem argument is the number of MB memory which is still available in the memory pool. The agent class should plan its memory use accordingly, and subtract its expected memory use from maxmem. In effect, the agent "reserves" some amount of memory. This is used by RedFlagger to contain the total memory footprint. Note that only a rough reckoning is sufficient, so only bother estimating the biggest data structures. See implementations in RFADiffBase and RFATimeMedian for good examples. nAgent is the total number of agents.

Reimplemented from casa::RFAFlagCubeBase.

virtual void casa::RFAUVBinner::startData ( bool  )
virtual

Called before starting a data pass on a chunk.

Reimplemented from casa::RFAFlagCubeBase.

virtual void casa::RFAUVBinner::startDry ( bool  )
virtual

Called before starting a dry pass on a chunk.

Reimplemented from casa::RFAFlagCubeBase.

Member Data Documentation

casacore::Cube<casacore::Int> casa::RFAUVBinner::bincounts
protected

bin counts

Definition at line 107 of file RFAUVBinner.h.

casacore::Bool casa::RFAUVBinner::binned
protected

Definition at line 92 of file RFAUVBinner.h.

casacore::uInt casa::RFAUVBinner::min_population
protected

Definition at line 90 of file RFAUVBinner.h.

casacore::uInt casa::RFAUVBinner::nbin_uv
protected

Definition at line 91 of file RFAUVBinner.h.

casacore::uInt casa::RFAUVBinner::nbin_y
protected

Definition at line 91 of file RFAUVBinner.h.

casacore::Vector< casacore::RigidVector<casacore::Double,3> >* casa::RFAUVBinner::puvw
protected

current UVW column

Definition at line 95 of file RFAUVBinner.h.

casacore::Double casa::RFAUVBinner::threshold
protected

Definition at line 89 of file RFAUVBinner.h.

casacore::Vector<casacore::Int> casa::RFAUVBinner::totcounts
protected

Definition at line 108 of file RFAUVBinner.h.

casacore::Vector<casacore::Float> casa::RFAUVBinner::uvbinsize
protected

Definition at line 103 of file RFAUVBinner.h.

casacore::Matrix<casacore::Float> casa::RFAUVBinner::uvdist
protected

matrix of UV distances [NIFR,NTIME]

Definition at line 100 of file RFAUVBinner.h.

casacore::Vector<casacore::Float> casa::RFAUVBinner::uvmax
protected

Definition at line 103 of file RFAUVBinner.h.

casacore::Vector<casacore::Float> casa::RFAUVBinner::uvmin
protected

for UV, we have individual ranges/bins per each channel

Definition at line 103 of file RFAUVBinner.h.

casacore::Vector<casacore::Float> casa::RFAUVBinner::ybinsize
protected

Definition at line 103 of file RFAUVBinner.h.

casacore::Vector<casacore::Float> casa::RFAUVBinner::ymax
protected

Definition at line 103 of file RFAUVBinner.h.

casacore::Vector<casacore::Float> casa::RFAUVBinner::ymin
protected

ranges and bin sizes

Definition at line 103 of file RFAUVBinner.h.

RFFloatLattice casa::RFAUVBinner::yvalue
protected

lattice of yvalues [NCH,NIFR,NTIME]

Definition at line 98 of file RFAUVBinner.h.


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