ATLAS Offline Software
MSVtxValidationAlg.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2025 CERN for the benefit of the ATLAS collaboration
3 */
4 
6 
7 #include "MSVtxValidationAlg.h"
8 #include "Utils.h"
9 
10 
11 using namespace MSVtxValidationAlgUtils;
12 
13 namespace{
14  constexpr int default_d = -99999;
15  constexpr float default_f = -99999.;
16 }
17 
18 
20  ATH_MSG_DEBUG ("Initializing " << name() << "...");
21 
22  ATH_CHECK(m_evtKey.initialize());
23  ATH_CHECK(m_TruthParticleKey.initialize());
24  ATH_CHECK(m_TrackParticleKey.initialize(m_computeIso));
25  ATH_CHECK(m_JetKey.initialize(m_readJets || m_computeIso));
26  ATH_CHECK(m_MetKey.initialize(m_readMET));
27  ATH_CHECK(m_TrackletKey.initialize());
28  ATH_CHECK(m_MSVtxKey.initialize());
29 
30  ATH_CHECK(m_trigDec.retrieve());
31  ATH_CHECK(m_matchingTool.retrieve());
32 
33  // attach branches to the tree
34  m_tree.addBranch(std::make_unique<MuonVal::EventInfoBranch>(m_tree, 0));
35 
36  // truth TrackParticles
37  m_truthParticle = std::make_shared<MuonVal::IParticleFourMomBranch>(m_tree, "truthParticle");
38  m_truthParticle->addVariableGeV<float>(default_f, "m");
39  m_truthParticle->addVariable<int>(default_d, "pdgId");
40  m_truthParticle->addVariable<float>(default_f, "pX");
41  m_truthParticle->addVariable<float>(default_f, "pY");
42  m_truthParticle->addVariable<float>(default_f, "pZ");
43  m_tree.addBranch(m_truthParticle);
44 
45  // portal
46  m_portal = std::make_shared<MuonVal::IParticleFourMomBranch>(m_tree, "portal");
47  m_portal->addVariableGeV<float>(default_f, "m");
48  m_tree.addBranch(m_portal);
49 
50  // LLP
51  m_llp = std::make_shared<MuonVal::IParticleFourMomBranch>(m_tree, "llp");
52  m_llp->addVariableGeV<float>(default_f, "m");
53  m_tree.addBranch(m_llp);
54 
55  if (!m_computeIso){
56  m_tree.disableBranch("msVtx_isoTracks_mindR");
57  m_tree.disableBranch("msVtx_isoTracks_pTsum");
58  m_tree.disableBranch("msVtx_isoJets_mindR");
59  }
60 
61  // muon segments: dumps the entire muon segment container without needing an explicit fill call
62  m_muonSeg = std::make_shared<MuonPRDTest::SegmentVariables>(m_tree, m_MuonSegKey, "muonSeg", msgLevel());
63  m_tree.addBranch(m_muonSeg);
64 
65  // jets
66  if (m_readJets){
67  m_jet = std::make_shared<MuonVal::IParticleFourMomBranch>(m_tree, "jet");
68  m_jet->addVariableGeV<float>(default_f, "m");
69  m_tree.addBranch(m_jet);
70  }
71  else m_tree.disableBranch("jet_N");
72 
73  // met
74  if (!m_readMET){
75  m_tree.disableBranch("met");
76  m_tree.disableBranch("met_x");
77  m_tree.disableBranch("met_y");
78  m_tree.disableBranch("met_phi");
79  }
80 
81 
82  ATH_CHECK(m_tree.init(this));
83 
84  // --- //
85  // Book output histograms following the THistSvc recommendation on managing ownership. Register via histSvc()->regHist("/<stream>/histName", rawHistPtr); //
86  // --- //
87 
88  // llp pair
89  auto h_LLP1LLP2dR = std::make_unique<TH1F>("h_LLP1LLP2dR","h_LLP1LLP2dR; #Delta R(LLP1, LLP2); Count / bin",50,0,4);
90  m_h_LLP1LLP2dR = h_LLP1LLP2dR.get();
91  ATH_CHECK(histSvc()->regHist("/MSVtxValidation/h_LLP1LLP2dR", std::move(h_LLP1LLP2dR)));
92 
93  auto h_diLLPMass = std::make_unique<TH1F>("h_diLLPMass","h_diLLPMass; m_{LL1, LLP2} [GeV]; Count / bin",50,0,1000);
94  m_h_diLLPMass = h_diLLPMass.get();
95  ATH_CHECK(histSvc()->regHist("/MSVtxValidation/h_diLLPMass", std::move(h_diLLPMass)));
96 
97  // leading LLP
98  auto h_leadLLPLxy = std::make_unique<TH1F>("h_leadLLPLxy","h_leadLLPLxy; lead LLP L_{xy} [mm]; Count / bin",50,0,10000);
99  m_h_leadLLPLxy = h_leadLLPLxy.get();
100  ATH_CHECK(histSvc()->regHist("/MSVtxValidation/h_leadLLPLxy", std::move(h_leadLLPLxy)));
101 
102  auto h_leadLLPLz = std::make_unique<TH1F>("h_leadLLPLz","h_leadLLPLz; lead LLP L_{z} [mm]; Count / bin",50,0,14000);
103  m_h_leadLLPLz = h_leadLLPLz.get();
104  ATH_CHECK(histSvc()->regHist("/MSVtxValidation/h_leadLLPLz", std::move(h_leadLLPLz)));
105 
106  auto h_leadLLPctau = std::make_unique<TH1F>("h_leadLLPctau","h_leadLLPctau; lead LLP c#tau [mm]; Count / bin",50,0,2000);
107  m_h_leadLLPctau = h_leadLLPctau.get();
108  ATH_CHECK(histSvc()->regHist("/MSVtxValidation/h_leadLLPctau", std::move(h_leadLLPctau)));
109 
110  auto h_leadLLPpt = std::make_unique<TH1F>("h_leadLLPpt","h_leadLLPpt; lead LLP p_{T} [GeV]; Count / bin",50,0,400);
111  m_h_leadLLPpt = h_leadLLPpt.get();
112  ATH_CHECK(histSvc()->regHist("/MSVtxValidation/h_leadLLPpt", std::move(h_leadLLPpt)));
113 
114  // subleading LLP
115  auto h_subleadLLPLxy = std::make_unique<TH1F>("h_subleadLLPLxy","h_subleadLLPLxy; sublead LLP L_{xy} [mm]; Count / bin",50,0,10000);
116  m_h_subleadLLPLxy = h_subleadLLPLxy.get();
117  ATH_CHECK(histSvc()->regHist("/MSVtxValidation/h_subleadLLPLxy", std::move(h_subleadLLPLxy)));
118 
119  auto h_subleadLLPLz = std::make_unique<TH1F>("h_subleadLLPLz","h_subleadLLPLz; sublead LLP L_{z} [mm]; Count / bin",50,0,10000);
120  m_h_subleadLLPLz = h_subleadLLPLz.get();
121  ATH_CHECK(histSvc()->regHist("/MSVtxValidation/h_subleadLLPLz", std::move(h_subleadLLPLz)));
122 
123  auto h_subleadLLPctau = std::make_unique<TH1F>("h_subleadLLPctau","h_subleadLLPctau; sublead LLP c#tau [mm]; Count / bin",50,0,2000);
124  m_h_subleadLLPctau = h_subleadLLPctau.get();
125  ATH_CHECK(histSvc()->regHist("/MSVtxValidation/h_subleadLLPctau", std::move(h_subleadLLPctau)));
126 
127  auto h_subleadLLPpt = std::make_unique<TH1F>("h_subleadLLPpt","h_subleadLLPpt; sublead LLP p_{T} [GeV]; Count / bin",50,0,400);
128  m_h_subleadLLPpt = h_subleadLLPpt.get();
129  ATH_CHECK(histSvc()->regHist("/MSVtxValidation/h_subleadLLPpt", std::move(h_subleadLLPpt)));
130 
131  return StatusCode::SUCCESS;
132 }
133 
134 
135 StatusCode MSVtxValidationAlg::fillTruth(const EventContext& ctx){
136  // Fill truth particle branches and histograms
137  const xAOD::TruthParticleContainer* truth_particles{nullptr};
138  ATH_CHECK(SG::get(truth_particles, m_TruthParticleKey, ctx));
139 
140  // dump the TruthParticle information and collect portal, LLPs
141  std::vector<const xAOD::TruthParticle*> portals{}, llps{};
142  for(const xAOD::TruthParticle* tp : *truth_particles){
143  if (!tp) continue;
144  m_truthParticle->push_back(tp);
145  // set default link index to vertex to -1
146  m_truthParticle_llpVtx_link_tmp->push_back(-1); // adjust in LLP children loop
147  m_truthParticle_jetVtx_link_tmp->push_back(-1); // adjust in fillJet
148 
149  // fill vector of portal particles, skipping the particle if it is a self-decay
150  if(std::abs(tp->pdgId()) == m_pdgId_portal){
151  bool selfdecay = false;
152  for (size_t p = 0; p < tp->production_vertex()->nIncomingParticles(); ++p) if (tp->parent(p)->pdgId() == tp->pdgId()) { selfdecay = true; break;}
153  if (!selfdecay) portals.push_back(tp);
154  }
155 
156  // fill vector of LLPs
157  if(std::abs(tp->pdgId()) == m_pdgId_llp) llps.push_back(tp);
158  }
159 
160  // portal
161  m_portal_N = portals.size();
162  for(const xAOD::TruthParticle* portal : portals) m_portal->push_back(portal);
163 
164  // LLP and LLP children
165  m_llp_N = llps.size();
166  std::sort(llps.begin(), llps.end(), comparePt); // sort llps by pT
167  const xAOD::TruthParticle* leadLLP = nullptr;
168  const xAOD::TruthParticle* subleadLLP = nullptr;
169 
170  int num_vtx = 0;
171  for(unsigned int llp_idx=0; const xAOD::TruthParticle* llp : llps){
172  m_llp->push_back(llp);
173 
174  if(llp->hasDecayVtx()){
175  const xAOD::TruthVertex* decVtx = llp->decayVtx();
176  m_llpVtx_pos.push_back(decVtx->v4().Vect());
177  m_llpVtx_Lxy.push_back(decVtx->perp());
178  m_llpVtx_ctau.push_back(getCTau(decVtx));
179  ++num_vtx;
180  }
181 
182  // leading LLP
183  if(llp_idx==0){
184  if(llp->hasDecayVtx()){
185  const xAOD::TruthVertex* decVtx = llp->decayVtx();
186  m_h_leadLLPLxy->Fill(decVtx->perp());
187  m_h_leadLLPLz->Fill(decVtx->z());
188  m_h_leadLLPctau->Fill(getCTau(decVtx));
189  }
190  m_h_leadLLPpt->Fill(llp->pt()/Gaudi::Units::GeV);
191  leadLLP = llp;
192  }
193  // subleading llp
194  if(llp_idx==1){
195  if(llp->hasDecayVtx()){
196  const xAOD::TruthVertex* decVtx = llp->decayVtx();
197  m_h_subleadLLPLxy->Fill(decVtx->perp());
198  m_h_subleadLLPLz->Fill(decVtx->z());
199  m_h_subleadLLPctau->Fill(getCTau(decVtx));
200  }
201  m_h_subleadLLPpt->Fill(llp->pt()/Gaudi::Units::GeV);
202  subleadLLP = llp;
203 
204  // di-llp histograms
205  TLorentzVector llpSum = subleadLLP->p4()+leadLLP->p4();
206  m_h_LLP1LLP2dR->Fill(leadLLP->p4().DeltaR(subleadLLP->p4()));
207  m_h_diLLPMass->Fill(llpSum.E()/Gaudi::Units::GeV);
208  }
209 
210  // LLP children
211  if (llp->hasDecayVtx() && llp->nChildren()>0 && !llp->isGenStable()){
212  std::vector<const xAOD::TruthParticle*> stableChildren = getStableChildren(llp, m_llp_genStableChildren);
213  m_llp_Nchildren.push_back((int)stableChildren.size());
214  // update links between LLP and its stable children
215  for (const xAOD::TruthParticle *child : stableChildren) m_truthParticle_llpVtx_link_tmp->at(child->index()) = llp_idx;
216  }
217  ++llp_idx;
218  }
219  m_llpVtx_N = num_vtx;
220  // copy linking data from temp vector and clear the temp vector for the next event
221  for (int link : *m_truthParticle_llpVtx_link_tmp) m_truthParticle_llpVtx_link.push_back(link);
222  m_truthParticle_llpVtx_link_tmp->clear();
223 
224 
225  return StatusCode::SUCCESS;
226 }
227 
228 
229 StatusCode MSVtxValidationAlg::fillJet(const EventContext& ctx){
230  if (!m_readJets) return StatusCode::SUCCESS;
231 
232  const xAOD::JetContainer* jets{nullptr};
233  ATH_CHECK(SG::get(jets, m_JetKey, ctx));
234 
235  const Trig::ChainGroup* chain = m_trigDec->getChainGroup(m_triggerString);
236  const std::vector<std::string> triggerNames = chain->getListOfTriggers();
237  // get the trigger decision for this event
238  std::vector<bool> triggerPassed{};
239  for (const std::string& triggerName : triggerNames) {
240  if (m_trigDec->isPassed(triggerName)) triggerPassed.push_back(true);
241  else triggerPassed.push_back(false);
242  }
243 
244  m_jet_N = jets->size();
245  bool jetFiredTrigger = false;
246  for (const xAOD::Jet* jet : *jets) {
247  m_jet->push_back(jet);
248  // fill trigger decisions for each jet
249  for (size_t i = 0; i < triggerNames.size(); ++i) {
250  if (!triggerPassed[i]) continue; // skip if trigger not passed
251  if (m_matchingTool->match(*jet, triggerNames[i], m_jetTriggerMatchingDR, false)) {
252  jetFiredTrigger = true;
253  m_jet_triggers.push_back(1);
254  break; // this jet has fired one for the triggers in the chain so do not need to check the other triggers
255  }
256  }
257  if (!jetFiredTrigger) m_jet_triggers.push_back(0);
258  jetFiredTrigger = false; // reset for the next jet
259 
260  if (m_computeJetVtx) ATH_CHECK(fillJetVtx(ctx, jet));
261  }
262 
263  // copy linking data from temp vector and clear the temp vector for the next event
264  for (int link : *m_truthParticle_jetVtx_link_tmp) m_truthParticle_jetVtx_link.push_back(link);
265  m_truthParticle_jetVtx_link_tmp->clear();
266 
267  return StatusCode::SUCCESS;
268 }
269 
270 
271 StatusCode MSVtxValidationAlg::fillJetVtx(const EventContext& ctx, const xAOD::Jet* jet){
272  // fill jet branches with an approximation with displaced vertex approx
273  const xAOD::TruthParticleContainer* truth_particles{nullptr};
274  ATH_CHECK(SG::get(truth_particles, m_TruthParticleKey, ctx));
275 
276  JetVtxApprox jetVtx = getJetVtxApprox(jet, *truth_particles);
277 
278  if (!jetVtx.vtx) {
279  m_jet_jetVtx_link.push_back(-1); // no suitable truth particles are close to the jet such that no vertex can be identified
280  return StatusCode::SUCCESS;
281  }
282  size_t currNjetVtx = m_jetVtx_NChildren.size(); // the current number of jet vertices
283  m_jetVtx_pos.push_back(jetVtx.vtx->v4().Vect());
284  m_jetVtx_jet_dEta.push_back(jet->eta() - jetVtx.vtx->v4().Eta());
285  m_jetVtx_jet_dPhi.push_back(jet->p4().DeltaPhi(jetVtx.vtx->v4()));
286  m_jetVtx_NChildren.push_back(jetVtx.nChildren);
287  m_jetVtx_chainDepth.push_back(jetVtx.decayDepth);
288 
289  // link between jet and jet vertex
290  m_jet_jetVtx_link.push_back(currNjetVtx);
291  // update the linking between TruthParticles and the jet vertex
292  for (auto tpLink : jetVtx.vtx->outgoingParticleLinks()) {
293  if (!tpLink) continue;
294  m_truthParticle_jetVtx_link_tmp->at(tpLink.index()) = currNjetVtx; // each TP daughter of the jet vertex is labeled by the jet vertex index
295  }
296 
297  return StatusCode::SUCCESS;
298 }
299 
300 
301 StatusCode MSVtxValidationAlg::fillMet(const EventContext& ctx){
302  if (!m_readMET) return StatusCode::SUCCESS;
303 
304  const xAOD::MissingETContainer* MET{nullptr};
305  ATH_CHECK(SG::get(MET, m_MetKey, ctx));
306 
307  m_met = (*MET)["Final"]->met()/Gaudi::Units::GeV;
308  m_met_x = (*MET)["Final"]->mpx()/Gaudi::Units::GeV;
309  m_met_y = (*MET)["Final"]->mpy()/Gaudi::Units::GeV;
310  m_met_phi = (*MET)["Final"]->phi();
311  m_sumEt = (*MET)["Final"]->sumet()/Gaudi::Units::GeV;
312 
313  return StatusCode::SUCCESS;
314 }
315 
316 
318 
319  const xAOD::TrackParticleContainer* msOnlyTracklets{nullptr};
320  ATH_CHECK(SG::get(msOnlyTracklets, m_TrackletKey, ctx));
321 
322  m_trklet_N = msOnlyTracklets->size();
323  for(const xAOD::TrackParticle* mstrklet : *msOnlyTracklets){
324  // perigee parameters
325  m_trklet_d0.push_back(mstrklet->d0());
326  m_trklet_z0.push_back(mstrklet->z0());
327  m_trklet_phi.push_back(mstrklet->phi());
328  m_trklet_theta.push_back(mstrklet->theta());
329  m_trklet_eta.push_back(mstrklet->eta());
330  m_trklet_qOverP.push_back(mstrklet->qOverP());
331  m_trklet_q.push_back(mstrklet->charge());
332  // cartesian parameters
333  const Trk::Perigee &tkl_perigee = mstrklet->perigeeParameters();
334  const Amg::Vector3D &trklet_pos = tkl_perigee.position();
335  const Amg::Vector3D &trklet_mom = tkl_perigee.momentum()/Gaudi::Units::GeV;
336  m_trklet_pos.push_back(trklet_pos);
337  m_trklet_mom.push_back(trklet_mom);
338  // set default link index to vertex to -1 and adjust when in fillMSVtx
339  m_trklet_vtxLink.push_back(-1);
340  }
341 
342  return StatusCode::SUCCESS;
343 }
344 
345 
346 void MSVtxValidationAlg::fillHits(const xAOD::Vertex* vtx, const std::string& decorator_str, MuonVal::VectorBranch<int>& branch) {
347  // fills branch with the number of hits close to the vertex. When the decorator is not available, the default integer value is used
348  const SG::AuxElement::Accessor<int> hits_acc(decorator_str);
349  if (hits_acc.isAvailable(*vtx)) branch.push_back(hits_acc(*vtx));
350 
351  return;
352 }
353 
354 
355 StatusCode MSVtxValidationAlg::fillMSVtx(const EventContext& ctx){
356  // Fill MS vertex branches
357  const xAOD::VertexContainer* msVertices{nullptr};
358  ATH_CHECK(SG::get(msVertices, m_MSVtxKey, ctx));
359 
360 
361  // fill MSVtx branches and histograms when the read handle is present
362  m_msVtx_N = msVertices->size();
363  for(const xAOD::Vertex* msVtx : *msVertices){
364  m_msVtx_pos.push_back(msVtx->position());
365  m_msVtx_chi2.push_back(msVtx->chiSquared());
366  m_msVtx_nDoF.push_back(msVtx->numberDoF());
367 
368  // hits close to vertex: total, inwards of the vertex, inner layer, extended layer, middle layer, outer layer
369  fillHits(msVtx, "nMDT", m_msVtx_nMDT);
370  fillHits(msVtx, "nMDT_inwards", m_msVtx_nMDT_inwards);
371  fillHits(msVtx, "nMDT_I", m_msVtx_nMDT_I);
372  fillHits(msVtx, "nMDT_E", m_msVtx_nMDT_E);
373  fillHits(msVtx, "nMDT_M", m_msVtx_nMDT_M);
374  fillHits(msVtx, "nMDT_O", m_msVtx_nMDT_O);
375 
376  fillHits(msVtx, "nRPC", m_msVtx_nRPC);
377  fillHits(msVtx, "nRPC_inwards", m_msVtx_nRPC_inwards);
378  fillHits(msVtx, "nRPC_I", m_msVtx_nRPC_I);
379  fillHits(msVtx, "nRPC_E", m_msVtx_nRPC_E);
380  fillHits(msVtx, "nRPC_M", m_msVtx_nRPC_M);
381  fillHits(msVtx, "nRPC_O", m_msVtx_nRPC_O);
382 
383  fillHits(msVtx, "nTGC", m_msVtx_nTGC);
384  fillHits(msVtx, "nTGC_inwards", m_msVtx_nTGC_inwards);
385  fillHits(msVtx, "nTGC_I", m_msVtx_nTGC_I);
386  fillHits(msVtx, "nTGC_E", m_msVtx_nTGC_E);
387  fillHits(msVtx, "nTGC_M", m_msVtx_nTGC_M);
388  fillHits(msVtx, "nTGC_O", m_msVtx_nTGC_O);
389 
390  // set a linking index for each tracklet used in the reconstruction of the vertex
391  size_t nTrk = msVtx->nTrackParticles();
392  m_msVtx_Ntrklet.push_back(nTrk);
393 
394  for(size_t j=0; j<nTrk; ++j){
395  const xAOD::TrackParticle *consti = msVtx->trackParticle(j);
396  if (!consti) continue;
397  m_trklet_vtxLink[consti->index()] = msVtx->index();
398  }
399  }
400 
401  return StatusCode::SUCCESS;
402 }
403 
404 
406  // Fill the isolation variables for the MS vertices
407  if (!m_computeIso) return StatusCode::SUCCESS;
408 
409  const xAOD::VertexContainer* msVertices{nullptr};
410  ATH_CHECK(SG::get(msVertices, m_MSVtxKey, ctx));
411  const xAOD::TrackParticleContainer* tracks{nullptr};
412  ATH_CHECK(SG::get(tracks, m_TrackParticleKey, ctx));
413  const xAOD::JetContainer* jets{nullptr};
414  ATH_CHECK(SG::get(jets, m_JetKey, ctx));
415 
416  for(const xAOD::Vertex* msVtx : *msVertices){
417  VtxIso iso = getIso(msVtx, *tracks, *jets, m_trackIso_pT, m_softTrackIso_R, m_jetIso_pT, m_jetIso_LogRatio);
418  m_msVtx_isoTracks_mindR.push_back(iso.track_mindR);
419  m_msVtx_isoTracks_pTsum.push_back(iso.track_pTsum);
420  m_msVtx_isoJets_mindR.push_back(iso.jet_mindR);
421  }
422 
423  return StatusCode::SUCCESS;
424 }
425 
426 
428  ATH_MSG_DEBUG ("Executing " << name() << "...");
429 
430  const EventContext& ctx = Gaudi::Hive::currentContext();
431 
432  // event variables
433  const xAOD::EventInfo* eventInfo{nullptr};
434  ATH_CHECK(SG::get(eventInfo, m_evtKey, ctx));
435 
436  ATH_MSG_DEBUG("Start to run over event "<<eventInfo->eventNumber()<<" in run" <<eventInfo->runNumber());
437 
438  ATH_CHECK(fillTruth(ctx));
439  ATH_CHECK(fillJet(ctx));
440  ATH_CHECK(fillMet(ctx));
441  ATH_CHECK(fillTracklets(ctx));
442  ATH_CHECK(fillMSVtx(ctx));
443  ATH_CHECK(fillMSVtxIso(ctx));
444 
445  ATH_CHECK(m_tree.fill(ctx));
446 
447  return StatusCode::SUCCESS;
448 }
449 
450 
452  ATH_MSG_DEBUG ("Finalizing " << name() << "...");
453  ATH_CHECK(m_tree.write());
454 
455  return StatusCode::SUCCESS;
456 }
GeV
#define GeV
Definition: PhysicsAnalysis/TauID/TauAnalysisTools/Root/HelperFunctions.cxx:18
MSVtxValidationAlgUtils::VtxIso::track_pTsum
double track_pTsum
Definition: MuonSpectrometer/MuonValidation/MuonVertexValidation/src/Utils.h:52
runLayerRecalibration.chain
chain
Definition: runLayerRecalibration.py:175
MSVtxValidationAlg::fillTruth
StatusCode fillTruth(const EventContext &ctx)
Definition: MSVtxValidationAlg.cxx:135
SG::Accessor
Helper class to provide type-safe access to aux data.
Definition: Control/AthContainers/AthContainers/Accessor.h:68
MSVtxValidationAlg::finalize
virtual StatusCode finalize() override final
Definition: MSVtxValidationAlg.cxx:451
Trk::ParametersT
Dummy class used to allow special convertors to be called for surfaces owned by a detector element.
Definition: EMErrorDetail.h:25
MSVtxValidationAlgUtils::VtxIso::track_mindR
double track_mindR
Definition: MuonSpectrometer/MuonValidation/MuonVertexValidation/src/Utils.h:51
MSVtxValidationAlgUtils::getCTau
double getCTau(const xAOD::TruthVertex *decVtx)
Definition: MuonSpectrometer/MuonValidation/MuonVertexValidation/src/Utils.cxx:10
defineDB.jets
jets
Definition: JetTagCalibration/share/defineDB.py:24
ParticleTest.tp
tp
Definition: ParticleTest.py:25
MSVtxValidationAlg::fillMSVtx
StatusCode fillMSVtx(const EventContext &ctx)
Definition: MSVtxValidationAlg.cxx:355
MSVtxValidationAlgUtils::JetVtxApprox::nChildren
size_t nChildren
Definition: MuonSpectrometer/MuonValidation/MuonVertexValidation/src/Utils.h:43
MuonVal::VectorBranch< int >
ChainGroup.h
MSVtxValidationAlgUtils::VtxIso
Definition: MuonSpectrometer/MuonValidation/MuonVertexValidation/src/Utils.h:50
keylayer_zslicemap.fillHits
fillHits
Definition: keylayer_zslicemap.py:124
xAOD::TruthVertex_v1::outgoingParticleLinks
const TPLinks_t & outgoingParticleLinks() const
Get all the outgoing particles.
MSVtxValidationAlg::fillJet
StatusCode fillJet(const EventContext &ctx)
Definition: MSVtxValidationAlg.cxx:229
xAOD::TruthVertex_v1::v4
FourVec_t v4() const
The full 4-vector of the vertex.
Definition: TruthVertex_v1.cxx:185
python.utils.AtlRunQueryDQUtils.p
p
Definition: AtlRunQueryDQUtils.py:209
MSVtxValidationAlg::fillMSVtxIso
StatusCode fillMSVtxIso(const EventContext &ctx)
Definition: MSVtxValidationAlg.cxx:405
jet
Definition: JetCalibTools_PlotJESFactors.cxx:23
lumiFormat.i
int i
Definition: lumiFormat.py:85
SG::get
const T * get(const ReadCondHandleKey< T > &key, const EventContext &ctx)
Convenience function to retrieve an object given a ReadCondHandleKey.
Definition: ReadCondHandle.h:287
MSVtxValidationAlg::execute
virtual StatusCode execute() override final
Definition: MSVtxValidationAlg.cxx:427
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
MSVtxValidationAlg::initialize
virtual StatusCode initialize() override final
Definition: MSVtxValidationAlg.cxx:19
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
xAOD::TruthParticle_v1
Class describing a truth particle in the MC record.
Definition: TruthParticle_v1.h:37
Utils.h
MSVtxValidationAlgUtils::comparePt
bool comparePt(const xAOD::TruthParticle *part1, const xAOD::TruthParticle *part2)
Definition: MuonSpectrometer/MuonValidation/MuonVertexValidation/src/Utils.cxx:33
xAOD::TruthVertex_v1::perp
float perp() const
Vertex transverse distance from the beam line.
Definition: TruthVertex_v1.cxx:164
MuonSegmentReaderConfig.histSvc
histSvc
Definition: MuonSegmentReaderConfig.py:96
ATH_CHECK
#define ATH_CHECK
Definition: AthCheckMacros.h:40
SG::AuxElement::index
size_t index() const
Return the index of this element within its container.
DataVector
Derived DataVector<T>.
Definition: DataVector.h:794
MSVtxValidationAlgUtils::JetVtxApprox::vtx
const xAOD::TruthVertex * vtx
Definition: MuonSpectrometer/MuonValidation/MuonVertexValidation/src/Utils.h:42
Trig::ChainGroup
Definition: ChainGroup.h:51
xAOD::TruthVertex_v1
Class describing a truth vertex in the MC record.
Definition: TruthVertex_v1.h:37
xAOD::MissingETContainer_v1
Container for xAOD::MissingET_v1 objects.
Definition: MissingETContainer_v1.h:21
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:240
MET
Definition: MET.py:1
MSVtxValidationAlgUtils::VtxIso::jet_mindR
double jet_mindR
Definition: MuonSpectrometer/MuonValidation/MuonVertexValidation/src/Utils.h:53
MSVtxValidationAlg.h
Amg::Vector3D
Eigen::Matrix< double, 3, 1 > Vector3D
Definition: GeoPrimitives.h:47
MSVtxValidationAlg::fillJetVtx
StatusCode fillJetVtx(const EventContext &ctx, const xAOD::Jet *jet)
Definition: MSVtxValidationAlg.cxx:271
xAOD::EventInfo_v1
Class describing the basic event information.
Definition: EventInfo_v1.h:43
xAOD::Jet_v1
Class describing a jet.
Definition: Jet_v1.h:57
RTTAlgmain.branch
branch
Definition: RTTAlgmain.py:61
xAOD::Vertex_v1
Class describing a Vertex.
Definition: Vertex_v1.h:42
MSVtxValidationAlgUtils::JetVtxApprox
Definition: MuonSpectrometer/MuonValidation/MuonVertexValidation/src/Utils.h:41
MSVtxValidationAlgUtils::getStableChildren
std::vector< const xAOD::TruthParticle * > getStableChildren(const xAOD::TruthParticle *particle, bool findOnlyGenStable)
Definition: MuonSpectrometer/MuonValidation/MuonVertexValidation/src/Utils.cxx:83
MSVtxValidationAlgUtils::getIso
VtxIso getIso(const xAOD::Vertex *vtx, const xAOD::TrackParticleContainer &Tracks, const xAOD::JetContainer &Jets, double trackIso_pT, double softTrackIso_R, double jetIso_pT, double jetIso_LogRatio)
Definition: MuonSpectrometer/MuonValidation/MuonVertexValidation/src/Utils.cxx:134
xAOD::TruthVertex_v1::z
float z() const
Vertex longitudinal distance along the beam line form the origin.
MSVtxValidationAlg::fillHits
void fillHits(const xAOD::Vertex *vtx, const std::string &decorator_str, MuonVal::VectorBranch< int > &branch)
Definition: MSVtxValidationAlg.cxx:346
SG::ConstAccessor< T, AuxAllocator_t< T > >::isAvailable
bool isAvailable(const ELT &e) const
Test to see if this variable exists in the store.
MSVtxValidationAlgUtils
Definition: MuonSpectrometer/MuonValidation/MuonVertexValidation/src/Utils.cxx:8
xAOD::TrackParticle_v1
Class describing a TrackParticle.
Definition: TrackParticle_v1.h:43
xAOD::TruthParticle_v1::p4
virtual FourMom_t p4() const override final
The full 4-momentum of the particle.
Definition: TruthParticle_v1.cxx:191
MSVtxValidationAlgUtils::JetVtxApprox::decayDepth
size_t decayDepth
Definition: MuonSpectrometer/MuonValidation/MuonVertexValidation/src/Utils.h:44
MSVtxValidationAlg::fillTracklets
StatusCode fillTracklets(const EventContext &ctx)
Definition: MSVtxValidationAlg.cxx:317
MSVtxValidationAlg::fillMet
StatusCode fillMet(const EventContext &ctx)
Definition: MSVtxValidationAlg.cxx:301
MSVtxValidationAlgUtils::getJetVtxApprox
JetVtxApprox getJetVtxApprox(const xAOD::Jet *jet, const xAOD::TruthParticleContainer &truthParticles)
Definition: MuonSpectrometer/MuonValidation/MuonVertexValidation/src/Utils.cxx:91