casa
$Rev:20696$
|
GBTIFLOHelper helps the GBT filler use the IF and LO FITS files. More...
#include <GBTIFLOHelper.h>
Public Member Functions | |
GBTIFLOHelper (GBTIFFiller *ifFiller, const GBTLO1File *lo1AFile, const GBTLO1File *lo1BFile, GBTLO1DAPFiller *lo1Handler, const Table &samplerTable, const Table &portTable, uInt nphases, uInt nchannels, const String &dcrBank="") | |
the ifFiller, lo1File and lo1Handler are used directly here. | |
~GBTIFLOHelper () | |
uInt | nfeeds () const |
number of independent feeds in use in the sampler table | |
uInt | whichFeed (uInt samplerFeed) |
map from sampler feed number (starts from 0 through (nfeeds()-1) to feedNumber (from iffiller). | |
Int | feedId (uInt whichFeed) const |
the feed IDs as returned by GBTIFFiller | |
const Block< uInt > & | receiverRows (uInt whichFeed) const |
row(s) in receiver table for each feed. | |
const Vector< Int > & | corrType (uInt whichFeed) const |
Polarization information for the indicated feed. | |
const Array< Int > & | corrProduct (uInt whichFeed) const |
const Vector< String > & | polarizationType (uInt whichFeed) const |
Feed information for the indicated feed. | |
const String & | receiverName (uInt whichFeed) const |
From the "receiver" column. | |
const Vector< String > & | feedName (uInt whichFeed) const |
From the "receptor" column. | |
Int | feed (uInt whichFeed) const |
From the "feed" column if present, returns -1 if not. | |
Int | srfeed1 (uInt whichFeed) const |
From the "srfeed1" column if present, returns -1 if not. | |
Int | srfeed2 (uInt whichFeed) const |
From the "srfeed2" column if present, returns -1 if not. | |
Int | highCal (uInt whichFeed) const |
From the "high_cal" column if present, returns -1 if not. | |
const String & | bank (uInt whichFeed) const |
From the "bank" column if present, returns "" if not. | |
const String & | srbank (uInt whichFeed) const |
Also from the "bank" column, but for the appropriate switched feed, this returns the bank of other feed involved if any switching is going on AND this is from the ACS. | |
const Vector< String > & | srFeedName (uInt whichFeed) const |
The feedName corresponding to srbank. | |
const Vector< Double > & | centerFreqs (uInt whichFeed, MFrequency::Types &refframe, MDoppler::Types &doptype, Double &souvel) |
Spectral information. | |
Double | deltaFreq (uInt whichFeed) const |
channel spacing is independent of phase and time | |
Double | refChan (uInt whichFeed) const |
reference channel is independent of phase and time Channels are numbered from 0 in this scheme. | |
const GBTLO1File & | lo1File (uInt whichFeed) const |
The LO1 file in use for each feed. | |
const IPosition & | shape (uInt whichFeed) const |
The shape of the FLOAT_DATA column for the indicated feed. | |
Private Member Functions | |
void | ifParms (GBTIFFiller &ifFiller, Int whichRow, Double &sffSideband, Double &sffMultiplier, Double &sffOffset) |
function to try and ensure that SFF_sideband, SFF_multiplier, SFF_offset, initial LO1, center_IF and center_Sky are all consistent. | |
GBTIFLOHelper () | |
undefined and unavailable | |
GBTIFLOHelper (const GBTIFLOHelper &) | |
GBTIFLOHelper & | operator= (const GBTIFLOHelper &) |
Private Attributes | |
uInt | itsNfeeds |
uInt | itsNphases |
uInt | itsNchannels |
Double | itsRefChan |
PtrBlock< const GBTLO1File * > | itsLO1Files |
GBTLO1DAPFiller * | itsLO1Filler |
PtrBlock< Block< uInt > * > | itsRcvrRows |
Block< Double > | itsT0CenterFreq |
Block< Double > | itsSFFMultiplier |
Block< Int > | itsFeedIds |
Block< Vector< Int > > | itsCorrType |
Block< Vector< Double > > | itsCenterFreq |
Block< Vector< String > > | itsPolType |
Block< String > | itsRxName |
Block< String > | itsBank |
Block< String > | itsSRBank |
Block< Vector< String > > | itsFeedName |
Block< Vector< String > > | itsSRFeedName |
Block< Int > | itsFeed |
Block< Int > | itsSrfeed1 |
Block< Int > | itsSrfeed2 |
Block< Int > | itsHighCal |
Block< Array< Int > > | itsCorrProduct |
Block< Double > | itsDeltaFreq |
Block< IPosition > | itsShapes |
Vector< Double > | itsLO1offset |
Vector< uInt > | itsSamplerFeeds |
GBTIFLOHelper helps the GBT filler use the IF and LO FITS files.
Internal
The GBT fillers need to take the IF and LO fits files plus their receiver tables and other information to arrive at feeds, spectral windows, and polarizations as well as groupings of data so that they can be filled into the MS appropriately.
Currently, this is only useful for SpectralProcessor data. It needs to be generalized as much as possible.
The code in the SP filler that this is derived from was getting sufficiently large and confusing that it was difficult to see the forest for the trees. Moving it here served to encapsulate it all in one place, hopefully making it easier to modify, understand, and reuse.
Definition at line 91 of file GBTIFLOHelper.h.
GBTIFLOHelper::GBTIFLOHelper | ( | GBTIFFiller * | ifFiller, |
const GBTLO1File * | lo1AFile, | ||
const GBTLO1File * | lo1BFile, | ||
GBTLO1DAPFiller * | lo1Handler, | ||
const Table & | samplerTable, | ||
const Table & | portTable, | ||
uInt | nphases, | ||
uInt | nchannels, | ||
const String & | dcrBank = "" |
||
) |
the ifFiller, lo1File and lo1Handler are used directly here.
If lo1File is a non-null pointer, it will be used in preference to lo1Handler. Neither should be deleted by the calling object until this object is no longer going to be used.
GBTIFLOHelper::GBTIFLOHelper | ( | ) | [private] |
undefined and unavailable
GBTIFLOHelper::GBTIFLOHelper | ( | const GBTIFLOHelper & | ) | [private] |
const String& GBTIFLOHelper::bank | ( | uInt | whichFeed | ) | const [inline] |
From the "bank" column if present, returns "" if not.
Definition at line 148 of file GBTIFLOHelper.h.
References itsBank, and whichFeed().
const Vector<Double>& GBTIFLOHelper::centerFreqs | ( | uInt | whichFeed, |
MFrequency::Types & | refframe, | ||
MDoppler::Types & | doptype, | ||
Double & | souvel | ||
) |
Spectral information.
The validity of whichFeed and whichPhase is not checked. Currently the SPECTRAL_WINDOW filler constructs the frequency axis from these linear values, although that could move here if appropriate.
all of the nphases values are returned together for the first timestamp in the LO1 table. Also set are the refframe (reference frame), doptype (velocity definition) and souvel (source velocity in m/s) arguments.
const Array<Int>& GBTIFLOHelper::corrProduct | ( | uInt | whichFeed | ) | const [inline] |
Definition at line 127 of file GBTIFLOHelper.h.
References itsCorrProduct, and whichFeed().
const Vector<Int>& GBTIFLOHelper::corrType | ( | uInt | whichFeed | ) | const [inline] |
Polarization information for the indicated feed.
The validity of whichFeed is not checked.
Definition at line 126 of file GBTIFLOHelper.h.
References itsCorrType, and whichFeed().
Double GBTIFLOHelper::deltaFreq | ( | uInt | whichFeed | ) | const [inline] |
channel spacing is independent of phase and time
Definition at line 168 of file GBTIFLOHelper.h.
References itsDeltaFreq, and whichFeed().
Int GBTIFLOHelper::feed | ( | uInt | whichFeed | ) | const [inline] |
From the "feed" column if present, returns -1 if not.
Definition at line 140 of file GBTIFLOHelper.h.
References itsFeed, and whichFeed().
Int GBTIFLOHelper::feedId | ( | uInt | whichFeed | ) | const [inline] |
the feed IDs as returned by GBTIFFiller
Definition at line 118 of file GBTIFLOHelper.h.
References itsFeedIds, and whichFeed().
const Vector<String>& GBTIFLOHelper::feedName | ( | uInt | whichFeed | ) | const [inline] |
From the "receptor" column.
Definition at line 138 of file GBTIFLOHelper.h.
References itsFeedName, and whichFeed().
Int GBTIFLOHelper::highCal | ( | uInt | whichFeed | ) | const [inline] |
From the "high_cal" column if present, returns -1 if not.
Definition at line 146 of file GBTIFLOHelper.h.
References itsHighCal, and whichFeed().
void GBTIFLOHelper::ifParms | ( | GBTIFFiller & | ifFiller, |
Int | whichRow, | ||
Double & | sffSideband, | ||
Double & | sffMultiplier, | ||
Double & | sffOffset | ||
) | [private] |
function to try and ensure that SFF_sideband, SFF_multiplier, SFF_offset, initial LO1, center_IF and center_Sky are all consistent.
const GBTLO1File& GBTIFLOHelper::lo1File | ( | uInt | whichFeed | ) | const [inline] |
The LO1 file in use for each feed.
Definition at line 176 of file GBTIFLOHelper.h.
References itsLO1Files, and whichFeed().
uInt GBTIFLOHelper::nfeeds | ( | ) | const [inline] |
number of independent feeds in use in the sampler table
Definition at line 110 of file GBTIFLOHelper.h.
References itsSamplerFeeds.
GBTIFLOHelper& GBTIFLOHelper::operator= | ( | const GBTIFLOHelper & | ) | [private] |
const Vector<String>& GBTIFLOHelper::polarizationType | ( | uInt | whichFeed | ) | const [inline] |
Feed information for the indicated feed.
The validity of whichFeed is not checked.
From the "polarize" column
Definition at line 134 of file GBTIFLOHelper.h.
References itsPolType, and whichFeed().
const String& GBTIFLOHelper::receiverName | ( | uInt | whichFeed | ) | const [inline] |
From the "receiver" column.
Definition at line 136 of file GBTIFLOHelper.h.
References itsRxName, and whichFeed().
const Block<uInt>& GBTIFLOHelper::receiverRows | ( | uInt | whichFeed | ) | const [inline] |
row(s) in receiver table for each feed.
The validity of whichFeed is not checked.
Definition at line 121 of file GBTIFLOHelper.h.
References itsRcvrRows, and whichFeed().
Double GBTIFLOHelper::refChan | ( | uInt | whichFeed | ) | const [inline] |
reference channel is independent of phase and time Channels are numbered from 0 in this scheme.
Definition at line 172 of file GBTIFLOHelper.h.
References itsRefChan.
const IPosition& GBTIFLOHelper::shape | ( | uInt | whichFeed | ) | const [inline] |
The shape of the FLOAT_DATA column for the indicated feed.
The value of whichFeed is not checked.
Definition at line 180 of file GBTIFLOHelper.h.
References itsShapes, and whichFeed().
const String& GBTIFLOHelper::srbank | ( | uInt | whichFeed | ) | const [inline] |
Also from the "bank" column, but for the appropriate switched feed, this returns the bank of other feed involved if any switching is going on AND this is from the ACS.
Definition at line 152 of file GBTIFLOHelper.h.
References itsSRBank, and whichFeed().
Int GBTIFLOHelper::srfeed1 | ( | uInt | whichFeed | ) | const [inline] |
From the "srfeed1" column if present, returns -1 if not.
Definition at line 142 of file GBTIFLOHelper.h.
References itsSrfeed1, and whichFeed().
Int GBTIFLOHelper::srfeed2 | ( | uInt | whichFeed | ) | const [inline] |
From the "srfeed2" column if present, returns -1 if not.
Definition at line 144 of file GBTIFLOHelper.h.
References itsSrfeed2, and whichFeed().
const Vector<String>& GBTIFLOHelper::srFeedName | ( | uInt | whichFeed | ) | const [inline] |
The feedName corresponding to srbank.
Definition at line 154 of file GBTIFLOHelper.h.
References itsSRFeedName, and whichFeed().
uInt GBTIFLOHelper::whichFeed | ( | uInt | samplerFeed | ) | [inline] |
map from sampler feed number (starts from 0 through (nfeeds()-1) to feedNumber (from iffiller).
feedNumber should be used as the whichFeed argument to the other methods here.
Definition at line 115 of file GBTIFLOHelper.h.
References itsSamplerFeeds.
Referenced by bank(), corrProduct(), corrType(), deltaFreq(), feed(), feedId(), feedName(), highCal(), lo1File(), polarizationType(), receiverName(), receiverRows(), shape(), srbank(), srfeed1(), srfeed2(), and srFeedName().
Block<String> GBTIFLOHelper::itsBank [private] |
Definition at line 198 of file GBTIFLOHelper.h.
Referenced by bank().
Block<Vector<Double> > GBTIFLOHelper::itsCenterFreq [private] |
Definition at line 196 of file GBTIFLOHelper.h.
Block<Array<Int> > GBTIFLOHelper::itsCorrProduct [private] |
Definition at line 202 of file GBTIFLOHelper.h.
Referenced by corrProduct().
Block<Vector<Int> > GBTIFLOHelper::itsCorrType [private] |
Definition at line 195 of file GBTIFLOHelper.h.
Referenced by corrType().
Block<Double> GBTIFLOHelper::itsDeltaFreq [private] |
Definition at line 204 of file GBTIFLOHelper.h.
Referenced by deltaFreq().
Block<Int> GBTIFLOHelper::itsFeed [private] |
Definition at line 200 of file GBTIFLOHelper.h.
Referenced by feed().
Block<Int> GBTIFLOHelper::itsFeedIds [private] |
Definition at line 193 of file GBTIFLOHelper.h.
Referenced by feedId().
Block<Vector<String> > GBTIFLOHelper::itsFeedName [private] |
Definition at line 199 of file GBTIFLOHelper.h.
Referenced by feedName().
Block<Int> GBTIFLOHelper::itsHighCal [private] |
Definition at line 200 of file GBTIFLOHelper.h.
Referenced by highCal().
PtrBlock<const GBTLO1File *> GBTIFLOHelper::itsLO1Files [private] |
Definition at line 184 of file GBTIFLOHelper.h.
Referenced by lo1File().
GBTLO1DAPFiller* GBTIFLOHelper::itsLO1Filler [private] |
Definition at line 185 of file GBTIFLOHelper.h.
Vector<Double> GBTIFLOHelper::itsLO1offset [private] |
Definition at line 208 of file GBTIFLOHelper.h.
uInt GBTIFLOHelper::itsNchannels [private] |
Definition at line 182 of file GBTIFLOHelper.h.
uInt GBTIFLOHelper::itsNfeeds [private] |
Definition at line 182 of file GBTIFLOHelper.h.
uInt GBTIFLOHelper::itsNphases [private] |
Definition at line 182 of file GBTIFLOHelper.h.
Block<Vector<String> > GBTIFLOHelper::itsPolType [private] |
Definition at line 197 of file GBTIFLOHelper.h.
Referenced by polarizationType().
PtrBlock<Block<uInt> *> GBTIFLOHelper::itsRcvrRows [private] |
Definition at line 187 of file GBTIFLOHelper.h.
Referenced by receiverRows().
Double GBTIFLOHelper::itsRefChan [private] |
Definition at line 183 of file GBTIFLOHelper.h.
Referenced by refChan().
Block<String> GBTIFLOHelper::itsRxName [private] |
Definition at line 198 of file GBTIFLOHelper.h.
Referenced by receiverName().
Vector<uInt> GBTIFLOHelper::itsSamplerFeeds [private] |
Definition at line 210 of file GBTIFLOHelper.h.
Referenced by nfeeds(), and whichFeed().
Block<Double> GBTIFLOHelper::itsSFFMultiplier [private] |
Definition at line 191 of file GBTIFLOHelper.h.
Block<IPosition> GBTIFLOHelper::itsShapes [private] |
Definition at line 206 of file GBTIFLOHelper.h.
Referenced by shape().
Block<String> GBTIFLOHelper::itsSRBank [private] |
Definition at line 198 of file GBTIFLOHelper.h.
Referenced by srbank().
Block<Int> GBTIFLOHelper::itsSrfeed1 [private] |
Definition at line 200 of file GBTIFLOHelper.h.
Referenced by srfeed1().
Block<Int> GBTIFLOHelper::itsSrfeed2 [private] |
Definition at line 200 of file GBTIFLOHelper.h.
Referenced by srfeed2().
Block<Vector<String> > GBTIFLOHelper::itsSRFeedName [private] |
Definition at line 199 of file GBTIFLOHelper.h.
Referenced by srFeedName().
Block<Double> GBTIFLOHelper::itsT0CenterFreq [private] |
Definition at line 190 of file GBTIFLOHelper.h.