IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Jul 3, 2013, 1:44:20 PM (13 years ago)
Author:
eugene
Message:

merge changes from trunk

Location:
branches/eam_branches/ipp-20130509/ippToPsps
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/eam_branches/ipp-20130509/ippToPsps

  • branches/eam_branches/ipp-20130509/ippToPsps/jython/queue.py

    r35417 r35748  
    3737        self.datastore = Datastore(self.logger, self.skychunk, self.ippToPspsDb)
    3838
    39         # print "made datastore"
     39        print "made datastore"
    4040
    4141        # connect to scratch database
    4242        self.scratchDb = ScratchDb(self.logger, self.config)
    4343
    44         # print "connect to scratchdb"
     44        print "connect to scratchdb"
    4545
    4646        try:
     
    5050            raise
    5151
    52         # print "got objects"
     52        print "got objects"
    5353
    5454        self.skychunk.printAll()
     
    6262    '''
    6363    def run(self):
    64 
     64        print "here"
    6565        # this outer while loop simply waits a few minutes then starts queuing again (as more stuff may appear in DVO over time)
    6666        while True:
    6767
    6868            self.ippToPspsDb.removeAllBoxes()
    69        
     69            print "remove boxes"
    7070            # queue up batches that are processed but not loaded to datastore
    7171            for batchType in self.skychunk.batchTypes:
    72 
     72                self.logger.infoPair("BatchType",batchType)
    7373                # self.logger.infoTitle("Previous failed datastore loads")
    7474                # self.publishAnyUnpublishedBatches(batchType)
     
    7676                # get totals for whole area to check if there is anything to do
    7777                processedIDs = self.ippToPspsDb.getProcessedIDs(batchType)
     78                print "got processed ids"
    7879                consistantlyFailedIDs = self.ippToPspsDb.getConsistentlyFailedIDs(batchType)
    79 
     80                print "got here"
    8081                # for object batches, get full list of stuff from Dvo
    8182                # XXX : need to fix 'dvo.setSkyArea' or this may not return the full list for a parallel dvo
     
    133134
    134135                    dD = 0.5*self.skychunk.boxSize
     136                   
    135137                    dec = self.skychunk.minDec + dD
     138                    #dec = self.skychunk.minDec
     139
    136140                    if (dec > 85): raise
    137141
    138                     # print "dec, dD: ", dec, dD
     142                    print "dec, dD: ", dec, dD ,self.skychunk.maxDec
    139143
    140144                    # 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                                       
    142148                    ra = self.skychunk.minRa + dR
    143149                   
    144                     # print "ra, dR: ", ra, dR
     150                    print "ra, dR, maxRa", ra, dR, self.skychunk.maxRa
    145151
    146152                    # XXX not sure why this is not done with a for-loop...
    147153                    while dec <= self.skychunk.maxDec:
    148154                        while ra <= self.skychunk.maxRa:
    149            
     155                           print "here"
    150156                           # a given box centered at RA,DEC with (linear) size of SIDE has the following bounds
    151157                           minRA  = ra  - dR
     
    165171                                       len(ids)))
    166172               
    167                            # print "box_id: ", box_id
     173                           print "box_id: ", box_id
    168174
    169175                           if len(ids) > 0: self.ippToPspsDb.insertPending(box_id, batchType, ids)
     
    175181                        if (dec > 85): raise
    176182
    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
    178185                        ra = self.skychunk.minRa + dR
    179186
Note: See TracChangeset for help on using the changeset viewer.