Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-04-06 12:18:29

0001 #
0002 # cfg file to test HLTBeamModeFilter
0003 # it requires as input:
0004 #   a RAW data file (with FED 812 included) or 
0005 #   a digi data file, with L1GlobalTriggerEvmReadoutRecord product valid
0006 #
0007 # V.M. Ghete 2010-05-31
0008 #
0009 import FWCore.ParameterSet.Config as cms
0010 import sys
0011 
0012 useMC = False
0013 
0014 process = cms.Process('TestHLTBeamModeFilter')
0015 
0016 process.source = cms.Source('PoolSource', fileNames = cms.untracked.vstring())
0017 
0018 if useMC:
0019     gtName = 'auto:run2_mc_l1stage1'
0020     process.source.fileNames = ['/store/relval/CMSSW_5_3_6-START53_V14/RelValProdMinBias/GEN-SIM-RAW/v2/00000/52000D8A-032A-E211-BC94-00304867BFA8.root']
0021 else:
0022     gtName = 'auto:run2_data'
0023     process.source.fileNames = ['/store/data/Run2012A/MuEG/RAW/v1/000/191/718/14932935-E289-E111-830C-5404A6388697.root']
0024 
0025 # load and configure modules via GlobalTag
0026 # https://twiki.cern.ch/twiki/bin/view/CMS/SWGuideFrontierConditions
0027 process.load("Configuration.StandardSequences.FrontierConditions_GlobalTag_cff")
0028 from Configuration.AlCa.GlobalTag import GlobalTag
0029 process.GlobalTag = GlobalTag(process.GlobalTag, gtName, '')
0030 
0031 # number of events to be processed and source file
0032 process.maxEvents.input = 100
0033 
0034 from EventFilter.L1GlobalTriggerRawToDigi.l1GtEvmUnpack_cfi import l1GtEvmUnpack as _l1GtEvmUnpack
0035 process.gtEvmDigis = _l1GtEvmUnpack.clone(
0036     EvmGtInputTag = 'rawDataCollector',
0037     UnpackBxInEvent = 1,
0038     Verbosity = cms.untracked.int32(1) # set EVM unpacker to verbose
0039 )
0040 
0041 process.load('HLTrigger.HLTfilters.hltBeamModeFilter_cfi')
0042 # replacing arguments for hltBeamModeFilter
0043 #  InputTag for the L1 Global Trigger EVM readout record
0044 #   gtDigis        GT Emulator
0045 #   l1GtEvmUnpack  GT EVM Unpacker (default module name)
0046 #   gtEvmDigis     GT EVM Unpacker in RawToDigi standard sequence
0047 #
0048 #   cloned GT unpacker in HLT = gtEvmDigis
0049 process.hltBeamModeFilter.L1GtEvmReadoutRecordTag = 'gtEvmDigis'
0050 # vector of allowed beam modes (see enumeration in header file for implemented values)
0051 # default value: 11 (STABLE)
0052 #process.hltBeamModeFilter.AllowedBeamMode = [11]
0053 process.hltBeamModeFilter.AllowedBeamMode = [9, 10, 11]
0054 
0055 process.p = cms.Path(process.gtEvmDigis * process.hltBeamModeFilter)
0056 
0057 # services
0058 
0059 # Message Logger
0060 process.load('FWCore.MessageService.MessageLogger_cfi')
0061 process.MessageLogger.debugModules = ['gtEvmDigis', 'hltBeamModeFilter']
0062 process.MessageLogger.L1GlobalTriggerEvmRawToDigi = dict()
0063 process.MessageLogger.HLTBeamModeFilter = dict()
0064 
0065 process.MessageLogger.cerr.threshold = 'DEBUG'
0066 #process.MessageLogger.cerr.threshold = 'INFO'
0067 #process.MessageLogger.cerr.threshold = 'WARNING'
0068 #process.MessageLogger.cerr.threshold = 'ERROR'
0069 
0070 process.MessageLogger.cerr.DEBUG = cms.untracked.PSet( limit = cms.untracked.int32(0) )
0071 process.MessageLogger.cerr.INFO = cms.untracked.PSet( limit = cms.untracked.int32(0) )
0072 process.MessageLogger.cerr.WARNING = cms.untracked.PSet( limit = cms.untracked.int32(0) )
0073 process.MessageLogger.cerr.ERROR = cms.untracked.PSet( limit = cms.untracked.int32(0) )
0074 
0075 process.MessageLogger.cerr.L1GlobalTriggerEvmRawToDigi = cms.untracked.PSet( limit = cms.untracked.int32(-1) )
0076 process.MessageLogger.cerr.HLTBeamModeFilter = cms.untracked.PSet( limit = cms.untracked.int32(-1) )