- Timestamp:
- Nov 11, 2015, 3:48:35 PM (11 years ago)
- File:
-
- 1 edited
-
trunk/ippToPsps/jython/detectionbatch.py (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/ippToPsps/jython/detectionbatch.py
r39101 r39109 356 356 Populates the ImageDetEffMeta table for this OTA 357 357 ''' 358 def populateImageDetEffMetaTablePart1(self, ota, header ):358 def populateImageDetEffMetaTablePart1(self, ota, header, deteffHeader): 359 359 print "---- *** populate ImageDetEffMetaTablePart1" 360 360 ippTableName = ota + "_deteff" … … 373 373 374 374 # CZW: 20151110 This needs to get the deteff header as well. 375 nInjected = int(self.getKeyInt(header, 0, 'DETEFF.NUM')) 376 detectionThreshold = self.getKeyFloat(header, "%.8f", 'DETEFF.MAGREF') 375 nInjected = int(self.getKeyInt(deteffHeader, 0, 'DETEFF.NUM')) 376 magref = self.getKeyFloat(deteffHeader, "%.8f", 'DETEFF.MAGREF') 377 377 378 expTime = self.getKeyFloat(header, "%.8f", 'EXPTIME') 378 379 zp = self.getKeyFloat(header, "%.8f", 'ZPT_OBS') 379 380 381 # zp correction comes from DVO (unless it is not found) 380 382 zpImage = self.scratchDb.getImageZeroPoint(self.imageIDs[ota]) 381 383 382 # XXX zp correction should come from DVO 383 detectionThreshold = detectionThreshold + zpImage + 2.5 * math.log10(expTime) 384 384 if zpImage < 0.0: 385 zpImage = zp 386 387 detectionThreshold = magref + zpImage + 2.5 * math.log10(expTime) 385 388 386 389 sqlLine.group("frameID", str(self.expID)) … … 672 675 self.updateImageID("ImageMeta_" + chipname, x, y) 673 676 677 deteffHeader = self.fits.findAndReadHeader(chipname + ".deteff", self.config.test) 678 674 679 # XXX EAM 20151024 : problem is here? 675 self.populateImageDetEffMetaTablePart1(chipname, header )680 self.populateImageDetEffMetaTablePart1(chipname, header, deteffHeader) 676 681 self.updateImageID("ImageDetEffMeta_" + chipname, x, y) 677 682
Note:
See TracChangeset
for help on using the changeset viewer.
