5 Module containing some utility tools
13 Creates and returns the configuration string for the ALCAPRODUCER step
14 starting from the list of AlcaReco path to be run.
20 step =
',ALCAPRODUCER:'+(
'+'.
join(skims))
28 Creates and returns the configuration string for the SKIM step
29 starting from the list of skims to be run.
34 if len(PhysicsSkims) >0 :
35 step =
',SKIM:'+(
'+'.
join(PhysicsSkims))
42 Add the monitoring services to the process provided
43 in order to write out performance summaries to the framework job report
45 import FWCore.ParameterSet.Config
as cms
47 process.SimpleMemoryCheck = cms.Service(
"SimpleMemoryCheck",
48 jobReportOutputOnly = cms.untracked.bool(
True)
50 process.Timing = cms.Service(
"Timing",
51 summaryOnly = cms.untracked.bool(
True)
61 Check attributes of process are appropriate for production
62 This method returns nothing but will throw a RuntimeError for any issues it finds
63 likely to cause problems in the production system
67 schedule=process.schedule_()
68 paths=process.paths_()
69 endpaths=process.endpaths_()
72 for outputModName
in process.outputModules_().
keys():
73 outputMod = getattr(process, outputModName)
74 if not hasattr(outputMod,
'dataset'):
75 msg =
"Process contains output module without dataset PSET: %s \n" % outputModName
76 msg +=
" You need to add this PSET to this module to set dataTier and filterName\n"
77 raise RuntimeError, msg
78 ds=getattr(outputMod,
'dataset')
79 if not hasattr(ds,
"dataTier"):
80 msg =
"Process contains output module without dataTier parameter: %s \n" % outputModName
81 msg +=
" You need to add an untracked parameter to the dataset PSET of this module to set dataTier\n"
82 raise RuntimeError, msg
89 if outputModName
in getattr(process,path).moduleNames():
92 if outputModName
in getattr(process,path).moduleNames():
96 if outputModName
in path.moduleNames():
99 msg =
"Output Module %s not in endPath" % outputModName
100 raise RuntimeError, msg
104 import FWCore.ParameterSet.Config
as cms
105 if args.get(
'newDQMIO',
False):
106 return cms.Source(
"DQMRootSource",
107 fileNames = cms.untracked(cms.vstring())
110 return cms.Source(
"PoolSource",
111 fileNames = cms.untracked(cms.vstring())
115 import FWCore.ParameterSet.Config
as cms
116 if rANDl
and (
not args.get(
'newDQMIO',
False)):
117 process.source.processingMode = cms.untracked.string(
'RunsAndLumis')
118 process.dqmSaver.workflow = datasetName
119 process.dqmSaver.saveByLumiSection = 1
120 if args.has_key(
'referenceFile')
and args.get(
'referenceFile',
''):
121 process.DQMStore.referenceFileName = cms.untracked.string(args[
'referenceFile'])
124 if args.has_key(
'outputs'):
125 options.outputDefinition = args[
'outputs'].
__str__()
127 writeTiers = args.get(
'writeTiers', [])
128 options.eventcontent =
','.
join(writeTiers)
129 options.datatier =
','.
join(writeTiers)
132 if 'dqmSeq' in args
and len(args[
'dqmSeq'])!=0:
133 return ':'+(
'+'.
join(args[
'dqmSeq']))
138 if args.has_key(
'globalTagConnect')
and args[
'globalTagConnect'] !=
'':
139 return globalTag +
','+args[
'globalTagConnect']
141 return globalTag +
',frontier://PromptProd/CMS_CONDITIONS'
static std::string join(char **cmd)