Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

decouple EventContent_cff load from general purpose use of Merge.py #22937

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 2 additions & 2 deletions Configuration/DataProcessing/python/Merge.py
Expand Up @@ -10,7 +10,6 @@

from FWCore.ParameterSet.Config import Process, EndPath
from FWCore.ParameterSet.Modules import OutputModule, Source, Service
from Configuration.EventContent.EventContent_cff import NANOAODEventContent
import FWCore.ParameterSet.Types as CfgTypes


Expand Down Expand Up @@ -65,7 +64,8 @@ def mergeProcess(*inputFiles, **options):
if newDQMIO:
outMod = OutputModule("DQMRootOutputModule")
elif mergeNANO:
outMod = OutputModule("NanoAODOutputModule",NANOAODEventContent.clone())
import Configuration.EventContent.EventContent_cff
outMod = OutputModule("NanoAODOutputModule",Configuration.EventContent.EventContent_cff.NANOAODEventContent.clone())
else:
outMod = OutputModule("PoolOutputModule")

Expand Down
8 changes: 5 additions & 3 deletions Configuration/DataProcessing/test/RunMerge.py
Expand Up @@ -35,7 +35,8 @@ def __call__(self):
process_name = self.processName,
output_file = self.outputFile,
output_lfn = self.outputLFN,
newDQMIO = self.newDQMIO)
newDQMIO = self.newDQMIO,
mergeNANO = self.mergeNANO)
except Exception as ex:
msg = "Error creating process for Merge:\n"
msg += str(ex)
Expand All @@ -51,7 +52,7 @@ def __call__(self):


if __name__ == '__main__':
valid = ["input-files=", "output-file=", "output-lfn=", "dqmroot" ]
valid = ["input-files=", "output-file=", "output-lfn=", "dqmroot", "mergeNANO" ]

usage = """RunMerge.py <options>"""
try:
Expand All @@ -75,6 +76,7 @@ def __call__(self):
merger.outputLFN = arg
if opt == "--dqmroot" :
merger.newDQMIO = True

if opt == "--mergeNANO" :
merger.mergeNANO = True

merger()