21 def addSource(x, angle, slotID, path):
23 Adds a laser source to the path
24 @param x local x coordinate of teh source in the bar frame
25 @param angle vertical tilt of the source
26 @param slotID 1-16, slot number. If it's 0, then all the coorinates are in the BelleII frame
28 path.add_module(
'OpticalGun',
43 angularDistribution=
'uniform'
49 main = b2.create_path()
53 main.add_module(
'EventInfoSetter',
58 main.add_module(
'Gearbox')
61 main.add_module(
'Geometry')
64 for slotId
in range(1, 17):
65 for pos
in [0.9, 5.7, 11.3, 16.9, 22.5, 28.1, 33.7, 39.3, 44.1]:
68 addSource(x, angle, slotId, main)
71 main.add_module(
'FullSim')
74 main.add_module(
'TOPDigitizer')
77 main.add_module(
'RootOutput',
78 outputFileName=
'opticalGun.root',
79 additionalBranchNames=[
'TOPSimPhotons',
'TOPSimHitsToTOPSimPhotons'])
82 main.add_module(
'Progress')