IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Aug 12, 2014, 4:10:18 PM (12 years ago)
Author:
eugene
Message:

merge changes from branches/eam_branches/ipp-20140717

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/ippToPsps/jython/queue.py

    r36697 r37246  
    2929        super(Queue, self).__init__(argv)
    3030
    31         # print "inited ipptopsps"
    32 
    3331        # create various objects
    3432        self.gpc1Db = Gpc1Db(self.logger, self.config)
    35         # print "connect to gpc1"
    3633
    3734        self.datastore = Datastore(self.logger, self.skychunk, self.ippToPspsDb)
    38 
    39         print "made datastore"
    4035
    4136        # connect to scratch database
    4237        self.scratchDb = ScratchDb(self.logger, self.config)
    4338
    44         print "connect to scratchdb"
    45 
    4639        try:
    47             print "why doesn't this work"
    4840            self.dvoObjects = DvoObjects(self.logger, self.config, self.skychunk, self.ippToPspsDb, self.scratchDb)
    4941        except:
     
    5143            raise
    5244
    53         print "got objects"
    54 
    5545        self.skychunk.printAll()
    5646
     
    6353    '''
    6454    def run(self):
    65         print "here"
     55        self.logger.info("------------- starting queue.run -----------------")
    6656        # this outer while loop simply waits a few minutes then starts queuing again (as more stuff may appear in DVO over time)
    6757        while True:
    6858
    6959            self.ippToPspsDb.removeAllBoxes()
    70             print "remove boxes"
     60
    7161            # queue up batches that are processed but not loaded to datastore
    7262            for batchType in self.skychunk.batchTypes:
     
    7767                # get totals for whole area to check if there is anything to do
    7868                processedIDs = self.ippToPspsDb.getProcessedIDs(batchType)
    79                 print "got processed ids"
    8069                consistantlyFailedIDs = self.ippToPspsDb.getConsistentlyFailedIDs(batchType)
    81                 print "got here"
     70
    8271                # for object batches, get full list of stuff from Dvo
    8372                # XXX : need to fix 'dvo.setSkyArea' or this may not return the full list for a parallel dvo
    84             #for object-like batches, info comes from dvo
     73
     74                # for object-like batches, info comes from dvo
    8575                if (batchType == "OB" or batchType =="DO" or batchType =="FO"):
    8676                    self.dvoObjects.setSkyArea(
     
    144134                    if (dec > 85): raise
    145135
    146                     print "dec, dD: ", dec, dD ,self.skychunk.maxDec
     136                    # print "dec, dD: ", dec, dD ,self.skychunk.maxDec
    147137
    148138                    # a given box centered at RA,DEC with (linear) size of SIDE has the following bounds
     
    152142                    ra = self.skychunk.minRa + dR
    153143                   
    154                     print "ra, dR, maxRa", ra, dR, self.skychunk.maxRa
     144                    # print "ra, dR, maxRa", ra, dR, self.skychunk.maxRa
    155145
    156146                    # XXX not sure why this is not done with a for-loop...
    157147                    while dec <= self.skychunk.maxDec:
    158148                        while ra <= self.skychunk.maxRa:
    159                            print "here"
    160149                           # a given box centered at RA,DEC with (linear) size of SIDE has the following bounds
    161150                           minRA  = ra  - dR
     
    175164                                       len(ids)))
    176165               
    177                            print "box_id: ", box_id
    178 
    179166                           if len(ids) > 0: self.ippToPspsDb.insertPending(box_id, batchType, ids)
    180167                           # print "inserted pending"
Note: See TracChangeset for help on using the changeset viewer.