Belle II Software development
phase2_sim_reco_tracking_localDB.py
1#!/usr/bin/env python3
2
3
10
11
15
16import basf2 as b2
17from tracking import add_tracking_reconstruction
18import sys
19
20print('***')
21print('*** Used steering script:')
22with open(sys.argv[0]) as fin:
23 print(fin.read(), end="")
24print('*** end of the script.')
25print('***')
26
27fileIN = sys.argv[1]
28fileOUT = sys.argv[2]
29localdb_dir = sys.argv[3]
30
31main = b2.create_path()
32main.add_module('RootInput', inputFileName=fileIN)
33
34main.add_module('Gearbox')
35main.add_module('Geometry')
36
37# SVD reconstruction
38main.add_module('SVDCoGTimeEstimator')
39main.add_module('SVDSimpleClusterizer', Clusters="SVDClusters")
40
41# add tracking recontruction
42add_tracking_reconstruction(main, components=['SVD'])
43# remove cut on CoG in SpacePointCreator
44for module in main.modules():
45 if module.name() == 'SVDSpacePointCreator':
46 module.param("MinClusterTime", -999)
47
48main.add_module('VXDDedxPID')
49
50main.add_module(
51 'RootOutput',
52 outputFileName=fileOUT,
53 branchNames=[
54 "SVDShaperDigits",
55 "SVDClusters",
56 "SVDRecoDigits",
57 "Tracks",
58 "RecoTracks",
59 "TracksToRecoTracks",
60 "TrackFitResults",
61 "MCParticles",
62 "SVDTrueHits",
63 "TracksToVXDDedxLikelihoods",
64 "TracksToVXDDedxTracks",
65 "VXDDedxLikelihoods",
66 "VXDDedxTracks"])
67b2.print_path(main)
68main.add_module('ProgressBar')
69# Process events
70b2.process(main)
71print(b2.statistics)