- Timestamp:
- Jan 11, 2015, 1:31:50 PM (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/eam_branches/ipp-20140904/ippToPsps/jython/batch.py
r37246 r37801 382 382 self.logger.infoPair("Min objID", "%ld" % self.minObjID) 383 383 self.logger.infoPair("Max objID", "%ld" % self.maxObjID) 384 385 386 ''' 387 Sets min and max obj ID using the provided table, or list of tables 388 ''' 389 def setMinMaxDiffObjID(self, tables): 390 first = True 391 self.totalDetections = 0 392 for table in tables: 393 sql = "SELECT MIN(diffObjID), MAX(diffObjID), COUNT(diffObjID) FROM " + table 394 rs = self.scratchDb.executeQuery(sql) 395 rs.first() 396 self.totalDetections = self.totalDetections + rs.getLong(3) 397 if first: 398 self.minObjID = rs.getLong(1) 399 self.maxObjID = rs.getLong(2) 400 else: 401 if rs.getLong(1) < self.minObjID: self.minObjID = rs.getLong(1) 402 if rs.getLong(2) > self.maxObjID: self.maxObjID = rs.getLong(2) 403 first = False 404 rs.close() 405 self.ippToPspsDb.updateDetectionStats(self.batchID, self.minObjID, self.maxObjID, self.totalDetections) 406 self.logger.infoPair("Total detections", "%ld" % self.totalDetections) 407 self.logger.infoPair("Min objID", "%ld" % self.minObjID) 408 self.logger.infoPair("Max objID", "%ld" % self.maxObjID) 409 410 384 411 385 412 ''' … … 579 606 # for OB, this imports object data from DVO 580 607 if not self.importIppTables(): 581 if self.batchType == "OB":608 if (self.batchType == "OB" or self.batchType =="DO" or self.batchType =="FO"): 582 609 self.logger.errorPair("skipping this batch", "no dvo tables for this region") 583 610 self.ippToPspsDb.updateProcessed(self.batchID, 1)
Note:
See TracChangeset
for help on using the changeset viewer.
