casa
5.7.0-16
|
Reweighter reweights a selected part of an casacore::MS based on the properties of a (possibly different) selection of it. More...
#include <Reweighter.h>
Public Member Functions | |
Reweighter (const casacore::String &theMS, const casacore::Bool dorms=false, const casacore::uInt minsamp=1) | |
virtual | ~Reweighter () |
casacore::Bool | selectSpw (std::set< casacore::Int > &spwset, casacore::Vector< casacore::Int > &chanStartv, casacore::Vector< casacore::Int > &chanEndv, casacore::Vector< casacore::Int > &chanStepv, const casacore::String &spwstr) |
Select spw and channels for each spw in spwstr. More... | |
casacore::Bool | selectCorrelations (const casacore::String &corrstr) |
Setup polarization selection (for now, only from available correlations - no casacore::Stokes transformations.) More... | |
casacore::Bool | setmsselect (const casacore::String &fitspw="", const casacore::String &outspw="", const casacore::String &field="", const casacore::String &baseline="", const casacore::String &scan="", const casacore::String &subarray="", const casacore::String &correlation="", const casacore::String &intent="", const casacore::String &obs="") |
select stuff using msselection syntax...time is left out call it separately with timebin Returns a success value. More... | |
casacore::Bool | selectSource (const casacore::Vector< casacore::Int > &fieldid) |
Select source or field. More... | |
void | selectAntenna (const casacore::Vector< casacore::Int > &antennaids, const casacore::Vector< casacore::String > &antennaSel) |
void | selectArray (const casacore::String &subarray) |
Select array IDs to use. More... | |
void | selectTime (casacore::Double timeBin=-1.0, casacore::String timerng="") |
select time parameters More... | |
void | setFitSpw (const casacore::String &fitspw) |
void selectSource(casacore::Vector<casacore::String> sourceid); More... | |
void | setOutSpw (const casacore::String &outspw) |
Set the selection string for output spws (not channels!). More... | |
casacore::Bool | reweight (casacore::String &colname, const casacore::String &combine) |
Do the reweighting! More... | |
Static Public Member Functions | |
static casacore::Bool | getCorrTypes (casacore::Vector< casacore::Int > &polIDs, casacore::Vector< casacore::Vector< casacore::Int > > &corrTypes, const casacore::MSColumns &msc) |
void verifyColumns(const casacore::MeasurementSet& ms, const casacore::Vector<casacore::MS::PredefinedColumns>& colNames); More... | |
Protected Member Functions | |
casacore::Bool | makeSelection () |
method that returns the selected ms (?! - but it's Boolean - RR) More... | |
const casacore::ArrayColumn < casacore::Complex > & | right_column (const casacore::ROMSColumns *ms_p, const casacore::MS::PredefinedColumns datacol) |
*** Private member functions *** More... | |
casacore::Bool | setSortOrder (casacore::Block< casacore::Int > &sort, const casacore::String &uncombinable="", const casacore::Bool verbose=true) const |
Sets sort to a casacore::Block of columns that a VisibilityIterator should sort by, according to combine_p. More... | |
casacore::Bool | shouldWatch (casacore::Bool &conflict, const casacore::String &col, const casacore::String &uncombinable="", const casacore::Bool verbose=true) const |
Returns whether col is (not in combine_p) || in uncombinable. More... | |
void | makeUnionSpw () |
casacore::MS::PredefinedColumns | dataColStrToEnum (const casacore::String &col) |
Defaults to DATA. More... | |
Reweighter reweights a selected part of an casacore::MS based on the properties of a (possibly different) selection of it.
Reweighter...it reweights.
The order of operations (as in ms::split()) is: ctor setmsselect selectTime makeReweighter
These forward declarations are so the corresponding.h files don't have to be included in this.h file, but it's only worth it if a lot of other files include this file.
Definition at line 86 of file Reweighter.h.
casa::Reweighter::Reweighter | ( | const casacore::String & | theMS, |
const casacore::Bool | dorms = false , |
||
const casacore::uInt | minsamp = 1 |
||
) |
|
virtual |
|
protected |
Defaults to DATA.
|
static |
void verifyColumns(const casacore::MeasurementSet& ms, const casacore::Vector<casacore::MS::PredefinedColumns>& colNames);
Fills polIDs with a map from DDID to polID, and corrTypes with a map from polID to corrTypes. The return value is meaningless for now.
|
protected |
method that returns the selected ms (?! - but it's Boolean - RR)
|
protected |
casacore::Bool casa::Reweighter::reweight | ( | casacore::String & | colname, |
const casacore::String & | combine | ||
) |
Do the reweighting!
|
protected |
*** Private member functions ***
Picks a reference to DATA, MODEL_DATA, CORRECTED_DATA, or LAG_DATA out of ms_p. FLOAT_DATA is not included because it is not natively complex.
|
inline |
Definition at line 117 of file Reweighter.h.
References antennaId_p, antennaSel_p, antennaSelStr_p, and casa::SubMS::pickAntennas().
|
inline |
casacore::Bool casa::Reweighter::selectCorrelations | ( | const casacore::String & | corrstr | ) |
Setup polarization selection (for now, only from available correlations - no casacore::Stokes transformations.)
casacore::Bool casa::Reweighter::selectSource | ( | const casacore::Vector< casacore::Int > & | fieldid | ) |
Select source or field.
casacore::Bool casa::Reweighter::selectSpw | ( | std::set< casacore::Int > & | spwset, |
casacore::Vector< casacore::Int > & | chanStartv, | ||
casacore::Vector< casacore::Int > & | chanEndv, | ||
casacore::Vector< casacore::Int > & | chanStepv, | ||
const casacore::String & | spwstr | ||
) |
Select spw and channels for each spw in spwstr.
Returns true on success and false on failure.
void casa::Reweighter::selectTime | ( | casacore::Double | timeBin = -1.0 , |
casacore::String | timerng = "" |
||
) |
select time parameters
|
inline |
void selectSource(casacore::Vector<casacore::String> sourceid);
Set the selection string for line-free channels.
Definition at line 133 of file Reweighter.h.
References fitspw_p.
casacore::Bool casa::Reweighter::setmsselect | ( | const casacore::String & | fitspw = "" , |
const casacore::String & | outspw = "" , |
||
const casacore::String & | field = "" , |
||
const casacore::String & | baseline = "" , |
||
const casacore::String & | scan = "" , |
||
const casacore::String & | subarray = "" , |
||
const casacore::String & | correlation = "" , |
||
const casacore::String & | intent = "" , |
||
const casacore::String & | obs = "" |
||
) |
select stuff using msselection syntax...time is left out call it separately with timebin Returns a success value.
|
inline |
Set the selection string for output spws (not channels!).
Definition at line 135 of file Reweighter.h.
References outspw_p.
|
protected |
Sets sort to a casacore::Block of columns that a VisibilityIterator should sort by, according to combine_p.
Columns that should never be combined in the calling function, i.e. spw for time averaging, should be listed in uncombinable.
verbose: log a message on error.
Returns whether or not there were any conflicts between combine_p and uncombinable.
|
protected |
Returns whether col is (not in combine_p) || in uncombinable.
Columns that should never be combined in the calling function, i.e. spw for time averaging, should be listed in uncombinable.
verbose: log a message on error.
conflict is set to true if there is a conflict between combine_p and uncombinable.
|
protected |
Definition at line 214 of file Reweighter.h.
Referenced by selectAntenna().
|
protected |
Definition at line 199 of file Reweighter.h.
Referenced by selectAntenna().
|
protected |
|
protected |
Definition at line 204 of file Reweighter.h.
Referenced by selectArray().
|
protected |
Definition at line 224 of file Reweighter.h.
|
protected |
Definition at line 205 of file Reweighter.h.
|
protected |
Definition at line 225 of file Reweighter.h.
|
protected |
Definition at line 226 of file Reweighter.h.
|
protected |
Definition at line 204 of file Reweighter.h.
|
protected |
casacore::Map from polID to corrTypes, filled in getCorrTypes().
Definition at line 222 of file Reweighter.h.
|
protected |
Definition at line 196 of file Reweighter.h.
|
protected |
Definition at line 216 of file Reweighter.h.
|
protected |
Definition at line 230 of file Reweighter.h.
|
protected |
scan #, observation, and/or state ID? Must be lowercase at all times.
Definition at line 208 of file Reweighter.h.
Referenced by setFitSpw().
|
protected |
Definition at line 229 of file Reweighter.h.
|
protected |
Definition at line 230 of file Reweighter.h.
|
protected |
Definition at line 230 of file Reweighter.h.
|
protected |
Definition at line 201 of file Reweighter.h.
|
protected |
Definition at line 197 of file Reweighter.h.
|
protected |
*** Member variables ***
Initialized* by ctors. (Maintain order both here and in ctors.) not necessarily to anything useful.
Definition at line 195 of file Reweighter.h.
|
protected |
Definition at line 198 of file Reweighter.h.
|
protected |
Definition at line 195 of file Reweighter.h.
|
protected |
Definition at line 201 of file Reweighter.h.
|
protected |
Definition at line 209 of file Reweighter.h.
Referenced by setOutSpw().
|
protected |
Definition at line 229 of file Reweighter.h.
|
protected |
casacore::Map from DDID to polID, filled in getCorrTypes().
Definition at line 219 of file Reweighter.h.
|
protected |
Definition at line 201 of file Reweighter.h.
|
protected |
Definition at line 227 of file Reweighter.h.
|
protected |
Definition at line 200 of file Reweighter.h.
|
protected |
Definition at line 204 of file Reweighter.h.
|
protected |
Definition at line 210 of file Reweighter.h.