Back to home page

Project CMSSW displayed by LXR

 
 

    


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

0001 import FWCore.ParameterSet.Config as cms
0002 
0003 def customiseForRunningOnMC(process, pathName) :
0004 
0005     if hasattr(process,"muNtupleProducer") :
0006         print("[customiseForRunningOnMC]: updating ntuple input tags")
0007         
0008         process.muNtupleTwinMuxInFiller.dtTpTag = "none"
0009         process.muNtupleTwinMuxOutFiller.dtTpTag = "none"
0010         process.muNtupleTwinMuxInThFiller.dtTpTag = "none"
0011 
0012     return process
0013 
0014 def customiseForMuonWorkflow(process) :
0015     print("[customiseForMuonWorkflow]: adding VarParsing")
0016 
0017     import FWCore.ParameterSet.VarParsing as VarParsing
0018     options = VarParsing.VarParsing()
0019 
0020     options.register('globalTag',
0021                      '130X_dataRun3_Express_v1', #default value
0022                       VarParsing.VarParsing.multiplicity.singleton,
0023                       VarParsing.VarParsing.varType.string,
0024                       "Global Tag")
0025 
0026     options.register('nEvents',
0027                       100, #default value
0028                       VarParsing.VarParsing.multiplicity.singleton,
0029                       VarParsing.VarParsing.varType.int,
0030                       "Maximum number of processed events")
0031 
0032     options.parseArguments()
0033 
0034     process.GlobalTag.globaltag = cms.string(options.globalTag)
0035     process.maxEvents = cms.untracked.PSet(input = cms.untracked.int32(options.nEvents))
0036 
0037     return process