CMS 3D CMS Logo

ScoutingMuon.h
Go to the documentation of this file.
1 #ifndef DataFormats_ScoutingMuon_h
2 #define DataFormats_ScoutingMuon_h
3 
4 #include <vector>
5 
6 // Class for holding muon information, for use in data scouting
7 // IMPORTANT: the content of this class should be changed only in backwards compatible ways!
8 class ScoutingMuon {
9 public:
10  //constructor with values for all data fields
12  float eta,
13  float phi,
14  float m,
15  float ecalIso,
16  float hcalIso,
17  float trackIso,
18  float chi2,
19  float ndof,
20  int charge,
21  float dxy,
22  float dz,
23  int nValidMuonHits,
24  int nValidPixelHits,
25  int nMatchedStations,
27  int type,
28  int nValidStripHits,
29  float trk_qoverp,
30  float trk_lambda,
31  float trk_pt,
32  float trk_phi,
33  float trk_eta,
34  float dxyError,
35  float dzError,
36  float trk_qoverpError,
37  float trk_lambdaError,
38  float trk_phiError,
39  float trk_dsz,
40  float trk_dszError,
41  std::vector<int> vtxIndx)
42  : pt_(pt),
43  eta_(eta),
44  phi_(phi),
45  m_(m),
46  ecalIso_(ecalIso),
47  hcalIso_(hcalIso),
48  trackIso_(trackIso),
49  chi2_(chi2),
50  ndof_(ndof),
51  charge_(charge),
52  dxy_(dxy),
53  dz_(dz),
54  nValidMuonHits_(nValidMuonHits),
55  nValidPixelHits_(nValidPixelHits),
56  nMatchedStations_(nMatchedStations),
57  nTrackerLayersWithMeasurement_(nTrackerLayersWithMeasurement),
58  type_(type),
59  nValidStripHits_(nValidStripHits),
60  trk_qoverp_(trk_qoverp),
61  trk_lambda_(trk_lambda),
62  trk_pt_(trk_pt),
63  trk_phi_(trk_phi),
64  trk_eta_(trk_eta),
65  dxyError_(dxyError),
66  dzError_(dzError),
67  trk_qoverpError_(trk_qoverpError),
68  trk_lambdaError_(trk_lambdaError),
69  trk_phiError_(trk_phiError),
70  trk_dsz_(trk_dsz),
71  trk_dszError_(trk_dszError),
72  vtxIndx_(std::move(vtxIndx)) {}
73  //default constructor
75  : pt_(0),
76  eta_(0),
77  phi_(0),
78  m_(0),
79  ecalIso_(0),
80  hcalIso_(0),
81  trackIso_(0),
82  chi2_(0),
83  ndof_(0),
84  charge_(0),
85  dxy_(0),
86  dz_(0),
87  nValidMuonHits_(0),
91  type_(0),
93  trk_qoverp_(0),
94  trk_lambda_(0),
95  trk_pt_(0),
96  trk_phi_(0),
97  trk_eta_(0),
98  dxyError_(0),
99  dzError_(0),
100  trk_qoverpError_(0),
101  trk_lambdaError_(0),
102  trk_phiError_(0),
103  trk_dsz_(0),
104  trk_dszError_(0),
105  vtxIndx_(0) {}
106 
107  //accessor functions
108  float pt() const { return pt_; }
109  float eta() const { return eta_; }
110  float phi() const { return phi_; }
111  float m() const { return m_; }
112  float ecalIso() const { return ecalIso_; }
113  float hcalIso() const { return hcalIso_; }
114  float trackIso() const { return trackIso_; }
115  float chi2() const { return chi2_; }
116  float ndof() const { return ndof_; }
117  int charge() const { return charge_; }
118  float dxy() const { return dxy_; }
119  float dz() const { return dz_; }
120  int nValidMuonHits() const { return nValidMuonHits_; }
121  int nValidPixelHits() const { return nValidPixelHits_; }
122  int nMatchedStations() const { return nMatchedStations_; }
124  int type() const { return type_; }
125  bool isGlobalMuon() const { return type_ & 1 << 1; }
126  bool isTrackerMuon() const { return type_ & 1 << 2; }
127  int nValidStripHits() const { return nValidStripHits_; }
128  float trk_qoverp() const { return trk_qoverp_; }
129  float trk_lambda() const { return trk_lambda_; }
130  float trk_pt() const { return trk_pt_; }
131  float trk_phi() const { return trk_phi_; }
132  float trk_eta() const { return trk_eta_; }
133  float dxyError() const { return dxyError_; }
134  float dzError() const { return dzError_; }
135  float trk_qoverpError() const { return trk_qoverpError_; }
136  float trk_lambdaError() const { return trk_lambdaError_; }
137  float trk_phiError() const { return trk_phiError_; }
138  float trk_dsz() const { return trk_dsz_; }
139  float trk_dszError() const { return trk_dszError_; }
140  std::vector<int> vtxIndx() const { return vtxIndx_; }
141 
142 private:
143  float pt_;
144  float eta_;
145  float phi_;
146  float m_;
147  float ecalIso_;
148  float hcalIso_;
149  float trackIso_;
150  float chi2_;
151  float ndof_;
152  int charge_;
153  float dxy_;
154  float dz_;
159  int type_;
161  float trk_qoverp_;
162  float trk_lambda_;
163  float trk_pt_;
164  float trk_phi_;
165  float trk_eta_;
166  float dxyError_;
167  float dzError_;
171  float trk_dsz_;
173  std::vector<int> vtxIndx_;
174 };
175 
176 typedef std::vector<ScoutingMuon> ScoutingMuonCollection;
177 
178 #endif
type
Definition: HCALResponse.h:21
int nValidStripHits() const
Definition: ScoutingMuon.h:127
int nTrackerLayersWithMeasurement() const
Definition: ScoutingMuon.h:123
int nValidPixelHits_
Definition: ScoutingMuon.h:156
std::vector< int > vtxIndx() const
Definition: ScoutingMuon.h:140
int nValidMuonHits() const
Definition: ScoutingMuon.h:120
float trk_lambdaError_
Definition: ScoutingMuon.h:169
float trk_lambdaError() const
Definition: ScoutingMuon.h:136
int nTrackerLayersWithMeasurement_
Definition: ScoutingMuon.h:158
int nMatchedStations() const
Definition: ScoutingMuon.h:122
float ecalIso() const
Definition: ScoutingMuon.h:112
float dxy() const
Definition: ScoutingMuon.h:118
float ndof() const
Definition: ScoutingMuon.h:116
float eta() const
Definition: ScoutingMuon.h:109
float trk_lambda() const
Definition: ScoutingMuon.h:129
bool isGlobalMuon() const
Definition: ScoutingMuon.h:125
float dzError() const
Definition: ScoutingMuon.h:134
float m() const
Definition: ScoutingMuon.h:111
float trk_qoverp() const
Definition: ScoutingMuon.h:128
float trk_phiError() const
Definition: ScoutingMuon.h:137
int type() const
Definition: ScoutingMuon.h:124
float pt() const
Definition: ScoutingMuon.h:108
float trk_phi() const
Definition: ScoutingMuon.h:131
bool isTrackerMuon() const
Definition: ScoutingMuon.h:126
std::vector< int > vtxIndx_
Definition: ScoutingMuon.h:173
float chi2() const
Definition: ScoutingMuon.h:115
float trk_pt() const
Definition: ScoutingMuon.h:130
float trk_dszError() const
Definition: ScoutingMuon.h:139
float trk_eta() const
Definition: ScoutingMuon.h:132
float dxyError() const
Definition: ScoutingMuon.h:133
std::vector< ScoutingMuon > ScoutingMuonCollection
Definition: ScoutingMuon.h:176
float trk_dszError_
Definition: ScoutingMuon.h:172
float trackIso() const
Definition: ScoutingMuon.h:114
float dz() const
Definition: ScoutingMuon.h:119
ScoutingMuon(float pt, float eta, float phi, float m, float ecalIso, float hcalIso, float trackIso, float chi2, float ndof, int charge, float dxy, float dz, int nValidMuonHits, int nValidPixelHits, int nMatchedStations, int nTrackerLayersWithMeasurement, int type, int nValidStripHits, float trk_qoverp, float trk_lambda, float trk_pt, float trk_phi, float trk_eta, float dxyError, float dzError, float trk_qoverpError, float trk_lambdaError, float trk_phiError, float trk_dsz, float trk_dszError, std::vector< int > vtxIndx)
Definition: ScoutingMuon.h:11
int nValidStripHits_
Definition: ScoutingMuon.h:160
float trk_lambda_
Definition: ScoutingMuon.h:162
int nMatchedStations_
Definition: ScoutingMuon.h:157
int charge() const
Definition: ScoutingMuon.h:117
float trk_qoverpError_
Definition: ScoutingMuon.h:168
float trk_qoverpError() const
Definition: ScoutingMuon.h:135
float phi() const
Definition: ScoutingMuon.h:110
float trk_qoverp_
Definition: ScoutingMuon.h:161
float trk_phiError_
Definition: ScoutingMuon.h:170
def move(src, dest)
Definition: eostools.py:511
int nValidPixelHits() const
Definition: ScoutingMuon.h:121
float trk_dsz() const
Definition: ScoutingMuon.h:138
float hcalIso() const
Definition: ScoutingMuon.h:113