35 import modularAnalysis
as ma
40 my_path = b2.create_path()
43 b2.conditions.prepend_globaltag(ma.getAnalysisGlobaltag())
46 ma.inputMdst(environmentType=
'default',
47 filename=b2.find_file(
'B2rhogamma_rho2pipi.root',
'examples',
False),
50 ma.fillParticleList(decayString=
'gamma:highE',
53 ma.fillParticleList(decayString=
'pi+:loose',
54 cut=
'abs(d0) < 0.5 and abs(z0) < 0.5 and pionID > 0.002',
59 ma.reconstructDecay(decayString=
'rho0 -> pi+:loose pi-:loose',
66 ma.reconstructDecay(decayString=
'B0 -> rho0 gamma:highE',
67 cut=
'5.2 < Mbc and abs(deltaE) < 2.0',
71 ma.matchMCTruth(list_name=
'B0',
76 ma.buildRestOfEvent(target_list_name=
'B0',
80 ma.writePi0EtaVeto(particleList=
'B0',
81 decayString=
'B0 -> rho0 ^gamma',
82 workingDirectory=
'./pi0etaveto',
118 roe_path = b2.create_path()
126 deadEndPath = b2.create_path()
131 ma.signalSideParticleFilter(particleList=
'B0',
134 deadEndPath=deadEndPath)
140 ma.fillParticleList(decayString=
'gamma:roe',
141 cut=
'isInRestOfEvent == 1 and E > 0.050',
148 ma.fillSignalSideParticleList(outputListName=
'gamma:sig',
149 decayString=
'B0 -> rho0 ^gamma',
154 ma.reconstructDecay(decayString=
'pi0:veto -> gamma:sig gamma:roe',
155 cut=
'0.080 < M < 0.200',
167 ma.rankByLowest(particleList=
'pi0:veto',
174 ma.variableToSignalSideExtraInfo(particleList=
'pi0:veto', varToExtraInfo={
'M':
'pi0veto'}, path=roe_path)
177 my_path.for_each(
'RestOfEvent',
'RestOfEvents', roe_path)
191 gamma_vars = vc.cluster + \
195 rho_vars = vc.cluster + \
202 b_vars = vc.kinematics + \
205 vu.create_aliases_for_selected(list_of_variables=gamma_vars,
206 decay_string=
'B0 -> rho0 ^gamma') + \
207 vu.create_aliases_for_selected(list_of_variables=rho_vars,
208 decay_string=
'B0 -> ^rho0 gamma') + \
209 vu.create_aliases_for_selected(list_of_variables=rho_vars,
210 decay_string=
'B0 -> [rho0 -> ^pi+ ^pi-] gamma') + \
211 vu.create_aliases(list_of_variables=[
'Pi0_Prob',
'Eta_Prob',
'pi0veto'],
212 wrapper=
'extraInfo({variable})',
216 rootOutputFile =
"B2A306-B02RhoGamma-withPi0EtaVeto.root"
217 ma.variablesToNtuple(decayString=
'B0',
219 filename=rootOutputFile,