CMS 3D CMS Logo

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Modules Pages
NeutronBGforMuons_cff.py
Go to the documentation of this file.
1 import FWCore.ParameterSet.Config as cms
2 
3 def neutronBG(process):
4 
5  # common fragment allowing to simulate neutron background in muon system
6 
7  if hasattr(process,'g4SimHits'):
8  # time window 10 second
9  TimeCut = cms.double(10000000000.0)
10  process.common_maximum_time.MaxTrackTime = TimeCut
11  process.common_maximum_time.DeadRegions = cms.vstring()
12  # Physics List XS
13  process.g4SimHits.Physics.type = cms.string('SimG4Core/Physics/FTFP_BERT_XS_EML')
14  process.g4SimHits.Physics.CutsOnProton = cms.untracked.bool(False)
15  process.g4SimHits.Physics.FlagFluo = cms.bool(True)
16  process.g4SimHits.Physics.ThermalNeutrons = cms.untracked.bool(False)
17  # Eta cut
18  process.g4SimHits.Generator.MinEtaCut = cms.double(-7.0)
19  process.g4SimHits.Generator.MaxEtaCut = cms.double(7.0)
20  # stacking action
21  process.g4SimHits.StackingAction.MaxTrackTime = TimeCut
22  process.g4SimHits.StackingAction.DeadRegions = cms.vstring()
23  process.g4SimHits.StackingAction.GammaThreshold = cms.double(0.0)
24  # stepping action
25  process.g4SimHits.SteppingAction.MaxNumberOfSteps = cms.int32(1000000)
26  process.g4SimHits.SteppingAction.MaxTrackTime = TimeCut
27  process.g4SimHits.SteppingAction.DeadRegions = cms.vstring()
28  # Russian roulette disabled
29  process.g4SimHits.StackingAction.RusRoGammaEnergyLimit = cms.double(0.0)
30  process.g4SimHits.StackingAction.RusRoNeutronEnergyLimit = cms.double(0.0)
31  # Calorimeter hits
32  process.g4SimHits.CaloSD.TmaxHit = TimeCut
33  process.g4SimHits.CaloSD.TmaxHits = cms.vdouble(10000000000,10000000000,10000000000,10000000000,10000000000)
34  # full simulation of HF
35  process.g4SimHits.HCalSD.UseShowerLibrary = cms.bool(False)
36  process.g4SimHits.HFShower.UseShowerLibrary = cms.bool(False)
37 
38  return(process)
return((rh ^ lh) &mask)