- Timestamp:
- Jul 3, 2013, 1:44:20 PM (13 years ago)
- Location:
- branches/eam_branches/ipp-20130509/ippToPsps
- Files:
-
- 2 edited
-
. (modified) (1 prop)
-
jython/queue.py (modified) (7 diffs)
Legend:
- Unmodified
- Added
- Removed
-
branches/eam_branches/ipp-20130509/ippToPsps
- Property svn:mergeinfo changed
/trunk/ippToPsps merged: 35605,35656,35738-35739
- Property svn:mergeinfo changed
-
branches/eam_branches/ipp-20130509/ippToPsps/jython/queue.py
r35417 r35748 37 37 self.datastore = Datastore(self.logger, self.skychunk, self.ippToPspsDb) 38 38 39 #print "made datastore"39 print "made datastore" 40 40 41 41 # connect to scratch database 42 42 self.scratchDb = ScratchDb(self.logger, self.config) 43 43 44 #print "connect to scratchdb"44 print "connect to scratchdb" 45 45 46 46 try: … … 50 50 raise 51 51 52 #print "got objects"52 print "got objects" 53 53 54 54 self.skychunk.printAll() … … 62 62 ''' 63 63 def run(self): 64 64 print "here" 65 65 # this outer while loop simply waits a few minutes then starts queuing again (as more stuff may appear in DVO over time) 66 66 while True: 67 67 68 68 self.ippToPspsDb.removeAllBoxes() 69 69 print "remove boxes" 70 70 # queue up batches that are processed but not loaded to datastore 71 71 for batchType in self.skychunk.batchTypes: 72 72 self.logger.infoPair("BatchType",batchType) 73 73 # self.logger.infoTitle("Previous failed datastore loads") 74 74 # self.publishAnyUnpublishedBatches(batchType) … … 76 76 # get totals for whole area to check if there is anything to do 77 77 processedIDs = self.ippToPspsDb.getProcessedIDs(batchType) 78 print "got processed ids" 78 79 consistantlyFailedIDs = self.ippToPspsDb.getConsistentlyFailedIDs(batchType) 79 80 print "got here" 80 81 # for object batches, get full list of stuff from Dvo 81 82 # XXX : need to fix 'dvo.setSkyArea' or this may not return the full list for a parallel dvo … … 133 134 134 135 dD = 0.5*self.skychunk.boxSize 136 135 137 dec = self.skychunk.minDec + dD 138 #dec = self.skychunk.minDec 139 136 140 if (dec > 85): raise 137 141 138 # print "dec, dD: ", dec, dD142 print "dec, dD: ", dec, dD ,self.skychunk.maxDec 139 143 140 144 # a given box centered at RA,DEC with (linear) size of SIDE has the following bounds 141 dR = 0.5*self.skychunk.boxSize / math.cos(math.radians(dec)) 145 #dR = 0.5*self.skychunk.boxSize / math.cos(math.radians(dec)) 146 dR = 0.5*self.skychunk.boxSize 147 142 148 ra = self.skychunk.minRa + dR 143 149 144 # print "ra, dR: ", ra, dR150 print "ra, dR, maxRa", ra, dR, self.skychunk.maxRa 145 151 146 152 # XXX not sure why this is not done with a for-loop... 147 153 while dec <= self.skychunk.maxDec: 148 154 while ra <= self.skychunk.maxRa: 149 155 print "here" 150 156 # a given box centered at RA,DEC with (linear) size of SIDE has the following bounds 151 157 minRA = ra - dR … … 165 171 len(ids))) 166 172 167 #print "box_id: ", box_id173 print "box_id: ", box_id 168 174 169 175 if len(ids) > 0: self.ippToPspsDb.insertPending(box_id, batchType, ids) … … 175 181 if (dec > 85): raise 176 182 177 dR = 0.5*self.skychunk.boxSize / math.cos(math.radians(dec)) 183 #dR = 0.5*self.skychunk.boxSize / math.cos(math.radians(dec)) 184 dR = 0.5*self.skychunk.boxSize 178 185 ra = self.skychunk.minRa + dR 179 186
Note:
See TracChangeset
for help on using the changeset viewer.
