Changeset 35780 for trunk/ippToPsps/jython/stackbatch.py
- Timestamp:
- Jul 8, 2013, 9:46:47 AM (13 years ago)
- File:
-
- 1 edited
-
trunk/ippToPsps/jython/stackbatch.py (modified) (5 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/ippToPsps/jython/stackbatch.py
r35739 r35780 616 616 ''' 617 617 def populateStackApFlx(self): 618 self.logger.infoPair("getting","imageID") 619 imageID = self.scratchDb.getImageIDFromExternID(self.header['IMAGEID']) 620 self.logger.infoPair("obtained","imageID") 618 621 619 622 self.logger.infoPair("Procesing", "StackApFlx") … … 651 654 self.scratchDb.execute(sql) 652 655 656 self.logger.infoPair("adding"," PrimaryF to stackApFlx") 657 sql = "UPDATE StackApFlx AS a, " + self.scratchDb.dvoDetectionTable + " AS b SET \ 658 a.primaryF = ((b.flags & 0x10000) >> 16 ) \ 659 WHERE a.ippDetectID = b.ippDetectID \ 660 AND b.imageID = " + str(imageID) 661 662 print "update dvo sql: ", sql 663 # response = raw_input("update dvo...") 664 self.scratchDb.execute(sql) 665 666 667 653 668 self.scratchDb.updateAllRows("StackApFlx", "surveyID", str(self.surveyID)) 654 669 self.scratchDb.updateFilterID("StackApFlx", self.filter) 655 670 self.scratchDb.updateAllRows("StackApFlx", "dataRelease", str(self.skychunk.dataRelease)) 656 self.scratchDb.updateAllRows("StackApFlx", "primaryF", "0")657 671 self.scratchDb.updateAllRows("StackApFlx", "activeFlag", "0") 658 672 self.updateStackMetaID("StackApFlx") … … 667 681 ''' 668 682 def populateStackModelFit(self): 669 683 self.logger.infoPair("getting","imageID") 684 imageID = self.scratchDb.getImageIDFromExternID(self.header['IMAGEID']) 685 self.logger.infoPair("obtained","imageID") 670 686 self.logger.infoPair("Procesing table", "StackModelFit") 687 671 688 672 689 # insert all the detections … … 688 705 self.scratchDb.updateFilterID("StackModelFit", self.filter) 689 706 self.scratchDb.updateAllRows("StackModelFit", "dataRelease", str(self.skychunk.dataRelease)) 690 self.scratchDb.updateAllRows("StackModelFit", "primaryF", "0") 707 708 self.logger.infoPair("adding"," PrimaryF to stackApFlx") 709 sql = "UPDATE StackModelFit AS a, " + self.scratchDb.dvoDetectionTable + " AS b SET \ 710 a.primaryF = ((b.flags & 0x10000) >> 16 ) \ 711 WHERE a.ippDetectID = b.ippDetectID \ 712 AND b.imageID = " + str(imageID) 713 714 print "update dvo sql: ", sql 715 # response = raw_input("update dvo...") 716 try: 717 self.scratchDb.execute(sql) 718 except: 719 return 720 691 721 self.scratchDb.updateAllRows("StackModelFit", "activeFlag", "0") 692 722 self.updateStackMetaID("StackModelFit") … … 943 973 a.stackDetectID = b.detectID, \ 944 974 a.objID = b.objID, \ 945 a.infoFlag = b.flags << 45 | a.infoFlag \975 a.infoFlag = b.flags << 45 | a.infoFlag, \ 946 976 a.primaryF = ((b.flags & 0x10000) >> 16 ) \ 947 977 WHERE a.ippDetectID = b.ippDetectID \ 948 978 AND b.imageID = " + str(imageID) 949 979 950 #print "update dvo sql: ", sql980 print "update dvo sql: ", sql 951 981 # response = raw_input("update dvo...") 952 982 self.scratchDb.execute(sql)
Note:
See TracChangeset
for help on using the changeset viewer.
