Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2023-03-17 11:23:50

0001 import FWCore.ParameterSet.Config as cms
0002 from SimCalorimetry.HcalSimProducers.hcalSimParameters_cfi import *
0003 from DataFormats.HcalCalibObjects.HFRecalibrationParameters_cff import *
0004 
0005 # make a block so other modules, such as the data mixing module, can
0006 # also run simulation
0007 
0008 hcalSimBlock = cms.PSet(    
0009     hcalSimParameters,
0010     # whether cells with MC signal get noise added
0011     doNoise = cms.bool(True),
0012     killHE = cms.bool(False),
0013     HcalPreMixStage1 = cms.bool(False),
0014     HcalPreMixStage2 = cms.bool(False),
0015     # whether cells with no MC signal get an empty signal created
0016     # These empty signals can get noise via the doNoise flag
0017     doEmpty = cms.bool(True),
0018     doIonFeedback = cms.bool(True),
0019     doThermalNoise = cms.bool(True),
0020     doTimeSlew = cms.bool(True),
0021     doHFWindow = cms.bool(False),
0022     hitsProducer = cms.string('g4SimHits'),
0023     DelivLuminosity = cms.double(0),
0024     TestNumbering = cms.bool(False),
0025     doNeutralDensityFilter = cms.bool(True),
0026     HBDarkening = cms.bool(False),
0027     HEDarkening = cms.bool(False),
0028     HFDarkening = cms.bool(False),
0029     minFCToDelay=cms.double(5.), # old TC model! set to 5 for the new one
0030     debugCaloSamples=cms.bool(False),
0031     ignoreGeantTime=cms.bool(False),
0032     # settings for SimHit test injection
0033     injectTestHits = cms.bool(False),
0034     # if no time is specified for injected hits, t = 0 will be used
0035     # (recommendation: enable "ignoreGeantTime" in that case to set t = tof)
0036     # otherwise, need 1 time value per energy value
0037     injectTestHitsEnergy = cms.vdouble(),
0038     injectTestHitsTime = cms.vdouble(),
0039     # format for cells: subdet, ieta, iphi, depth
0040     # multiple quadruplets can be specified
0041     # if instead only 1 value is given, 
0042     # it will be interpreted as an entire subdetector
0043     injectTestHitsCells = cms.vint32(),
0044     HFRecalParameterBlock = HFRecalParameterBlock,
0045 )
0046 
0047 from Configuration.Eras.Modifier_fastSim_cff import fastSim
0048 fastSim.toModify( hcalSimBlock, hitsProducer=cms.string('fastSimProducer') )
0049 
0050 from Configuration.ProcessModifiers.premix_stage1_cff import premix_stage1
0051 premix_stage1.toModify(hcalSimBlock,
0052     doNoise = False,
0053     doEmpty = False,
0054     doIonFeedback = False,
0055     doThermalNoise = False,
0056     doTimeSlew = False,
0057     HcalPreMixStage1 = True,
0058 )
0059 
0060 # test numbering not used in fastsim
0061 from Configuration.Eras.Modifier_run2_HCAL_2017_cff import run2_HCAL_2017
0062 (run2_HCAL_2017 & ~fastSim).toModify( hcalSimBlock, TestNumbering = cms.bool(True) )
0063 
0064 # remove HE processing for phase 2, completely put in HGCal land
0065 from Configuration.Eras.Modifier_phase2_hgcal_cff import phase2_hgcal
0066 phase2_hgcal.toModify(hcalSimBlock, killHE = cms.bool(True) )