1 import FWCore.ParameterSet.Config
as cms
2 import FWCore.ParameterSet.VarParsing
as VarParsing
5 from dqmPythonTypes
import *
9 options.register(
'runNumber',
11 VarParsing.VarParsing.multiplicity.singleton,
12 VarParsing.VarParsing.varType.int,
15 options.register(
'runInputDir',
17 VarParsing.VarParsing.multiplicity.singleton,
18 VarParsing.VarParsing.varType.string,
19 "Directory where the DQM files will appear.")
21 options.register(
'scanOnce',
23 VarParsing.VarParsing.multiplicity.singleton,
24 VarParsing.VarParsing.varType.bool,
25 "Don't repeat file scans: use what was found during the initial scan. EOR file is ignored and the state is set to 'past end of run'.")
27 options.register(
'skipFirstLumis',
29 VarParsing.VarParsing.multiplicity.singleton,
30 VarParsing.VarParsing.varType.bool,
31 "Skip (and ignore the minEventsPerLumi parameter) for the files which have been available at the begining of the processing. ")
35 options.register (
'runkey',
37 VarParsing.VarParsing.multiplicity.singleton,
38 VarParsing.VarParsing.varType.string,
41 options.parseArguments()
48 if not options.runkey.strip():
49 options.runkey =
'pp_run'
51 runType.setRunType(options.runkey.strip())
54 nextLumiTimeoutMillis = 120000
59 nextLumiTimeoutMillis = 0
61 source = cms.Source(
"DQMProtobufReader",
62 runNumber = cms.untracked.uint32(options.runNumber),
63 runInputDir = cms.untracked.string(options.runInputDir),
65 streamLabel = cms.untracked.string(
'streamDQMHistograms'),
66 scanOnce = cms.untracked.bool(options.scanOnce),
68 delayMillis = cms.untracked.uint32(500),
69 nextLumiTimeoutMillis = cms.untracked.int32(nextLumiTimeoutMillis),
70 skipFirstLumis = cms.untracked.bool(options.skipFirstLumis),
71 deleteDatFiles = cms.untracked.bool(
False),
72 endOfRunKills = cms.untracked.bool(endOfRunKills),
75 print "Source:", source