 
# description of the chip metadata
BLANK METADATA
  COMMENT  STR  MULTI
  COMMENT  STR
  COMMENT  STR  Combination (P4S, P4D, Image Stack/ Cumulative Sky) Image
  COMMENT  STR  Metadata HDU
  COMMENT  STR  
  OBS_ID   STR  UnknownFormat       # Observation Identifier
  CLASSID  S32                    0 # Class ID = focal plane location
  DETECTID S32                    0 # Numerical ID of detector
  NX       S32                 4800 # Number of columns on the detector
  NY       S32                 4800 # Number of rows on the detector   DATE    STR 2006/02/05
  COMMENT  STR
  COMMENT  STR  Astrometric Solution (up to linear terms)
  COMMENT  STR
  NASTRO   S32                  100 # Number of astrometry stars
  CERROR   F32               10.000 # Scatter in astrometry solution (MAS)
  CTYPE1   STR  RA---TAN            # WCS Coordinate type
  CTYPE2   STR  DEC--TAN            # WCS Coordinate type
  CRVAL1   F32      321.30941666667 # WCS Ref value (RA in decimal degrees)
  CRVAL2   F32     -5.1685277777778 # WCS Ref value (DEC in decimal degrees)
  CRPIX1   F32    -1051.17692913657 # WCS Coordinate reference pixel
  CRPIX2   F32     2033.40939404705 # WCS Coordinate reference pixel
  CD1_1    F32  1.13378419402790E-4 # WCS Coordinate scale matrix
  CD1_2    F32  8.93919113249280E-8 # WCS Coordinate scale matrix
  CD2_1    F32  -5.4105516940550E-7 # WCS Coordinate scale matrix
  CD2_2    F32  -1.1365323690945E-4 # WCS Coordinate scale matrix
  COMMENT  STR
  COMMENT  STR  Higher order terms in astrometric solution
  COMMENT  STR
  POLYORD  S32                    3 # Polynomial Order
  PCA1X3Y0 F32                  0.0 # WCS, Axis 1, coefficient of X^3
  PCA1X2Y1 F32                  0.0 # WCS, Axis 1, coefficient of X^2 * Y
  PCA1X1Y2 F32                  0.0 # WCS, Axis 1, coefficient of X * Y^2
  PCA1X0Y3 F32                  0.0 # WCS, Axis 1, coefficient of Y^3
  PCA1X2Y0 F32                  0.0 # WCS, Axis 1, coefficient of X^2
  PCA1X1Y1 F32                  0.0 # WCS, Axis 1, coefficient of X * Y
  PCA1X0Y2 F32                  0.0 # WCS, Axis 1, coefficient of Y^2
  PCA1X3Y0 F32                  0.0 # WCS, Axis 2, coefficient of X^3
  PCA1X2Y1 F32                  0.0 # WCS, Axis 2, coefficient of X^2 * Y
  PCA1X1Y2 F32                  0.0 # WCS, Axis 2, coefficient of X * Y^2
  PCA1X0Y3 F32                  0.0 # WCS, Axis 2, coefficient of Y^3
  PCA1X2Y0 F32                  0.0 # WCS, Axis 2, coefficient of X^2
  PCA1X1Y1 F32                  0.0 # WCS, Axis 2, coefficient of X * Y
  PCA1X0Y2 F32                  0.0 # WCS, Axis 2, coefficient of Y^2
  COMMENT  STR
  COMMENT  STR  PSF Description Parameters
  COMMENT  STR
  PSFMOD   S32                    1 # PSF Model number
  PSFFWHM  F32                  1.0 # PSF Full width at Half Maximum (pixels)
  PSFWIDX  F32                  1.0 # PSF Width in X coordinate (pixels)
  PSFWIDY  F32                  1.0 # PSF Width in Y coordinate (pixels)
  PSFTHETA F32                  0.0 # PSF Orientation angle (degrees)
  PSF_EX1  F32                  0.0 # PSF Extra parameter #1
  PSF_EX2  F32                  0.0 # PSF Extra parameter #2
  COMMENT  STR
  COMMENT  STR  Photometry Calibration information
  COMMENT  STR
  COMMENT  STR   Formula for Photometry, based on keywords given in this header:
  COMMENT  STR   m = -2.5*log(DN) + 2.5*log(EXPTIME)
  COMMENT  STR   M = m + PHOT_C + PHOT_K*(AIRMASS - 1) + PHOT_X*(PHOT_C1 - PHOT_C2)
  COMMENT  STR
  PHOTCODE STR  GPC.00.r            # Photometry reduction code identifier
  PHOTOCID S32                      # Numerical code for reduction code
  PHOT_C   F32              25.7150 # Elixir zero point - measured for camera run
  PHOT_CS  F32               0.0048 # Elixir zero point - scatter
  PHOT_NS  S32                   19 # Elixir zero point - N stars
  PHOT_NM  S32                    5 # Elixir zero point - N images
  PHOT_C0  F32              25.7430 # Elixir zero point - nominal
  PHOT_X   F32               0.0830 # Elixir zero point - color term
  PHOT_K   F32              -0.0400 # Elixir zero point - airmass term
  PHOT_C1  STR  i_SDSS              # Elixir zero point - color 1
  PHOT_C2  STR  r_SDSS              # Elixir zero point - color 2
  COMMENT  STR
  COMMENT  STR  Some statistics on this image
  COMMENT  STR
  NDETECT  S32                 1000 # Number of detections
  MAGSAT   F32                15.0  # Magnitude at which sources saturate
  MAGCOMP  F32                22.0  # Magnitude for which frame is 95% complete
  SKYVAL   F32              1000.0  # Median sky value on detector
  SKYVAR   F32                 1.0  # Variance of sky values
  BIASVAL  F32               200.0  # Mean bias level of frame
  BIASVAR  F32                 1.0  # Variance of bias values
  COMMENT  STR
  COMMENT  STR  Images used to process this exposure
  COMMENT  STR 
  DETREND1 STR  bias.00.fits        # 
  DETREND2 STR  dark.00.fits        # 
  DETREND3 STR  flat.00.fits        # 
  DETREND4 STR  fringe.01.fits      # 
  DETREND5 STR  none                # 
  DETREND6 STR  none                # 
  DETREND7 STR  none                # 
  DETREND8 STR  none                # 
  COMMENT  STR
  COMMENT  STR  Quality Assurance Flags from IPP
  COMMENT  STR
  QAFLAGS  STR  UnknownValue        # IP QA flags
END

# extra data which belongs to table header
HEADER METADATA
  COMMENT  STR  MULTI
  COMMENT  STR   
  COMMENT  STR   This HDU applies to all detections that have been analyzed
  COMMENT  STR   with the IPP PSF fitting procedure. Note that the IPP_IDET
  COMMENT  STR   must be unique within a file so as to allow matching up
  COMMENT  STR   sources between the PSF matching and either the alternative
  COMMENT  STR   PSF fits for P2, P4S, and P4D detections or the extended
  COMMENT  STR   source fits to the Image Stack/Cumulative Sky detections.
  COMMENT  STR
  EXTNAME  STR PSF_FIT_PARAMS
END

# description of the FITS table columns
COLUMNS METADATA
  TYPE              TTYPE  TFORM TUNIT            TMIN   TMAX   COMMENT
  IPP_IDET          TTYPE  J     NONE             NONE   NONE   "IPP detection identifer index"                 
  X_PSF             TTYPE  E     PIXELS              0   5000   "PSF x coordinate"                              
  Y_PSF             TTYPE  E     PIXELS              0   5000   "PSF y coordinate"                              
  X_PSF_SIG         TTYPE  E     PIXELS              0     10   "Sigma in PSF x coordinate"                     
  Y_PSF_SIG         TTYPE  E     PIXELS              0     10   "Sigma in PSF y coordinate"                     
  RA_PSF            TTYPE  D     DECIMAL DEGREES     0    360   "RA from PSF fit"
  DEC_PSF           TTYPE  D     DECIMAL DEGREES   -90    +90   "DEC from PSF fit"
  RA_PSF_SIG        TTYPE  E     ARCSECONDS          0      1   "Sigma of PSF fit RA"
  DEC_PSF_SIG       TTYPE  E     ARCSECONDS          0      1   "Sigma of PSF fit DEC"
  PSF_INST_MAG      TTYPE  E     MAG               -20      0   "PSF fit instrumental magnitude"
  PSF_INST_MAG_SIG  TTYPE  E     MAG                 0    0.5   "Sigma of PSF instrumental magnitude"
  PEAK_FLUX_AS_MAG  TTYPE  E     MAG               -20      0   "Peak flux expressed as magnitude"
  SKY               TTYPE  E     ADU                 0  60000   "Sky level"
  SKY_SIGMA         TTYPE  E     ADU                 0  60000   "Sigma of sky level"
  STAR_GALAXY_SEP   TTYPE  E     NONE                0      1   "Star-Galaxy separator"
  PSF_WIDTH_X       TTYPE  E     ARCSECONDS          0     20   "PSF width in x coordinate"
  PSF_WIDTH_Y       TTYPE  E     ARCSECONDS          0     20   "PSF width in y coordinate"
  PSF_THETA         TTYPE  E     DEGREES          -180   +180   "PSF orientation angle"
  PSF_QF            TTYPE  E     NONE                0      1   "PSF coverage/quality factor"
  CAL_PSF_MAG       TTYPE  E     MAG               -10    +30   "Calibrated magnitude"
  CAL_PSF_MAG_SIG   TTYPE  E     MAG                 0    0.5   "Sigma of calibrated magnitude"
  N_FRAMES          TTYPE  I     NONE                0  10000   "Number of frames overlapping source center"
END
