CMS 3D CMS Logo

L1TMuonDQMOffline_cfi.py
Go to the documentation of this file.
1 import FWCore.ParameterSet.Config as cms
2 
3 # define binning for efficiency plots
4 # pt
5 effVsPtBins = range(0, 30, 1)
6 effVsPtBins += range(30, 50, 2)
7 effVsPtBins += range(50, 70, 5)
8 effVsPtBins += range(70, 100, 10)
9 effVsPtBins += range(100, 200, 25)
10 effVsPtBins += range(200, 300, 50)
11 effVsPtBins += range(300, 500, 100)
12 effVsPtBins += range(500, 700, 200)
13 effVsPtBins += range(700, 1000, 300)
14 effVsPtBins.append(1000)
15 
16 # phi
17 nPhiBins = 34
18 phiMin = -3.4
19 phiMax = 3.4
20 effVsPhiBins = [i*(phiMax-phiMin)/nPhiBins + phiMin for i in range(nPhiBins+1)]
21 
22 # eta
23 nEtaBins = 50
24 etaMin = -2.5
25 etaMax = 2.5
26 effVsEtaBins = [i*(etaMax-etaMin)/nEtaBins + etaMin for i in range(nEtaBins+1)]
27 
28 # vtx
29 effVsVtxBins = range(0, 101)
30 
31 # A list of pt cut + quality cut pairs for which efficiency plots should be made
32 ptQualCuts = [[25, 12], [15, 8], [7, 8], [3, 4]]
33 cutsPSets = []
34 for ptQualCut in ptQualCuts:
35  cutsPSets.append(cms.untracked.PSet(ptCut = cms.untracked.int32(ptQualCut[0]),
36  qualCut = cms.untracked.int32(ptQualCut[1])))
37 
38 from DQMServices.Core.DQMEDAnalyzer import DQMEDAnalyzer
39 l1tMuonDQMOffline = DQMEDAnalyzer('L1TMuonDQMOffline',
40  histFolder = cms.untracked.string('L1T/L1TObjects/L1TMuon/L1TriggerVsReco'),
41  tagPtCut = cms.untracked.double(30.),
42  recoToL1PtCutFactor = cms.untracked.double(1.25),
43  cuts = cms.untracked.VPSet(cutsPSets),
44  useL1AtVtxCoord = cms.untracked.bool(True),
45 
46  muonInputTag = cms.untracked.InputTag("muons"),
47  gmtInputTag = cms.untracked.InputTag("gmtStage2Digis","Muon"),
48  vtxInputTag = cms.untracked.InputTag("offlinePrimaryVertices"),
49  bsInputTag = cms.untracked.InputTag("offlineBeamSpot"),
50 
51  triggerNames = cms.untracked.vstring(
52  "HLT_IsoMu27_v*",
53  "HLT_IsoMu30_v*"
54  ),
55  trigInputTag = cms.untracked.InputTag("hltTriggerSummaryAOD", "", "HLT"),
56  trigProcess = cms.untracked.string("HLT"),
57  trigProcess_token = cms.untracked.InputTag("TriggerResults","","HLT"),
58 
59  efficiencyVsPtBins = cms.untracked.vdouble(effVsPtBins),
60  efficiencyVsPhiBins = cms.untracked.vdouble(effVsPhiBins),
61  efficiencyVsEtaBins = cms.untracked.vdouble(effVsEtaBins),
62  efficiencyVsVtxBins = cms.untracked.vdouble(effVsVtxBins),
63 
64  verbose = cms.untracked.bool(False)
65 )
66 
67 # modifications for the pp reference run
68 # A list of pt cut + quality cut pairs for which efficiency plots should be made
69 ptQualCuts_HI = [[12, 12], [7, 8], [5, 4]]
70 cutsPSets_HI = []
71 for ptQualCut in ptQualCuts_HI:
72  cutsPSets_HI.append(cms.untracked.PSet(ptCut = cms.untracked.int32(ptQualCut[0]),
73  qualCut = cms.untracked.int32(ptQualCut[1])))
74 from Configuration.Eras.Modifier_ppRef_2017_cff import ppRef_2017
75 ppRef_2017.toModify(l1tMuonDQMOffline,
76  tagPtCut = cms.untracked.double(14.),
77  cuts = cms.untracked.VPSet(cutsPSets_HI),
78  triggerNames = cms.untracked.vstring(
79  "HLT_HIL3Mu12_v*",
80  )
81 )
82