CMS 3D CMS Logo

Functions
studyJets Namespace Reference

Functions

def getJetProperties (jetSeed, etaFwd, etaCen)
 Python script for studying eta dependence of jet sizes and seed centrality # Author: Aaron Bundock (aaron. More...
 
def printJetProperties (etaRange)
 

Function Documentation

def studyJets.getJetProperties (   jetSeed,
  etaFwd,
  etaCen 
)

Python script for studying eta dependence of jet sizes and seed centrality # Author: Aaron Bundock (aaron.

*nospamthankyamaam*bundock.ch) # Date: 15/01/18 # #

Definition at line 25 of file studyJets.py.

References funct.abs().

Referenced by printJetProperties().

25 def getJetProperties(jetSeed,etaFwd,etaCen):
26 
27  jetSize = 0
28  etaFwdSize = 0
29  etaCenSize = 0
30 
31  for ring in xrange(jetSeed-etaCen,jetSeed+etaFwd+1):
32 
33  if ring < 1:
34  ring = abs(ring-1)
35 
36  if ring >= len(towerEtaWidths):
37  break
38 
39  if ring < jetSeed:
40  etaFwdSize += towerEtaWidths[ring]
41  if ring > jetSeed:
42  etaCenSize += towerEtaWidths[ring]
43 
44  jetSize = (etaFwdSize + etaCenSize + towerEtaWidths[jetSeed])/0.8
45  seedCent = etaCenSize/etaFwdSize
46 
47  jetProps = [jetSize, seedCent]
48 
49  return jetProps
50 
51 
def getJetProperties(jetSeed, etaFwd, etaCen)
Python script for studying eta dependence of jet sizes and seed centrality # Author: Aaron Bundock (a...
Definition: studyJets.py:25
Abs< T >::type abs(const T &t)
Definition: Abs.h:22
def studyJets.printJetProperties (   etaRange)

Definition at line 52 of file studyJets.py.

References getJetProperties(), edm.print(), and str.

52 def printJetProperties(etaRange):
53 
54  print "Size \ eta\t",
55  for seedEta in etaRange:
56  if(seedEta<29):
57  print str(seedEta)+"\t\t",
58  else:
59  print str(seedEta+1)+"\t\t",
60  print
61 
62  for size in jetEtaSizes:
63 
64  if size%2:
65  print " 9x"+str(size)+("\t"),
66  for seedEta in etaRange:
67  print("\t"),
68  etaFwdCen = (size-1)/2
69  jetProps = getJetProperties(seedEta,etaFwdCen,etaFwdCen)
70  print("%.2f / %.2f" %(jetProps[0],jetProps[1])),
71  print
72 
73  else:
74  print " 9x"+str(size)+" cen",
75  for seedEta in etaRange:
76  print("\t"),
77  etaFwd = size/2-1
78  etaCen = size/2
79  jetProps = getJetProperties(seedEta, etaFwd, etaCen)
80  print("%.2f / %.2f" %(jetProps[0],jetProps[1])),
81  print
82  print " 9x"+str(size)+" fwd",
83  for seedEta in etaRange:
84  print("\t"),
85  etaFwd = size/2
86  etaCen = size/2-1
87  jetProps = getJetProperties(seedEta, etaFwd, etaCen)
88  print("%.2f / %.2f" %(jetProps[0],jetProps[1])),
89  print
90 
91 
92 
def printJetProperties(etaRange)
Definition: studyJets.py:52
S & print(S &os, JobReport::InputFile const &f)
Definition: JobReport.cc:65
def getJetProperties(jetSeed, etaFwd, etaCen)
Python script for studying eta dependence of jet sizes and seed centrality # Author: Aaron Bundock (a...
Definition: studyJets.py:25
#define str(s)