version=cms.untracked.string('$Revision: 1.19 $'))

# Output definition

# Additional output definition

# Other statements
from HLTrigger.Configuration.CustomConfigs import ProcessName
process = ProcessName(process)

from Configuration.AlCa.GlobalTag import GlobalTag
process.GlobalTag = GlobalTag(process.GlobalTag, '92X_dataRun2_HLT_v7',
                              'L1Menu_Collisions2017_v4,L1TUtmTriggerMenuRcd')

from Analysis.Ntuplizer.TriggerFilter_cfi import triggerFilter
process.triggerFilter = triggerFilter
process.triggerFilter.hltResults = cms.InputTag("TriggerResults", "", "HLT2")
process.triggerFilter.triggerConditions = cms.vstring(
    'HLT_ZeroBias_v*',
    'HLT_Mu12_DoublePFJets40_CaloBTagCSV_p33_v*',
    'HLT_Mu12_DoublePFJets40_CaloBTagCSV0p80_px_v*',
    'HLT_Mu12_DoublePFJets40_CaloBTagCSV0p84_px_v*',
    'HLT_Mu12_DoublePFJets40_CaloBTagCSV0p88_px_v*',
    'HLT_Mu12_DoublePFJets40MaxDeta1p6_DoubleCaloBTagCSV_p33_v*',
    'HLT_Mu12_DoublePFJets40MaxDeta1p6_DoubleCaloBTagCSV0p80_px_v*',
    'HLT_Mu12_DoublePFJets40MaxDeta1p6_DoubleCaloBTagCSV0p84_px_v*',
    'HLT_Mu12_DoublePFJets40MaxDeta1p6_DoubleCaloBTagCSV0p88_px_v*',
    'HLT_DoublePFJets40_CaloBTagCSV_p33_v*',
    'HLT_DoublePFJets40_CaloBTagCSV0p80_px_v*',
    'HLT_DoublePFJets40_CaloBTagCSV0p84_px_v*',
    'HLT_DoublePFJets40_CaloBTagCSV0p88_px_v*',
示例#2
0
process.FilteredEvents = cms.EDProducer("EventCountProducer")

# pileup filter MC
process.RemovePileUpDominatedEventsGen = cms.EDFilter(
    "RemovePileUpDominatedEventsGen")

# Trigger filter (HLT config)
from Analysis.Ntuplizer.TriggerFilter_cfi import triggerFilter

# =========================
# Trigger config modifications
# Example triggers
#                                  'HLT_BTagMu_DiJet20_Mu5_v*',
#                                  'HLT_ZeroBias_BunchTrains_part*',
#                                  'HLT_ZeroBias_part0_v*',
process.triggerFilter = triggerFilter.clone()
process.triggerFilter.hltResults = cms.InputTag('TriggerResults', '', 'HLT')
process.triggerFilter.triggerConditions = cms.vstring(
    'HLT_BTagMu_DiJet20_Mu5_v*')
# =========================
# Filtering the trigger sequence
# comment or modified the lines below if no filter or other filters are required
if isMC:
    process.triggerFilter.hltResults = cms.InputTag('TriggerResults', '',
                                                    'HLT2')
    process.triggerFilter.triggerConditions = cms.vstring('HLT_ZeroBias_v*')
    process.HLTBeginSequence.insert(
        -1, process.RemovePileUpDominatedEventsGen)  # qcd MC
else:
    process.HLTBeginSequence.insert(-1, process.triggerFilter)  # data
# =========================