Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2021-02-14 13:33:02

0001 import FWCore.ParameterSet.Config as cms
0002 from PhysicsTools.PatAlgos.tools.helpers import getPatAlgosToolsTask
0003 from Configuration.Eras.Modifier_stage2L1Trigger_cff import stage2L1Trigger
0004 
0005 process = cms.Process("PAT", stage2L1Trigger)
0006 
0007 ## MessageLogger
0008 process.load("FWCore.MessageLogger.MessageLogger_cfi")
0009 
0010 ## Options and Output Report
0011 process.options = cms.untracked.PSet( wantSummary = cms.untracked.bool(True) )
0012 
0013 ## Source
0014 process.source = cms.Source("PoolSource",
0015     fileNames = cms.untracked.vstring()
0016 )
0017 ## Maximal Number of Events
0018 process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(100) )
0019 
0020 ## Geometry and Detector Conditions (needed for a few patTuple production steps)
0021 process.load("Configuration.Geometry.GeometryRecoDB_cff")
0022 process.load("Configuration.StandardSequences.FrontierConditions_GlobalTag_cff")
0023 from Configuration.AlCa.GlobalTag import GlobalTag
0024 process.GlobalTag = GlobalTag(process.GlobalTag, 'auto:run2_mc')
0025 process.load("Configuration.StandardSequences.MagneticField_cff")
0026 
0027 ## Output Module Configuration (expects a path 'p')
0028 from PhysicsTools.PatAlgos.patEventContent_cff import patEventContentNoCleaning
0029 process.out = cms.OutputModule("PoolOutputModule",
0030                                fileName = cms.untracked.string('patTuple.root'),
0031                                ## save only events passing the full path
0032                                #SelectEvents = cms.untracked.PSet( SelectEvents = cms.vstring('p') ),
0033                                ## save PAT output; you need a '*' to unpack the list of commands
0034                                ## 'patEventContent'
0035                                outputCommands = cms.untracked.vstring('drop *', *patEventContentNoCleaning )
0036                                )
0037 
0038 patAlgosToolsTask = getPatAlgosToolsTask(process)
0039 process.outpath = cms.EndPath(process.out, patAlgosToolsTask)