Belle II Software  release-05-01-25
test2_BtoXgamma.py
1 #!/usr/bin/env/python3
2 # -*-coding: utf-8-*-
3 
4 """
5 <header>
6  <input>12160100.udst.root</input>
7  <output>BtoXgamma_Validation.root</output>
8  <contact>simon.wehle@desy.de</contact>
9 </header>
10 """
11 __author__ = "Simon Wehle, Trevor Shillington"
12 
13 import basf2 as b2
14 import modularAnalysis as ma
15 from stdCharged import stdK, stdPi
16 from stdPhotons import stdPhotons
17 from variables import variables as vm
18 
19 path = b2.Path()
20 
21 histogram_filename = 'BtoXgamma_Validation.root'
22 my_email = 'Trevor Shillington <trshillington@hep.physics.mcgill.ca>'
23 
24 ma.inputMdst('default', '12160100.udst.root', path=path)
25 
26 stdPi('all', path=path)
27 stdK('all', path=path)
28 stdPhotons('cdc', path=path)
29 ma.cutAndCopyList('gamma:sig', 'gamma:cdc', 'clusterNHits > 1.5 and E > 1.5', True, path)
30 
31 ma.reconstructDecay('K*0:sig -> K+:all pi-:all', '0.6 < M < 1.6', path=path)
32 ma.reconstructDecay('B0:sig -> K*0:sig gamma:sig', '5.22 < Mbc < 5.3 and abs(deltaE)< .5', path=path)
33 
34 # the variables that are printed out are: Mbc and deltaE
35 
36 create_validation_histograms(
37  rootfile=histogram_filename,
38  particlelist='B0:sig',
39  variables_1d=[
40  ('Mbc', 100, 5.2, 5.3, 'Signal B0 Mbc', my_email,
41  'Mbc of the signal B0', '', 'Mbc [GeV/c^2]', 'Candidates'),
42  ('deltaE', 100, -1, 1, 'Signal B0 deltaE', my_email,
43  'deltaE of the signal B0', '', 'deltaE [GeV]', 'Candidates')
44  ],
45  variables_2d=[],
46  path=path)
47 
48 
49 b2.process(path)
50 print(b2.statistics)
stdPhotons
Definition: stdPhotons.py:1