28 #ifndef MS_MSFITSOUTPUT_H
29 #define MS_MSFITSOUTPUT_H
43 template<
class T>
class ScalarColumn;
45 template<
class T>
class Block;
122 Int nchan=1,
Int stepchan=1,
126 const Bool padWithFlags=
false,
Int avgchan=1,
166 Int chanstart = 0,
Int nchan = -1,
Int chanstep = 1,
266 const Bool asMultiSource,
TableExprNode time(const TableExprNode &node)
void setOverwrite(Bool overwrite)
Main interface class to a read/write table.
void setSensitivity(Double sensitivity)
static Table handleSysCal(const MeasurementSet &ms, const Vector< Int > &spwids, Bool isSubset)
Handle the SYSCAL table.
void setPadWitFlags(Bool padWithFlags)
static Bool _writeAN(std::shared_ptr< FitsOutput > output, const MeasurementSet &ms, Double refFreq, Bool writeStation)
Write the AN table.
static Int _makeIdMap(Block< Int > &map, Vector< Int > &selids, const Vector< Int > &allids)
Determine which ids are selected in the main table (used for fields and spectral-window).
void setCombineSpw(Bool combineSpw)
Write a MeasurementSet to a random group uvfits file.
static void getStartHA(Double &startTime, Double &startHA, const MeasurementSet &ms, uInt rownr)
Get the time and hourangle from the MS at the given row.
void setFieldNumber(uInt fieldNumber)
void setChannelInfo(Int startChan, Int nchan, Int stepChan, Int avgChan)
static Bool _writeFQ(std::shared_ptr< FitsOutput > output, const MeasurementSet &ms, const Block< Int > &spwidMap, Int nrspw, Double refFreq, Int refPixelFreq, Double chanbw, Bool combineSpw, Int chanstart=0, Int nchan=-1, Int chanstep=1, Int avgchan=1)
Write the FQ table.
void write() const
write the uvfits file.
static Bool _writeSY(std::shared_ptr< FitsOutput > output, const MeasurementSet &ms, Table &syspower, Int nspw, const Block< Int > &spwIDMap, Bool combineSpw)
Write the SY table.
static void timeToDay(Int &day, Double &dayFraction, Double time)
Convert time to day and fraction.
static Bool writeFitsFile(const String &fitsfile, const MeasurementSet &ms, const String &column, Int startchan=0, Int nchan=1, Int stepchan=1, Bool writeSysCal=False, Bool asMultiSource=False, Bool combineSpw=False, Bool writeStation=False, Double sensitivity=1.0, const Bool padWithFlags=false, Int avgchan=1, uInt fieldNumber=0, Bool overwrite=False)
Convert a MeasurementSet to random group UVFITS.
static uInt get_tbf_end(const uInt rownr, const uInt nrow, const uInt nif, const ScalarColumn< Double > &timec, const ScalarColumn< Double > &ininterval, const ScalarColumn< Int > &ant1, const ScalarColumn< Int > &ant2, const Bool asMultiSource, const ScalarColumn< Int > &fieldid)
Find the end of a group of rows with the same time(_centroid) (within 0.25 * ininterval(rownr)), baseline #, and, if asMultiSource, field ID.
void setWriteStation(Bool writeStation)
static void _checkReceptorAngles(const Vector< Quantity > &ra0, Vector< Quantity > &ra1, Int antnum)
MSFitsOutput(const String &fitsfile, const MeasurementSet &ms, const String &column)
void setAsMultiSource(Bool asMultiSource)
bool Bool
Define the standard types used by Casacore.
static Bool _writeWX(std::shared_ptr< FitsOutput > output, const MeasurementSet &ms)
Write the WX table.
static Bool _writeGC(std::shared_ptr< FitsOutput > output, const MeasurementSet &ms, const Table &syscal, const Block< Int > &spwidMap, uInt nrif, Bool combineSpw, Double sensitivity, Int refPixelFreq, Double refFreq, Double chanbw)
Write the GC table.
void setWriteSysCal(Bool writeSysCal)
static Bool _writeSU(std::shared_ptr< FitsOutput > output, const MeasurementSet &ms, const Block< Int > &fieldidMap, Int nrfield, const Block< Int > &spwidMap, Int nrspw)
Write the SU table.
A Table intended to hold astronomical data (a set of Measurements).
TableExprNode day(const TableExprNode &node)
static Bool _writeTY(std::shared_ptr< FitsOutput > output, const MeasurementSet &ms, const Table &syscal, const Block< Int > &spwidMap, uInt nrif, Bool combineSpw)
Write the TY table.
String: the storage and methods of handling collections of characters.
std::shared_ptr< FitsOutput > _writeMain(Int &refPixelFreq, Double &refFreq, Double &chanbw, const String &outFITSFile, const Block< Int > &spwidMap, Int nrspw, const Block< Int > &fieldidMap, Bool asMultiSource) const
Write the main table.
static void _handleAntNumbers(const MeasurementSet &ms, Vector< Int > &antnumbers)
Discern the antenna numbers that go into UVFITS.