Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2022-02-04 00:11:29

0001 import FWCore.ParameterSet.Config as cms
0002 from Configuration.Eras.Modifier_h2tb_cff import h2tb
0003 
0004 process = cms.Process("PROD", h2tb)
0005 
0006 process.load('FWCore.MessageService.MessageLogger_cfi')
0007 process.load("SimGeneral.HepPDTESSource.pdt_cfi")
0008 process.load("SimG4CMS.HcalTestBeam.TB2004GeometryXML_cfi")
0009 process.load("Geometry.EcalCommonData.ecalSimulationParameters_cff")
0010 process.load("Geometry.HcalTestBeamData.hcalDDDSimConstants_cff")
0011 process.load('GeneratorInterface.Core.generatorSmeared_cfi')
0012 process.load("Configuration.EventContent.EventContent_cff")
0013 process.load("SimG4Core.Application.g4SimHits_cfi")
0014 
0015 process.TFileService = cms.Service("TFileService",
0016     fileName = cms.string('hcaltb04.root')
0017 )
0018 
0019 process.MessageLogger.cerr.FwkReport.reportEvery = 5
0020 if hasattr(process,'MessageLogger'):
0021     process.MessageLogger.HCalGeom=dict()
0022     process.MessageLogger.EcalGeom=dict()
0023     process.MessageLogger.HcalSim=dict()
0024     process.MessageLogger.HcalTBSim=dict()
0025     process.MessageLogger.EcalSim=dict()
0026     process.MessageLogger.CaloSim=dict()
0027     process.MessageLogger.SimHCalData=dict()
0028     process.MessageLogger.VertexGenerator=dict()
0029 
0030 process.load("IOMC.RandomEngine.IOMC_cff")
0031 process.RandomNumberGeneratorService.generator.initialSeed = 456789
0032 process.RandomNumberGeneratorService.g4SimHits.initialSeed = 9876
0033 process.RandomNumberGeneratorService.VtxSmeared.initialSeed = 123456789
0034 
0035 process.maxEvents = cms.untracked.PSet(
0036     input = cms.untracked.int32(10)
0037 )
0038 
0039 beamPosition = -521.5
0040 
0041 process.common_beam_direction_parameters = cms.PSet(
0042     MinEta       = cms.double(0.5655),
0043     MaxEta       = cms.double(0.5655),
0044     MinPhi       = cms.double(-0.1309),
0045     MaxPhi       = cms.double(-0.1309),
0046     BeamPosition = cms.double(beamPosition)
0047 )
0048 
0049 from IOMC.EventVertexGenerators.VtxSmearedParameters_cfi import *
0050 process.VtxSmeared = cms.EDProducer("BeamProfileVtxGenerator",
0051     process.common_beam_direction_parameters,
0052     VtxSmearedCommon,
0053     BeamMeanX       = cms.double(0.0),
0054     BeamMeanY       = cms.double(0.0),
0055     BeamSigmaX      = cms.double(0.0001),
0056     BeamSigmaY      = cms.double(0.0001),
0057     Psi             = cms.double(999.9),
0058     GaussianProfile = cms.bool(False),
0059     BinX            = cms.int32(50),
0060     BinY            = cms.int32(50),
0061     File            = cms.string('beam.profile'),
0062     UseFile         = cms.bool(False),
0063     TimeOffset      = cms.double(0.)
0064 )
0065 
0066 process.source = cms.Source("EmptySource")
0067 
0068 process.generator = cms.EDProducer("FlatRandomEGunProducer",
0069     PGunParameters = cms.PSet(
0070         process.common_beam_direction_parameters,
0071         MinE   = cms.double(9.99),
0072         MaxE   = cms.double(10.01),
0073         PartID = cms.vint32(211)
0074     ),
0075     Verbosity       = cms.untracked.int32(0),
0076     AddAntiParticle = cms.bool(False),
0077     firstRun        = cms.untracked.uint32(1)
0078 )
0079 
0080 process.o1 = cms.OutputModule("PoolOutputModule",
0081     process.FEVTSIMEventContent,
0082     fileName = cms.untracked.string('sim2004.root')
0083 )
0084 
0085 process.Timing = cms.Service("Timing")
0086 
0087 process.p1 = cms.Path(process.generator*process.VtxSmeared*process.generatorSmeared*process.g4SimHits)
0088 process.outpath = cms.EndPath(process.o1)
0089 process.g4SimHits.NonBeamEvent = True
0090 process.g4SimHits.UseMagneticField = False
0091 process.g4SimHits.Physics.type = 'SimG4Core/Physics/QGSP_FTFP_BERT_EML'
0092 process.g4SimHits.Physics.Region = 'HcalRegion'
0093 process.g4SimHits.Physics.DefaultCutValue = 1.
0094 
0095 process.g4SimHits.StackingAction.KillGamma = False
0096 process.g4SimHits.CaloSD.BeamPosition = beamPosition
0097 process.g4SimHits.ECalSD.UseBirkLaw = True
0098 process.g4SimHits.ECalSD.BirkL3Parametrization = True
0099 process.g4SimHits.ECalSD.BirkC1 = 0.033
0100 process.g4SimHits.ECalSD.BirkC2 = 0.0
0101 process.g4SimHits.ECalSD.SlopeLightYield = 0.05
0102 process.g4SimHits.HCalSD.UseBirkLaw = True
0103 process.g4SimHits.HCalSD.BirkC1 = 0.0052
0104 process.g4SimHits.HCalSD.BirkC2 = 0.142
0105 process.g4SimHits.HCalSD.BirkC3 = 1.75
0106 process.g4SimHits.HCalSD.UseLayerWt = False
0107 process.g4SimHits.HCalSD.WtFile     = ' '
0108 process.g4SimHits.HCalSD.UseShowerLibrary = False
0109 process.g4SimHits.HCalSD.TestNumberingScheme = True
0110 process.g4SimHits.HCalSD.UseHF   = False
0111 process.g4SimHits.HCalSD.ForTBH2 = True
0112 process.g4SimHits.Watchers = cms.VPSet(cms.PSet(
0113     HcalTB04Analysis = cms.PSet(
0114         process.common_beam_direction_parameters,
0115         HcalOnly  = cms.bool(False),
0116         Type      = cms.int32(2),
0117         Mode      = cms.int32(1),
0118         ScaleHB0  = cms.double(0.5),
0119         ScaleHB16 = cms.double(0.5),
0120         ScaleHE0  = cms.double(0.5),
0121         ScaleHO   = cms.double(0.4),
0122         EcalNoise = cms.double(0.13),
0123         Names     = cms.vstring('HcalHits', 'EcalHitsEB'),
0124         Verbose   = cms.untracked.bool(True),
0125         FileName  = cms.untracked.string('HcalTB04.root'),
0126         ETtotMax  = cms.untracked.double(20.0),
0127         EHCalMax  = cms.untracked.double(2.0)
0128     ),
0129     HcalQie = cms.PSet(
0130         NumOfBuckets  = cms.int32(10),
0131         BaseLine      = cms.int32(4),
0132         BinOfMax      = cms.int32(6),
0133         PreSamples    = cms.int32(0),
0134         EDepPerPE     = cms.double(0.0005),
0135         SignalBuckets = cms.int32(2),
0136         SigmaNoise    = cms.double(0.5),
0137         qToPE         = cms.double(4.0)
0138     ),
0139     type = cms.string('HcalTB04Analysis')
0140 ))
0141