Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-04-06 12:32:48

0001 import FWCore.ParameterSet.Config as cms
0002 from FWCore.ParameterSet.VarParsing import VarParsing
0003 from Configuration.Eras.Era_Run3_cff import Run3
0004 
0005 options = VarParsing('analysis')
0006 options.register("doSim", True, VarParsing.multiplicity.singleton, VarParsing.varType.bool)
0007 options.register("cmssw", "CMSSW_X_Y_Z", VarParsing.multiplicity.singleton, VarParsing.varType.string)
0008 options.register("globalTag", "tag", VarParsing.multiplicity.singleton, VarParsing.varType.string)
0009 options.register("dataSetTag", "sample", VarParsing.multiplicity.singleton, VarParsing.varType.string)
0010 options.parseArguments()
0011 
0012 process = cms.Process('HARVESTING',Run3)
0013 
0014 # import of standard configurations
0015 process.load('Configuration.StandardSequences.Services_cff')
0016 process.load('SimGeneral.HepPDTESSource.pythiapdt_cfi')
0017 process.load('FWCore.MessageService.MessageLogger_cfi')
0018 process.load('Configuration.EventContent.EventContent_cff')
0019 process.load('SimGeneral.MixingModule.mixNoPU_cfi')
0020 process.load('Configuration.StandardSequences.DQMSaverAtRunEnd_cff')
0021 process.load('Configuration.StandardSequences.Harvesting_cff')
0022 process.load('DQMOffline.Configuration.DQMOfflineMC_cff')
0023 process.load('Configuration.StandardSequences.EndOfProcess_cff')
0024 process.load('Configuration.StandardSequences.FrontierConditions_GlobalTag_cff')
0025 
0026 process.maxEvents = cms.untracked.PSet(
0027     input = cms.untracked.int32(-1),
0028     output = cms.optional.untracked.allowed(cms.int32,cms.PSet)
0029 )
0030 
0031 # Input source
0032 process.source = cms.Source("DQMRootSource",
0033     fileNames = cms.untracked.vstring('file:step3_inDQM.root')
0034 )
0035 
0036 # Other statements
0037 from Configuration.AlCa.GlobalTag import GlobalTag
0038 process.GlobalTag = GlobalTag(process.GlobalTag, 'auto:phase1_2022_realistic', '')
0039 
0040 # Path and EndPath definitions
0041 if options.doSim:
0042     process.harvesting_step = cms.Path(process.cscDigiHarvesting)
0043 process.dqmsave_step = cms.Path(process.DQMSaver)
0044 process.endjob_step = cms.EndPath(process.endOfProcess)
0045 
0046 process.dqmSaver.workflow = '/{}/{}/{}'.format(options.dataSetTag,options.globalTag,options.cmssw)
0047 
0048 # Schedule definition
0049 process.schedule = cms.Schedule()
0050 
0051 if options.doSim:
0052     process.schedule.extend([process.harvesting_step])
0053 
0054 process.schedule.extend([process.endjob_step, process.dqmsave_step])