CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
g4SimHits_cfi.py
Go to the documentation of this file.
2 
4 
5 ## This object is used to customise g4SimHits for different running scenarios
6 from Configuration.StandardSequences.Eras import eras
7 
8 common_heavy_suppression = cms.PSet(
9  NeutronThreshold = cms.double(30.0),
10  ProtonThreshold = cms.double(30.0),
11  IonThreshold = cms.double(30.0)
12 )
13 
14 common_maximum_time = cms.PSet(
15  MaxTrackTime = cms.double(500.0),
16  MaxTimeNames = cms.vstring('ZDCRegion'),
17  MaxTrackTimes = cms.vdouble(2000.0),
18  #DeadRegions = cms.vstring('QuadRegion','CastorRegion','InterimRegion'),
19  DeadRegions = cms.vstring('QuadRegion','InterimRegion'),
20  CriticalEnergyForVacuum = cms.double(2.0),
21  CriticalDensity = cms.double(1e-15)
22 )
23 
24 common_UsePMT = cms.PSet(
25  UseR7600UPMT = cms.bool(False)
26 )
27 
28 common_UseHF = cms.PSet(
29  Lambda1 = cms.double(280.0),
30  Lambda2 = cms.double(700.0),
31  Gain = cms.double(0.33),
32  CheckSurvive = cms.bool(False),
33  FibreR = cms.untracked.double(0.3)
34 )
35 
36 common_UseLuminosity = cms.PSet(
37  InstLuminosity = cms.double(0.),
38  DelivLuminosity = cms.double(5000.)
39 )
40 
41 g4SimHits = cms.EDProducer("OscarMTProducer",
42  NonBeamEvent = cms.bool(False),
43  G4EventManagerVerbosity = cms.untracked.int32(0),
44  G4StackManagerVerbosity = cms.untracked.int32(0),
45  G4TrackingManagerVerbosity = cms.untracked.int32(0),
46  UseMagneticField = cms.bool(True),
47  StoreRndmSeeds = cms.bool(False),
48  RestoreRndmSeeds = cms.bool(False),
49  PhysicsTablesDirectory = cms.string('PhysicsTables'),
50  StorePhysicsTables = cms.bool(False),
51  RestorePhysicsTables = cms.bool(False),
52  CheckOverlap = cms.untracked.bool(False),
53  G4Commands = cms.vstring(''),
54  FileNameField = cms.untracked.string(''),
55  FileNameGDML = cms.untracked.string(''),
56  FileNameRegions = cms.untracked.string(''),
57  Watchers = cms.VPSet(),
58  HepMCProductLabel = cms.InputTag("generator"),
59  theLHCTlinkTag = cms.InputTag("LHCTransport"),
60  CustomUIsession = cms.untracked.PSet(
61  Type = cms.untracked.string("MessageLogger"), # MessageLoggerThreadPrefix, FilePerThread; the non-default ones are meant only for MT debugging
62  ThreadPrefix = cms.untracked.string("W"), # For MessageLoggerThreadPrefix
63  ThreadFile = cms.untracked.string("sim_output_thread"), # For FilePerThread
64  ),
65  MagneticField = cms.PSet(
66  UseLocalMagFieldManager = cms.bool(False),
67  Verbosity = cms.untracked.bool(False),
68  ConfGlobalMFM = cms.PSet(
69  Volume = cms.string('OCMS'),
70  OCMS = cms.PSet(
71  Stepper = cms.string('G4ClassicalRK4'),
72  Type = cms.string('CMSIMField'),
73  StepperParam = cms.PSet(
74  MaximumEpsilonStep = cms.untracked.double(0.01), ## in mm
75  DeltaOneStep = cms.double(0.001), ## in mm
76  MaximumLoopCounts = cms.untracked.double(1000.0),
77  DeltaChord = cms.double(0.001), ## in mm
78  MinStep = cms.double(0.1), ## in mm
79  DeltaIntersectionAndOneStep = cms.untracked.double(-1.0),
80  DeltaIntersection = cms.double(0.0001), ## in mm
81  MinimumEpsilonStep = cms.untracked.double(1e-05) ## in mm
82  )
83  )
84  ),
85  delta = cms.double(1.0)
86  ),
87  Physics = cms.PSet(
88  common_maximum_time,
89  # NOTE : if you want EM Physics only,
90  # please select "SimG4Core/Physics/DummyPhysics" for type
91  # and turn ON DummyEMPhysics
92  #
93  type = cms.string('SimG4Core/Physics/QGSP_FTFP_BERT_EML'),
94  DummyEMPhysics = cms.bool(False),
95  CutsPerRegion = cms.bool(True),
96  CutsOnProton = cms.untracked.bool(True),
97  DefaultCutValue = cms.double(1.0), ## cuts in cm
98  G4BremsstrahlungThreshold = cms.double(0.5), ## cut in GeV
99  Verbosity = cms.untracked.int32(0),
100  # 1 will print cuts as they get set from DD
101  # 2 will do as 1 + will dump Geant4 table of cuts
102  MonopoleCharge = cms.untracked.int32(1),
103  MonopoleDeltaRay = cms.untracked.bool(True),
104  MonopoleMultiScatter = cms.untracked.bool(False),
105  MonopoleTransport = cms.untracked.bool(True),
106  MonopoleMass = cms.untracked.double(0),
107  Region = cms.string(' '),
108  TrackingCut = cms.bool(False),
109  SRType = cms.bool(True),
110  FlagMuNucl = cms.bool(False),
111  FlagFluo = cms.bool(False),
112  EMPhysics = cms.untracked.bool(True),
113  HadPhysics = cms.untracked.bool(True),
114  FlagBERT = cms.untracked.bool(False),
115  GflashEcal = cms.bool(False),
116  GflashHcal = cms.bool(False),
117  GflashEcalHad = cms.bool(False),
118  GflashHcalHad = cms.bool(False),
119  bField = cms.double(3.8),
120  energyScaleEB = cms.double(1.032),
121  energyScaleEE = cms.double(1.024),
122  ExoticaPhysicsSS = cms.untracked.bool(False),
123  RusRoElectronEnergyLimit = cms.double(0.0),
124  RusRoEcalElectron = cms.double(1.0),
125  RusRoHcalElectron = cms.double(1.0),
126  RusRoMuonIronElectron = cms.double(1.0),
127  RusRoPreShowerElectron = cms.double(1.0),
128  RusRoCastorElectron = cms.double(1.0),
129  RusRoWorldElectron = cms.double(1.0),
130  ElectronStepLimit = cms.bool(False),
131  ElectronRangeTest = cms.bool(False),
132  PositronStepLimit = cms.bool(False),
133  MinStepLimit = cms.double(1.0)
134  ),
135  Generator = cms.PSet(
136  HectorEtaCut,
137  # string HepMCProductLabel = "VtxSmeared"
138  HepMCProductLabel = cms.string('generator'),
139  ApplyPCuts = cms.bool(True),
140  ApplyPtransCut = cms.bool(False),
141  MinPCut = cms.double(0.04), ## the cut is in GeV
142  MaxPCut = cms.double(99999.0), ## the pmax=99.TeV
143  ApplyEtaCuts = cms.bool(True),
144  MinEtaCut = cms.double(-5.5),
145  MaxEtaCut = cms.double(5.5),
146  RDecLenCut = cms.double(2.9), ## (cm) the cut on vertex radius
147  LDecLenCut = cms.double(30.0), ## (cm) decay volume length
148  ApplyPhiCuts = cms.bool(False),
149  MinPhiCut = cms.double(-3.14159265359), ## (radians)
150  MaxPhiCut = cms.double(3.14159265359), ## according to CMS conventions
151  ApplyLumiMonitorCuts = cms.bool(False), ## primary for lumi monitors
152  Verbosity = cms.untracked.int32(0)
153  ),
154  RunAction = cms.PSet(
155  StopFile = cms.string('StopRun')
156  ),
157  EventAction = cms.PSet(
158  debug = cms.untracked.bool(False),
159  StopFile = cms.string('StopRun'),
160  PrintRandomSeed = cms.bool(False),
161  CollapsePrimaryVertices = cms.bool(False)
162  ),
163  StackingAction = cms.PSet(
164  common_heavy_suppression,
165  common_maximum_time,
166  KillDeltaRay = cms.bool(False),
167  TrackNeutrino = cms.bool(False),
168  KillHeavy = cms.bool(False),
169  KillGamma = cms.bool(True),
170  GammaThreshold = cms.double(0.0001), ## (MeV)
171  SaveFirstLevelSecondary = cms.untracked.bool(False),
172  SavePrimaryDecayProductsAndConversionsInTracker = cms.untracked.bool(False),
173  SavePrimaryDecayProductsAndConversionsInCalo = cms.untracked.bool(False),
174  SavePrimaryDecayProductsAndConversionsInMuon = cms.untracked.bool(False),
175  SaveAllPrimaryDecayProductsAndConversions = cms.untracked.bool(True),
176  RusRoGammaEnergyLimit = cms.double(5.0), ## (MeV)
177  RusRoEcalGamma = cms.double(0.3),
178  RusRoHcalGamma = cms.double(0.3),
179  RusRoMuonIronGamma = cms.double(0.3),
180  RusRoPreShowerGamma = cms.double(0.3),
181  RusRoCastorGamma = cms.double(0.3),
182  RusRoWorldGamma = cms.double(0.3),
183  RusRoNeutronEnergyLimit = cms.double(10.0), ## (MeV)
184  RusRoEcalNeutron = cms.double(0.1),
185  RusRoHcalNeutron = cms.double(0.1),
186  RusRoMuonIronNeutron = cms.double(0.1),
187  RusRoPreShowerNeutron = cms.double(0.1),
188  RusRoCastorNeutron = cms.double(0.1),
189  RusRoWorldNeutron = cms.double(0.1),
190  RusRoProtonEnergyLimit = cms.double(0.0),
191  RusRoEcalProton = cms.double(1.0),
192  RusRoHcalProton = cms.double(1.0),
193  RusRoMuonIronProton = cms.double(1.0),
194  RusRoPreShowerProton = cms.double(1.0),
195  RusRoCastorProton = cms.double(1.0),
196  RusRoWorldProton = cms.double(1.0)
197  ),
198  TrackingAction = cms.PSet(
199  DetailedTiming = cms.untracked.bool(False),
200  CheckTrack = cms.untracked.bool(False)
201  ),
202  SteppingAction = cms.PSet(
203  common_maximum_time,
204  EkinNames = cms.vstring(),
205  EkinThresholds = cms.vdouble(),
206  EkinParticles = cms.vstring()
207  ),
208  TrackerSD = cms.PSet(
209  ZeroEnergyLoss = cms.bool(False),
210  PrintHits = cms.bool(False),
211  ElectronicSigmaInNanoSeconds = cms.double(12.06),
212  NeverAccumulate = cms.bool(False),
213  EnergyThresholdForPersistencyInGeV = cms.double(0.2),
214  EnergyThresholdForHistoryInGeV = cms.double(0.05)
215  ),
216  MuonSD = cms.PSet(
217  EnergyThresholdForPersistency = cms.double(1.0),
218  PrintHits = cms.bool(False),
219  AllMuonsPersistent = cms.bool(True)
220  ),
221  CaloSD = cms.PSet(
222  common_heavy_suppression,
223  SuppressHeavy = cms.bool(False),
224  EminTrack = cms.double(1.0),
225  TmaxHit = cms.double(1000.0),
226  HCNames = cms.vstring('EcalHitsEB','EcalHitsEE','EcalHitsES','HcalHits','ZDCHITS'),
227  EminHits = cms.vdouble(0.015,0.010,0.0,0.0,0.0),
228  EminHitsDepth = cms.vdouble(0.0,0.0,0.0,0.0,0.0),
229  TmaxHits = cms.vdouble(500.0,500.0,500.0,500.0,2000.0),
230  UseResponseTables = cms.vint32(0,0,0,0,0),
231  BeamPosition = cms.double(0.0),
232  CorrectTOFBeam = cms.bool(False),
233  DetailedTiming = cms.untracked.bool(False),
234  UseMap = cms.untracked.bool(False),
235  Verbosity = cms.untracked.int32(0),
236  CheckHits = cms.untracked.int32(25)
237  ),
238  CaloResponse = cms.PSet(
239  UseResponseTable = cms.bool(True),
240  ResponseScale = cms.double(1.0),
241  ResponseFile = cms.FileInPath('SimG4CMS/Calo/data/responsTBpim50.dat')
242  ),
243  ECalSD = cms.PSet(
244  common_UseLuminosity,
245  UseBirkLaw = cms.bool(True),
246  BirkL3Parametrization = cms.bool(True),
247  BirkSlope = cms.double(0.253694),
248  BirkCut = cms.double(0.1),
249  BirkC1 = cms.double(0.03333),
250  BirkC3 = cms.double(1.0),
251  BirkC2 = cms.double(0.0),
252  SlopeLightYield = cms.double(0.02),
253  StoreSecondary = cms.bool(False),
254  TimeSliceUnit = cms.int32(1),
255  IgnoreTrackID = cms.bool(False),
256  XtalMat = cms.untracked.string('E_PbWO4'),
257  TestBeam = cms.untracked.bool(False),
258  NullNumbering = cms.untracked.bool(False),
259  StoreRadLength = cms.untracked.bool(False),
260  AgeingWithSlopeLY = cms.untracked.bool(False)
261  ),
262  HCalSD = cms.PSet(
263  common_UseLuminosity,
264  UseBirkLaw = cms.bool(True),
265  BirkC3 = cms.double(1.75),
266  BirkC2 = cms.double(0.142),
267  BirkC1 = cms.double(0.0052),
268  UseShowerLibrary = cms.bool(True),
269  UseParametrize = cms.bool(False),
270  UsePMTHits = cms.bool(False),
271  UseFibreBundleHits = cms.bool(False),
272  TestNumberingScheme = cms.bool(False),
273  EminHitHB = cms.double(0.0),
274  EminHitHE = cms.double(0.0),
275  EminHitHO = cms.double(0.0),
276  EminHitHF = cms.double(0.0),
277  BetaThreshold = cms.double(0.7),
278  TimeSliceUnit = cms.int32(1),
279  IgnoreTrackID = cms.bool(False),
280  HEDarkening = cms.bool(False),
281  HFDarkening = cms.bool(False),
282  UseHF = cms.untracked.bool(True),
283  ForTBH2 = cms.untracked.bool(False),
284  UseLayerWt = cms.untracked.bool(False),
285  WtFile = cms.untracked.string('None')
286  ),
287  CaloTrkProcessing = cms.PSet(
288  TestBeam = cms.bool(False),
289  EminTrack = cms.double(0.01),
290  PutHistory = cms.bool(False)
291  ),
292  HFShower = cms.PSet(
293  common_UsePMT,
294  common_UseHF,
295  ProbMax = cms.double(1.0),
296  CFibre = cms.double(0.5),
297  PEPerGeV = cms.double(0.31),
298  TrackEM = cms.bool(False),
299  UseShowerLibrary = cms.bool(True),
300  UseHFGflash = cms.bool(False),
301  EminLibrary = cms.double(0.0),
302  OnlyLong = cms.bool(True),
303  LambdaMean = cms.double(350.0),
304  ApplyFiducialCut = cms.bool(True),
305  RefIndex = cms.double(1.459),
306  Aperture = cms.double(0.33),
307  ApertureTrapped = cms.double(0.22),
308  CosApertureTrapped= cms.double(0.5),
309  SinPsiMax = cms.untracked.double(0.5),
310  ParametrizeLast = cms.untracked.bool(False)
311  ),
312  HFShowerLibrary = cms.PSet(
313  FileName = cms.FileInPath('SimG4CMS/Calo/data/HFShowerLibrary_oldpmt_noatt_eta4_16en_v3.root'),
314  BackProbability = cms.double(0.2),
315  TreeEMID = cms.string('emParticles'),
316  TreeHadID = cms.string('hadParticles'),
317  Verbosity = cms.untracked.bool(False),
318  ApplyFiducialCut= cms.bool(True),
319  BranchPost = cms.untracked.string(''),
320  BranchEvt = cms.untracked.string(''),
321  BranchPre = cms.untracked.string('')
322  ),
323  HFShowerPMT = cms.PSet(
324  common_UsePMT,
325  common_UseHF,
326  PEPerGeVPMT = cms.double(1.0),
327  RefIndex = cms.double(1.52),
328  Aperture = cms.double(0.99),
329  ApertureTrapped = cms.double(0.22),
330  CosApertureTrapped= cms.double(0.5),
331  SinPsiMax = cms.untracked.double(0.5)
332  ),
333  HFShowerStraightBundle = cms.PSet(
334  common_UsePMT,
335  common_UseHF,
336  FactorBundle = cms.double(1.0),
337  RefIndex = cms.double(1.459),
338  Aperture = cms.double(0.33),
339  ApertureTrapped = cms.double(0.22),
340  CosApertureTrapped= cms.double(0.5),
341  SinPsiMax = cms.untracked.double(0.5)
342  ),
343  HFShowerConicalBundle = cms.PSet(
344  common_UsePMT,
345  common_UseHF,
346  FactorBundle = cms.double(1.0),
347  RefIndex = cms.double(1.459),
348  Aperture = cms.double(0.33),
349  ApertureTrapped = cms.double(0.22),
350  CosApertureTrapped= cms.double(0.5),
351  SinPsiMax = cms.untracked.double(0.5)
352  ),
353  HFGflash = cms.PSet(
354  BField = cms.untracked.double(3.8),
355  WatcherOn = cms.untracked.bool(True),
356  FillHisto = cms.untracked.bool(True)
357  ),
358  CastorSD = cms.PSet(
359  useShowerLibrary = cms.bool(True),
360  minEnergyInGeVforUsingSLibrary = cms.double(1.0),
361  nonCompensationFactor = cms.double(0.817),
362  Verbosity = cms.untracked.int32(0)
363  ),
364  CastorShowerLibrary = cms.PSet(
365  FileName = cms.FileInPath('SimG4CMS/Forward/data/CastorShowerLibrary_CMSSW500_Standard.root'),
366  BranchEvt = cms.untracked.string('hadShowerLibInfo.'),
367  BranchEM = cms.untracked.string('emParticles.'),
368  BranchHAD = cms.untracked.string('hadParticles.'),
369  Verbosity = cms.untracked.bool(False)
370  ),
371  TotemSD = cms.PSet(
372  Verbosity = cms.untracked.int32(0)
373  ),
374  ZdcSD = cms.PSet(
375  Verbosity = cms.int32(0),
376  UseShowerLibrary = cms.bool(True),
377  UseShowerHits = cms.bool(False),
378  FiberDirection = cms.double(45.0),
379  ZdcHitEnergyCut = cms.double(10.0)
380  ),
381  ZdcShowerLibrary = cms.PSet(
382  Verbosity = cms.untracked.int32(0)
383  ),
384  FP420SD = cms.PSet(
385  Verbosity = cms.untracked.int32(2)
386  ),
387  BscSD = cms.PSet(
388  Verbosity = cms.untracked.int32(0)
389  ),
390  PltSD = cms.PSet(
391  EnergyThresholdForPersistencyInGeV = cms.double(0.2),
392  EnergyThresholdForHistoryInGeV = cms.double(0.05)
393  ),
394  Bcm1fSD = cms.PSet(
395  EnergyThresholdForPersistencyInGeV = cms.double(0.010),
396  EnergyThresholdForHistoryInGeV = cms.double(0.005)
397  ),
398  HcalTB02SD = cms.PSet(
399  UseBirkLaw = cms.untracked.bool(False),
400  BirkC1 = cms.untracked.double(0.013),
401  BirkC3 = cms.untracked.double(1.75),
402  BirkC2 = cms.untracked.double(0.0568)
403  ),
404  EcalTBH4BeamSD = cms.PSet(
405  UseBirkLaw = cms.bool(False),
406  BirkC1 = cms.double(0.013),
407  BirkC3 = cms.double(1.75),
408  BirkC2 = cms.double(0.0568)
409  ),
410  HcalTB06BeamSD = cms.PSet(
411  UseBirkLaw = cms.bool(False),
412  BirkC1 = cms.double(0.013),
413  BirkC3 = cms.double(1.75),
414  BirkC2 = cms.double(0.0568)
415  )
416 )
417 
418 
419 ##
420 ## Change the HFShowerLibrary file used for Run 2
421 ##
422 eras.run2_common.toModify( g4SimHits.HFShowerLibrary, FileName = 'SimG4CMS/Calo/data/HFShowerLibrary_npmt_noatt_eta4_16en_v3.root' )