Belle II Software  release-08-01-10
skim.py
1 # @cond
2 import basf2 as b2
3 import modularAnalysis as ma
4 import vertex as vx
5 from extravariables import runningOnMC, outputfile
6 import udst
7 
8 gbasf2_dataset = [] # gbasf2 will figure this out
9 
10 mypath = b2.create_path()
11 ma.inputMdstList(filelist=gbasf2_dataset, path=mypath, entrySequences=['0:10'])
12 
13 ma.fillParticleList(decayString='K+:my', cut="dr < 0.5 and abs(dz) < 3 and thetaInCDCAcceptance and kaonID > 0.01", path=mypath)
14 ma.fillParticleList(decayString='pi+:my', cut="dr < 0.5 and abs(dz) < 3 and thetaInCDCAcceptance", path=mypath)
15 
16 ma.reconstructDecay(decayString="D-:K2Pi -> K+:my pi-:my pi-:my", cut="1.5 < M < 2.2", path=mypath)
17 
18 ma.reconstructDecay(decayString='B0:PiD-toK2Pi -> D-:K2Pi pi+:my', cut='5.0 < Mbc and abs(deltaE) < 1.0', path=mypath)
19 vx.treeFit('B0:PiD-toK2Pi', 0, path=mypath, updateAllDaughters=False, ipConstraint=True, massConstraint=[411])
20 ma.applyCuts('B0:PiD-toK2Pi', '5.2 < Mbc and abs(deltaE) < 0.5', path=mypath)
21 
22 # dump in UDST format
24  mypath,
25  skimDecayMode='BtoPiD',
26  skimParticleLists=['B0:PiD-toK2Pi'],
27  mc=runningOnMC,
28  outputFile=outputfile)
29 b2.process(mypath)
30 print(b2.statistics)
31 # @endcond
def add_skimmed_udst_output(path, skimDecayMode, skimParticleLists=None, outputParticleLists=None, additionalBranches=None, outputFile=None, dataDescription=None, mc=True)
Definition: udst.py:99