Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-04-06 12:30:12

0001 import FWCore.ParameterSet.Config as cms
0002 
0003 process = cms.Process("CastorShowerLibraryMaker")
0004 
0005 process.common_maximum_timex = cms.PSet(
0006   MaxTrackTime = cms.double(500.0),
0007   MaxTimeNames = cms.vstring(),
0008   MaxTrackTimes = cms.vdouble()
0009 )
0010 
0011 process.common_pgun_particleID = cms.PSet(
0012         PartID = cms.vint32(11,211)
0013         #PartID = cms.vint32(211)
0014 )
0015 
0016 process.load("SimGeneral.HepPDTESSource.pdt_cfi")
0017 
0018 process.load("IOMC.EventVertexGenerators.VtxSmearedGauss_cfi")
0019 
0020 # process.load("Configuration.StandardSequences.GeometryExtended_cff")
0021 process.load("SimG4CMS.Forward.castorGeometryXML_cfi")
0022 #process.load("Geometry.CMSCommonData.cmsAllGeometryXML_cfi")
0023 #process.load("Geometry.TrackerNumberingBuilder.trackerNumberingGeometry_cfi")
0024 
0025 #process.load("Configuration.StandardSequences.SimulationRandomNumberGeneratorSeeds_cff")
0026 
0027 #process.load("Configuration.EventContent.EventContent_cff")
0028 
0029 process.load("SimG4Core.Application.g4SimHits_cfi")
0030 
0031 process.MessageLogger = cms.Service("MessageLogger",
0032     cerr = cms.untracked.PSet(
0033         enable = cms.untracked.bool(False)
0034     ),
0035     cout = cms.untracked.PSet(
0036         enable = cms.untracked.bool(True)
0037     )
0038 )
0039 
0040 process.RandomNumberGeneratorService = cms.Service("RandomNumberGeneratorService",
0041     moduleSeeds = cms.PSet(
0042         g4SimHits  = cms.untracked.uint32(8245),         # std: 9784
0043         VtxSmeared = cms.untracked.uint32(123456789),
0044         generator  = cms.untracked.uint32(536870912)     # std: 135799753
0045     )
0046     #sourceSeed = cms.untracked.uint32(135799753)         # std: 135799753
0047 )
0048 
0049 process.maxEvents = cms.untracked.PSet(
0050     input = cms.untracked.int32(1000000000)
0051 )
0052 
0053 
0054 process.g4SimHits.UseMagneticField = False
0055 process.g4SimHits.Physics.DefaultCutValue = 10.
0056 process.g4SimHits.Generator.MinEtaCut        = -7.0
0057 process.g4SimHits.Generator.MaxEtaCut        = 7.0
0058 process.g4SimHits.Generator.Verbosity        = 0
0059 process.g4SimHits.CaloTrkProcessing.TestBeam = True
0060 
0061 process.CaloSD = cms.PSet(
0062     DetailedTiming = cms.bool(False),
0063     EminTrack      = cms.double(1.0),
0064     Verbosity      = cms.int32(0),
0065     UseMap         = cms.bool(True),
0066     CheckHits      = cms.int32(25),
0067     TmaxHit        = cms.int32(500)  # L.M. testing
0068 )
0069 
0070 process.g4SimHits.StackingAction = cms.PSet(
0071    process.common_heavy_suppression,
0072    process.common_maximum_timex,        # need to be localy redefined
0073    TrackNeutrino = cms.bool(False),
0074    KillHeavy     = cms.bool(False),
0075    KillDeltaRay  = cms.bool(False),
0076    SaveFirstLevelSecondary = cms.untracked.bool(True),
0077    SavePrimaryDecayProductsAndConversionsInTracker = cms.untracked.bool(True),
0078    SavePrimaryDecayProductsAndConversionsInCalo    = cms.untracked.bool(True),
0079    SavePrimaryDecayProductsAndConversionsInMuon    = cms.untracked.bool(True)
0080 )
0081 
0082 process.g4SimHits.SteppingAction = cms.PSet(
0083    process.common_maximum_timex, # need to be localy redefined
0084    KillBeamPipe            = cms.bool(True),
0085    CriticalEnergyForVacuum = cms.double(2.0),
0086    CriticalDensity         = cms.double(1e-15),
0087    EkinNames               = cms.vstring(),
0088    EkinThresholds          = cms.vdouble(),
0089    EkinParticles           = cms.vstring(),
0090    Verbosity               = cms.untracked.int32(0)
0091 )
0092 
0093 process.generator = cms.EDProducer("FlatRandomEGunProducer",
0094     PGunParameters = cms.PSet(
0095         process.common_pgun_particleID,
0096         MinEta = cms.double(-6.6),
0097         MaxEta = cms.double(-5.2),
0098         MinPhi = cms.double(0.),
0099         MaxPhi = cms.double(0.7854), # PI/4 = 0.7854
0100         MinE = cms.double(12.00),
0101         #MeanE = cms.double(12.00),
0102         MaxE = cms.double(14.00)
0103         #Energybins = cms.vdouble(1.,2.,3.,5.,7.,10.,20.,30.,45.,60.,75.,100.,140.,200.,300.,600.,1000.,1500.)
0104     ),
0105     AddAntiParticle = cms.bool(False),
0106     Verbosity = cms.untracked.int32(False)
0107 )
0108 
0109 process.g4SimHits.CastorSD.useShowerLibrary = False
0110 
0111 process.source = cms.Source("EmptySource")
0112 #process.o1 = cms.OutputModule("PoolOutputModule",
0113 #    fileName = cms.untracked.string('sim_pion_1events-ppON.root')
0114 #)
0115 
0116 
0117 process.g4SimHits.Watchers = cms.VPSet(cms.PSet(
0118     type = cms.string('CastorShowerLibraryMaker'),
0119     CastorShowerLibraryMaker = cms.PSet(
0120         process.common_pgun_particleID,
0121         EventNtupleFileName = cms.string('SL_had_E12GeV_eta-6.0phi0.3_1events-ppON.root'),
0122         Verbosity = cms.int32(0),
0123         DeActivatePhysicsProcess = cms.bool(False),
0124         StepNtupleFileName = cms.string('stepNtuple_pion_electron_E12GeV_1event-ppON.root'),
0125         StepNtupleFlag = cms.int32(0),
0126         EventNtupleFlag = cms.int32(0),
0127         # for shower library
0128         nemEvents       = cms.int32(5),
0129         SLemEnergyBins  = cms.vdouble(10.),
0130         SLemEtaBins     = cms.vdouble(-6.6,-6.4,-6.2,-6.0,-5.8,-5.6,-5.4),
0131         SLemPhiBins     = cms.vdouble(0.,0.07854,0.15708,0.23562,0.31416,0.3927,0.47124,0.54978,0.62832,0.70686),
0132         nhadEvents       = cms.int32(5),
0133         SLhadEnergyBins  = cms.vdouble(10.),
0134         #SLhadEnergyBins  = cms.vdouble(1.,2.,3.,5.,7.,10.,20.,30.,45.,60.,75.,100.,140.,200.),
0135         SLhadEtaBins     = cms.vdouble(-6.6,-6.4,-6.2,-6.0,-5.8,-5.6,-5.4),
0136         SLhadPhiBins     = cms.vdouble(0.,0.07854,0.15708,0.23562,0.31416,0.3927,0.47124,0.54978,0.62832,0.70686),
0137         SLMaxPhi         = cms.double(0.7854),
0138         SLMaxEta         = cms.double(-5.2)
0139     )
0140 ))
0141 
0142 
0143 process.p1 = cms.Path(process.generator*process.VtxSmeared*process.g4SimHits)
0144 #process.outpath = cms.EndPath(process.o1)