Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2021-02-14 14:29:13

0001 import FWCore.ParameterSet.Config as cms
0002 
0003 process = cms.Process("CastorTest")
0004 
0005 process.load("SimGeneral.HepPDTESSource.pdt_cfi")
0006 
0007 process.load("IOMC.EventVertexGenerators.VtxSmearedGauss_cfi")
0008 
0009 # process.load("Configuration.StandardSequences.GeometryExtended_cff")
0010 process.load("SimG4CMS.Forward.castorGeometryXML_cfi")
0011 #process.load("Geometry.CMSCommonData.cmsAllGeometryXML_cfi")
0012 #process.load("Geometry.TrackerNumberingBuilder.trackerNumberingGeometry_cfi")
0013 
0014 process.load("Configuration.StandardSequences.SimulationRandomNumberGeneratorSeeds_cff")
0015 
0016 process.RandomNumberGeneratorService.generator.initialSeed = 113456789
0017 
0018 process.load("Configuration.EventContent.EventContent_cff")
0019 
0020 process.load("SimG4Core.Application.g4SimHits_cfi")
0021 
0022 process.MessageLogger = cms.Service("MessageLogger",
0023     cerr = cms.untracked.PSet(
0024         enable = cms.untracked.bool(False)
0025     ),
0026     cout = cms.untracked.PSet(
0027         DEBUG = cms.untracked.PSet(
0028             limit = cms.untracked.int32(0)
0029         ),
0030         ForwardSim = cms.untracked.PSet(
0031             limit = cms.untracked.int32(0)
0032         ),
0033         enable = cms.untracked.bool(True)
0034     )
0035 )
0036 
0037 process.maxEvents = cms.untracked.PSet(
0038     input = cms.untracked.int32(1000)
0039 )
0040 
0041 process.source = cms.Source("EmptySource")
0042 
0043 process.generator = cms.EDProducer("FlatRandomEGunProducer",
0044     PGunParameters = cms.PSet(
0045         PartID = cms.vint32(211),
0046         MinEta = cms.double(-6.6),
0047         MaxEta = cms.double(-5.2),
0048         MinPhi = cms.double(-3.14),
0049         MaxPhi = cms.double(3.14),
0050         MinE = cms.double(50.00),
0051         MaxE = cms.double(50.00)
0052     ),
0053     AddAntiParticle = cms.bool(False),
0054     Verbosity = cms.untracked.int32(1)
0055 
0056 )
0057 
0058 process.o1 = cms.OutputModule("PoolOutputModule",
0059     fileName = cms.untracked.string('/tmp/sim_pion_SL.root')
0060 )
0061 
0062 process.common_maximum_timex = cms.PSet( # need to be localy redefined
0063    MaxTrackTime  = cms.double(500.0),  # need to be localy redefined
0064    MaxTimeNames  = cms.vstring(), # need to be localy redefined
0065    MaxTrackTimes = cms.vdouble()  # need to be localy redefined
0066 )
0067 process.p1 = cms.Path(process.generator*process.VtxSmeared*process.g4SimHits)
0068 process.outpath = cms.EndPath(process.o1)
0069 
0070 process.g4SimHits.UseMagneticField = False
0071 process.g4SimHits.Physics.DefaultCutValue = 10.
0072 process.g4SimHits.Generator.ApplyEtaCuts = False
0073 process.g4SimHits.CaloTrkProcessing.TestBeam = True
0074 process.g4SimHits.CastorSD.useShowerLibrary = True
0075 process.g4SimHits.CastorSD.minEnergyInGeVforUsingSLibrary = 1.0   # default = 1.0
0076 process.g4SimHits.CastorShowerLibrary.FileName = '../../../../../../p/polme/scratch0/CMSSW_3_7_0/src/SL_em+had_E1-1.5-2-2.5-3-3.5-4-4.5-5-6-7-8-9-10-12.5-15-17.5-20-25-30-35-40-45-50-60-70-80-100-125-150-175-200-300-400-500GeV_7eta-6.6--5.2_5phi0-0.7854.root'
0077 process.g4SimHits.CastorShowerLibrary.BranchEvt = 'hadShowerLibInfo.'
0078 process.g4SimHits.CastorShowerLibrary.BranchEM  =  'emParticles.'
0079 process.g4SimHits.CastorShowerLibrary.BranchHAD = 'hadParticles.'
0080 
0081 process.g4SimHits.StackingAction = cms.PSet(
0082    process.common_heavy_suppression,
0083    process.common_maximum_timex,        # need to be localy redefined
0084    TrackNeutrino = cms.bool(False),
0085    KillDeltaRay  = cms.bool(False),
0086    KillHeavy     = cms.bool(False),
0087    SaveFirstLevelSecondary = cms.untracked.bool(True),
0088    SavePrimaryDecayProductsAndConversionsInTracker = cms.untracked.bool(True),
0089    SavePrimaryDecayProductsAndConversionsInCalo    = cms.untracked.bool(True),
0090    SavePrimaryDecayProductsAndConversionsInMuon    = cms.untracked.bool(True)
0091 )
0092 
0093 process.g4SimHits.SteppingAction = cms.PSet(
0094    process.common_maximum_timex, # need to be localy redefined
0095    KillBeamPipe            = cms.bool(True),
0096    CriticalEnergyForVacuum = cms.double(2.0),
0097    CriticalDensity         = cms.double(1e-15),
0098    EkinNames               = cms.vstring(),
0099    EkinThresholds          = cms.vdouble(),
0100    EkinParticles           = cms.vstring(),
0101    Verbosity               = cms.untracked.int32(0)
0102 )
0103 
0104 process.g4SimHits.Watchers = cms.VPSet(cms.PSet(
0105     type = cms.string('CastorTestAnalysis'),
0106     CastorTestAnalysis = cms.PSet(
0107         Verbosity           = cms.int32(0),
0108         EventNtupleFlag     = cms.int32(1),
0109         StepNtupleFlag      = cms.int32(0),
0110         EventNtupleFileName = cms.string('eventNtuple_pion_SL.root'),
0111         StepNtupleFileName  = cms.string('stepNtuple_pion_SL.root'),
0112     )
0113 ))
0114 
0115 
0116