ATLAS Offline Software
Loading...
Searching...
No Matches
jobOptions_MarsBeamHalo.py
Go to the documentation of this file.
1import AthenaCommon.AtlasUnixGeneratorJob
2
3
4from AthenaCommon.AlgSequence import AlgSequence
5topSequence = AlgSequence()
6
7
8from AthenaCommon.AppMgr import ServiceMgr
9
10
11from AthenaCommon.AppMgr import theApp
12
13theApp.EvtMax = 150000
14
15
16
17ServiceMgr.MessageSvc.OutputLevel = INFO
18
19from BeamHaloGenerator.BeamHaloGeneratorConf import BeamHaloGeneratorAlg
20BeamHaloGenerator = BeamHaloGeneratorAlg()
21BeamHaloGenerator.inputType="MARS-NM"
22BeamHaloGenerator.inputFile="bgi-b2l1.1"
23BeamHaloGenerator.generateShowers = False;
24BeamHaloGenerator.interfacePlane = -20850.0
25BeamHaloGenerator.flipProbability = 0.0
26BeamHaloGenerator.randomStream = "BeamHalo"
27
28BeamHaloGenerator.doMonitoringPlots = True;
29
30# The generator settings determine if the event is accepted.
31# * If the allowedPdgId list is not given all particles are accepted.
32# * Limits are in the form of (lower limit, upper limit)
33# * If a limit is not given it is disabled.
34# * If a limit value is -1 then it is disabled.
35# * All limits are checked against |value|
36# * r = sqrt(x^2 + y^2)
37BeamHaloGenerator.generatorSettings = [#
38 "shape cylinder", # require trajectory to pass through shape
39# "allowedPdgId 2212 -2212 2112 -2112", # Just p and n
40# "pxLimits 0. 0.", # lower and upper limits. The upper limit is optional
41# "pyLimits 0. 0.", # lower and upper limits. The upper limit is optional
42 "pzLimits 50000.0", # above 50 GeV
43# "energyLimits 0. 0.", # lower and upper limits. The upper limit is optional
44# "xLimits 0. 0.", # lower and upper limits. The upper limit is optional
45# "yLimits 0. 0.", # lower and upper limits. The upper limit is optional
46 "zLimits -4000. 4000.", # required for shape=cylinder
47# "ptLimits 0. 0.", # lower and upper limits. The upper limit is optional
48# "phiLimits 0. 0.", # lower and upper limits. The upper limit is optional
49# "etaLimits 0. 0.", # lower and upper limits. The upper limit is optional
50 "rLimits 650. 1950."] # required for shape=cylinder
51# "weightLimits 0. 0."] # lower and upper limits. The upper limit is optional
52
53topSequence += BeamHaloGenerator
54print BeamHaloGenerator
55
56# Required when monitoring plots are enabled.
57theApp.HistogramPersistency = "ROOT"
58
59if not hasattr(ServiceMgr, 'THistSvc'):
60 from GaudiSvc.GaudiSvcConf import THistSvc
61 ServiceMgr += THistSvc()
62
63ServiceMgr.THistSvc.Output += [ "BeamHalo DATAFILE='BeamHalo.root' OPT='RECREATE'"]
64
65# For debugging
66from TruthExamples.TruthExamplesConf import DumpMC
67topSequence += DumpMC()
68
69from AthenaPoolCnvSvc.WriteAthenaPool import AthenaPoolOutputStream
70Stream1 = AthenaPoolOutputStream( "StreamEVGEN" )
71Stream1.OutputFile = "evgen.pool.root"
72Stream1.ItemList += [ 'EventInfo#*', 'McEventCollection#*' ]
73
74
A GenModule algorithm to produce beam halo HepMC records from input ASCII files produced with MARS or...
Dump MC event record.
Definition DumpMC.h:12