Fork me on GitHub

source: git/cards/CMS_PhaseII/CMS_PhaseII_Substructure_0PU.tcl@ 5a697dde

ImprovedOutputFile Timing dual_readout llp
Last change on this file since 5a697dde was 29fe90c, checked in by Michele Selvaggi <michele.selvaggi@…>, 8 years ago

put correct path for PU file

  • Property mode set to 100644
File size: 32.7 KB
Line 
1#
2# Phase II - No Pile-Up
3#
4# Main authors: Michele Selvaggi (UCL)
5#
6# Released on:
7#
8# Version: v01
9#
10#
11#######################################
12# Order of execution of various modules
13#######################################
14
15set ExecutionPath {
16
17 PileUpMerger
18 ParticlePropagator
19
20 ChargedHadronTrackingEfficiency
21 ElectronTrackingEfficiency
22 MuonTrackingEfficiency
23
24 ChargedHadronMomentumSmearing
25 ElectronEnergySmearing
26 MuonMomentumSmearing
27
28 TrackMerger
29
30 ECal
31 HCal
32
33 PhotonEnergySmearing
34 ElectronFilter
35 TrackPileUpSubtractor
36
37 TowerMerger
38 NeutralEFlowMerger
39 EFlowMergerAllTracks
40 EFlowMerger
41
42 LeptonFilterNoLep
43 LeptonFilterLep
44 RunPUPPIBase
45 RunPUPPI
46
47 PhotonFilter
48
49 PhotonIsolation
50 PhotonEfficiency
51
52 ElectronIsolation
53 ElectronEfficiency
54
55 MuonIsolation
56 MuonLooseIdEfficiency
57 MuonTightIdEfficiency
58
59 NeutrinoFilter
60
61 MissingET
62 PuppiMissingET
63 GenMissingET
64 GenPileUpMissingET
65
66 GenJetFinder
67 GenJetFinderAK8
68 FastJetFinder
69 FastJetFinderAK8
70 FastJetFinderPUPPI
71 FastJetFinderPUPPIAK8
72
73 ScalarHT
74
75 JetEnergyScale
76 JetEnergyScaleAK8
77 JetEnergyScalePUPPI
78 JetEnergyScalePUPPIAK8
79
80 JetFlavorAssociation
81 JetFlavorAssociationAK8
82 JetFlavorAssociationPUPPI
83 JetFlavorAssociationPUPPIAK8
84
85 BTaggingLoose
86 BTaggingMedium
87 BTaggingTight
88 BTaggingLooseAK8
89 BTaggingMediumAK8
90 BTaggingTightAK8
91 BTaggingLoosePUPPI
92 BTaggingMediumPUPPI
93 BTaggingTightPUPPI
94 BTaggingLoosePUPPIAK8
95 BTaggingMediumPUPPIAK8
96 BTaggingTightPUPPIAK8
97
98 TauTagging
99
100 GenParticleFilter
101
102 TreeWriter
103}
104
105###############
106# PileUp Merger
107###############
108
109module PileUpMerger PileUpMerger {
110 set InputArray Delphes/stableParticles
111
112 set ParticleOutputArray stableParticles
113 set VertexOutputArray vertices
114
115 # pre-generated minbias input file
116 set PileUpFile ../eos/cms/store/group/upgrade/delphes/PhaseII/MinBias_100k.pileup
117 #set PileUpFile MinBias_100k.pileup
118
119 # average expected pile up
120 set MeanPileUp 0
121
122 # maximum spread in the beam direction in m
123 set ZVertexSpread 0
124
125 # maximum spread in time in s
126 set TVertexSpread 0
127
128 # vertex smearing formula f(z,t) (z,t need to be respectively given in m,s) - {exp(-(t^2/160e-12^2/2))*exp(-(z^2/0.053^2/2))}
129 set VertexDistributionFormula 1
130
131}
132
133
134#################################
135# Propagate particles in cylinder
136#################################
137
138module ParticlePropagator ParticlePropagator {
139 #set InputArray PileUpMerger/stableParticles
140 set InputArray Delphes/stableParticles
141
142 set OutputArray stableParticles
143 set ChargedHadronOutputArray chargedHadrons
144 set ElectronOutputArray electrons
145 set MuonOutputArray muons
146
147 # radius of the magnetic field coverage, in m
148 set Radius 1.29
149 # half-length of the magnetic field coverage, in m
150 set HalfLength 3.0
151
152 # magnetic field
153 set Bz 3.8
154}
155
156
157####################################
158# Charged hadron tracking efficiency
159####################################
160
161module Efficiency ChargedHadronTrackingEfficiency {
162 ## particles after propagation
163 set InputArray ParticlePropagator/chargedHadrons
164 set OutputArray chargedHadrons
165 # tracking efficiency formula for charged hadrons
166 set EfficiencyFormula {
167 (pt <= 0.2) * (0.00) + \
168 (abs(eta) <= 1.2) * (pt > 0.2 && pt <= 1.0) * (pt * 0.96) + \
169 (abs(eta) <= 1.2) * (pt > 1.0) * (0.97) + \
170 (abs(eta) > 1.2 && abs(eta) <= 2.5) * (pt > 0.2 && pt <= 1.0) * (pt*0.85) + \
171 (abs(eta) > 1.2 && abs(eta) <= 2.5) * (pt > 1.0) * (0.87) + \
172 (abs(eta) > 2.5 && abs(eta) <= 4.0) * (pt > 0.2 && pt <= 1.0) * (pt*0.8) + \
173 (abs(eta) > 2.5 && abs(eta) <= 4.0) * (pt > 1.0) * (0.82) + \
174 (abs(eta) > 4.0) * (0.00)
175 }
176}
177
178
179#####################################
180# Electron tracking efficiency - ID
181####################################
182
183module Efficiency ElectronTrackingEfficiency {
184 set InputArray ParticlePropagator/electrons
185 set OutputArray electrons
186 # tracking efficiency formula for electrons
187 set EfficiencyFormula {
188 (pt <= 0.2) * (0.00) + \
189 (abs(eta) <= 1.2) * (pt > 0.2 && pt <= 1.0) * (pt * 0.96) + \
190 (abs(eta) <= 1.2) * (pt > 1.0) * (0.97) + \
191 (abs(eta) > 1.2 && abs(eta) <= 2.5) * (pt > 0.2 && pt <= 1.0) * (pt*0.85) + \
192 (abs(eta) > 1.2 && abs(eta) <= 2.5) * (pt > 1.0 && pt <= 10.0) * (0.82+pt*0.01) + \
193 (abs(eta) > 1.2 && abs(eta) <= 2.5) * (pt > 10.0) * (0.90) + \
194 (abs(eta) > 2.5 && abs(eta) <= 4.0) * (pt > 0.2 && pt <= 1.0) * (pt*0.8) + \
195 (abs(eta) > 2.5 && abs(eta) <= 4.0) * (pt > 1.0 && pt <= 10.0) * (0.8+pt*0.01) + \
196 (abs(eta) > 2.5 && abs(eta) <= 4.0) * (pt > 10.0) * (0.85) + \
197 (abs(eta) > 4.0) * (0.00)
198
199 }
200}
201
202##########################
203# Muon tracking efficiency
204##########################
205
206module Efficiency MuonTrackingEfficiency {
207 set InputArray ParticlePropagator/muons
208 set OutputArray muons
209 # tracking efficiency formula for muons
210 set EfficiencyFormula {
211 (pt <= 0.2) * (0.00) + \
212 (abs(eta) <= 1.2) * (pt > 0.2 && pt <= 1.0) * (pt * 1.00) + \
213 (abs(eta) <= 1.2) * (pt > 1.0) * (1.00) + \
214 (abs(eta) > 1.2 && abs(eta) <= 2.8) * (pt > 0.2 && pt <= 1.0) * (pt*1.00) + \
215 (abs(eta) > 1.2 && abs(eta) <= 2.8) * (pt > 1.0) * (1.00) + \
216 (abs(eta) > 2.8 && abs(eta) <= 4.0) * (pt > 0.2 && pt <= 1.0) * (pt*0.95) + \
217 (abs(eta) > 2.8 && abs(eta) <= 4.0) * (pt > 1.0) * (0.95) + \
218 (abs(eta) > 4.0) * (0.00)
219
220 }
221}
222
223
224########################################
225# Momentum resolution for charged tracks
226########################################
227
228module MomentumSmearing ChargedHadronMomentumSmearing {
229 ## hadrons after having applied the tracking efficiency
230 set InputArray ChargedHadronTrackingEfficiency/chargedHadrons
231 set OutputArray chargedHadrons
232 # resolution formula for charged hadrons ,
233
234 # from http://mersi.web.cern.ch/mersi/layouts/.private/Baseline_tilted_200_Pixel_1_1_1/index.html
235 source trackMomentumResolution.tcl
236}
237
238#################################
239# Energy resolution for electrons
240#################################
241
242module EnergySmearing ElectronEnergySmearing {
243 set InputArray ElectronTrackingEfficiency/electrons
244 set OutputArray electrons
245
246 # set ResolutionFormula {resolution formula as a function of eta and energy}
247
248 # resolution formula for electrons
249
250 # taking something flat in energy for now, ECAL will take over at high energy anyway.
251 # inferred from hep-ex/1306.2016 and 1502.02701
252 set ResolutionFormula {
253
254 (abs(eta) <= 1.5) * (energy*0.028) +
255 (abs(eta) > 1.5 && abs(eta) <= 1.75) * (energy*0.037) +
256 (abs(eta) > 1.75 && abs(eta) <= 2.15) * (energy*0.038) +
257 (abs(eta) > 2.15 && abs(eta) <= 3.00) * (energy*0.044) +
258 (abs(eta) > 3.00 && abs(eta) <= 4.00) * (energy*0.10)}
259
260}
261
262###############################
263# Momentum resolution for muons
264###############################
265
266module MomentumSmearing MuonMomentumSmearing {
267 set InputArray MuonTrackingEfficiency/muons
268 set OutputArray muons
269 # resolution formula for muons
270
271 # up to |eta| < 2.8 take measurement from tracking + muon chambers
272 # for |eta| > 2.8 and pT < 5.0 take measurement from tracking alone taken from
273 # http://mersi.web.cern.ch/mersi/layouts/.private/Baseline_tilted_200_Pixel_1_1_1/index.html
274 source muonMomentumResolution.tcl
275}
276
277
278
279
280##############
281# Track merger
282##############
283
284module Merger TrackMerger {
285# add InputArray InputArray
286 add InputArray ChargedHadronMomentumSmearing/chargedHadrons
287 add InputArray ElectronEnergySmearing/electrons
288 add InputArray MuonMomentumSmearing/muons
289 set OutputArray tracks
290}
291
292#############
293# ECAL
294#############
295
296module SimpleCalorimeter ECal {
297 set ParticleInputArray ParticlePropagator/stableParticles
298 set TrackInputArray TrackMerger/tracks
299
300 set TowerOutputArray ecalTowers
301 set EFlowTrackOutputArray eflowTracks
302 set EFlowTowerOutputArray eflowPhotons
303
304 set IsEcal true
305
306 set EnergyMin 0.5
307 set EnergySignificanceMin 1.0
308
309 set SmearTowerCenter true
310
311 set pi [expr {acos(-1)}]
312
313 # lists of the edges of each tower in eta and phi
314 # each list starts with the lower edge of the first tower
315 # the list ends with the higher edged of the last tower
316
317 # assume 0.02 x 0.02 resolution in eta,phi in the barrel |eta| < 1.5
318
319 set PhiBins {}
320 for {set i -180} {$i <= 180} {incr i} {
321 add PhiBins [expr {$i * $pi/180.0}]
322 }
323
324 # 0.02 unit in eta up to eta = 1.5 (barrel)
325 for {set i -85} {$i <= 86} {incr i} {
326 set eta [expr {$i * 0.0174}]
327 add EtaPhiBins $eta $PhiBins
328 }
329
330 # assume 0.02 x 0.02 resolution in eta,phi in the endcaps 1.5 < |eta| < 3.0 (HGCAL- ECAL)
331
332 set PhiBins {}
333 for {set i -180} {$i <= 180} {incr i} {
334 add PhiBins [expr {$i * $pi/180.0}]
335 }
336
337 # 0.02 unit in eta up to eta = 3
338 for {set i 1} {$i <= 84} {incr i} {
339 set eta [expr { -2.958 + $i * 0.0174}]
340 add EtaPhiBins $eta $PhiBins
341 }
342
343 for {set i 1} {$i <= 84} {incr i} {
344 set eta [expr { 1.4964 + $i * 0.0174}]
345 add EtaPhiBins $eta $PhiBins
346 }
347
348 # take present CMS granularity for HF
349
350 # 0.175 x (0.175 - 0.35) resolution in eta,phi in the HF 3.0 < |eta| < 5.0
351 set PhiBins {}
352 for {set i -18} {$i <= 18} {incr i} {
353 add PhiBins [expr {$i * $pi/18.0}]
354 }
355
356 foreach eta {-5 -4.7 -4.525 -4.35 -4.175 -4 -3.825 -3.65 -3.475 -3.3 -3.125 -2.958 3.125 3.3 3.475 3.65 3.825 4 4.175 4.35 4.525 4.7 5} {
357 add EtaPhiBins $eta $PhiBins
358 }
359
360
361 add EnergyFraction {0} {0.0}
362 # energy fractions for e, gamma and pi0
363 add EnergyFraction {11} {1.0}
364 add EnergyFraction {22} {1.0}
365 add EnergyFraction {111} {1.0}
366 # energy fractions for muon, neutrinos and neutralinos
367 add EnergyFraction {12} {0.0}
368 add EnergyFraction {13} {0.0}
369 add EnergyFraction {14} {0.0}
370 add EnergyFraction {16} {0.0}
371 add EnergyFraction {1000022} {0.0}
372 add EnergyFraction {1000023} {0.0}
373 add EnergyFraction {1000025} {0.0}
374 add EnergyFraction {1000035} {0.0}
375 add EnergyFraction {1000045} {0.0}
376 # energy fractions for K0short and Lambda
377 add EnergyFraction {310} {0.3}
378 add EnergyFraction {3122} {0.3}
379
380 # set ResolutionFormula {resolution formula as a function of eta and energy}
381
382 # for the ECAL barrel (|eta| < 1.5), see hep-ex/1306.2016 and 1502.02701
383 # for the endcaps (1.5 < |eta| < 3.0), we take HGCAL see LHCC-P-008, Fig. 3.39, p.117
384
385 set ResolutionFormula { (abs(eta) <= 1.50) * sqrt(energy^2*0.009^2 + energy*0.12^2 + 0.45^2) +
386 (abs(eta) > 1.50 && abs(eta) <= 1.75) * sqrt(energy^2*0.006^2 + energy*0.20^2) + \
387 (abs(eta) > 1.75 && abs(eta) <= 2.15) * sqrt(energy^2*0.007^2 + energy*0.21^2) + \
388 (abs(eta) > 2.15 && abs(eta) <= 3.00) * sqrt(energy^2*0.008^2 + energy*0.24^2) + \
389 (abs(eta) >= 3.0 && abs(eta) <= 5.0) * sqrt(energy^2*0.08^2 + energy*1.98^2)}
390
391}
392
393#############
394# HCAL
395#############
396
397module SimpleCalorimeter HCal {
398 set ParticleInputArray ParticlePropagator/stableParticles
399 set TrackInputArray ECal/eflowTracks
400
401 set TowerOutputArray hcalTowers
402 set EFlowTrackOutputArray eflowTracks
403 set EFlowTowerOutputArray eflowNeutralHadrons
404
405 set IsEcal false
406
407 set EnergyMin 1.0
408 set EnergySignificanceMin 1.0
409
410 set SmearTowerCenter true
411
412 set pi [expr {acos(-1)}]
413
414 # lists of the edges of each tower in eta and phi
415 # each list starts with the lower edge of the first tower
416 # the list ends with the higher edged of the last tower
417
418 # assume 0.087 x 0.087 resolution in eta,phi in the barrel |eta| < 1.5
419
420 set PhiBins {}
421 for {set i -36} {$i <= 36} {incr i} {
422 add PhiBins [expr {$i * $pi/36.0}]
423 }
424 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.65} {
425 add EtaPhiBins $eta $PhiBins
426 }
427
428 # assume 0.02 x 0.02 resolution in eta,phi in the endcaps 1.5 < |eta| < 3.0 (HGCAL- HCAL)
429
430 set PhiBins {}
431 for {set i -180} {$i <= 180} {incr i} {
432 add PhiBins [expr {$i * $pi/180.0}]
433 }
434
435 # 0.02 unit in eta up to eta = 3
436 for {set i 1} {$i <= 84} {incr i} {
437 set eta [expr { -2.958 + $i * 0.0174}]
438 add EtaPhiBins $eta $PhiBins
439 }
440
441 for {set i 1} {$i <= 84} {incr i} {
442 set eta [expr { 1.4964 + $i * 0.0174}]
443 add EtaPhiBins $eta $PhiBins
444 }
445
446 # take present CMS granularity for HF
447
448 # 0.175 x (0.175 - 0.35) resolution in eta,phi in the HF 3.0 < |eta| < 5.0
449 set PhiBins {}
450 for {set i -18} {$i <= 18} {incr i} {
451 add PhiBins [expr {$i * $pi/18.0}]
452 }
453
454 foreach eta {-5 -4.7 -4.525 -4.35 -4.175 -4 -3.825 -3.65 -3.475 -3.3 -3.125 -2.958 3.125 3.3 3.475 3.65 3.825 4 4.175 4.35 4.525 4.7 5} {
455 add EtaPhiBins $eta $PhiBins
456 }
457
458
459 # default energy fractions {abs(PDG code)} {Fecal Fhcal}
460 add EnergyFraction {0} {1.0}
461 # energy fractions for e, gamma and pi0
462 add EnergyFraction {11} {0.0}
463 add EnergyFraction {22} {0.0}
464 add EnergyFraction {111} {0.0}
465 # energy fractions for muon, neutrinos and neutralinos
466 add EnergyFraction {12} {0.0}
467 add EnergyFraction {13} {0.0}
468 add EnergyFraction {14} {0.0}
469 add EnergyFraction {16} {0.0}
470 add EnergyFraction {1000022} {0.0}
471 add EnergyFraction {1000023} {0.0}
472 add EnergyFraction {1000025} {0.0}
473 add EnergyFraction {1000035} {0.0}
474 add EnergyFraction {1000045} {0.0}
475 # energy fractions for K0short and Lambda
476 add EnergyFraction {310} {0.7}
477 add EnergyFraction {3122} {0.7}
478
479# set ResolutionFormula {resolution formula as a function of eta and energy}
480 set ResolutionFormula { (abs(eta) <= 1.5) * sqrt(energy^2*0.05^2 + energy*1.00^2) + \
481 (abs(eta) > 1.5 && abs(eta) <= 3.0) * sqrt(energy^2*0.05^2 + energy*1.00^2) + \
482 (abs(eta) > 3.0 && abs(eta) <= 5.0) * sqrt(energy^2*0.11^2 + energy*2.80^2)}
483
484}
485
486#################################
487# Energy resolution for electrons
488#################################
489
490module EnergySmearing PhotonEnergySmearing {
491 set InputArray ECal/eflowPhotons
492 set OutputArray eflowPhotons
493
494 # adding 1% extra photon smearing
495 set ResolutionFormula {energy*0.01}
496
497}
498
499
500
501#################
502# Electron filter
503#################
504
505module PdgCodeFilter ElectronFilter {
506 set InputArray HCal/eflowTracks
507 set OutputArray electrons
508 set Invert true
509 add PdgCode {11}
510 add PdgCode {-11}
511}
512
513
514##########################
515# Track pile-up subtractor
516##########################
517
518module TrackPileUpSubtractor TrackPileUpSubtractor {
519# add InputArray InputArray OutputArray
520 add InputArray HCal/eflowTracks eflowTracks
521 add InputArray ElectronFilter/electrons electrons
522 add InputArray MuonMomentumSmearing/muons muons
523
524 set VertexInputArray PileUpMerger/vertices
525 # assume perfect pile-up subtraction for tracks with |z| > fZVertexResolution
526 # Z vertex resolution in m
527 set ZVertexResolution 0.0001
528}
529
530
531###################################################
532# Tower Merger (in case not using e-flow algorithm)
533###################################################
534
535module Merger TowerMerger {
536# add InputArray InputArray
537 add InputArray ECal/ecalTowers
538 add InputArray HCal/hcalTowers
539 set OutputArray towers
540}
541
542
543####################
544# Neutral eflow erger
545####################
546
547module Merger NeutralEFlowMerger {
548# add InputArray InputArray
549 add InputArray PhotonEnergySmearing/eflowPhotons
550 add InputArray HCal/eflowNeutralHadrons
551 set OutputArray eflowTowers
552}
553
554
555####################
556# Energy flow merger
557####################
558
559module Merger EFlowMerger {
560# add InputArray InputArray
561 add InputArray HCal/eflowTracks
562 add InputArray PhotonEnergySmearing/eflowPhotons
563 add InputArray HCal/eflowNeutralHadrons
564 set OutputArray eflow
565}
566
567##################################
568# Energy flow merger (all tracks)
569##################################
570
571module Merger EFlowMergerAllTracks {
572# add InputArray InputArray
573 add InputArray TrackMerger/tracks
574 add InputArray PhotonEnergySmearing/eflowPhotons
575 add InputArray HCal/eflowNeutralHadrons
576 set OutputArray eflow
577}
578
579#########################################
580### Run the puppi code (to be tuned) ###
581#########################################
582
583module PdgCodeFilter LeptonFilterNoLep {
584 set InputArray HCal/eflowTracks
585 set OutputArray eflowTracksNoLeptons
586 set Invert false
587 add PdgCode {13}
588 add PdgCode {-13}
589 add PdgCode {11}
590 add PdgCode {-11}
591}
592
593module PdgCodeFilter LeptonFilterLep {
594 set InputArray HCal/eflowTracks
595 set OutputArray eflowTracksLeptons
596 set Invert true
597 add PdgCode {11}
598 add PdgCode {-11}
599 add PdgCode {13}
600 add PdgCode {-13}
601}
602
603module RunPUPPI RunPUPPIBase {
604 ## input information
605 set TrackInputArray LeptonFilterNoLep/eflowTracksNoLeptons
606 set NeutralInputArray NeutralEFlowMerger/eflowTowers
607 set PVInputArray PileUpMerger/vertices
608 set MinPuppiWeight 0.05
609 set UseExp false
610 set UseNoLep false
611
612 ## define puppi algorithm parameters (more than one for the same eta region is possible)
613 add EtaMinBin 0.0 1.5 4.0
614 add EtaMaxBin 1.5 4.0 10.0
615 add PtMinBin 0.0 0.0 0.0
616 add ConeSizeBin 0.2 0.2 0.2
617 add RMSPtMinBin 0.1 0.5 0.5
618 add RMSScaleFactorBin 1.0 1.0 1.0
619 add NeutralMinEBin 0.2 0.2 0.5
620 add NeutralPtSlope 0.006 0.013 0.067
621 add ApplyCHS true true true
622 add UseCharged true true false
623 add ApplyLowPUCorr true true true
624 add MetricId 5 5 5
625 add CombId 0 0 0
626
627 ## output name
628 set OutputArray PuppiParticles
629 set OutputArrayTracks puppiTracks
630 set OutputArrayNeutrals puppiNeutrals
631}
632
633module Merger RunPUPPI {
634 add InputArray RunPUPPIBase/PuppiParticles
635 add InputArray LeptonFilterLep/eflowTracksLeptons
636 set OutputArray PuppiParticles
637}
638
639###################
640# Missing ET merger
641###################
642
643module Merger MissingET {
644# add InputArray InputArray
645# add InputArray RunPUPPI/PuppiParticles
646 add InputArray EFlowMerger/eflow
647 set MomentumOutputArray momentum
648}
649
650module Merger PuppiMissingET {
651 #add InputArray InputArray
652 add InputArray RunPUPPI/PuppiParticles
653 #add InputArray EFlowMerger/eflow
654 set MomentumOutputArray momentum
655}
656
657###################
658# Ger PileUp Missing ET
659###################
660
661module Merger GenPileUpMissingET {
662# add InputArray InputArray
663# add InputArray RunPUPPI/PuppiParticles
664 add InputArray ParticlePropagator/stableParticles
665 set MomentumOutputArray momentum
666}
667
668##################
669# Scalar HT merger
670##################
671
672module Merger ScalarHT {
673# add InputArray InputArray
674 add InputArray RunPUPPI/PuppiParticles
675 set EnergyOutputArray energy
676}
677
678#################
679# Neutrino Filter
680#################
681
682module PdgCodeFilter NeutrinoFilter {
683
684 set InputArray Delphes/stableParticles
685 set OutputArray filteredParticles
686
687 set PTMin 0.0
688
689 add PdgCode {12}
690 add PdgCode {14}
691 add PdgCode {16}
692 add PdgCode {-12}
693 add PdgCode {-14}
694 add PdgCode {-16}
695
696}
697
698
699#####################
700# MC truth jet finder
701#####################
702
703module FastJetFinder GenJetFinder {
704 set InputArray NeutrinoFilter/filteredParticles
705
706 set OutputArray jets
707
708 # algorithm: 1 CDFJetClu, 2 MidPoint, 3 SIScone, 4 kt, 5 Cambridge/Aachen, 6 antikt
709 set JetAlgorithm 6
710 set ParameterR 0.4
711
712 set JetPTMin 15.0
713}
714
715module FastJetFinder GenJetFinderAK8 {
716 set InputArray NeutrinoFilter/filteredParticles
717
718 set OutputArray jetsAK8
719
720 # algorithm: 1 CDFJetClu, 2 MidPoint, 3 SIScone, 4 kt, 5 Cambridge/Aachen, 6 antikt
721 set JetAlgorithm 6
722 set ParameterR 0.8
723
724 set JetPTMin 200.0
725}
726
727#########################
728# Gen Missing ET merger
729########################
730
731module Merger GenMissingET {
732
733# add InputArray InputArray
734 add InputArray NeutrinoFilter/filteredParticles
735 set MomentumOutputArray momentum
736}
737
738
739
740#########################
741# Gen Missing ET merger
742########################
743
744module Merger GenMissingET {
745
746# add InputArray InputArray
747 add InputArray NeutrinoFilter/filteredParticles
748 set MomentumOutputArray momentum
749}
750
751
752
753############
754# Jet finder
755############
756
757module FastJetFinder FastJetFinder {
758# set InputArray TowerMerger/towers
759 set InputArray EFlowMerger/eflow
760
761 set OutputArray jets
762
763 # algorithm: 1 CDFJetClu, 2 MidPoint, 3 SIScone, 4 kt, 5 Cambridge/Aachen, 6 antikt
764 set JetAlgorithm 6
765 set ParameterR 0.4
766
767 set JetPTMin 15.0
768}
769
770#module Class Name
771module FastJetFinder FastJetFinderAK8 {
772# set InputArray TowerMerger/towers
773 set InputArray EFlowMerger/eflow
774
775 set OutputArray jets
776
777 # algorithm: 1 CDFJetClu, 2 MidPoint, 3 SIScone, 4 kt, 5 Cambridge/Aachen, 6 antikt
778 set JetAlgorithm 6
779 set ParameterR 0.8
780
781 set ComputeNsubjettiness 1
782 set Beta 1.0
783 set AxisMode 4
784
785 set ComputeTrimming 1
786 set RTrim 0.2
787 set PtFracTrim 0.05
788
789 set ComputePruning 1
790 set ZcutPrun 0.1
791 set RcutPrun 0.5
792 set RPrun 0.8
793
794 set ComputeSoftDrop 1
795 set BetaSoftDrop 0.0
796 set SymmetryCutSoftDrop 0.1
797 set R0SoftDrop 0.8
798
799 set JetPTMin 200.0
800}
801
802module FastJetFinder FastJetFinderPUPPI {
803# set InputArray TowerMerger/towers
804 set InputArray RunPUPPI/PuppiParticles
805
806 set OutputArray jets
807
808 # algorithm: 1 CDFJetClu, 2 MidPoint, 3 SIScone, 4 kt, 5 Cambridge/Aachen, 6 antikt
809 set JetAlgorithm 6
810 set ParameterR 0.4
811
812 set JetPTMin 15.0
813}
814
815
816module FastJetFinder FastJetFinderPUPPIAK8 {
817# set InputArray TowerMerger/towers
818 set InputArray RunPUPPI/PuppiParticles
819
820 set OutputArray jets
821
822 set JetAlgorithm 6
823 set ParameterR 0.8
824
825 set ComputeNsubjettiness 1
826 set Beta 1.0
827 set AxisMode 4
828
829 set ComputeTrimming 1
830 set RTrim 0.2
831 set PtFracTrim 0.05
832
833 set ComputePruning 1
834 set ZcutPrun 0.1
835 set RcutPrun 0.5
836 set RPrun 0.8
837
838 set ComputeSoftDrop 1
839 set BetaSoftDrop 0.0
840 set SymmetryCutSoftDrop 0.1
841 set R0SoftDrop 0.8
842
843 set JetPTMin 200.0
844}
845
846##################
847# Jet Energy Scale
848##################
849
850module EnergyScale JetEnergyScale {
851 set InputArray FastJetFinder/jets
852 set OutputArray jets
853
854 # scale formula for jets
855 set ScaleFormula {1.00}
856}
857
858module EnergyScale JetEnergyScaleAK8 {
859 set InputArray FastJetFinderAK8/jets
860 set OutputArray jets
861
862 # scale formula for jets
863 set ScaleFormula {1.00}
864}
865
866module EnergyScale JetEnergyScalePUPPI {
867 set InputArray FastJetFinderPUPPI/jets
868 set OutputArray jets
869
870 # scale formula for jets
871 set ScaleFormula {1.00}
872}
873
874module EnergyScale JetEnergyScalePUPPIAK8 {
875 set InputArray FastJetFinderPUPPIAK8/jets
876 set OutputArray jets
877
878 # scale formula for jets
879 set ScaleFormula {1.00}
880}
881
882#################
883# Photon filter
884#################
885
886module PdgCodeFilter PhotonFilter {
887 set InputArray PhotonEnergySmearing/eflowPhotons
888 set OutputArray photons
889 set Invert true
890 set PTMin 5.0
891 add PdgCode {22}
892}
893
894
895####################
896# Photon isolation #
897####################
898
899module Isolation PhotonIsolation {
900
901 # particle for which calculate the isolation
902 set CandidateInputArray PhotonFilter/photons
903
904 # isolation collection
905 set IsolationInputArray RunPUPPI/PuppiParticles
906
907 # output array
908 set OutputArray photons
909
910 # veto isolation cand. based on proximity to input cand.
911 set DeltaRMin 0.01
912 set UseMiniCone true
913
914 # isolation cone
915 set DeltaRMax 0.3
916
917 # minimum pT
918 set PTMin 1.0
919
920 # iso ratio to cut
921 set PTRatioMax 9999.
922
923}
924
925
926
927#####################
928# Photon efficiency #
929#####################
930
931module Efficiency PhotonEfficiency {
932
933 ## input particles
934 set InputArray PhotonIsolation/photons
935 ## output particles
936 set OutputArray photons
937 # set EfficiencyFormula {efficiency formula as a function of eta and pt}
938 # efficiency formula for photons
939 set EfficiencyFormula { (pt <= 10.0) * (0.00) + \
940 (abs(eta) <= 1.5) * (pt > 10.0) * (0.9635) + \
941 (abs(eta) > 1.5 && abs(eta) <= 4.0) * (pt > 10.0) * (0.9624) + \
942 (abs(eta) > 4.0) * (0.00)}
943
944}
945
946
947######################
948# Electron isolation #
949######################
950
951module Isolation ElectronIsolation {
952
953 set CandidateInputArray ElectronFilter/electrons
954
955 # isolation collection
956 set IsolationInputArray RunPUPPI/PuppiParticles
957 #set IsolationInputArray EFlowMerger/eflow
958
959 set OutputArray electrons
960
961 set DeltaRMax 0.3
962 set PTMin 1.0
963 set PTRatioMax 9999.
964
965}
966
967
968
969#######################
970# Electron efficiency #
971#######################
972
973module Efficiency ElectronEfficiency {
974
975 set InputArray ElectronIsolation/electrons
976 set OutputArray electrons
977
978 # set EfficiencyFormula {efficiency formula as a function of eta and pt}
979 # efficiency formula for electrons
980 set EfficiencyFormula {
981 (pt <= 4.0) * (0.00) + \
982 (abs(eta) <= 1.45 ) * (pt > 4.0 && pt <= 6.0) * (0.50) + \
983 (abs(eta) <= 1.45 ) * (pt > 6.0 && pt <= 8.0) * (0.70) + \
984 (abs(eta) <= 1.45 ) * (pt > 8.0 && pt <= 10.0) * (0.85) + \
985 (abs(eta) <= 1.45 ) * (pt > 10.0 && pt <= 30.0) * (0.94) + \
986 (abs(eta) <= 1.45 ) * (pt > 30.0 && pt <= 50.0) * (0.97) + \
987 (abs(eta) <= 1.45 ) * (pt > 50.0 && pt <= 70.0) * (0.98) + \
988 (abs(eta) <= 1.45 ) * (pt > 70.0 ) * (1.0) + \
989 (abs(eta) > 1.45 && abs(eta) <= 1.55) * (pt > 4.0 && pt <= 10.0) * (0.35) + \
990 (abs(eta) > 1.45 && abs(eta) <= 1.55) * (pt > 10.0 && pt <= 30.0) * (0.40) + \
991 (abs(eta) > 1.45 && abs(eta) <= 1.55) * (pt > 30.0 && pt <= 70.0) * (0.45) + \
992 (abs(eta) > 1.45 && abs(eta) <= 1.55) * (pt > 70.0 ) * (0.55) + \
993 (abs(eta) >= 1.55 && abs(eta) <= 2.0 ) * (pt > 4.0 && pt <= 10.0) * (0.75) + \
994 (abs(eta) >= 1.55 && abs(eta) <= 2.0 ) * (pt > 10.0 && pt <= 30.0) * (0.85) + \
995 (abs(eta) >= 1.55 && abs(eta) <= 2.0 ) * (pt > 30.0 && pt <= 50.0) * (0.95) + \
996 (abs(eta) >= 1.55 && abs(eta) <= 2.0 ) * (pt > 50.0 && pt <= 70.0) * (0.95) + \
997 (abs(eta) >= 1.55 && abs(eta) <= 2.0 ) * (pt > 70.0 ) * (1.0) + \
998 (abs(eta) >= 2.0 && abs(eta) <= 2.5 ) * (pt > 4.0 && pt <= 10.0) * (0.65) + \
999 (abs(eta) >= 2.0 && abs(eta) <= 2.5 ) * (pt > 10.0 && pt <= 30.0) * (0.75) + \
1000 (abs(eta) >= 2.0 && abs(eta) <= 2.5 ) * (pt > 30.0 && pt <= 50.0) * (0.90) + \
1001 (abs(eta) >= 2.0 && abs(eta) <= 2.5 ) * (pt > 50.0 && pt <= 70.0) * (0.90) + \
1002 (abs(eta) >= 2.0 && abs(eta) <= 2.5 ) * (pt > 70.0 ) * (0.90) + \
1003 (abs(eta) > 2.5 && abs(eta) <= 4.0 ) * (pt > 4.0 && pt <= 10.0) * (0.65) + \
1004 (abs(eta) > 2.5 && abs(eta) <= 4.0 ) * (pt > 10.0 && pt <= 30.0) * (0.75) + \
1005 (abs(eta) > 2.5 && abs(eta) <= 4.0 ) * (pt > 30.0 && pt <= 50.0) * (0.90) + \
1006 (abs(eta) > 2.5 && abs(eta) <= 4.0 ) * (pt > 50.0 && pt <= 70.0) * (0.90) + \
1007 (abs(eta) > 2.5 && abs(eta) <= 4.0 ) * (pt > 70.0 ) * (0.90) + \
1008 (abs(eta) > 4.0) * (0.00)
1009
1010 }
1011}
1012
1013##################
1014# Muon isolation #
1015##################
1016
1017module Isolation MuonIsolation {
1018 set CandidateInputArray MuonMomentumSmearing/muons
1019
1020 # isolation collection
1021 set IsolationInputArray RunPUPPI/PuppiParticles
1022
1023 set OutputArray muons
1024
1025 set DeltaRMax 0.3
1026 set PTMin 1.0
1027 set PTRatioMax 9999.
1028
1029}
1030
1031
1032##################
1033# Muon Loose Id #
1034##################
1035
1036module Efficiency MuonLooseIdEfficiency {
1037 set InputArray MuonIsolation/muons
1038 set OutputArray muons
1039 # tracking + LooseID efficiency formula for muons
1040 source muonLooseId.tcl
1041
1042}
1043
1044
1045##################
1046# Muon Tight Id #
1047##################
1048
1049module Efficiency MuonTightIdEfficiency {
1050 set InputArray MuonIsolation/muons
1051 set OutputArray muons
1052 # tracking + TightID efficiency formula for muons
1053 source muonTightId.tcl
1054}
1055
1056
1057
1058########################
1059# Jet Flavor Association
1060########################
1061
1062module JetFlavorAssociation JetFlavorAssociation {
1063
1064 set PartonInputArray Delphes/partons
1065 set ParticleInputArray Delphes/allParticles
1066 set ParticleLHEFInputArray Delphes/allParticlesLHEF
1067 set JetInputArray JetEnergyScale/jets
1068
1069 set DeltaR 0.5
1070 set PartonPTMin 10.0
1071 set PartonEtaMax 4.0
1072
1073}
1074
1075module JetFlavorAssociation JetFlavorAssociationAK8 {
1076
1077 set PartonInputArray Delphes/partons
1078 set ParticleInputArray Delphes/allParticles
1079 set ParticleLHEFInputArray Delphes/allParticlesLHEF
1080 set JetInputArray JetEnergyScaleAK8/jets
1081
1082 set DeltaR 0.8
1083 set PartonPTMin 100.0
1084 set PartonEtaMax 4.0
1085
1086}
1087
1088module JetFlavorAssociation JetFlavorAssociationPUPPI {
1089
1090 set PartonInputArray Delphes/partons
1091 set ParticleInputArray Delphes/allParticles
1092 set ParticleLHEFInputArray Delphes/allParticlesLHEF
1093 set JetInputArray JetEnergyScalePUPPI/jets
1094
1095 set DeltaR 0.5
1096 set PartonPTMin 10.0
1097 set PartonEtaMax 4.0
1098
1099}
1100
1101module JetFlavorAssociation JetFlavorAssociationPUPPIAK8 {
1102
1103 set PartonInputArray Delphes/partons
1104 set ParticleInputArray Delphes/allParticles
1105 set ParticleLHEFInputArray Delphes/allParticlesLHEF
1106 set JetInputArray JetEnergyScalePUPPIAK8/jets
1107
1108 set DeltaR 0.8
1109 set PartonPTMin 100.0
1110 set PartonEtaMax 4.0
1111
1112}
1113
1114
1115#############
1116# b-tagging #
1117#############
1118module BTagging BTaggingLoose {
1119
1120 set JetInputArray JetEnergyScale/jets
1121
1122 set BitNumber 0
1123
1124 source btagLoose.tcl
1125}
1126
1127module BTagging BTaggingLooseAK8 {
1128
1129 set JetInputArray JetEnergyScaleAK8/jets
1130
1131 set BitNumber 0
1132
1133 source btagLoose.tcl
1134}
1135
1136module BTagging BTaggingLoosePUPPI {
1137
1138 set JetInputArray JetEnergyScalePUPPI/jets
1139
1140 set BitNumber 0
1141
1142 source btagLoose.tcl
1143}
1144
1145module BTagging BTaggingLoosePUPPIAK8 {
1146
1147 set JetInputArray JetEnergyScalePUPPIAK8/jets
1148
1149 set BitNumber 0
1150
1151 source btagLoose.tcl
1152}
1153
1154
1155#############
1156# b-tagging #
1157#############
1158module BTagging BTaggingMedium {
1159
1160 set JetInputArray JetEnergyScale/jets
1161
1162 set BitNumber 1
1163
1164 source btagMedium.tcl
1165}
1166
1167module BTagging BTaggingMediumAK8 {
1168
1169 set JetInputArray JetEnergyScaleAK8/jets
1170
1171 set BitNumber 1
1172
1173 source btagMedium.tcl
1174}
1175
1176module BTagging BTaggingMediumPUPPI {
1177
1178 set JetInputArray JetEnergyScalePUPPI/jets
1179
1180 set BitNumber 1
1181
1182 source btagMedium.tcl
1183}
1184
1185module BTagging BTaggingMediumPUPPIAK8 {
1186
1187 set JetInputArray JetEnergyScalePUPPIAK8/jets
1188
1189 set BitNumber 1
1190
1191 source btagMedium.tcl
1192}
1193
1194
1195
1196#############
1197# b-tagging #
1198#############
1199module BTagging BTaggingTight {
1200
1201 set JetInputArray JetEnergyScale/jets
1202
1203 set BitNumber 2
1204
1205 source btagTight.tcl
1206}
1207
1208module BTagging BTaggingTightAK8 {
1209
1210 set JetInputArray JetEnergyScaleAK8/jets
1211
1212 set BitNumber 2
1213
1214 source btagTight.tcl
1215}
1216
1217module BTagging BTaggingTightPUPPI {
1218
1219 set JetInputArray JetEnergyScalePUPPI/jets
1220
1221 set BitNumber 2
1222
1223 source btagTight.tcl
1224}
1225
1226module BTagging BTaggingTightPUPPIAK8 {
1227
1228 set JetInputArray JetEnergyScalePUPPIAK8/jets
1229
1230 set BitNumber 2
1231
1232 source btagTight.tcl
1233}
1234
1235#############
1236# tau-tagging
1237#############
1238
1239
1240module TauTagging TauTagging {
1241 set ParticleInputArray Delphes/allParticles
1242 set PartonInputArray Delphes/partons
1243 set JetInputArray JetEnergyScale/jets
1244
1245 set DeltaR 0.5
1246
1247 set TauPTMin 20.0
1248
1249 set TauEtaMax 2.3
1250
1251 # add EfficiencyFormula {abs(PDG code)} {efficiency formula as a function of eta and pt}
1252
1253 add EfficiencyFormula {0} { (abs(eta) < 2.3) * ((( -0.00621816+0.00130097*pt-2.19642e-5*pt^2+1.49393e-7*pt^3-4.58972e-10*pt^4+5.27983e-13*pt^5 )) * (pt<250) + 0.0032*(pt>250)) + \
1254 (abs(eta) > 2.3) * (0.000)
1255 }
1256 add EfficiencyFormula {15} { (abs(eta) < 2.3) * 0.97*0.77*( (0.32 + 0.01*pt - 0.000054*pt*pt )*(pt<100)+0.78*(pt>100) ) + \
1257 (abs(eta) > 2.3) * (0.000)
1258 }
1259}
1260
1261
1262###############################################################################################################
1263# StatusPidFilter: this module removes all generated particles except electrons, muons, taus, and status == 3 #
1264###############################################################################################################
1265
1266module StatusPidFilter GenParticleFilter {
1267
1268 set InputArray Delphes/allParticles
1269 set OutputArray filteredParticles
1270 set PTMin 5.0
1271
1272}
1273
1274
1275##################
1276# ROOT tree writer
1277##################
1278
1279module TreeWriter TreeWriter {
1280# add Branch InputArray BranchName BranchClass
1281 add Branch GenParticleFilter/filteredParticles Particle GenParticle
1282 add Branch PileUpMerger/vertices Vertex Vertex
1283
1284 add Branch GenJetFinder/jets GenJet Jet
1285 add Branch GenJetFinderAK8/jetsAK8 GenJetAK8 Jet
1286 add Branch GenMissingET/momentum GenMissingET MissingET
1287
1288# add Branch HCal/eflowTracks EFlowTrack Track
1289# add Branch ECal/eflowPhotons EFlowPhoton Tower
1290# add Branch HCal/eflowNeutralHadrons EFlowNeutralHadron Tower
1291
1292 add Branch PhotonEfficiency/photons Photon Photon
1293 add Branch ElectronEfficiency/electrons Electron Electron
1294 add Branch MuonLooseIdEfficiency/muons MuonLoose Muon
1295 add Branch MuonTightIdEfficiency/muons MuonTight Muon
1296
1297 add Branch JetEnergyScale/jets Jet Jet
1298# add Branch FatJetFinder/jets FatJet Jet
1299 add Branch JetEnergyScalePUPPI/jets JetPUPPI Jet
1300 add Branch JetEnergyScaleAK8/jets JetAK8 Jet
1301 add Branch JetEnergyScalePUPPIAK8/jets JetPUPPIAK8 Jet
1302
1303 add Branch MissingET/momentum MissingET MissingET
1304 add Branch PuppiMissingET/momentum PuppiMissingET MissingET
1305 add Branch GenPileUpMissingET/momentum GenPileUpMissingET MissingET
1306 add Branch ScalarHT/energy ScalarHT ScalarHT
1307}
Note: See TracBrowser for help on using the repository browser.