ATLAS Offline Software
jobOptions_FlukaBeamHalo2.py
Go to the documentation of this file.
1 import AthenaCommon.AtlasUnixGeneratorJob
2 
3 
4 from AthenaCommon.AlgSequence import AlgSequence
5 topSequence = AlgSequence()
6 
7 
8 from AthenaCommon.AppMgr import ServiceMgr
9 
10 
11 from AthenaCommon.AppMgr import theApp
12 
13 theApp.EvtMax = 402719 # All of the events
14 
15 
16 
17 ServiceMgr.MessageSvc.OutputLevel = INFO
18 
19 from BeamHaloGenerator.BeamHaloGeneratorConf import BeamHaloGeneratorAlg
20 BeamHaloGenerator = BeamHaloGeneratorAlg()
21 BeamHaloGenerator.inputType="FLUKA-VT"
22 BeamHaloGenerator.inputFile="/pcdisk/pcgeneve01/wbell/castor_stage/atlasgroupdisk/proj-bembk/talanov/tcth.4l1.b1_lowb.coll_hor_b1"
23 BeamHaloGenerator.interfacePlane = 23000.0
24 BeamHaloGenerator.flipProbability = 0.0
25 BeamHaloGenerator.randomStream = "BeamHalo"
26 BeamHaloGenerator.doMonitoringPlots = True
27 
28 # The generator settings determine if the event is accepted.
29 # * If the allowedPdgId list is not given all particles are accepted.
30 # * Limits are in the form of (lower limit, upper limit)
31 # * If a limit is not given it is disabled.
32 # * If a limit value is -1 then it is disabled.
33 # * All limits are checked against |value|
34 # * r = sqrt(x^2 + y^2)
35 BeamHaloGenerator.generatorSettings = [#
36  "shape cylinder", # require trajectory to pass through shape
37 # "allowedPdgId 2212 -2212 2112 -2112", # Just p and n
38 # "pxLimits 0. 0.", # lower and upper limits. The upper limit is optional
39 # "pyLimits 0. 0.", # lower and upper limits. The upper limit is optional
40  "pzLimits 50000.0", # above 50 GeV
41 # "energyLimits 0. 0.", # lower and upper limits. The upper limit is optional
42 # "xLimits 0. 0.", # lower and upper limits. The upper limit is optional
43 # "yLimits 0. 0.", # lower and upper limits. The upper limit is optional
44  "zLimits -4000. 4000.", # required for shape=cylinder
45 # "ptLimits 0. 0.", # lower and upper limits. The upper limit is optional
46 # "phiLimits 0. 0.", # lower and upper limits. The upper limit is optional
47 # "etaLimits 0. 0.", # lower and upper limits. The upper limit is optional
48  "rLimits 650. 1950."] # required for shape=cylinder
49 # "weightLimits 0. 0."] # lower and upper limits. The upper limit is optional
50 
51 topSequence += BeamHaloGenerator
52 print BeamHaloGenerator
53 
54 # Required when monitoring plots are enabled.
55 theApp.HistogramPersistency = "ROOT"
56 
57 if not hasattr(ServiceMgr, 'THistSvc'):
58  from GaudiSvc.GaudiSvcConf import THistSvc
59  ServiceMgr += THistSvc()
60 
61 ServiceMgr.THistSvc.Output += [ "BeamHalo DATAFILE='BeamHalo.root' OPT='RECREATE'"]
62 
63 # For debugging
64 from TruthExamples.TruthExamplesConf import DumpMC
65 topSequence += DumpMC()
66 
67 from AthenaPoolCnvSvc.WriteAthenaPool import AthenaPoolOutputStream
68 Stream1 = AthenaPoolOutputStream( "StreamEVGEN" )
69 Stream1.OutputFile = "evgen.pool.root"
70 Stream1.ItemList += [ 'EventInfo#*', 'McEventCollection#*' ]
71 
72 
python.AlgSequence.AlgSequence
AlgSequence
Definition: PhysicsAnalysis/D3PDTools/AnaAlgorithm/python/AlgSequence.py:7
Lb2Lll.THistSvc
THistSvc
Definition: Lb2Lll.py:216
python.CreateOutputStreams.AthenaPoolOutputStream
def AthenaPoolOutputStream
backward compat
Definition: CreateOutputStreams.py:144