GBT PAF FITS Data

Introduction

The GBT telescope system logs a considerable amount of information about each data scan that is useful and often essential to interpreting data from the PAF. These log data are stored as FITS format files in the Green Bank system directory

/home/gbtdata/[program name_dn]
where [program name_dn] is the observing program identifier assigned by the telescope scheduler, e.g., AGBT15A_356, plus an observing day serial number, e.g., AGBT15A_356_01. Logging data from successive days will be in separate directories. Within each day's directory the FITS files are stored in subdirectories according to GBT subsystems in use for the observing program. For the Phased Array Feed these will be Antenna, GO, LO1A, RcvrArray1_2, and FXcorPAF. Each data scan will generate one FITS file in each directory, and all files from that scan will have the same file name composed of the date and UTC time string, e.g., 2013_01_05_08:04:23.fits. The common file name uniquely ties all FITS files from the same scan together, but they must be kept in separate directories to avoid overwriting one another. If the files are copied to another location, their directory structure must be maintained.

Reading Fits Files

GBT FITS files use the binary table FITS standard (as opposed to image data). A FITS file reader in any programming language can be used to retrieve the data from these files. Python and its FITS package, pyfits, from the Space Telescope Institute will be used here for illustration.

GO FITS Files

GO stands for 'GBT Observe' and its FITS files contain the observer's setup for each scan plus some other basic information. These files contain only a primary FITS table so they may be examined like any ASCII file, but the Python code for showing the contents of this file from any Green Bank Linux box is as follows,

paf0> /opt/local/bin/python
>>> import pyfits as pf
>>> hdulist = pf.open('/home/gbtdata/TGBT12A_501_17/GO/2013_01_05_09:07:23.fits')
>>> print hdulist[0].header.ascardlist()
>>> hdulist.close()
where the program and file names are only examples. Notice the use of the python executable in /opt/local/bin. This has access to a number of mudules, such as pytfits, that are not necessarily found with the generic python installation.

Antenna FITS Files

The Antenna FITS files contain all of the information about GBT pointing, including pointing corrections and beam offsets for multi-feed receivers. These FITS files contain binary tables, which can be asummarized with the following Python code.

>>> import pyfits as pf
>>> hdulist = pf.open('/home/gbtdata/TGBT12A_501_17/Antenna/2013_01_05_09:07:23.fits')
>>> print hdulist.info()
>>> hdulist.close()

The resulting output looks like

Filename: /home/gbtdata/TGBT12A_501_17/Antenna/2013_01_05_09:07:23.fits
No.    Name         Type      Cards   Dimensions   Format
0    PRIMARY     PrimaryHDU     117  ()            uint8
1    BEAM_OFFSETS  BinTableHDU     24  4R x 5C       [32A, 1D, 1D, 1J, 1J]
2    ANTPOSGR    BinTableHDU     57  3661R x 16C   [1D, 1D, 1D, 1D, 1D, 1D, 1D, 1D, 1D, 1D, 1D, 1D, 1D, 1D, 1D, 1D]
3    DYN_POINT   BinTableHDU     21  37R x 4C      [1D, 1D, 1D, 1D]
4    DYN_FOCUS   BinTableHDU     15  37R x 2C      [1D, 1D]

The PRIMARY header data unit (HDU) can be listed the same way as shown for the GO FITS files above. The HDU of most interest is ANTPOSGR, which contains binary table that logs the antenna position throughout the scan. From the hdulist.info() output you can see that there are 16 columns in the ANTPOSGR HDU. The column names can be listed with the following python code:

>>> import pyfits as pf
>>> hdulist = pf.open('/home/gbtdata/TGBT12A_501_17/Antenna/2013_01_05_09:07:23.fits')
>>> print self.hdulist[2].columns
>>> hdulist.close()

The rusulting output looks like

ColDefs(name = 'DMJD'
format = '1D'
unit = 'd', name = 'RAJ2000'
format = '1D'
unit = 'deg', name = 'DECJ2000'
format = '1D'
unit = 'deg', name = 'MNT_AZ'
format = '1D'
unit = 'deg', name = 'MNT_EL'
format = '1D'
unit = 'deg', name = 'REFRACT'
format = '1D'
unit = 'deg', name = 'MAJOR'
format = '1D'
unit = 'deg', name = 'MINOR'
format = '1D'
unit = 'deg', name = 'OBSC_AZ'
format = '1D'
unit = 'deg', name = 'OBSC_EL'
format = '1D'
unit = 'deg', name = 'SR_XP'
format = '1D'
unit = 'mm', name = 'SR_YP'
format = '1D'
unit = 'mm', name = 'SR_ZP'
format = '1D'
unit = 'mm', name = 'SR_XT'
format = '1D'
unit = 'deg', name = 'SR_YT'
format = '1D'
unit = 'deg', name = 'SR_ZT'
format = '1D'
unit = 'deg')

As an example of how the column data might be retrieved and used, the following code will plot the GBT azimuth/elevation track during the scan using the MNT_EL and MNT_AZ table columns.

>>> import pyfits as pf
>>> import pylab as pl
>>> hdulist = pf.open('/home/gbtdata/TGBT12A_501_17/Antenna/2013_01_05_09:07:23.fits')
>>> az = hdulist[2].data.field('MNT_AZ')
>>> el = hdulist[2].data.field('MNT_EL')
>>> hdulist.close()
>>> pl.plot(az, el)
>>> pl.xlabel('Azimuth')
>>> pl.ylabel('Elevation')
>>> pl.show()

As of this writing (Feb. 19, 2013) the details of how the data in these columns are to be used for PAF pointing is still being worked out. Unlike multi-feed receivers, the PAF has a continuous field of view so some pointing definitions may need to be added or clarified.