14 from simulation
import add_simulation
15 from reconstruction
import add_reconstruction
17 basf2.set_log_level(basf2.LogLevel.WARNING)
19 eventinfosetter = basf2.register_module(
'EventInfoSetter')
20 eventinfosetter.param(
'evtNumList', [1000])
21 eventinfosetter.param(
'runList', [1])
22 eventinfosetter.param(
'expList', [0])
24 pGun = basf2.register_module(
'ParticleGun')
26 'pdgCodes': [13, -13],
28 'momentumGeneration':
'uniform',
29 'momentumParams': [1., 3.],
30 'thetaGeneration':
'uniform',
31 'thetaParams': [17., 150.],
32 'phiGeneration':
'uniform',
33 'phiParams': [0, 360],
34 'vertexGeneration':
'uniform',
35 'xVertexParams': [0.0, 0.0],
36 'yVertexParams': [0.0, 0.0],
37 'zVertexParams': [0.0, 0.0],
40 pGun.param(param_pGun)
42 output = basf2.register_module(
'RootOutput')
43 output.param(
'outputFileName',
'ParticleGunMuons.root')
46 main = basf2.create_path()
47 main.add_module(eventinfosetter)
50 add_reconstruction(main)
51 main.add_module(output)
52 main.add_module(
'Progress')
55 print(basf2.statistics)