CMS 3D CMS Logo

MuonRecoAnalyzer.h
Go to the documentation of this file.
1 #ifndef MuonRecoAnalyzer_H
2 #define MuonRecoAnalyzer_H
3 
11 #include <memory>
12 #include <fstream>
19 
23 
25 
32 
33 
35  public:
36 
39 
41  ~MuonRecoAnalyzer() override;
42 
44  void analyze(const edm::Event&, const edm::EventSetup&) override;
45  void bookHistograms(DQMStore::IBooker &, edm::Run const &, edm::EventSetup const &) override;
46 
47  //calculate residual & pull:
48  void GetRes( reco::TrackRef t1, reco::TrackRef t2, std::string par, float &res, float &pull);
49 
50  //Functions needed by the SoftMuon MVA monitoring
51  double getDeltaR(reco::Track track1, reco::Track track2);
52 
53  int getPv(int tidx, const reco::VertexCollection *vc);
54 
55  private:
56  // ----------member data ---------------------------
59 
64 
65 
66  // Switch for verbosity
68  bool doMVA;
69 
70  //histo binning parameters
71  int etaBin;
72  double etaMin;
73  double etaMax;
74 
75  int thetaBin;
76  double thetaMin;
77  double thetaMax;
78 
79  int phiBin;
80  double phiMin;
81  double phiMax;
82 
83  int chi2Bin;
84  double chi2Min;
85  double chi2Max;
86 
87  int pBin;
88  double pMin;
89  double pMax;
90 
91  int ptBin;
92  double ptMin;
93  double ptMax;
94 
95  int pResBin;
96  double pResMin;
97  double pResMax;
98 
99  int rhBin;
100  double rhMin;
101  double rhMax;
102 
103  int tunePBin;
104  double tunePMin;
105  double tunePMax;
106 
107 
108  //the histos
110  // global muon
111  std::vector<MonitorElement*> etaGlbTrack;
112  std::vector<MonitorElement*> etaResolution;
113  std::vector<MonitorElement*> thetaGlbTrack;
114  std::vector<MonitorElement*> thetaResolution;
115  std::vector<MonitorElement*> phiGlbTrack;
116  std::vector<MonitorElement*> phiResolution;
117  std::vector<MonitorElement*> chi2OvDFGlbTrack;
118  std::vector<MonitorElement*> probchi2GlbTrack;
119  std::vector<MonitorElement*> pGlbTrack;
120  std::vector<MonitorElement*> ptGlbTrack;
121  std::vector<MonitorElement*> qGlbTrack;
122  std::vector<MonitorElement*> qOverpResolution;
123  std::vector<MonitorElement*> qOverptResolution;
124  std::vector<MonitorElement*> oneOverpResolution;
125  std::vector<MonitorElement*> oneOverptResolution;
126  std::vector<MonitorElement*> rhAnalysis;
127  std::vector<MonitorElement*> muVStkSytemRotation;
128  std::vector<MonitorElement*> phiVsetaGlbTrack;
129  std::vector<MonitorElement*> phiVsetaGlbTrack_badlumi;
130 
131 
132  //Soft MVA Muon
163 
164 
166 
174 
175  // tracker muon
184  // sta muon
193  // efficiency
194  std::vector<MonitorElement*> etaEfficiency;
195  std::vector<MonitorElement*> phiEfficiency;
196 
197  bool IsminiAOD;
199 };
200 #endif
MonitorElement * NTrkVHitsSoftMuonMVA
MonitorElement * muReco
std::vector< MonitorElement * > oneOverpResolution
MonitorElement * deltaRSoftMuonMVA
MonitorElement * trkRelChi2SoftMuonMVA
MonitorElement * qOverptPull
std::vector< MonitorElement * > ptGlbTrack
std::vector< MonitorElement * > chi2OvDFGlbTrack
std::vector< MonitorElement * > phiVsetaGlbTrack_badlumi
MonitorElement * gNchi2SoftMuonMVA
std::vector< MonitorElement * > phiVsetaGlbTrack
MonitorElement * getMuonHitsPerStationSoftMuonMVA
MonitorElement * segCompSoftMuonMVA
MonitorElement * iValFracSoftMuonMVA
MonitorElement * outerChi2SoftMuonMVA
MonitorElement * etaStaTrack
MonitorElement * vRPChitsSoftMuonMVA
std::vector< Vertex > VertexCollection
collection of Vertex objects
Definition: VertexFwd.h:9
MonitorElement * dzRefSoftMuonMVA
edm::EDGetTokenT< DcsStatusCollection > dcsStatusCollection_
std::vector< MonitorElement * > phiGlbTrack
MonitorElement * LWHSoftMuonMVA
MonitorElement * chi2OvDFStaTrack
MuonServiceProxy * theService
MonitorElement * vMuHitsSoftMuonMVA
MonitorElement * phiStaTrack
MonitorElement * vDThitsSoftMuonMVA
std::string theFolder
MonitorElement * qOverpPull
Definition: Electron.h:6
void analyze(const edm::Event &, const edm::EventSetup &) override
Inizialize parameters for histo binning.
std::vector< MonitorElement * > phiEfficiency
MonitorElement * mNuStationsSoftMuonMVA
MonitorElement * etaTrack
MonitorElement * innerChi2SoftMuonMVA
double getDeltaR(reco::Track track1, reco::Track track2)
MonitorElement * chi2OvDFTrack
std::vector< MonitorElement * > qOverptResolution
std::vector< MonitorElement * > etaGlbTrack
std::vector< MonitorElement * > pGlbTrack
std::vector< MonitorElement * > qOverpResolution
MonitorElement * timeAtIpInOutSoftMuonMVA
MonitorElement * oneOverpPull
std::string metname
MonitorElement * valPixHitsSoftMuonMVA
std::vector< MonitorElement * > qGlbTrack
MonitorElement * pTrack
MonitorElement * timeAtIpInOutErrSoftMuonMVA
std::vector< MonitorElement * > probchi2GlbTrack
std::vector< MonitorElement * > etaResolution
edm::EDGetTokenT< reco::BeamSpot > theBeamSpotLabel_
MonitorElement * ptSoftMuonMVA
MonitorElement * oneOverptPull
MonitorElement * tunePResolution
MonitorElement * glbKinkFinderLogSoftMuonMVA
std::vector< MonitorElement * > etaEfficiency
MonitorElement * dxyRefSoftMuonMVA
void GetRes(reco::TrackRef t1, reco::TrackRef t2, std::string par, float &res, float &pull)
MonitorElement * staRelChi2SoftMuonMVA
MonitorElement * thetaStaTrack
void bookHistograms(DQMStore::IBooker &, edm::Run const &, edm::EventSetup const &) override
edm::EDGetTokenT< edm::View< reco::Muon > > theMuonCollectionLabel_
std::vector< MonitorElement * > phiResolution
edm::ParameterSet parameters
MonitorElement * chi2LocMomSoftMuonMVA
std::vector< MonitorElement * > thetaGlbTrack
int getPv(int tidx, const reco::VertexCollection *vc)
MonitorElement * phiPull
MonitorElement * phiTrack
MonitorElement * vCSChitsSoftMuonMVA
std::vector< MonitorElement * > oneOverptResolution
MonitorElement * probchi2Track
std::vector< MonitorElement * > muVStkSytemRotation
MonitorElement * kinkFinderSoftMuonMVA
MonitorElement * ptTrack
MonitorElement * glbKinkFinderSoftMuonMVA
MonitorElement * chi2LocPosSoftMuonMVA
MonitorElement * glbDeltaEtaPhiSoftMuonMVA
MonitorElement * QprodSoftMuonMVA
MonitorElement * probchi2StaTrack
MonitorElement * ptStaTrack
std::vector< MonitorElement * > rhAnalysis
MonitorElement * etaPull
MonitorElement * pStaTrack
~MuonRecoAnalyzer() override
Destructor.
MonitorElement * thetaTrack
std::vector< MonitorElement * > thetaResolution
MonitorElement * glbTrackTailProbSoftMuonMVA
MonitorElement * qTrack
MonitorElement * thetaPull
Definition: Run.h:44
MonitorElement * qStaTrack
MuonRecoAnalyzer(const edm::ParameterSet &)
Constructor.
edm::EDGetTokenT< reco::VertexCollection > theVertexLabel_