CMS 3D CMS Logo

TimingTask_cfi.py
Go to the documentation of this file.
1 import FWCore.ParameterSet.Config as cms
2 
3 bxBins = [1]
4 
5 bxStepSizes = [9, 50, 100, 300]
6 bxMaxVals = [101, 1501, 2401, 3601]
7 runningMinVal = 1
8 
9 for stepCounter in range(len(bxStepSizes)):
10  runningMinVal = bxBins[-1]
11  bxStepSize = bxStepSizes[stepCounter]
12  bxMaxVal = bxMaxVals[stepCounter]
13  bxBins += list(range(runningMinVal + bxStepSize, bxMaxVal, bxStepSize))
14 
15 bxBinLabels = [str(bxBins[0])]
16 for bxBinCounter in range(0, -1+len(bxBins)):
17  bxBinLabels += [str(1+bxBins[bxBinCounter]) + "-->" + str(bxBins[bxBinCounter+1])]
18 
19 nBXBins = len(bxBins)
20 
21 bxBinsFine = [i for i in range(1, 3601)]
22 bxBinLabelsFine = [str(i) for i in range(1, 3601)]
23 nBXBinsFine = len(bxBinsFine)
24 
25 EaxisEdges = []
26 for i in range(50) :
27  EaxisEdges.append(pow(10., -0.5 + 2.5 / 50. * i))
28 
29 chi2ThresholdEE = 50.
30 chi2ThresholdEB = 16.
31 energyThresholdEE = 4.6
32 energyThresholdEEFwd = 12.
33 energyThresholdEB = 2.02
34 timingVsBXThreshold = energyThresholdEB
35 timeErrorThreshold = 3.
36 timeWindow = 12.5
37 summaryTimeWindow = 7.
38 
39 ecalTimingTask = cms.untracked.PSet(
40  params = cms.untracked.PSet(
41  bxBins = cms.untracked.vint32(bxBins),
42  bxBinsFine = cms.untracked.vint32(bxBinsFine),
43  chi2ThresholdEE = cms.untracked.double(chi2ThresholdEE),
44  chi2ThresholdEB = cms.untracked.double(chi2ThresholdEB),
45  energyThresholdEE = cms.untracked.double(energyThresholdEE),
46  energyThresholdEEFwd = cms.untracked.double(energyThresholdEEFwd),
47  energyThresholdEB = cms.untracked.double(energyThresholdEB),
48  timingVsBXThreshold = cms.untracked.double(timingVsBXThreshold),
49  timeErrorThreshold = cms.untracked.double(timeErrorThreshold),
50  splashSwitch = cms.untracked.bool(False)
51  ),
52  MEs = cms.untracked.PSet(
53  TimeMap = cms.untracked.PSet(
54  path = cms.untracked.string('%(subdet)s/%(prefix)sTimingTask/%(prefix)sTMT timing %(sm)s'),
55  kind = cms.untracked.string('TProfile2D'),
56  zaxis = cms.untracked.PSet(
57  high = cms.untracked.double(timeWindow),
58  low = cms.untracked.double(-timeWindow),
59  title = cms.untracked.string('time (ns)')
60  ),
61  otype = cms.untracked.string('SM'),
62  btype = cms.untracked.string('Crystal'),
63  description = cms.untracked.string('2D distribution of the mean rec hit timing. Only hits with GOOD or OUT_OF_TIME reconstruction flags and energy above threshold are used. Hits with |t| > ' + str(timeWindow) + ' ns are discarded. The energy thresholds are ' + ('%f and %f' % (energyThresholdEB, energyThresholdEE)) + ' for EB and EE respectively.')
64  ),
65  TimeMapByLS = cms.untracked.PSet(
66  path = cms.untracked.string('%(subdet)s/%(prefix)sTimingTask/%(prefix)sTMT timing by LS %(sm)s'),
67  kind = cms.untracked.string('TProfile2D'),
68  zaxis = cms.untracked.PSet(
69  high = cms.untracked.double(timeWindow),
70  low = cms.untracked.double(-timeWindow),
71  title = cms.untracked.string('time (ns)')
72  ),
73  otype = cms.untracked.string('SM'),
74  btype = cms.untracked.string('Crystal'),
75  description = cms.untracked.string('2D distribution of the mean rec hit timing. Only hits with GOOD or OUT_OF_TIME reconstruction flags and energy above threshold are used. Hits with |t| > ' + str(timeWindow) + ' ns are discarded. The energy thresholds are ' + ('%f and %f' % (energyThresholdEB, energyThresholdEE)) + ' for EB and EE respectively.')
76  ),
77  TimeAll = cms.untracked.PSet(
78  path = cms.untracked.string('%(subdet)s/%(prefix)sTimingTask/%(prefix)sTMT timing 1D summary%(suffix)s'),
79  kind = cms.untracked.string('TH1F'),
80  otype = cms.untracked.string('Ecal3P'),
81  xaxis = cms.untracked.PSet(
82  high = cms.untracked.double(timeWindow),
83  nbins = cms.untracked.int32(100),
84  low = cms.untracked.double(-timeWindow),
85  title = cms.untracked.string('time (ns)')
86  ),
87  btype = cms.untracked.string('User'),
88  description = cms.untracked.string('Distribution of the mean rec hit timing. Only hits with GOOD or OUT_OF_TIME reconstruction flags and energy above threshold are used. The energy thresholds are ' + ('%f and %f' % (energyThresholdEB, energyThresholdEE)) + ' for EB and EE respectively.')
89  ),
90  TimeAllMap = cms.untracked.PSet(
91  path = cms.untracked.string('%(subdet)s/%(prefix)sTimingTask/%(prefix)sTMT timing map%(suffix)s'),
92  kind = cms.untracked.string('TProfile2D'),
93  zaxis = cms.untracked.PSet(
94  high = cms.untracked.double(summaryTimeWindow),
95  low = cms.untracked.double(-summaryTimeWindow),
96  title = cms.untracked.string('time (ns)')
97  ),
98  otype = cms.untracked.string('Ecal3P'),
99  btype = cms.untracked.string('SuperCrystal'),
100  description = cms.untracked.string('2D distribution of the mean rec hit timing. Only hits with GOOD or OUT_OF_TIME reconstruction flags and energy above threshold are used. Hits with |t| > ' + str(summaryTimeWindow) + ' ns are discarded. The energy thresholds are ' + ('%f and %f' % (energyThresholdEB, energyThresholdEE)) + ' for EB and EE respectively.')
101  ),
102  TimeAmpAll = cms.untracked.PSet(
103  kind = cms.untracked.string('TH2F'),
104  yaxis = cms.untracked.PSet(
105  high = cms.untracked.double(50.0),
106  nbins = cms.untracked.int32(200),
107  low = cms.untracked.double(-50.0),
108  title = cms.untracked.string('time (ns)')
109  ),
110  otype = cms.untracked.string('Ecal3P'),
111  xaxis = cms.untracked.PSet(
112  edges = cms.untracked.vdouble(EaxisEdges),
113  title = cms.untracked.string('energy (GeV)')
114  ),
115  btype = cms.untracked.string('User'),
116  path = cms.untracked.string('%(subdet)s/%(prefix)sTimingTask/%(prefix)sTMT timing vs amplitude summary%(suffix)s'),
117  description = cms.untracked.string('Correlation between hit timing and energy. Only hits with GOOD or OUT_OF_TIME reconstruction flags are used.')
118  ),
119  TimeAmp = cms.untracked.PSet(
120  kind = cms.untracked.string('TH2F'),
121  yaxis = cms.untracked.PSet(
122  high = cms.untracked.double(50.0),
123  nbins = cms.untracked.int32(200),
124  low = cms.untracked.double(-50.0),
125  title = cms.untracked.string('time (ns)')
126  ),
127  otype = cms.untracked.string('SM'),
128  xaxis = cms.untracked.PSet(
129  edges = cms.untracked.vdouble(EaxisEdges),
130  title = cms.untracked.string('energy (GeV)')
131  ),
132  btype = cms.untracked.string('User'),
133  path = cms.untracked.string('%(subdet)s/%(prefix)sTimingTask/%(prefix)sTMT timing vs amplitude %(sm)s'),
134  description = cms.untracked.string('Correlation between hit timing and energy. Only hits with GOOD or OUT_OF_TIME reconstruction flags are used.')
135  ),
136  BarrelTimingVsBX = cms.untracked.PSet(
137  path = cms.untracked.string('EcalBarrel/EBTimingTask/EBTMT Timing vs BX'),
138  kind = cms.untracked.string('TProfile'),
139  otype = cms.untracked.string('EB'),
140  xaxis = cms.untracked.PSet(
141  high = cms.untracked.double(1.0*nBXBins),
142  nbins = cms.untracked.int32(nBXBins),
143  low = cms.untracked.double(0.0),
144  title = cms.untracked.string('BX Id'),
145  labels = cms.untracked.vstring(bxBinLabels)
146  ),
147  yaxis = cms.untracked.PSet(
148  title = cms.untracked.string('Timing (ns)')
149  ),
150  btype = cms.untracked.string('User'),
151  description = cms.untracked.string('Average hit timing in EB as a function of BX number. BX ids start at 1. Only events with energy above 2.02 GeV and chi2 less than 16 are used.')
152  ),
153  BarrelTimingVsBXFineBinned = cms.untracked.PSet(
154  path = cms.untracked.string('EcalBarrel/EBTimingTask/EBTMT Timing vs Finely Binned BX'),
155  kind = cms.untracked.string('TProfile'),
156  otype = cms.untracked.string('EB'),
157  xaxis = cms.untracked.PSet(
158  high = cms.untracked.double(1.0*nBXBinsFine),
159  nbins = cms.untracked.int32(nBXBinsFine),
160  low = cms.untracked.double(0.0),
161  title = cms.untracked.string('BX Id'),
162  labels = cms.untracked.vstring(bxBinLabelsFine)
163  ),
164  yaxis = cms.untracked.PSet(
165  title = cms.untracked.string('Timing (ns)')
166  ),
167  btype = cms.untracked.string('User'),
168  description = cms.untracked.string('Average hit timing in EB as a finely binned function of BX number. BX ids start at 1. Only events with energy above 2.02 GeV and chi2 less than 16 are used. The Customize button can be used to zoom in.')
169  ),
170  TimeAmpBXm = cms.untracked.PSet(
171  kind = cms.untracked.string('TH2F'),
172  yaxis = cms.untracked.PSet(
173  high = cms.untracked.double(100.0),
174  nbins = cms.untracked.int32(100),
175  low = cms.untracked.double(0.0),
176  title = cms.untracked.string('Amplitude BX-1 [ADC]')
177  ),
178  otype = cms.untracked.string('Ecal3P'),
179  xaxis = cms.untracked.PSet(
180  high = cms.untracked.double(1000.0),
181  nbins = cms.untracked.int32(250),
182  low = cms.untracked.double(0.0),
183  title = cms.untracked.string('In-time amplitude [ADC]')
184  ),
185  btype = cms.untracked.string('User'),
186  path = cms.untracked.string('%(subdet)s/%(prefix)sTimingTask/%(prefix)sTMT in-time vs BX-1 amplitude%(suffix)s'),
187  description = cms.untracked.string('Correlation between in-time amplitude and BX-1 out-of-time amplitude. Only events with kGood reconstruction flag set, energy > ( ' + ('EB:%f, EE:%f' % (energyThresholdEB*20., energyThresholdEE*5.)) + ' ) GeV, and chi2 < ( ' + ('EB:%f, EE:%f' % (chi2ThresholdEB, chi2ThresholdEE)) + ' ) are used.')
188  ),
189  TimeAmpBXp = cms.untracked.PSet(
190  kind = cms.untracked.string('TH2F'),
191  yaxis = cms.untracked.PSet(
192  high = cms.untracked.double(100.0),
193  nbins = cms.untracked.int32(100),
194  low = cms.untracked.double(0.0),
195  title = cms.untracked.string('Amplitude BX+1 [ADC]')
196  ),
197  otype = cms.untracked.string('Ecal3P'),
198  xaxis = cms.untracked.PSet(
199  high = cms.untracked.double(1000.0),
200  nbins = cms.untracked.int32(250),
201  low = cms.untracked.double(0.0),
202  title = cms.untracked.string('In-time amplitude [ADC]')
203  ),
204  btype = cms.untracked.string('User'),
205  path = cms.untracked.string('%(subdet)s/%(prefix)sTimingTask/%(prefix)sTMT in-time vs BX+1 amplitude%(suffix)s'),
206  description = cms.untracked.string('Correlation between in-time amplitude and BX+1 out-of-time amplitude. Only events with kGood reconstruction flag set, energy > ( ' + ('EB:%f, EE:%f' % (energyThresholdEB*20., energyThresholdEE*5.)) + ' ) GeV, and chi2 < ( ' + ('EB:%f, EE:%f' % (chi2ThresholdEB, chi2ThresholdEE)) + ' ) are used.')
207  ),
208  Time1D = cms.untracked.PSet(
209  path = cms.untracked.string('%(subdet)s/%(prefix)sTimingTask/%(prefix)sTMT timing 1D %(sm)s'),
210  kind = cms.untracked.string('TH1F'),
211  otype = cms.untracked.string('SM'),
212  xaxis = cms.untracked.PSet(
213  high = cms.untracked.double(timeWindow),
214  nbins = cms.untracked.int32(100),
215  low = cms.untracked.double(-timeWindow),
216  title = cms.untracked.string('time (ns)')
217  ),
218  btype = cms.untracked.string('User'),
219  description = cms.untracked.string('Distribution of the mean rec hit timing. Only hits with GOOD or OUT_OF_TIME reconstruction flags and energy above threshold are used. The energy thresholds are ' + ('%f and %f' % (energyThresholdEB, energyThresholdEE)) + ' for EB and EE respectively.')
220  ),
221  Chi2 = cms.untracked.PSet(
222  path = cms.untracked.string("%(subdet)s/%(prefix)sTimingTask/%(prefix)sTMT %(subdetshortsig)s Chi2"),
223  kind = cms.untracked.string('TH1F'),
224  otype = cms.untracked.string('Ecal3P'),
225  btype = cms.untracked.string('User'),
226  xaxis = cms.untracked.PSet(
227  high = cms.untracked.double(100.),
228  low = cms.untracked.double(0.),
229  nbins = cms.untracked.int32(100)
230  ),
231  description = cms.untracked.string('Chi2 of the pulse reconstruction.')
232  )
233  )
234 )
#define str(s)
Power< A, B >::type pow(const A &a, const B &b)
Definition: Power.h:29