Index: trunk/ippToPsps/jython/forcedwarpbatch.py
===================================================================
--- trunk/ippToPsps/jython/forcedwarpbatch.py	(revision 39123)
+++ trunk/ippToPsps/jython/forcedwarpbatch.py	(revision 39305)
@@ -228,7 +228,23 @@
         pltscale2 = pltscale * pltscale
 
-        psfFwhmMajor = pltscale * self.getKeyFloat(header, "%.8f", 'FWHM_MAJ')
-        psfFwhmMinor = pltscale * self.getKeyFloat(header, "%.8f", 'FWHM_MIN')
-        psfFWHM = 0.5*(psfFwhmMajor + psfFwhmMinor)
+        # NOTE: getKeyFloat returns the header value if it is a float,
+        # -999 if the value is missing and "NULL" if the value in the
+        # header is a NaN.  any math operations below need to handle
+        # these cases correctly
+
+        # NOTE 2: getKeyFloat NOW returns the header value if it is a
+        # float or "NULL" if the value is missing or if the value in
+        # the header is a NaN.  any math operations below need to
+        # handle these cases correctly
+
+        psfFwhmMajor = self.getKeyFloat(header, "%.8f", 'FWHM_MAJ')
+        if (psfFwhmMajor != "NULL"): psfFwhmMajor *= pltscale
+
+        psfFwhmMinor = self.getKeyFloat(header, "%.8f", 'FWHM_MIN')
+        if (psfFwhmMinor != "NULL"): psfFwhmMinor *= pltscale
+
+        psfFWHM = "NULL"
+        if (psfFwhmMajor != "NULL") and (psfFwhmMinor != "NULL"):
+            psfFWHM = 0.5*(psfFwhmMajor + psfFwhmMinor)
 
         psfmodel_name = self.getKeyValue(header, 'PSFMODEL')
@@ -252,19 +268,12 @@
         sqlLine.group("ippSkycalID",    self.ippSkycalID[num])
         sqlLine.group("stackMetaID",    self.stackMetaID[num])
-# no astrometry calibration for forced warp
-#       sqlLine.group("astroScat",      self.getKeyFloat(header, "%.8f", 'CERROR'))
-#       sqlLine.group("nAstroRef",      self.getKeyValue(header, 'NASTRO'))
-#       sqlLine.group("nPhotoRef",      self.getKeyValue(header, 'NASTRO'))
-#       sqlLine.group("photoScat",      self.getKeyFloat(self.header, "%.8f", 'ZPT_ERR'));
         sqlLine.group("psfModelID",     psfmodelID)
         sqlLine.group("psfFWHM",        psfFWHM)
         sqlLine.group("psfWidMajor",    psfFwhmMajor)
         sqlLine.group("psfWidMinor",    psfFwhmMinor)
-        # sqlLine.group("psfFwhm_mean",   self.getKeyFloat(header, "%.8f", 'FWHM_MAJ'))
-        # sqlLine.group("psfFwhm_max",    self.getKeyFloat(header, "%.8f", 'FW_MJ_UQ'))
+
+        # sqlLine.group("photoZero",      self.getKeyFloat(header, "%.8f", 'FPA.ZP'))
 
         sqlLine.group("psfTheta",       self.getKeyFloat(header, "%.8f", 'ANGLE'))
-
-        # sqlLine.group("photoZero",      self.getKeyFloat(header, "%.8f", 'FPA.ZP'))
         sqlLine.group("photoZero",      zpImage)
 
