Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-04-06 12:31:55

0001 import FWCore.ParameterSet.Config as cms
0002 
0003 
0004 from Configuration.Eras.Era_Run2_2017_cff import Run2_2017
0005 process = cms.Process('TEST',Run2_2017)
0006 
0007 ### RANDOM setting (change last digit(s) to make runs different !)
0008 process.load("Configuration.StandardSequences.SimulationRandomNumberGeneratorSeeds_cff")
0009 
0010 process.load("Configuration.StandardSequences.Simulation_cff")
0011 process.load("Configuration.StandardSequences.Reconstruction_cff")
0012 process.load("SimGeneral.MixingModule.mixNoPU_cfi")
0013 process.load('Configuration/StandardSequences/DigiToRaw_cff')
0014 process.load('Configuration/StandardSequences/RawToDigi_cff')
0015 
0016 process.load("Configuration.StandardSequences.FrontierConditions_GlobalTag_cff")
0017 # from Configuration.AlCa.autoCond import autoCond
0018 # process.GlobalTag.globaltag = autoCond['run2_mc']
0019 from Configuration.AlCa.GlobalTag import GlobalTag
0020 process.GlobalTag = GlobalTag(process.GlobalTag, 'auto:phase1_2017_realistic', '')
0021 
0022 process.load("IOMC.EventVertexGenerators.VtxSmearedGauss_cfi")
0023 process.load("Configuration.StandardSequences.GeometryDB_cff")
0024 process.load("Configuration.StandardSequences.MagneticField_cff")
0025 process.g4SimHits.UseMagneticField = False
0026 
0027 process.load("DQMServices.Core.DQMStore_cfi")
0028 process.load("DQMServices.Components.MEtoEDMConverter_cfi")
0029 
0030 process.maxEvents = cms.untracked.PSet(
0031     input = cms.untracked.int32(2000) 
0032 )
0033 # Input source
0034 process.source = cms.Source("PoolSource",
0035     firstEvent = cms.untracked.uint32(XXXXX), 
0036     fileNames = cms.untracked.vstring('file:mc.root') 
0037 ) 
0038 
0039 process.FEVT = cms.OutputModule("PoolOutputModule",
0040      outputCommands = cms.untracked.vstring('drop *', 'keep *_MEtoEDMConverter_*_*'),
0041      splitLevel = cms.untracked.int32(0),
0042      fileName = cms.untracked.string("output.root")
0043 )
0044 
0045 process.VtxSmeared.SigmaX = 0.00001
0046 process.VtxSmeared.SigmaY = 0.00001
0047 process.VtxSmeared.SigmaZ = 0.00001
0048 
0049 process.load("Validation.HcalHits.HcalSimHitsValidation_cfi")
0050 process.HcalSimHitsAnalyser.outputFile = cms.untracked.string('HcalSimHitsValidation.root')
0051 
0052 process.load("Validation.HcalDigis.HcalDigisParam_cfi")
0053 process.hcaldigisAnalyzer.outputFile = cms.untracked.string('HcalDigisValidationRelVal.root')
0054 
0055 process.load("Validation.HcalRecHits.HcalRecHitParam_cfi")
0056 
0057 process.load("Validation.CaloTowers.CaloTowersParam_cfi")
0058 process.calotowersAnalyzer.outputFile = cms.untracked.string('CaloTowersValidationRelVal.root')
0059 
0060 #--- replace hbhereco with hbheprereco
0061 delattr(process,"hbhereco")
0062 process.hbhereco = process.hbheprereco.clone()
0063 process.hcalLocalRecoSequence = cms.Sequence(process.hbhereco+process.hfprereco+process.hfreco+process.horeco)
0064 
0065 #--- post-LS1 customization 
0066 process.mix.digitizers.hcal.minFCToDelay=cms.double(5.) # new TS model
0067 process.mix.digitizers.hcal.ho.photoelectronsToAnalog = cms.vdouble([4.0]*16)
0068 process.mix.digitizers.hcal.ho.siPMCode = cms.int32(1)
0069 process.mix.digitizers.hcal.ho.pixels = cms.int32(2500)
0070 process.mix.digitizers.hcal.ho.doSiPMSmearing = cms.bool(False)
0071 process.mix.digitizers.hcal.hf1.samplingFactor = cms.double(0.67)
0072 process.mix.digitizers.hcal.hf2.samplingFactor = cms.double(0.67)
0073 process.g4SimHits.HFShowerLibrary.FileName = 'SimG4CMS/Calo/data/HFShowerLibrary_npmt_noatt_eta4_16en_v4.root'
0074 
0075 #---------- PATH
0076 # -- NB: for vertex smearing the Label should be: "unsmeared" 
0077 # for GEN produced since 760pre6, for older GEN - just "": 
0078 process.VtxSmeared.src = cms.InputTag("generator", "") 
0079 process.generatorSmeared = cms.EDProducer("GeneratorSmearedProducer")
0080 process.g4SimHits.Generator.HepMCProductLabel = 'VtxSmeared' 
0081 
0082 process.p = cms.Path(
0083  process.VtxSmeared *
0084  process.generatorSmeared *
0085  process.g4SimHits *
0086  process.mix *
0087  process.ecalDigiSequence * 
0088  process.hcalDigiSequence *
0089  process.addPileupInfo *
0090  process.bunchSpacingProducer *
0091  process.ecalPacker *
0092  process.esDigiToRaw *
0093  process.hcalRawData *
0094  process.rawDataCollector *
0095  process.ecalDigis *
0096  process.ecalPreshowerDigis *
0097  process.hcalDigis *
0098  process.calolocalreco *
0099  process.caloTowersRec *
0100  process.hcalnoise *
0101  process.HcalSimHitsAnalyser *
0102  process.hcaldigisAnalyzer *
0103  process.calotowersAnalyzer *
0104  process.hcalRecoAnalyzer *
0105  process.MEtoEDMConverter
0106 )
0107 
0108 process.outpath = cms.EndPath(process.FEVT)
0109