Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-05-29 04:20:53

0001 import FWCore.ParameterSet.Config as cms
0002 from Configuration.Eras.Modifier_hgcaltb_cff import hgcaltb
0003 
0004 process = cms.Process('SIM', hgcaltb)
0005 
0006 # import of standard configurations
0007 process.load("FWCore.MessageService.MessageLogger_cfi")
0008 process.load('Configuration.StandardSequences.Services_cff')
0009 process.load('SimGeneral.HepPDTESSource.pythiapdt_cfi')
0010 process.load('Configuration.EventContent.EventContent_cff')
0011 process.load('Geometry.HGCalTBCommonData.testTB230AugXML_cfi')
0012 process.load('Geometry.HGCalCommonData.hgcalEENumberingInitialization_cfi')
0013 process.load('Geometry.HGCalCommonData.hgcalEEParametersInitialization_cfi')
0014 process.load('Geometry.HcalTestBeamData.hcalTB06Parameters_cff')
0015 process.load('Configuration.StandardSequences.MagneticField_0T_cff')
0016 process.load('Configuration.StandardSequences.Generator_cff')
0017 process.load('IOMC.EventVertexGenerators.VtxSmearedFlat_cfi')
0018 process.load('GeneratorInterface.Core.genFilterSummary_cff')
0019 process.load('Configuration.StandardSequences.SimIdeal_cff')
0020 process.load('Configuration.StandardSequences.EndOfProcess_cff')
0021 process.load('Configuration.StandardSequences.FrontierConditions_GlobalTag_cff')
0022 process.load('SimG4CMS.HGCalTestBeam.HGCalTB23Analyzer_cfi')
0023 
0024 process.maxEvents = cms.untracked.PSet(
0025     input = cms.untracked.int32(10)
0026 )
0027 
0028 if 'MessageLogger' in process.__dict__:
0029     process.MessageLogger.G4cerr=dict()
0030     process.MessageLogger.G4cout=dict()
0031     process.MessageLogger.HGCSim=dict()
0032     process.MessageLogger.CaloSim=dict()
0033     process.MessageLogger.FlatThetaGun=dict()
0034     process.MessageLogger.FlatEvtVtx=dict()
0035     process.MessageLogger.HGCalGeom=dict()
0036 
0037 # Input source
0038 process.source = cms.Source("EmptySource")
0039 
0040 process.options = cms.untracked.PSet(
0041 )
0042 
0043 # Production Info
0044 process.configurationMetadata = cms.untracked.PSet(
0045     annotation = cms.untracked.string('SingleMuonE200_cfi nevts:10'),
0046     name = cms.untracked.string('Applications'),
0047     version = cms.untracked.string('$Revision: 1.19 $')
0048 )
0049 
0050 # Output definition
0051 
0052 process.RAWSIMoutput = cms.OutputModule("PoolOutputModule",
0053     SelectEvents = cms.untracked.PSet(
0054         SelectEvents = cms.vstring('generation_step')
0055     ),
0056     dataset = cms.untracked.PSet(
0057         dataTier = cms.untracked.string('GEN-SIM'),
0058         filterName = cms.untracked.string('')
0059     ),
0060     eventAutoFlushCompressedSize = cms.untracked.int32(5242880),
0061     fileName = cms.untracked.string('file:gensim.root'),
0062     outputCommands = process.RAWSIMEventContent.outputCommands,
0063     splitLevel = cms.untracked.int32(0)
0064 )
0065 
0066 # Additional output definition
0067 process.TFileService = cms.Service("TFileService",
0068                                    fileName = cms.string('TBGenSim.root')
0069                                    )
0070 
0071 # Other statements
0072 process.genstepfilter.triggerConditions=cms.vstring("generation_step")
0073 from Configuration.AlCa.GlobalTag import GlobalTag
0074 process.GlobalTag = GlobalTag(process.GlobalTag, 'auto:run2_mc', '')
0075 
0076 process.generator = cms.EDProducer("FlatRandomEThetaGunProducer",
0077     AddAntiParticle = cms.bool(False),
0078     PGunParameters = cms.PSet(
0079         MinE = cms.double(99.99),
0080         MaxE = cms.double(100.01),
0081         MinTheta = cms.double(0.0),
0082         MaxTheta = cms.double(0.0),
0083         MinPhi = cms.double(-3.14159265359),
0084         MaxPhi = cms.double(3.14159265359),
0085         PartID = cms.vint32(11)
0086     ),
0087     Verbosity = cms.untracked.int32(1),
0088     firstRun = cms.untracked.uint32(1),
0089     psethack = cms.string('single electron E 10')
0090 )
0091 process.VtxSmeared.MinZ = -100.0
0092 process.VtxSmeared.MaxZ = -100.0
0093 #process.VtxSmeared.MinX = -1.0
0094 #process.VtxSmeared.MaxX =  1.0
0095 #process.VtxSmeared.MinY = -1.0
0096 #process.VtxSmeared.MaxY =  1.0
0097 process.g4SimHits.OnlySDs = ['HGCalSensitiveDetector', 'HcalTB06BeamDetector']
0098 process.g4SimHits.HGCSD.Detectors = 1
0099 process.g4SimHits.HGCSD.RejectMouseBite = False
0100 process.g4SimHits.HGCSD.RotatedWafer    = False
0101 
0102 process.g4SimHits.CaloTrkProcessing.TestBeam = True
0103 process.g4SimHits.HCalSD.ForTBHCAL = True
0104 process.g4SimHits.NonBeamEvent = True
0105 process.g4SimHits.UseMagneticField = False
0106 
0107 process.g4SimHits.EventVerbose = 2
0108 process.g4SimHits.SteppingVerbosity = 2
0109 process.g4SimHits.StepVerboseThreshold= 0.1
0110 process.g4SimHits.VerboseEvents = [1]
0111 process.g4SimHits.VertexNumber = []
0112 process.g4SimHits.VerboseTracks =[]
0113 
0114 # Path and EndPath definitions
0115 process.generation_step = cms.Path(process.pgen)
0116 process.simulation_step = cms.Path(process.psim)
0117 process.genfiltersummary_step = cms.EndPath(process.genFilterSummary)
0118 process.analysis_step = cms.Path(process.HGCalTB23Analyzer)
0119 process.endjob_step = cms.EndPath(process.endOfProcess)
0120 process.RAWSIMoutput_step = cms.EndPath(process.RAWSIMoutput)
0121 
0122 # Schedule definition
0123 process.schedule = cms.Schedule(process.generation_step,
0124                 process.simulation_step,
0125                     process.analysis_step,
0126                 process.endjob_step,
0127                 process.RAWSIMoutput_step,
0128                 )
0129 # filter all path with the production filter sequence
0130 for path in process.paths:
0131     getattr(process,path)._seq = process.generator * getattr(process,path)._seq 
0132 
0133