Skip to content

Commit

Permalink
Add more output options.
Browse files Browse the repository at this point in the history
  • Loading branch information
schneiml committed Dec 12, 2019
1 parent a99fdbf commit a101c5e
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 44 deletions.
43 changes: 0 additions & 43 deletions DQMServices/Demo/test/run_all_analyzers_cfg.py

This file was deleted.

31 changes: 30 additions & 1 deletion DQMServices/Demo/test/run_analyzers_cfg.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@
string = VarParsing.VarParsing.varType.string
parser.register('nolegacy', False, one, bool, "Don't run modules which block concurrent lumis.")
parser.register('noone', False, one, bool, "Don't run any one modules.")
parser.register('legacyoutput', False, one, bool, "Use DQMFileSaver for output instead of DQMIO.")
parser.register('protobufoutput', False, one, bool, "Use DQMFileSaverPB for output instead of DQMIO.")
parser.register('firstLuminosityBlock', 1, one, int, "See EmptySource.")
parser.register('firstEvent', 1, one, int, "See EmptySource.")
parser.register('firstRun', 1, one, int, "See EmptySource.")
Expand Down Expand Up @@ -68,6 +70,7 @@
else:
process.p = cms.Path(process.test_general + process.test_one + process.test_legacy)

# DQMIO output
process.out = cms.OutputModule(
"DQMRootOutputModule",
fileName = cms.untracked.string(args.outfile),
Expand All @@ -76,5 +79,31 @@
)
)

process.o = cms.EndPath(process.out)
# legacy output
process.dqmSaver = cms.EDAnalyzer("DQMFileSaver",
convention = cms.untracked.string('Offline'),
fileFormat = cms.untracked.string('ROOT'),
producer = cms.untracked.string('DQM'),
workflow = cms.untracked.string('/EmptySource/DQMTests/DQMIO'),
dirName = cms.untracked.string('.'),
saveByRun = cms.untracked.int32(-1),
saveAtJobEnd = cms.untracked.bool(True),
)

# protobuf output
process.pbSaver = cms.EDAnalyzer("DQMFileSaverPB",
producer = cms.untracked.string('DQM'),
path = cms.untracked.string('./'),
tag = cms.untracked.string('UNKNOWN'),
fakeFilterUnitMode = cms.untracked.bool(True),
streamLabel = cms.untracked.string("streamDQMHistograms"),
)


if args.legacyoutput:
process.o = cms.EndPath(process.dqmSaver)
elif args.protobufoutput:
process.o = cms.EndPath(process.pbSaver)
else:
process.o = cms.EndPath(process.out)

0 comments on commit a101c5e

Please sign in to comment.