ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/UserCode/VHbb/python/HistoMaker.py
(Generate patch)

Comparing UserCode/VHbb/python/HistoMaker.py (file contents):
Revision 1.2 by peller, Tue Oct 2 13:00:32 2012 UTC vs.
Revision 1.3 by peller, Tue Oct 2 13:19:45 2012 UTC

# Line 16 | Line 16 | class HistoMaker:
16          self.rescale = rescale
17          self.which_weightF=which_weightF
18          self.region = region
19 +        self.lumi=0.
20  
21      def getScale(self,job,subsample=-1):
22          anaTag=self.config.get('Analysis','tag')
# Line 31 | Line 32 | class HistoMaker:
32              sf=float(job.sf)
33          theScale = 1.
34          if anaTag == '7TeV':
35 <            theScale = float(job.lumi)*xsec*sf/(0.46502*CountWithPU.GetBinContent(1)+0.53498*CountWithPU2011B.GetBinContent(1))*self.rescale/float(job.split)
35 >            theScale = float(self.lumi)*xsec*sf/(0.46502*CountWithPU.GetBinContent(1)+0.53498*CountWithPU2011B.GetBinContent(1))*self.rescale/float(job.split)
36          elif anaTag == '8TeV':
37 <            theScale = float(job.lumi)*xsec*sf/(CountWithPU.GetBinContent(1))*self.rescale/float(job.split)
37 >            theScale = float(self.lumi)*xsec*sf/(CountWithPU.GetBinContent(1))*self.rescale/float(job.split)
38          return theScale
39  
40  
41      def getHistoFromTree(self,job,subsample=-1):
42 <        
42 >        if self.lumi == 0: raise Exception("You're trying to plot with no lumi")
43 >        
44          hTreeList=[]
45          groupList=[]
46  

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines