6 Skim list building functions for EWP inclusive skims:
7 B->Xgamma, B->Xll, B->Xll (LFV modes)
16 import modularAnalysis
as ma
17 from skimExpertFunctions
import BaseSkim, fancy_skim_header
18 from stdCharged
import stdE, stdMu, stdPi
19 from stdPhotons
import stdPhotons
20 from variables
import variables
22 __liaison__ =
"Trevor Shillington <trshillington@hep.physics.mcgill.ca>"
28 Reconstructed decay modes:
30 * :math:`B^+ \\to X\\gamma` inclusive
34 * :math:`\\text{foxWolframR2} < 0.5` constructed using tracks with
35 :math:`p_T>0.1\\,\\text{GeV}` and clusters with :math:`E>0.1\\,\\text{GeV}`.
36 * :math:`n_{\\text{tracks}} \\geq 3`
40 * :math:`\\text{clusterE9E21}>0.9`
41 * :math:`1.4\\,\\text{GeV}<\\E_{\\gamma}<3.4\\,\\text{GeV}` in CMS frame
44 __authors__ = [
"Trevor Shillington"]
45 __description__ =
":math:`B\\to X\\gamma` inclusive skim."
46 __contact__ = __liaison__
47 __category__ =
"physics, electroweak penguins, radiative decays"
50 stdPi(
"all", path=path)
55 """Build the skim list for :math:`B \\to X\\gamma` decays."""
57 ma.fillParticleList(decayString=
'pi+:BtoXgamma_eventshape', cut=
'pt > 0.1', path=path)
58 ma.fillParticleList(decayString=
'gamma:BtoXgamma_eventshape', cut=
'E > 0.1', path=path)
60 ma.buildEventShape(inputListNames=[
'pi+:BtoXgamma_eventshape',
'gamma:BtoXgamma_eventshape'],
63 harmonicMoments=
False,
69 checkForDuplicates=
False,
73 path = self.
skim_event_cuts(
'foxWolframR2 < 0.5 and nTracks >= 3', path=path)
76 ma.cutAndCopyList(
'gamma:ewp',
'gamma:loose',
'clusterE9E21 > 0.9 and 1.4 < useCMSFrame(E) < 3.4', path=path)
78 ma.reconstructDecay(
'B+:gamma -> gamma:ewp',
'', path=path, allowChargeViolation=
True)
86 Reconstructed decay modes:
88 * :math:`B^+ \\to X e^+ e^-`
89 * :math:`B^+ \\to X e^+ e^+`
90 * :math:`B^+ \\to X \\mu^+ \\mu^-`
91 * :math:`B^+ \\to X \\mu^+ \\mu^+`
96 * :math:`\\text{foxWolframR2} < 0.5` constructed using tracks with
97 :math:`p_T>0.1\\,\\text{GeV}` and clusters with :math:`E>0.1\\,\\text{GeV}`.
98 * :math:`n_{\\text{tracks}} \\geq 3`
102 * :math:`\\text{electronID} > 0.1`
103 * :math:`p > 0.395\\,\\text{GeV}` in lab frame
104 * :math:`dr<0.5 and abs(dz)<2`
108 * :math:`\\text{muonID} > 0.5`
109 * :math:`p > 0.395\\,\\text{GeV}` in lab frame
110 * :math:`dr<0.5 and abs(dz)<2`
113 Cut on dilepton energy:
115 * :math:`E_{\\ell\\ell}>1.5\\,\\text{GeV}` in CMS frame.
118 __authors__ = [
"Trevor Shillington"]
119 __description__ =
":math:`B\\to X\\ell\\ell` (no LFV modes) inclusive skim."
120 __contact__ = __liaison__
121 __category__ =
"physics, electroweak penguins, radiative decays"
124 stdE(
"all", path=path)
125 stdMu(
"all", path=path)
126 stdPi(
"all", path=path)
130 """Build the skim list for :math:`B \\to X\\ell\\ell` non-LFV decays."""
133 ma.fillParticleList(decayString=
'pi+:BtoXll_eventshape', cut=
'pt > 0.1', path=path)
134 ma.fillParticleList(decayString=
'gamma:BtoXll_eventshape', cut=
'E > 0.1', path=path)
136 ma.buildEventShape(inputListNames=[
'pi+:BtoXll_eventshape',
'gamma:BtoXll_eventshape'],
139 harmonicMoments=
False,
145 checkForDuplicates=
False,
149 path = self.
skim_event_cuts(
'foxWolframR2 < 0.5 and nTracks >= 3', path=path)
153 fairTrack =
'dr < 0.5 and abs(dz) < 2'
155 ma.cutAndCopyList(
'e+:ewp',
'e+:all',
'p > 0.395 and electronID > 0.1 and ' + fairTrack, path=path)
156 ma.cutAndCopyList(
'mu+:ewp',
'mu+:all',
'p > 0.395 and muonID > 0.5 and ' + fairTrack, path=path)
159 E_dilep_cut =
'formula(daughter(0, useCMSFrame(E))+daughter(1, useCMSFrame(E))) > 1.5'
163 ma.reconstructDecay(
'B+:ch1 -> e+:ewp e-:ewp', E_dilep_cut, dmID=1, path=path, allowChargeViolation=
True)
164 ma.reconstructDecay(
'B+:ch2 -> mu+:ewp mu-:ewp', E_dilep_cut, dmID=2, path=path, allowChargeViolation=
True)
166 ma.reconstructDecay(
'B+:ch3 -> e+:ewp e+:ewp', E_dilep_cut, dmID=3, path=path, allowChargeViolation=
True)
167 ma.reconstructDecay(
'B+:ch4 -> mu+:ewp mu+:ewp', E_dilep_cut, dmID=4, path=path, allowChargeViolation=
True)
169 ma.copyLists(
'B+:xll', [
'B+:ch1',
'B+:ch2',
'B+:ch3',
'B+:ch4'], path=path)
177 Reconstructed decay modes:
179 * :math:`B^+ \\to X e^+ \\mu^-`
180 * :math:`B^+ \\to X \\mu^+ e^-`
181 * :math:`B^+ \\to X e^+ \\mu^+`
186 * :math:`\\text{foxWolframR2} < 0.5` constructed using tracks with
187 :math:`p_T>0.1\\,\\text{GeV}` and clusters with :math:`E>0.1\\,\\text{GeV}`.
188 * :math:`n_{\\text{tracks}} \\geq 3`
192 * :math:`\\text{electronID} > 0.1`
193 * :math:`p > 0.395\\,\\text{GeV}` in lab frame
194 * :math:`dr<0.5 and abs(dz)<2`
198 * :math:`\\text{muonID} > 0.5`
199 * :math:`p > 0.395\\,\\text{GeV}` in lab frame
200 * :math:`dr<0.5 and abs(dz)<2`
203 Cut on dilepton energy:
205 * :math:`E_{\\ell\\ell}>1.5\\,\\text{GeV}` in CMS frame.
208 __authors__ = [
"Trevor Shillington"]
209 __description__ =
":math:`B\\to X\\ell\\ell` (LFV modes only) inclusive skim."
210 __contact__ = __liaison__
211 __category__ =
"physics, electroweak penguins, radiative decays"
214 stdE(
"all", path=path)
215 stdMu(
"all", path=path)
216 stdPi(
"all", path=path)
220 """Build the skim list for :math:`B \\to X\\ell\\ell` LFV decays."""
222 ma.cutAndCopyList(
'pi+:BtoXllLFV_eventshape',
'pi+:all',
'pt> 0.1', path=path)
223 ma.cutAndCopyList(
'gamma:BtoXllLFV_eventshape',
'gamma:all',
'E > 0.1', path=path)
226 ma.buildEventShape(inputListNames=[
'pi+:BtoXllLFV_eventshape',
'gamma:BtoXllLFV_eventshape'],
229 harmonicMoments=
False,
235 checkForDuplicates=
False,
239 path = self.
skim_event_cuts(
'foxWolframR2 < 0.5 and nTracks >= 3', path=path)
243 fairTrack =
'dr < 0.5 and abs(dz) < 2'
245 ma.cutAndCopyList(
'e+:ewp',
'e+:all',
'p > 0.395 and electronID > 0.1 and ' + fairTrack, path=path)
246 ma.cutAndCopyList(
'mu+:ewp',
'mu+:all',
'p > 0.395 and muonID > 0.5 and ' + fairTrack, path=path)
249 E_dilep_cut =
'formula(daughter(0, useCMSFrame(E))+daughter(1, useCMSFrame(E))) > 1.5'
253 ma.reconstructDecay(
'B+:lfvch1 -> e+:ewp mu-:ewp', E_dilep_cut, dmID=1, path=path, allowChargeViolation=
True)
254 ma.reconstructDecay(
'B+:lfvch2 -> mu+:ewp e-:ewp', E_dilep_cut, dmID=2, path=path, allowChargeViolation=
True)
256 ma.reconstructDecay(
'B+:lfvch3 -> e+:ewp mu+:ewp', E_dilep_cut, dmID=3, path=path, allowChargeViolation=
True)
258 ma.copyLists(
'B+:lfv', [
'B+:lfvch1',
'B+:lfvch2',
'B+:lfvch3'], path=path)
265 Reconstructed decay modes:
267 * :math:`B^+ \\to K\\nu\\nu` inclusive
271 * :math:`thetaInCDCAcceptance`
272 * :math:`dr<0.5 and abs(dz)<3.0`
275 * :math:`3 < nCleanedTracks < 11`
278 * :math:`track cleanup + event cleanup + nPXDHits > 0`
280 * :math:`kaonID>0.01`
283 * mva_identifier: MVAFastBDT_InclusiveBplusToKplusNuNu_Skim
284 * Global Tag: mva_inclusiveBplusToKplusNuNu
285 * :math:`mva\\_identifier > 0.5`
288 __authors__ = [
"Cyrille Praz"]
289 __description__ =
"Inclusive skim for :math:`B\\to K\\nu\\nu` analysis"
290 __contact__ = __liaison__
291 __category__ =
"physics, electroweak penguins, radiative decays"
293 NoisyModules = [
"ParticleCombiner"]
298 track_cleanup =
'pt > 0.1'
299 track_cleanup +=
' and thetaInCDCAcceptance'
300 track_cleanup +=
' and abs(dz) < 3.0'
301 track_cleanup +=
' and dr < 0.5'
304 event_cleanup =
'nCleanedTracks({}) > 3'.format(track_cleanup)
305 event_cleanup +=
' and nCleanedTracks({}) < 11'.format(track_cleanup)
308 total_cleanup = track_cleanup +
' and ' + event_cleanup +
' and ' +
'nPXDHits>0'
309 ma.fillParticleList(
'K+:inclusiveBplusToKplusNuNu', cut=total_cleanup, path=path)
310 ma.rankByHighest(
'K+:inclusiveBplusToKplusNuNu',
'pt', path=path)
311 ma.applyCuts(
'K+:inclusiveBplusToKplusNuNu',
'extraInfo(pt_rank)==1', path=path)
312 ma.applyCuts(
'K+:inclusiveBplusToKplusNuNu',
'kaonID>1e-2', path=path)
313 ma.reconstructDecay(decayString=
'B+:inclusiveBplusToKplusNuNu -> K+:inclusiveBplusToKplusNuNu', cut=
'', path=path)
316 ma.buildEventShape(inputListNames=[],
317 default_cleanup=
True,
322 harmonicMoments=
True,
326 checkForDuplicates=
False,
330 mva_identifier =
'MVAFastBDT_InclusiveBplusToKplusNuNu_Skim'
331 b2.conditions.append_globaltag(
'mva_inclusiveBplusToKplusNuNu')
332 path.add_module(
'MVAExpert', listNames=[
'B+:inclusiveBplusToKplusNuNu'],
333 extraInfoName=mva_identifier, identifier=mva_identifier)
334 variables.addAlias(mva_identifier,
'extraInfo({})'.format(mva_identifier))
335 ma.applyCuts(
'B+:inclusiveBplusToKplusNuNu', mva_identifier+
'>0.5', path=path)
337 self.
SkimLists = [
'B+:inclusiveBplusToKplusNuNu']