IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Jan 31, 2013, 4:13:09 PM (13 years ago)
Author:
eugene
Message:

split out config (static info) and skychunk (area being processed)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/eam_branches/ipp-20121219/ippToPsps/jython/plot.py

    r34165 r35076  
    1515    Constructor
    1616    '''
    17     def __init__(self, logger, config, ippToPspsDb):
     17    def __init__(self, logger, skychunk, ippToPspsDb):
    1818
    1919        self.logger = logger
    20         self.config = config
     20        self.skychunk = skychunk
    2121        self.ippToPspsDb = ippToPspsDb
    2222
    2323    '''
    24     Creates a density plot of pending exposures for this config
     24    Creates a density plot of pending exposures for this skychunk
    2525    '''
    2626    def createDensityPlot(self, batchType, forCzartool=False):
    2727
    28         tempFilename = "./" + self.config.name + "_" + batchType + "_plotData.dat"
     28        tempFilename = "./" + self.skychunk.name + "_" + batchType + "_plotData.dat"
    2929        DATFILE = open(tempFilename,'w')
    3030        max = self.ippToPspsDb.createPendingDensityPlotData(batchType, DATFILE)
     
    3636
    3737        if forCzartool:
    38             OUTPUTFILE = self.config.czarPlotsPath + "/ippToPsps_density_" + self.config.name + "_" + batchType + ".png"
     38            ## XXX from config??
     39            OUTPUTFILE = self.skychunk.czarPlotsPath + "/ippToPsps_density_" + self.skychunk.name + "_" + batchType + ".png"
    3940        else:
    40             OUTPUTFILE = self.config.name + "_" + batchType + "_" + timestamp + ".png"
     41            OUTPUTFILE = self.skychunk.name + "_" + batchType + "_" + timestamp + ".png"
    4142
    4243        f = os.popen('/home/panstarrs/ipp/local/bin/gnuplot', 'w')
     
    4950        print >> f, "set term " + TERM + "; \
    5051            set output \"" + OUTPUTFILE + "\"; \
    51             set title \"Unprocessed " + batchType + " items for '" + self.config.name + "' as of " + timestamp + "\"; \
     52            set title \"Unprocessed " + batchType + " items for '" + self.skychunk.name + "' as of " + timestamp + "\"; \
    5253            set grid; \
    53             set xrange [" + str(self.config.minRa) + ":" + str(self.config.maxRa) + "] reverse; \
    54             set yrange [" + str(self.config.minDec) + ":" + str(self.config.maxDec) + "]; \
     54            set xrange [" + str(self.skychunk.minRa) + ":" + str(self.skychunk.maxRa) + "] reverse; \
     55            set yrange [" + str(self.skychunk.minDec) + ":" + str(self.skychunk.maxDec) + "]; \
    5556            unset key; \
    5657            set palette rgb 22,13,10; \
Note: See TracChangeset for help on using the changeset viewer.