PublicAnalysisDatabase: cms_b2g_12_012.tcl

File cms_b2g_12_012.tcl, 17.8 KB (added by Benjamin Fuks, 9 years ago)

CMS detector card for CMS_B2G_12_012

Line 
1#######################################
2# Order of execution of various modules
3#######################################
4
5set ExecutionPath {
6 ParticlePropagator
7
8 ChargedHadronTrackingEfficiency
9 ElectronTrackingEfficiency
10 MuonTrackingEfficiency
11
12 ChargedHadronMomentumSmearing
13 ElectronEnergySmearing
14 MuonMomentumSmearing
15
16 TrackMerger
17 Calorimeter
18 EFlowMerger
19
20 PhotonEfficiency
21
22 ElectronEfficiency
23
24 MuonEfficiency
25
26 MissingET
27
28 NeutrinoFilter
29 GenJetFinder
30 FastJetFinder
31
32 JetEnergyScale
33
34 BTagging
35 TauTagging
36
37 TreeWriter
38}
39
40#################################
41# Propagate particles in cylinder
42#################################
43
44module ParticlePropagator ParticlePropagator {
45 set InputArray Delphes/stableParticles
46
47 set OutputArray stableParticles
48 set ChargedHadronOutputArray chargedHadrons
49 set ElectronOutputArray electrons
50 set MuonOutputArray muons
51
52 # radius of the magnetic field coverage, in m
53 set Radius 1.29
54 # half-length of the magnetic field coverage, in m
55 set HalfLength 3.00
56
57 # magnetic field
58 set Bz 3.8
59}
60
61####################################
62# Charged hadron tracking efficiency
63####################################
64
65module Efficiency ChargedHadronTrackingEfficiency {
66 set InputArray ParticlePropagator/chargedHadrons
67 set OutputArray chargedHadrons
68
69 # add EfficiencyFormula {efficiency formula as a function of eta and pt}
70
71 # tracking efficiency formula for charged hadrons
72 set EfficiencyFormula { (pt <= 0.1) * (0.00) +
73 (abs(eta) <= 1.5) * (pt > 0.1 && pt <= 1.0) * (0.70) +
74 (abs(eta) <= 1.5) * (pt > 1.0) * (0.95) +
75 (abs(eta) > 1.5 && abs(eta) <= 2.5) * (pt > 0.1 && pt <= 1.0) * (0.60) +
76 (abs(eta) > 1.5 && abs(eta) <= 2.5) * (pt > 1.0) * (0.85) +
77 (abs(eta) > 2.5) * (0.00)}
78}
79
80##############################
81# Electron tracking efficiency
82##############################
83
84module Efficiency ElectronTrackingEfficiency {
85 set InputArray ParticlePropagator/electrons
86 set OutputArray electrons
87
88 # set EfficiencyFormula {efficiency formula as a function of eta and pt}
89
90 # tracking efficiency formula for electrons
91 set EfficiencyFormula { (pt <= 0.1) * (0.00) +
92 (abs(eta) <= 1.5) * (pt > 0.1 && pt <= 1.0) * (0.73) +
93 (abs(eta) <= 1.5) * (pt > 1.0 && pt <= 1.0e2) * (0.95) +
94 (abs(eta) <= 1.5) * (pt > 1.0e2) * (0.99) +
95 (abs(eta) > 1.5 && abs(eta) <= 2.5) * (pt > 0.1 && pt <= 1.0) * (0.50) +
96 (abs(eta) > 1.5 && abs(eta) <= 2.5) * (pt > 1.0 && pt <= 1.0e2) * (0.83) +
97 (abs(eta) > 1.5 && abs(eta) <= 2.5) * (pt > 1.0e2) * (0.90) +
98 (abs(eta) > 2.5) * (0.00)}
99}
100
101##########################
102# Muon tracking efficiency
103##########################
104
105module Efficiency MuonTrackingEfficiency {
106 set InputArray ParticlePropagator/muons
107 set OutputArray muons
108
109 # set EfficiencyFormula {efficiency formula as a function of eta and pt}
110
111 # tracking efficiency formula for muons
112 set EfficiencyFormula { (pt <= 0.1) * (0.00) +
113 (abs(eta) <= 1.5) * (pt > 0.1 && pt <= 1.0) * (0.75) +
114 (abs(eta) <= 1.5) * (pt > 1.0) * (0.99) +
115 (abs(eta) > 1.5 && abs(eta) <= 2.5) * (pt > 0.1 && pt <= 1.0) * (0.70) +
116 (abs(eta) > 1.5 && abs(eta) <= 2.5) * (pt > 1.0) * (0.98) +
117 (abs(eta) > 2.5) * (0.00)}
118}
119
120########################################
121# Momentum resolution for charged tracks
122########################################
123
124module MomentumSmearing ChargedHadronMomentumSmearing {
125 set InputArray ChargedHadronTrackingEfficiency/chargedHadrons
126 set OutputArray chargedHadrons
127
128 # set ResolutionFormula {resolution formula as a function of eta and pt}
129
130 # resolution formula for charged hadrons
131 set ResolutionFormula { (abs(eta) <= 1.5) * (pt > 0.1 && pt <= 1.0) * (0.02) +
132 (abs(eta) <= 1.5) * (pt > 1.0 && pt <= 1.0e1) * (0.01) +
133 (abs(eta) <= 1.5) * (pt > 1.0e1 && pt <= 2.0e2) * (0.03) +
134 (abs(eta) <= 1.5) * (pt > 2.0e2) * (0.05) +
135 (abs(eta) > 1.5 && abs(eta) <= 2.5) * (pt > 0.1 && pt <= 1.0) * (0.03) +
136 (abs(eta) > 1.5 && abs(eta) <= 2.5) * (pt > 1.0 && pt <= 1.0e1) * (0.02) +
137 (abs(eta) > 1.5 && abs(eta) <= 2.5) * (pt > 1.0e1 && pt <= 2.0e2) * (0.04) +
138 (abs(eta) > 1.5 && abs(eta) <= 2.5) * (pt > 2.0e2) * (0.05)}
139}
140
141#################################
142# Energy resolution for electrons
143#################################
144
145module EnergySmearing ElectronEnergySmearing {
146 set InputArray ElectronTrackingEfficiency/electrons
147 set OutputArray electrons
148
149 # set ResolutionFormula {resolution formula as a function of eta and energy}
150
151 # resolution formula for electrons
152 set ResolutionFormula { (abs(eta) <= 2.5) * (energy > 0.1 && energy <= 2.0e1) * (energy*0.0225) +
153 (abs(eta) <= 2.5) * (energy > 2.0e1) * sqrt(energy^2*0.007^2 + energy*0.07^2 + 0.35^2) +
154 (abs(eta) > 2.5 && abs(eta) <= 3.0) * sqrt(energy^2*0.007^2 + energy*0.07^2 + 0.35^2) +
155 (abs(eta) > 3.0 && abs(eta) <= 5.0) * sqrt(energy^2*0.107^2 + energy*2.08^2)}
156
157}
158
159###############################
160# Momentum resolution for muons
161###############################
162
163module MomentumSmearing MuonMomentumSmearing {
164 set InputArray MuonTrackingEfficiency/muons
165 set OutputArray muons
166
167 # set ResolutionFormula {resolution formula as a function of eta and pt}
168
169 # resolution formula for muons
170 set ResolutionFormula { (abs(eta) <= 0.5) * (pt > 0.1 && pt <= 5.0) * (0.02) +
171 (abs(eta) <= 0.5) * (pt > 5.0 && pt <= 1.0e2) * (0.015) +
172 (abs(eta) <= 0.5) * (pt > 1.0e2 && pt <= 2.0e2) * (0.03) +
173 (abs(eta) <= 0.5) * (pt > 2.0e2) * (0.05 + pt*1.e-4) +
174 (abs(eta) > 0.5 && abs(eta) <= 1.5) * (pt > 0.1 && pt <= 5.0) * (0.03) +
175 (abs(eta) > 0.5 && abs(eta) <= 1.5) * (pt > 5.0 && pt <= 1.0e2) * (0.02) +
176 (abs(eta) > 0.5 && abs(eta) <= 1.5) * (pt > 1.0e2 && pt <= 2.0e2) * (0.04) +
177 (abs(eta) > 0.5 && abs(eta) <= 1.5) * (pt > 2.0e2) * (0.05 + pt*1.e-4) +
178 (abs(eta) > 1.5 && abs(eta) <= 2.5) * (pt > 0.1 && pt <= 5.0) * (0.04) +
179 (abs(eta) > 1.5 && abs(eta) <= 2.5) * (pt > 5.0 && pt <= 1.0e2) * (0.035) +
180 (abs(eta) > 1.5 && abs(eta) <= 2.5) * (pt > 1.0e2 && pt <= 2.0e2) * (0.05) +
181 (abs(eta) > 1.5 && abs(eta) <= 2.5) * (pt > 2.0e2) * (0.05 + pt*1.e-4)}
182}
183
184##############
185# Track merger
186##############
187
188module Merger TrackMerger {
189# add InputArray InputArray
190 add InputArray ChargedHadronMomentumSmearing/chargedHadrons
191 add InputArray ElectronEnergySmearing/electrons
192 add InputArray MuonMomentumSmearing/muons
193 set OutputArray tracks
194}
195
196#############
197# Calorimeter
198#############
199
200module Calorimeter Calorimeter {
201 set ParticleInputArray ParticlePropagator/stableParticles
202 set TrackInputArray TrackMerger/tracks
203
204 set TowerOutputArray towers
205 set PhotonOutputArray photons
206
207 set EFlowTrackOutputArray eflowTracks
208 set EFlowPhotonOutputArray eflowPhotons
209 set EFlowNeutralHadronOutputArray eflowNeutralHadrons
210
211 set ECalEnergyMin 0.5
212 set HCalEnergyMin 1.0
213
214 set ECalEnergySignificanceMin 1.0
215 set HCalEnergySignificanceMin 1.0
216
217 set SmearTowerCenter true
218
219 set pi [expr {acos(-1)}]
220
221 # lists of the edges of each tower in eta and phi
222 # each list starts with the lower edge of the first tower
223 # the list ends with the higher edged of the last tower
224
225 # 5 degrees towers
226 set PhiBins {}
227 for {set i -36} {$i <= 36} {incr i} {
228 add PhiBins [expr {$i * $pi/36.0}]
229 }
230 foreach eta {-1.566 -1.479 -1.392 -1.305 -1.218 -1.131 -1.044 -0.957 -0.87 -0.783 -0.696 -0.609 -0.522 -0.435 -0.348 -0.261 -0.174 -0.087 0 0.087 0.174 0.261 0.348 0.435 0.522 0.609 0.696 0.783 0.87 0.957 1.044 1.131 1.218 1.305 1.392 1.479 1.566 1.653} {
231 add EtaPhiBins $eta $PhiBins
232 }
233
234 # 10 degrees towers
235 set PhiBins {}
236 for {set i -18} {$i <= 18} {incr i} {
237 add PhiBins [expr {$i * $pi/18.0}]
238 }
239 foreach eta {-4.35 -4.175 -4 -3.825 -3.65 -3.475 -3.3 -3.125 -2.95 -2.868 -2.65 -2.5 -2.322 -2.172 -2.043 -1.93 -1.83 -1.74 -1.653 1.74 1.83 1.93 2.043 2.172 2.322 2.5 2.65 2.868 2.95 3.125 3.3 3.475 3.65 3.825 4 4.175 4.35 4.525} {
240 add EtaPhiBins $eta $PhiBins
241 }
242
243 # 20 degrees towers
244 set PhiBins {}
245 for {set i -9} {$i <= 9} {incr i} {
246 add PhiBins [expr {$i * $pi/9.0}]
247 }
248 foreach eta {-5 -4.7 -4.525 4.7 5} {
249 add EtaPhiBins $eta $PhiBins
250 }
251
252 # default energy fractions {abs(PDG code)} {Fecal Fhcal}
253 add EnergyFraction {0} {0.0 1.0}
254 # energy fractions for e, gamma and pi0
255 add EnergyFraction {11} {1.0 0.0}
256 add EnergyFraction {22} {1.0 0.0}
257 add EnergyFraction {111} {1.0 0.0}
258 # energy fractions for muon, neutrinos and neutralinos
259 add EnergyFraction {12} {0.0 0.0}
260 add EnergyFraction {13} {0.0 0.0}
261 add EnergyFraction {14} {0.0 0.0}
262 add EnergyFraction {16} {0.0 0.0}
263 add EnergyFraction {1000022} {0.0 0.0}
264 add EnergyFraction {1000023} {0.0 0.0}
265 add EnergyFraction {1000025} {0.0 0.0}
266 add EnergyFraction {1000035} {0.0 0.0}
267 add EnergyFraction {1000045} {0.0 0.0}
268 # energy fractions for K0short and Lambda
269 add EnergyFraction {310} {0.3 0.7}
270 add EnergyFraction {3122} {0.3 0.7}
271
272 # set ECalResolutionFormula {resolution formula as a function of eta and energy}
273 set ECalResolutionFormula { (abs(eta) <= 3.0) * sqrt(energy^2*0.007^2 + energy*0.07^2 + 0.35^2) +
274 (abs(eta) > 3.0 && abs(eta) <= 5.0) * sqrt(energy^2*0.107^2 + energy*2.08^2)}
275
276 # set HCalResolutionFormula {resolution formula as a function of eta and energy}
277 set HCalResolutionFormula { (abs(eta) <= 3.0) * sqrt(energy^2*0.050^2 + energy*1.50^2) +
278 (abs(eta) > 3.0 && abs(eta) <= 5.0) * sqrt(energy^2*0.130^2 + energy*2.70^2)}
279}
280
281####################
282# Energy flow merger
283####################
284
285module Merger EFlowMerger {
286# add InputArray InputArray
287 add InputArray Calorimeter/eflowTracks
288 add InputArray Calorimeter/eflowPhotons
289 add InputArray Calorimeter/eflowNeutralHadrons
290 set OutputArray eflow
291}
292
293###################
294# Photon efficiency
295###################
296
297module Efficiency PhotonEfficiency {
298 set InputArray Calorimeter/eflowPhotons
299 set OutputArray photons
300
301 # set EfficiencyFormula {efficiency formula as a function of eta and pt}
302
303 # efficiency formula for photons
304 set EfficiencyFormula { (pt <= 10.0) * (0.00) +
305 (abs(eta) <= 1.5) * (pt > 10.0) * (0.95) +
306 (abs(eta) > 1.5 && abs(eta) <= 2.5) * (pt > 10.0) * (0.85) +
307 (abs(eta) > 2.5) * (0.00)}
308}
309
310
311#####################
312# Electron efficiency
313#####################
314
315module Efficiency ElectronEfficiency {
316 set InputArray ElectronEnergySmearing/electrons
317 set OutputArray electrons
318
319 # set EfficiencyFormula {efficiency formula as a function of eta and pt}
320
321 # efficiency formula for electrons
322 set EfficiencyFormula { (pt <= 10.0) * (0.00) +
323 (abs(eta) <= 1.5) * (pt > 10.0) * (0.95) +
324 (abs(eta) > 1.5 && abs(eta) <= 2.5) * (pt > 10.0) * (0.85) +
325 (abs(eta) > 2.5) * (0.00)}
326}
327
328
329#################
330# Muon efficiency
331#################
332
333module Efficiency MuonEfficiency {
334 set InputArray MuonMomentumSmearing/muons
335 set OutputArray muons
336
337 # set EfficiencyFormula {efficiency as a function of eta and pt}
338
339 # efficiency formula for muons
340 set EfficiencyFormula { (pt <= 10.0) * (0.00) +
341 (abs(eta) <= 1.5) * (pt > 10.0 && pt <= 1.0e3) * (0.95) +
342 (abs(eta) <= 1.5) * (pt > 1.0e3) * (0.95 * exp(0.5 - pt*5.0e-4)) +
343 (abs(eta) > 1.5 && abs(eta) <= 2.4) * (pt > 10.0 && pt <= 1.0e3) * (0.95) +
344 (abs(eta) > 1.5 && abs(eta) <= 2.4) * (pt > 1.0e3) * (0.95 * exp(0.5 - pt*5.0e-4)) +
345 (abs(eta) > 2.4) * (0.00)}
346}
347
348
349###################
350# Missing ET merger
351###################
352
353module Merger MissingET {
354# add InputArray InputArray
355 add InputArray EFlowMerger/eflow
356 set MomentumOutputArray momentum
357}
358
359
360
361#####################
362# Neutrino Filter
363#####################
364
365module PdgCodeFilter NeutrinoFilter {
366
367 set InputArray Delphes/stableParticles
368 set OutputArray filteredParticles
369
370 set PTMin 0.0
371
372 add PdgCode {12}
373 add PdgCode {14}
374 add PdgCode {16}
375 add PdgCode {-12}
376 add PdgCode {-14}
377 add PdgCode {-16}
378
379}
380
381
382#####################
383# MC truth jet finder
384#####################
385
386module FastJetFinder GenJetFinder {
387 set InputArray NeutrinoFilter/filteredParticles
388
389 set OutputArray jets
390
391 # algorithm: 1 CDFJetClu, 2 MidPoint, 3 SIScone, 4 kt, 5 Cambridge/Aachen, 6 antikt
392 set JetAlgorithm 6
393 set ParameterR 0.5
394
395 set JetPTMin 20.0
396}
397
398
399
400
401############
402# Jet finder
403############
404
405module FastJetFinder FastJetFinder {
406# set InputArray Calorimeter/towers
407 set InputArray EFlowMerger/eflow
408
409 set OutputArray jets
410
411 # algorithm: 1 CDFJetClu, 2 MidPoint, 3 SIScone, 4 kt, 5 Cambridge/Aachen, 6 antikt
412 set JetAlgorithm 6
413 set ParameterR 0.5
414
415 set JetPTMin 20.0
416}
417
418##################
419# Jet Energy Scale
420##################
421
422module EnergyScale JetEnergyScale {
423 set InputArray FastJetFinder/jets
424 set OutputArray jets
425
426 # scale formula for jets
427 set ScaleFormula {sqrt( (2.5 - 0.15*(abs(eta)))^2 / pt + 1.0 )}
428}
429
430###########
431# b-tagging
432###########
433
434module BTagging BTagging {
435 set PartonInputArray Delphes/partons
436 set JetInputArray JetEnergyScale/jets
437
438 set BitNumber 0
439
440 set DeltaR 0.5
441
442 set PartonPTMin 1.0
443
444 set PartonEtaMax 2.5
445
446 # add EfficiencyFormula {abs(PDG code)} {efficiency formula as a function of eta and pt}
447 # PDG code = the highest PDG code of a quark or gluon inside DeltaR cone around jet axis
448 # gluon's PDG code has the lowest priority
449
450 # https://twiki.cern.ch/twiki/bin/view/CMSPublic/PhysicsResultsBTV
451 # default efficiency formula (misidentification rate)
452 add EfficiencyFormula {0} {0.001}
453
454 # efficiency formula for c-jets (misidentification rate)
455 add EfficiencyFormula {4} { (pt <= 15.0) * (0.000) +
456 (abs(eta) <= 1.2) * (pt > 15.0) * (0.2*tanh(pt*0.03 - 0.4)) +
457 (abs(eta) > 1.2 && abs(eta) <= 2.5) * (pt > 15.0) * (0.1*tanh(pt*0.03 - 0.4)) +
458 (abs(eta) > 2.5) * (0.000)}
459
460 # efficiency formula for b-jets
461 add EfficiencyFormula {5} { (pt <= 15.0) * (0.000) +
462 (abs(eta) <= 1.2) * (pt > 15.0) * (0.5*tanh(pt*0.03 - 0.4)) +
463 (abs(eta) > 1.2 && abs(eta) <= 2.5) * (pt > 15.0) * (0.4*tanh(pt*0.03 - 0.4)) +
464 (abs(eta) > 2.5) * (0.000)}
465}
466
467module TauTagging TauTagging {
468 set ParticleInputArray Delphes/allParticles
469 set PartonInputArray Delphes/partons
470 set JetInputArray JetEnergyScale/jets
471
472 set DeltaR 0.5
473
474 set TauPTMin 1.0
475
476 set TauEtaMax 2.5
477
478 # add EfficiencyFormula {abs(PDG code)} {efficiency formula as a function of eta and pt}
479
480 # default efficiency formula (misidentification rate)
481 add EfficiencyFormula {0} {0.001}
482 # efficiency formula for tau-jets
483 add EfficiencyFormula {15} {0.4}
484}
485
486
487##################
488# ROOT tree writer
489##################
490
491# tracks, towers and eflow objects are not stored by default in the output.
492# if needed (for jet constituent or other studies), uncomment the relevant
493# "add Branch ..." lines.
494
495module TreeWriter TreeWriter {
496 add Branch Delphes/allParticles Particle GenParticle
497 add Branch GenJetFinder/jets GenJet Jet
498 add Branch TrackMerger/tracks Track Track
499 add Branch Calorimeter/towers Tower Tower
500 add Branch Calorimeter/eflowTracks EFlowTrack Track
501 add Branch Calorimeter/eflowPhotons EFlowPhoton Tower
502 add Branch Calorimeter/eflowNeutralHadrons EFlowNeutralHadron Tower
503 add Branch JetEnergyScale/jets JetMA5 Jet
504 add Branch PhotonEfficiency/photons PhotonMA5 Photon
505 add Branch ElectronEfficiency/electrons ElectronMA5 Electron
506 add Branch MuonEfficiency/muons MuonMA5 Muon
507 add Branch MissingET/momentum MissingET MissingET
508}