CMS 3D CMS Logo

customiseL1Ntuple.py
Go to the documentation of this file.
1 import FWCore.ParameterSet.Config as cms
2 import os
3 
4 ##############################################################################
5 # customisations for L1 ntuple generation
6 #
7 # Add new customisations to this file!
8 #
9 # Example usage :
10 # cmsDriver.py testNtuple -s NONE --customise=L1Trigger/L1TNtuples/customiseL1Ntuple.customiseL1NtupleAOD --conditions=auto:run2_mc_50ns --filein='/store/relval/CMSSW_7_5_0_pre1/RelValProdTTbar_13/AODSIM/MCRUN2_74_V7-v1/00000/48159643-5EE3-E411-818F-0025905A48F0.root' -n 100
11 #
12 ##############################################################################
13 
14 def L1NtupleTFileOut(process):
15 
16  process.TFileService = cms.Service(
17  "TFileService",
18  fileName = cms.string('L1Ntuple.root')
19  )
20 
21  return process
22 
24 
25 
26 def L1NtupleAOD(process):
27 
28  L1NtupleTFileOut(process)
29  L1NtupleCustomReco(process)
30 
31  process.load('L1Trigger.L1TNtuples.L1NtupleAOD_cff')
32  process.l1ntupleaod = cms.Path(
33  process.L1NtupleAOD
34  )
35 
36  process.schedule.append(process.l1ntupleaod)
37 
38  return process
39 
40 
41 def L1NtupleAOD_MC(process):
42 
43  L1NtupleAOD(process)
44 
45  process.l1JetRecoTree.jecToken = cms.untracked.InputTag("ak4PFCHSL1FastL2L3Corrector")
46 
47  return process
48 
49 
50 
51 def L1NtupleRAW(process):
52 
53  L1NtupleTFileOut(process)
54 
55  process.load('L1Trigger.L1TNtuples.L1NtupleRAW_cff')
56  process.l1ntupleraw = cms.Path(
57  process.L1NtupleRAW
58  )
59 
60  process.schedule.append(process.l1ntupleraw)
61 
62  # for 5 BX of candidates in L1Extra
63  if "gctDigis" in process.producers:
64  process.gctDigis.numberOfGctSamplesToUnpack = cms.uint32(5)
65 
66  if "l1extraParticles" in process.producers:
67  process.l1extraParticles.centralBxOnly = cms.bool(False)
68 
69  return process
70 
71 
72 
73 def L1NtupleEMU(process):
74 
75  L1NtupleTFileOut(process)
76 
77  process.load('L1Trigger.L1TNtuples.L1NtupleEMU_cff')
78  process.l1ntupleemu = cms.Path(
79  process.L1NtupleEMU
80  )
81 
82  process.schedule.append(process.l1ntupleemu)
83 
84  return process
85 
86 def L1NtupleEMULegacy(process):
87 
88  L1NtupleTFileOut(process)
89 
90  process.load('L1Trigger.L1TNtuples.L1NtupleEMULegacy_cff')
91  process.l1ntupleemulegacy = cms.Path(
92  process.L1NtupleEMULegacy
93  )
94 
95  process.schedule.append(process.l1ntupleemulegacy)
96 
97  return process
98 
99 
100 def L1NtupleGEN(process):
101 
102  L1NtupleTFileOut(process)
103 
104  process.load('L1Trigger.L1TNtuples.L1NtupleGEN_cff')
105  process.l1ntuplegen = cms.Path(
106  process.L1NtupleGEN
107  )
108 
109  process.schedule.append(process.l1ntuplegen)
110 
111  return process
112 
113 
114 def L1NtupleRAWEMU(process):
115 
116  L1NtupleRAW(process)
117  L1NtupleEMU(process)
118 
119  return process
120 
121 def L1NtupleRAWEMULegacy(process):
122 
123  L1NtupleRAW(process)
124  L1NtupleEMU(process)
125  L1NtupleEMULegacy(process)
126 
127  return process
128 
129 
130 
131 def L1NtupleAODRAW(process):
132 
133  L1NtupleRAW(process)
134  L1NtupleAOD(process)
135 
136  return process
137 
139 
140  L1NtupleRAW(process)
141  L1NtupleEMU(process)
142  L1NtupleEMULegacy(process)
143  L1NtupleAOD(process)
144 
145  return process
146 
147 
148 def L1NtupleAODRAWEMU(process):
149 
150  L1NtupleRAW(process)
151  L1NtupleEMU(process)
152  L1NtupleAOD(process)
153 
154  return process
155 
156 def L1NtupleAODEMU(process):
157 
158  L1NtupleEMU(process)
159  L1NtupleAOD(process)
160 
161  return process
162 
163 def L1NtupleAODEMU_MC(process):
164 
165  L1NtupleEMU(process)
166  L1NtupleAOD_MC(process)
167 
168  return process
169 
170 
171 def L1NtupleRAWEMUGEN_MC(process):
172 
173  L1NtupleRAW(process)
174  L1NtupleEMU(process)
175  L1NtupleGEN(process)
176 
177  return process
178 
179 def L1NtupleAODEMUGEN_MC(process):
180 
181  L1NtupleEMU(process)
182  L1NtupleAOD_MC(process)
183  L1NtupleGEN(process)
184 
185  return process
186 
187 
189 
190  L1NtupleTFileOut(process)
191 
192  process.load('L1Trigger.L1TNtuples.L1NtupleEMU_cff')
193  process.L1NtupleEMU = cms.Sequence( process.l1CaloTowerEmuTree+process.l1UpgradeEmuTree+process.l1UpgradeTfMuonEmuTree )
194  process.l1ntuplesim = cms.Path(
195  process.L1NtupleEMU
196  )
197  process.schedule.append(process.l1ntuplesim)
198 
199  return process
200 
201 
def L1NtupleAODEMU_MC(process)
def L1NtupleRAWEMULegacy(process)
def L1NtupleEMULegacy(process)
def L1NtupleAOD(process)
def L1NtupleAODRAW(process)
def L1NtupleEMUNoEventTree(process)
def L1NtupleEMU(process)
def L1NtupleAODEMUGEN_MC(process)
def L1NtupleAOD_MC(process)
def L1NtupleAODRAWEMULegacy(process)
def L1NtupleGEN(process)
def L1NtupleRAWEMU(process)
def L1NtupleRAWEMUGEN_MC(process)
def L1NtupleTFileOut(process)
customisations for L1 ntuple generation
def L1NtupleAODEMU(process)
def L1NtupleAODRAWEMU(process)
def L1NtupleRAW(process)