casa
5.7.0-16
|
#include <DataAccumulator.h>
Public Member Functions | |
DataChunk (casacore::String const &poltype) | |
virtual | ~DataChunk () |
casacore::String | getPolType () const |
void | resetPolType (casacore::String const &poltype) |
casacore::uInt | getNumPol () const |
void | initialize (size_t num_chan) |
void | clear () |
bool | readyToWrite () |
bool | accumulate (DataRecord const &record) |
bool | get (MSDataRecord &record) |
Public Attributes | |
friend | DataAccumulator |
Private Member Functions | |
bool | isFullPol () const |
Functions to return if accumulated corr types are conformant set, e.g., liner polarization should have XX and YY for dual pol. More... | |
bool | isDualPol () const |
bool | isSinglePol0 () const |
bool | isSinglePol1 () const |
bool | isValidRecord (DataRecord const &record) |
void | setPolType (casacore::String const &poltype) |
void | setTsys2 (MSDataRecord &record, std::vector< size_t > order={}) |
Tsys and Tcal assignment for 2 & 4 pols. More... | |
void | setTcal2 (MSDataRecord &record, std::vector< size_t > order={}) |
void | setTsys1 (MSDataRecord &record, ssize_t start_src) |
void | setTcal1 (MSDataRecord &record, ssize_t start_src) |
bool | getLinear (MSDataRecord &record) |
bool | getCircular (MSDataRecord &record) |
bool | getStokes (MSDataRecord &record) |
bool | getLinpol (MSDataRecord &record) |
casacore::uInt | getNumPolLinear () const |
casacore::uInt | getNumPolCircular () const |
casacore::uInt | getNumPolStokes () const |
casacore::uInt | getNumPolLinpol () const |
Private Attributes | |
size_t const | num_pol_max_ |
size_t | num_chan_ |
casacore::Matrix< casacore::Float > | data_ |
casacore::Matrix< casacore::Bool > | flag_ |
casacore::Vector< casacore::Bool > | flag_row_ |
casacore::Matrix< casacore::Float > | tsys_ |
casacore::Matrix< casacore::Float > | tcal_ |
casacore::Vector< casacore::Float > | weight_ |
casacore::Vector< casacore::Float > | sigma_ |
casacore::String | poltype_ |
casacore::Vector< casacore::Int > | valid_pcorr_ |
std::vector < casacore::Stokes::StokesTypes > | pcorr_type_ |
bool(DataChunk::* | get_chunk_ )(MSDataRecord &record) |
casacore::uInt(DataChunk::* | get_num_pol_ )() const |
Definition at line 247 of file DataAccumulator.h.
|
inline |
Definition at line 251 of file DataAccumulator.h.
References POST_END, and POST_START.
|
inlinevirtual |
Definition at line 263 of file DataAccumulator.h.
|
inline |
Polarization
check for consistency between pol_type and stokes
check if pcorr is the new corr type to be added
new polarization type
Matrices in DataRecord is stacked in the order of accumulation
std::cout << "tsys is not empty: " << record.tsys[0] << std::endl;
std::cout << "tcal is not empty: " << record.tcal << std::endl;
Filling Matrices[chan, pol] in DataRecord. The Matrices are column (channel) major
data_.column(colid) = data;
flag_.column(colid) = flag;
tsys_.column(polid) = tsys;
tcal_.column(polid) = tcal;
Definition at line 300 of file DataAccumulator.h.
References casacore::Vector< T >::assign(), casa::data, casa::sdfiller::DataRecord::data, casacore::ArrayBase::empty(), casa::sdfiller::DataRecord::flag, casa::sdfiller::DataRecord::flag_row, casa::isValidRecord(), casacore::Stokes::name(), casacore::ArrayBase::nelements(), casa::sdfiller::DataRecord::pol, POST_START, casacore::Vector< T >::shape(), casacore::ArrayBase::size(), casa::sdfiller::DataRecord::tcal, and casa::sdfiller::DataRecord::tsys.
|
inline |
Definition at line 291 of file DataAccumulator.h.
|
inline |
Definition at line 385 of file DataAccumulator.h.
|
inlineprivate |
Definition at line 666 of file DataAccumulator.h.
|
inlineprivate |
POL 0, 1, 2, and 3 std::cout << "set data/flag" << std::endl;
std::cout << "weight = " << record.weight << std::endl;
std::cout << "set tsys" << std::endl;
std::cout << "set tcal " << tcal_ << std::endl;
POL 0 and 1 std::cout << "set data/flag" << std::endl;
std::cout << "weight = " << record.weight << std::endl;
std::cout << "set tsys" << std::endl;
std::cout << "set tcal " << tcal_ << std::endl;
only POL 0 std::cout << "set data/flag (pol 0)" << std::endl;
std::cout << "set tcal " << tcal_ << std::endl;
only POL 1 std::cout << "set data/flag (pol 1)" << std::endl;
std::cout << "set tcal " << tcal_ << std::endl;
std::cout << "DataChunk is not ready for get" << std::endl;
Definition at line 571 of file DataAccumulator.h.
References casacore::anyEQ(), casa::sdfiller::MSDataRecord::complex_data, casa::sdfiller::MSDataRecord::corr_type, casa::sdfiller::MSDataRecord::flag, casa::sdfiller::MSDataRecord::flag_row, casa::sdfiller::MSDataRecord::float_data, casa::sdfiller::MSDataRecord::num_pol, POST_END, POST_START, casa::sdfiller::MSDataRecord::setComplex(), casa::sdfiller::MSDataRecord::setDataSize(), and casa::sdfiller::MSDataRecord::setFloat().
|
inlineprivate |
POL 0 and 1
Definition at line 709 of file DataAccumulator.h.
References casa::sdfiller::MSDataRecord::corr_type, casa::sdfiller::MSDataRecord::flag, casa::sdfiller::MSDataRecord::flag_row, casa::sdfiller::MSDataRecord::float_data, casa::sdfiller::MSDataRecord::num_pol, POST_END, POST_START, casa::sdfiller::MSDataRecord::setDataSize(), and casa::sdfiller::MSDataRecord::setFloat().
|
inline |
Definition at line 275 of file DataAccumulator.h.
|
inlineprivate |
Definition at line 760 of file DataAccumulator.h.
|
inlineprivate |
Definition at line 748 of file DataAccumulator.h.
|
inlineprivate |
Definition at line 774 of file DataAccumulator.h.
|
inlineprivate |
Definition at line 764 of file DataAccumulator.h.
|
inline |
Definition at line 266 of file DataAccumulator.h.
|
inlineprivate |
Definition at line 670 of file DataAccumulator.h.
References casa::sdfiller::MSDataRecord::corr_type, casa::sdfiller::MSDataRecord::flag, casa::sdfiller::MSDataRecord::flag_row, casa::sdfiller::MSDataRecord::float_data, casa::sdfiller::MSDataRecord::num_pol, POST_END, POST_START, casa::sdfiller::MSDataRecord::setDataSize(), and casa::sdfiller::MSDataRecord::setFloat().
|
inline |
Definition at line 279 of file DataAccumulator.h.
References casacore::shape().
|
inlineprivate |
Definition at line 398 of file DataAccumulator.h.
|
inlineprivate |
Functions to return if accumulated corr types are conformant set, e.g., liner polarization should have XX and YY for dual pol.
assumption: pcorr_type_ has StokesTypes consistent with poltype_ and not redundant (assured by accumulate())
Definition at line 395 of file DataAccumulator.h.
|
inlineprivate |
Definition at line 406 of file DataAccumulator.h.
|
inlineprivate |
Definition at line 410 of file DataAccumulator.h.
|
inlineprivate |
Definition at line 414 of file DataAccumulator.h.
References casa::sdfiller::DataRecord::data, casacore::ArrayBase::empty(), and casa::sdfiller::DataRecord::flag.
|
inline |
Definition at line 296 of file DataAccumulator.h.
|
inline |
Definition at line 270 of file DataAccumulator.h.
|
inlineprivate |
Definition at line 417 of file DataAccumulator.h.
References casacore::Stokes::I, casacore::Stokes::LL, casacore::Stokes::LR, casacore::Stokes::Pangle, casacore::Stokes::Plinear, POST_END, POST_START, casacore::Stokes::Q, casacore::String::resize(), casacore::Stokes::RL, casacore::Stokes::RR, casacore::Stokes::U, casacore::Stokes::V, casacore::Stokes::XX, casacore::Stokes::XY, casacore::Stokes::YX, and casacore::Stokes::YY.
|
inlineprivate |
should be spectral Tsys
record.tsys = -1;
record.tsys.row(0) = tsys_.column(0);
scalar Tsys
Definition at line 553 of file DataAccumulator.h.
References casa::sdfiller::MSDataRecord::setTcalSize(), and casa::sdfiller::MSDataRecord::tcal.
|
inlineprivate |
clear Tcal
Definition at line 505 of file DataAccumulator.h.
|
inlineprivate |
should be spectral Tsys
record.tsys = -1;
record.tsys.row(0) = tsys_.column(0);
scalar Tsys
Definition at line 535 of file DataAccumulator.h.
References casa::sdfiller::MSDataRecord::setTsysSize(), and casa::sdfiller::MSDataRecord::tsys.
|
inlineprivate |
Tsys and Tcal assignment for 2 & 4 pols.
Auto-correlation components of pol should be used.
clear Tsys
Definition at line 475 of file DataAccumulator.h.
|
private |
Definition at line 460 of file DataAccumulator.h.
friend casa::sdfiller::DataChunk::DataAccumulator |
Definition at line 249 of file DataAccumulator.h.
|
private |
Definition at line 461 of file DataAccumulator.h.
|
private |
Definition at line 462 of file DataAccumulator.h.
|
private |
Definition at line 471 of file DataAccumulator.h.
|
private |
Definition at line 472 of file DataAccumulator.h.
|
private |
Definition at line 459 of file DataAccumulator.h.
|
private |
Definition at line 458 of file DataAccumulator.h.
|
private |
Definition at line 470 of file DataAccumulator.h.
|
private |
Definition at line 468 of file DataAccumulator.h.
|
private |
Definition at line 466 of file DataAccumulator.h.
|
private |
Definition at line 464 of file DataAccumulator.h.
|
private |
Definition at line 463 of file DataAccumulator.h.
|
private |
Definition at line 469 of file DataAccumulator.h.
|
private |
Definition at line 465 of file DataAccumulator.h.