ATLAS Offline Software
InDetPhysValMonitoringTool.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3 */
4 
10 #include "GaudiKernel/SystemOfUnits.h"
11 
14 #include "InDetRttPlots.h"
15 #include "InDetPerfPlot_nTracks.h"
16 #include "AthTruthSelectionTool.h"
17 #include "CachedGetAssocTruth.h"
18 
19 #include "safeDecorator.h"
20 // #include "TrackTruthLookup.h"
21 //
28 #include "xAODTruth/TruthVertex.h"
32 
34 //
35 #include <algorithm>
36 #include <limits>
37 #include <cmath> // to get std::isnan(), std::abs etc.
38 // #include <functional> // to get std::plus
39 #include <utility>
40 #include <cstdlib> // to getenv
41 #include <vector>
42 
44 
45 namespace { // utility functions used here
46 
47  // get truth/track matching probability
48  float
49  getMatchingProbability(const xAOD::TrackParticle& trackParticle) {
50  float result(std::numeric_limits<float>::quiet_NaN());
51 
52  static const SG::ConstAccessor<float> truthMatchProbabilityAcc("truthMatchProbability");
53  if (truthMatchProbabilityAcc.isAvailable(trackParticle)) {
54  result = truthMatchProbabilityAcc(trackParticle);
55  }
56  return result;
57  }
58 
59  template <class T>
60  inline float
61  safelyGetEta(const T& pTrk, const float safePtThreshold = 0.1) {
62  return (pTrk->pt() > safePtThreshold) ? (pTrk->eta()) : std::nan("");
63  }
64 
65  // general utility function to check value is in range
66  template <class T>
67  inline bool
68  inRange(const T& value, const T& minVal, const T& maxVal) {
69  return not ((value < minVal)or(value > maxVal));
70  }
71 
72  template<class T>
73  inline bool
74  inRange(const T& value, const T& absoluteMax) {
75  return not (std::abs(value) > absoluteMax);
76  }
77 
78  // Cuts on various objects
79 
80  // general utility function to return bin index given a value and the upper endpoints of each bin
81  template <class T>
82  unsigned int
83  binIndex(const T& val, const std::vector<T>& partitions) {// signature should allow other containers
84  unsigned int i(0);
85  bool nf = true;
86 
87  while (nf and i != partitions.size()) {
88  nf = (val > partitions[i++]);
89  }
90  return nf ? i : i - 1;
91  }
92 
93  bool
94  acceptTruthVertex(const xAOD::TruthVertex* vtx) {
95  const float x(vtx->x()), y(vtx->y()), z(vtx->z());
96  const float vrtR2 = (x * x + y * y); // radial distance squared
97 
98  return inRange(z, 500.f) and not (vrtR2 > 1); // units?
99  }
100 
101  const std::vector<float> ETA_PARTITIONS = {
102  2.7, 3.5, std::numeric_limits<float>::infinity()
103  };
104 
105 }// namespace
106 
108 InDetPhysValMonitoringTool::InDetPhysValMonitoringTool(const std::string& type, const std::string& name,
109  const IInterface* parent) :
111 }
112 
114 
118  // Get the track selector tool only if m_useTrackSelection is true;
119  // first check for consistency i.e. that there is a trackSelectionTool if you ask
120  // for trackSelection
121  ATH_CHECK(m_trackSelectionTool.retrieve(EnableTool {m_useTrackSelection} ));
122  ATH_CHECK(m_truthSelectionTool.retrieve(EnableTool {not m_truthParticleName.key().empty()} ));
123  ATH_CHECK(m_vtxValidTool.retrieve(EnableTool {m_useVertexTruthMatchTool}));
124  ATH_CHECK(m_trackTruthOriginTool.retrieve( EnableTool {m_doTruthOriginPlots} ));
126  ATH_CHECK(m_grlTool.retrieve(EnableTool{m_useGRL}));
127 
128  ATH_MSG_DEBUG("m_useVertexTruthMatchTool ====== " <<m_useVertexTruthMatchTool);
129  if (m_truthSelectionTool.get() ) {
130  m_truthCutFlow = CutFlow(m_truthSelectionTool->nCuts());
131  }
132 
133  m_monPlots = std::make_unique<InDetRttPlots>
134  (nullptr, static_cast<std::string>(m_dirName) + static_cast<std::string>(m_folder),
135  getFilledPlotConfig()); // m_detailLevel := DEBUG, enable expert histograms
136 
138  ATH_CHECK( m_truthParticleName.initialize( (m_pileupSwitch == "HardScatter" or m_pileupSwitch == "All") and not m_truthParticleName.key().empty() ) );
139  ATH_CHECK( m_vertexContainerName.initialize( not m_vertexContainerName.empty() ) );
140  ATH_CHECK( m_truthVertexContainerName.initialize( not m_truthVertexContainerName.key().empty() ) );
142 
143  ATH_CHECK( m_truthEventName.initialize( (m_pileupSwitch == "HardScatter" or m_pileupSwitch == "All") and not m_truthEventName.key().empty() ) );
144  ATH_CHECK( m_truthPileUpEventName.initialize( (m_pileupSwitch == "PileUp" or m_pileupSwitch == "All") and not m_truthPileUpEventName.key().empty() ) );
145  ATH_CHECK( m_jetContainerName.initialize( m_doTrackInJetPlots and not m_jetContainerName.key().empty()) );
146 
147  std::vector<std::string> required_float_track_decorations {"d0","hitResiduals_residualLocX","d0err"};
148  std::vector<std::string> required_int_track_decorations {};
149  std::vector<std::string> required_float_truth_decorations {"d0"};
150  std::vector<std::string> required_int_truth_decorations {};
151  std::vector<std::string> required_int_jet_decorations {"HadronConeExclTruthLabelID"};
152 
153  std::string empty_prefix;
154  IDPVM::addReadDecoratorHandleKeys(*this, m_trkParticleName, empty_prefix, required_float_track_decorations, m_floatTrkDecor);
155  IDPVM::addReadDecoratorHandleKeys(*this, m_trkParticleName, empty_prefix, required_int_truth_decorations, m_intTrkDecor);
156  if (!m_truthParticleName.key().empty()) {
157  IDPVM::addReadDecoratorHandleKeys(*this, m_truthParticleName, empty_prefix, required_float_truth_decorations, m_floatTruthDecor);
158  IDPVM::addReadDecoratorHandleKeys(*this, m_truthParticleName, empty_prefix, required_int_truth_decorations, m_intTruthDecor);
159  }
161  IDPVM::addReadDecoratorHandleKeys(*this, m_jetContainerName, empty_prefix, required_int_jet_decorations, m_intJetDecor);
162  }
163 
165 
167  return StatusCode::SUCCESS;
168 }
169 
170 
172 
173 
174  InDetRttPlotConfig rttConfig;
175  rttConfig.detailLevel = m_detailLevel;
176 
177  rttConfig.isITk = m_isITk;
178 
183 
185  rttConfig.doHitEffPlot = m_doHitLevelPlots;
186 
191 
194 
196 
201 
203 
206 
208  if (m_truthParticleName.key().empty()){
209  rttConfig.doFakePlots = false;
210  rttConfig.doMissingTruthFakePlots = false;
211  rttConfig.doHitsFakeTracksPlots = false;
212  rttConfig.doHitsUnlinkedTracksPlots = false;
213  rttConfig.doEffPlots = false;
214  rttConfig.doResolutionPlotPrim = false;
215  rttConfig.doResolutionPlotPrim_truthFromB = false;
216  rttConfig.doResolutionPlotSecd = false;
217  rttConfig.doHitsMatchedTracksPlots = false;
218  rttConfig.doVertexTruthMatchingPlots = false;
219  rttConfig.doHardScatterVertexTruthMatchingPlots = false;
220  rttConfig.doEfficienciesPerAuthor = false;
221  rttConfig.doFakesPerAuthor = false;
222  rttConfig.doResolutionsPerAuthor = false;
223  rttConfig.doNtupleTruthToReco = false;
224  rttConfig.doTrkInJetPlots_fake_bjets = false;
225  rttConfig.doTrkInJetPlots_matched_bjets = false;
226  rttConfig.doTrkInJetPlots_unlinked_bjets = false;
227  rttConfig.doTrkInJetPlots_truthFromB = false;
228  rttConfig.doResolutionPlotPrim_truthFromB = false;
229  }
230 
232  if (m_onlyFillMatched){
233  rttConfig.doTrackParameters = false;
234  rttConfig.doNTracks = false;
235  rttConfig.doHitResidualPlot = false;
236  rttConfig.doHitEffPlot = false;
237  rttConfig.doHitsRecoTracksPlots = false;
238  rttConfig.doTrtExtensionPlots = false;
239  rttConfig.doFakePlots = false;
240  rttConfig.doMissingTruthFakePlots = false;
241  rttConfig.doHitsFakeTracksPlots = false;
242  rttConfig.doHitsUnlinkedTracksPlots = false;
243  rttConfig.doVertexPlots = false;
244  rttConfig.doVerticesVsMuPlots = false;
245  rttConfig.doHardScatterVertexPlots = false;
246  rttConfig.doVertexTruthMatchingPlots = false;
247  rttConfig.doHardScatterVertexTruthMatchingPlots = false;
248  rttConfig.doTrkInJetPlots = false;
249  rttConfig.doTrkInJetPlots_bjets = false;
250  rttConfig.doTrkInJetPlots_matched = false;
251  rttConfig.doTrkInJetPlots_matched_bjets = false;
252  rttConfig.doTrkInJetPlots_fake = false;
253  rttConfig.doTrkInJetPlots_fake_bjets = false;
254  rttConfig.doTrkInJetPlots_unlinked = false;
255  rttConfig.doTrkInJetPlots_unlinked_bjets = false;
256  rttConfig.doTrkInJetPlots_truthFromB = false;
257  }
258 
259  // For IDTIDE derivation
260  // disable the vertex plots since no covariance from IDTIDE
261  if (m_doIDTIDEPlots){
262  rttConfig.doVertexPlots = false;
263  rttConfig.doVerticesVsMuPlots = false;
264  rttConfig.doHardScatterVertexPlots = false;
265  rttConfig.doVertexTruthMatchingPlots = false;
266  rttConfig.doHardScatterVertexTruthMatchingPlots = false;
267  rttConfig.doTrkInJetPlots = true;
268  rttConfig.doTrkInJetPlots_bjets = true;
269  rttConfig.doTrkInJetPlots_matched = true;
270  rttConfig.doTrkInJetPlots_matched_bjets = true;
271  rttConfig.doTrkInJetPlots_fake = true;
272  rttConfig.doTrkInJetPlots_fake_bjets = true;
273  rttConfig.doTrkInJetPlots_unlinked = true;
274  rttConfig.doTrkInJetPlots_unlinked_bjets = true;
275  rttConfig.doTrkInJetPlots_truthFromB = true;
276  }
277 
279  if (m_detailLevel < 200){
280  rttConfig.doResolutionPlotSecd = false;
281  rttConfig.doHitsMatchedTracksPlots = false;
282  rttConfig.doHitsFakeTracksPlots = false;
283  rttConfig.doHitsUnlinkedTracksPlots = false;
284  rttConfig.doVertexTruthMatchingPlots = false;
285  rttConfig.doFakesPerAuthor = false;
286  rttConfig.doTrackParametersPerAuthor = false;
287  rttConfig.doEfficienciesPerAuthor = false;
288  rttConfig.doResolutionsPerAuthor = false;
289  rttConfig.doTrkInJetPlots_matched = false;
290  rttConfig.doTrkInJetPlots_fake = false;
291  rttConfig.doTrkInJetPlots_unlinked = false;
292  rttConfig.doTrkInJetPlots_matched_bjets = false;
293  rttConfig.doTrkInJetPlots_fake_bjets = false;
294  rttConfig.doTrkInJetPlots_unlinked_bjets = false;
295  }
296 
297  return rttConfig;
298 }
299 
302  ATH_MSG_DEBUG("Filling hists " << name() << "...");
303  // function object could be used to retrieve truth: IDPVM::CachedGetAssocTruth getTruth;
304 
305  // Get the Event Context
306  const EventContext& ctx = Gaudi::Hive::currentContext();
307 
308  // retrieve trackParticle container
310  if (not trackHandle.isValid()) {
311  ATH_MSG_ERROR("Invalid trackname = " << m_trkParticleName << "!");
312  return StatusCode::FAILURE;
313  }
314  const xAOD::TrackParticleContainer* tracks = trackHandle.cptr();
315 
316  SG::ReadHandle<xAOD::TruthPileupEventContainer> truthPileupEventContainer;
317  if( not m_truthPileUpEventName.key().empty()) {
319  }
320 
322  if (not pie.isValid()){
323  ATH_MSG_WARNING("Shouldn't happen - EventInfo is buggy, setting mu to 0");
324  }
325 
326  // FIX-ME: I'm not sure if we should stop execution if EventInfo is not valid ...
327  // it is used after as if they assume it is valid
328  if (m_useGRL and pie.isValid() and !pie->eventType(xAOD::EventInfo::IS_SIMULATION)) {
329  if (!m_grlTool->passRunLB(*pie)) {
330  ATH_MSG_VERBOSE("GRL veto");
331  return StatusCode::SUCCESS;
332  }
333  }
334 
335  std::vector<const xAOD::TruthParticle*> truthParticlesVec = getTruthParticles(ctx);
336 
337  // Mark the truth particles in our vector as "selected".
338  // This is needed because we later access the truth matching via xAOD decorations, where we do not 'know' about membership to this vector.
340 
341  IDPVM::CachedGetAssocTruth getAsTruth; // only cache one way, track->truth, not truth->tracks
342 
343  unsigned int truthMu = 0;
344  float actualMu = 0.;
345  if(not m_truthPileUpEventName.key().empty() and truthPileupEventContainer.isValid()){
346  truthMu = static_cast<int>( truthPileupEventContainer->size() );
347  }
348  if(pie.isValid()) actualMu = pie->actualInteractionsPerCrossing();
349 
350  // This is questionable but kept for backward compatibility for now
351  float puEvents = truthMu>0 ? truthMu : actualMu;
352 
353  const xAOD::Vertex* primaryvertex = nullptr;
354  unsigned int nVertices = 0;
355  float beamSpotWeight = 1;
356 
357  if(not m_vertexContainerName.key().empty()){
358  ATH_MSG_DEBUG("Getting number of pu interactings per event");
359 
360  ATH_MSG_DEBUG("Filling vertex plots");
362  ATH_CHECK(vertices.isValid());
363 
364  nVertices = not vertices->empty() ? vertices->size() : 0;
365  beamSpotWeight = pie->beamSpotWeight();
366  ATH_MSG_DEBUG("beamSpotWeight is equal to " << beamSpotWeight);
367  if(m_doPRW){
368  float prwWeight = 1;
370  if(readDecorHandle.isAvailable()) prwWeight = readDecorHandle(*pie);
371  ATH_MSG_DEBUG("Applying pileup weight equal to " << prwWeight);
372  beamSpotWeight *= prwWeight;
373  }
374 
375  if (vertices.isValid() and not vertices->empty()) {
376  ATH_MSG_DEBUG("Number of vertices retrieved for this event " << vertices->size());
377  //Find the HS vertex following the user-configured strategy
378  primaryvertex = m_hardScatterSelectionTool->getHardScatter(vertices.get());
379  if (!primaryvertex){
382  ATH_MSG_DEBUG("Failed to find a hard scatter vertex in this event.");
383  }
384  //Filling plots for all reconstructed vertices and the hard-scatter
385  ATH_MSG_DEBUG("Filling vertices info monitoring plots");
386 
387  // Fill vectors of truth HS and PU vertices
388  std::pair<std::vector<const xAOD::TruthVertex*>, std::vector<const xAOD::TruthVertex*>> truthVertices = getTruthVertices(ctx);
389  std::vector<const xAOD::TruthVertex*> truthHSVertices = truthVertices.first;
390  std::vector<const xAOD::TruthVertex*> truthPUVertices = truthVertices.second;
391 
392  // Decorate vertices
394  ATH_CHECK(m_vtxValidTool->matchVertices(*vertices));
395  ATH_MSG_DEBUG("Hard scatter classification type: " << InDetVertexTruthMatchUtils::classifyHardScatter(*vertices) << ", vertex container size = " << vertices->size());
396  }
397  m_monPlots->fill(*vertices, primaryvertex, truthHSVertices, truthPUVertices, actualMu, beamSpotWeight);
398 
399  ATH_MSG_DEBUG("Filling vertex/event info monitoring plots");
400  //Filling vertexing plots for the reconstructed hard-scatter as a function of mu
401  m_monPlots->fill(*vertices, truthMu, actualMu, beamSpotWeight);
402  } else {
403  //FIXME: Does this happen for single particles?
404  ATH_MSG_WARNING("Skipping vertexing plots.");
405  }
406  }
407 
408  if( not m_truthVertexContainerName.key().empty()){
409  // get truth vertex container name - m_truthVertexContainerName
411 
412  //
413  //Get the HS vertex position from the truthVertexContainer
414  //FIXME: Add plots w.r.t truth HS positions (vertexing plots)
415  //
416  const xAOD::TruthVertex* truthVertex = nullptr;
417  if (truthVrt.isValid()) {
418  const auto& stdVertexContainer = truthVrt->stdcont();
419  //First truth particle vertex?
420  auto findVtx = std::find_if(stdVertexContainer.rbegin(), stdVertexContainer.rend(), acceptTruthVertex);
421  truthVertex = (findVtx == stdVertexContainer.rend()) ? nullptr : *findVtx;
422  } else {
423  ATH_MSG_WARNING("Cannot open " << m_truthVertexContainerName.key() << " truth vertex container");
424  }
425  if (not truthVertex) ATH_MSG_INFO ("Truth vertex did not pass cuts");
426  }
427  //
428  //Counters for cutflow
429  //
430  unsigned int nSelectedTruthTracks(0), nSelectedRecoTracks(0), nSelectedMatchedTracks(0), nAssociatedTruth(0), nMissingAssociatedTruth(0), nTruths(0);
431 
432  CutFlow tmp_truth_cutflow( m_truthSelectionTool.get() ? m_truthSelectionTool->nCuts() : 0 );
433 
434  //
435  //Loop over all reconstructed tracks
436  //
437  // If writing ntuples, use a truth-to-track(s) cache to handle truth matching.
438  // Based on the assumption that multiple tracks can (albeit rarely) share the same truth association.
439  std::map<const xAOD::TruthParticle*, std::vector<const xAOD::TrackParticle*>> cacheTruthMatching {};
440  //
441  std::vector<const xAOD::TrackParticle*> selectedTracks {};
442  selectedTracks.reserve(tracks->size());
443  unsigned int nTrackTOT = 0;
444  unsigned int nTrackCentral = 0;
445  unsigned int nTrackPt1GeV = 0;
446  for (const auto *const thisTrack: *tracks) {
447  //FIXME: Why is this w.r.t the primary vertex?
448  const asg::AcceptData& accept = m_trackSelectionTool->accept(*thisTrack, primaryvertex);
449  if (m_useTrackSelection and not accept) continue;
450  fillTrackCutFlow(accept); //?? Is this equal???
451 
452  selectedTracks.push_back(thisTrack);
453  //Number of selected reco tracks
454  nSelectedRecoTracks++;
455 
456  //Fill plots for selected reco tracks, hits / perigee / ???
457  nTrackTOT++;
458  if (thisTrack->pt() >= (1 * Gaudi::Units::GeV))
459  nTrackPt1GeV++;
460  if (std::abs(thisTrack->eta()) < 2.5)
461  nTrackCentral++;
462  m_monPlots->fill(*thisTrack, beamSpotWeight);
463  m_monPlots->fill(*thisTrack, puEvents, nVertices, beamSpotWeight); //fill mu dependent plots
464  const xAOD::TruthParticle* associatedTruth = getAsTruth.getTruth(thisTrack);
465  float prob = getMatchingProbability(*thisTrack);
466 
467  // This is where the Fake, and Really Fake fillers need to go. Where would the really really fakes go?
468  if (associatedTruth) {
469  nAssociatedTruth++;
470 
471  // if there is associated truth also a truth selection tool was retrieved.
473  if (m_truthSelectionTool) {
474  //FIXME: What is this for???
475  tmp_truth_cutflow.update( passed.missingCuts() );
476  }
477 
478  if ((not std::isnan(prob)) and (prob > m_lowProb) and passed and (not m_usingSpecialPileupSwitch or isSelectedByPileupSwitch(*associatedTruth)) ) {
479  nSelectedMatchedTracks++;
480  bool truthIsFromB = false;
481  if ( m_doTruthOriginPlots and m_trackTruthOriginTool->isFrom(associatedTruth, 5) ) {
482  truthIsFromB = true;
483  }
484  m_monPlots->fill(*thisTrack, *associatedTruth, truthIsFromB, puEvents, beamSpotWeight); // Make plots requiring matched truth
485  }
486  }
487 
488  const bool isAssociatedTruth = associatedTruth != nullptr;
489  const bool isFake = not std::isnan(prob) ? (prob < m_lowProb) : true;
490 
491  if(!isAssociatedTruth) nMissingAssociatedTruth++;
492  m_monPlots->fillFakeRate(*thisTrack, isFake, isAssociatedTruth, puEvents, beamSpotWeight);
493 
495  // Decorate track particle with extra flags
496  decorateTrackParticle(*thisTrack, accept);
497 
498  if (isAssociatedTruth) {
499  // Decorate truth particle with extra flags
500  decorateTruthParticle(*associatedTruth, m_truthSelectionTool->accept(associatedTruth));
501 
502  // Cache truth-to-track associations
503  auto cachedAssoc = cacheTruthMatching.find(associatedTruth);
504  // Check if truth particle already present in cache
505  if (cachedAssoc == cacheTruthMatching.end()) {
506  // If not yet present, add truth-to-track association in cache
507  cacheTruthMatching[associatedTruth] = {thisTrack};
508  }
509  else {
510  // If already present, cache additional track associations (here multiple track particle can be linked to the same truth particle)
511  cachedAssoc->second.push_back(thisTrack);
512  }
513  }
514  else if(m_fillTruthToRecoNtuple){
515  // Fill track only entries with dummy truth values
516  m_monPlots->fillNtuple(*thisTrack, primaryvertex);
517  }
518  }
519  }
521  // Now fill all truth-to-track associations
522  // Involves some double-filling of truth particles in cases where multiple tracks share the same truth association,
523  // these duplicates can be filtered in the ntuple by selecting only the 'best matched' truth-associated track particles.
524  for (auto& cachedAssoc: cacheTruthMatching) {
525  const xAOD::TruthParticle* thisTruth = cachedAssoc.first;
526 
527  // Decorate that this truth particle is being filled to prevent double counting in truth particle loop
528  m_dec_hasTruthFilled(*thisTruth) = true;
529 
530  // Sort all associated tracks by truth match probability
531  std::sort(cachedAssoc.second.begin(), cachedAssoc.second.end(),
532  [](const xAOD::TrackParticle* t1, const xAOD::TrackParticle* t2) { return getMatchingProbability(*t1) > getMatchingProbability(*t2); }
533  );
534 
536  // Fill all tracks associated to to this truth particle, also recording 'truth match ranking' as index in probability-sorted vector of matched tracks
537  for (int itrack = 0; itrack < (int) cachedAssoc.second.size(); itrack++) {
538  const xAOD::TrackParticle* thisTrack = cachedAssoc.second[itrack];
539 
540  // Fill track entries with truth association
541  m_monPlots->fillNtuple(*thisTrack, *thisTruth, primaryvertex, itrack);
542  }
543  }
544  }
545  }
546 
547  m_monPlots->fill(nTrackTOT, nTrackCentral, nTrackPt1GeV, truthMu, actualMu, nVertices, beamSpotWeight);
548 
549  //FIXME: I don't get why... this is here
550  if (m_truthSelectionTool.get()) {
551  ATH_MSG_DEBUG( CutFlow(tmp_truth_cutflow).report(m_truthSelectionTool->names()) );
552  std::lock_guard<std::mutex> lock(m_mutex);
553  m_truthCutFlow.merge(std::move(tmp_truth_cutflow));
554  }
555 
556  //
557  //TruthParticle loop to fill efficiencies
558  //
559  for (int itruth = 0; itruth < (int) truthParticlesVec.size(); itruth++) { // Outer loop over all truth particles
560  nTruths++;
561  const xAOD::TruthParticle* thisTruth = truthParticlesVec[itruth];
562 
563  // if the vector of truth particles is not empty also a truthSelectionTool was retrieved
564  const IAthSelectionTool::CutResult accept = m_truthSelectionTool->accept(thisTruth);
565  if (accept) {
566  ++nSelectedTruthTracks; // total number of truth which pass cuts per event
567  bool isEfficient(false); // weight for the trackeff histos
568  m_monPlots->fill(*thisTruth, beamSpotWeight); // This is filling truth-only plots
569 
570  if(m_doDuplicatePlots){
571  auto cachedAssoc = cacheTruthMatching.find(thisTruth);
572  // Check if truth particle already present in cache
573  if (cachedAssoc == cacheTruthMatching.end()) {
574  // If not yet present, then no track associated
575  cacheTruthMatching[thisTruth] = {};
576  }
577  m_monPlots->fillDuplicate(*thisTruth, cacheTruthMatching[thisTruth], beamSpotWeight);
578  }
579 
580  //
581  //Loop over reco tracks to find the match
582  //
583  const xAOD::TrackParticle* matchedTrack = nullptr;
584  for (const auto& thisTrack: selectedTracks) { // Inner loop over selected track particleis
585  const xAOD::TruthParticle* associatedTruth = getAsTruth.getTruth(thisTrack);
586  if (associatedTruth && associatedTruth == thisTruth) {
587  float prob = getMatchingProbability(*thisTrack);
588  if (not std::isnan(prob) && prob > m_lowProb) {
589  isEfficient = true;
590  matchedTrack = thisTrack;
591  break;
592  }
593  }
594  }
595  if (!thisTruth){
596  ATH_MSG_ERROR("An error occurred: Truth particle for tracking efficiency calculation is a nullptr");
597  }
598  else if (isEfficient && !matchedTrack){
599  ATH_MSG_ERROR("Something went wrong - we log a truth particle as reconstructed, but the reco track is a nullptr! Bailing out... ");
600  }
601  else{
602  ATH_MSG_DEBUG("Filling efficiency plots info monitoring plots");
603  m_monPlots->fillEfficiency(*thisTruth, matchedTrack, isEfficient, truthMu, actualMu, beamSpotWeight);
605  ATH_MSG_DEBUG("Filling technical efficiency plots info monitoring plots");
606  static const SG::ConstAccessor< float > nSilHitsAcc("nSilHits");
607  if (nSilHitsAcc.isAvailable(*thisTruth)) {
608  if (nSilHitsAcc(*thisTruth) >= m_minHits.value().at(getIndexByEta(*thisTruth))){
609  m_monPlots->fillTechnicalEfficiency(*thisTruth, isEfficient,
610  truthMu, actualMu, beamSpotWeight);
611  }
612  } else {
613  ATH_MSG_DEBUG("Cannot fill technical efficiency. Missing si hit information for truth particle.");
614  }
615  }
616  }
617  }
618 
620  // Skip if already filled in track loop
621  if (hasTruthFilled(*thisTruth)) continue;
622 
623  // Decorate truth particle with extra flags
624  decorateTruthParticle(*thisTruth, accept);
625 
626  // Fill truth only entries with dummy track values
627  m_monPlots->fillNtuple(*thisTruth);
628  }
629  }
630 
631  if (nSelectedRecoTracks == nMissingAssociatedTruth) {
632  if (not m_truthParticleName.key().empty()) {
633  ATH_MSG_DEBUG("NO TRACKS had associated truth.");
634  }
635  } else {
636  ATH_MSG_DEBUG(nAssociatedTruth << " tracks out of " << tracks->size() << " had associated truth.");
637  }
638 
639  m_monPlots->fillCounter(nSelectedRecoTracks, InDetPerfPlot_nTracks::SELECTEDRECO, beamSpotWeight);
640  m_monPlots->fillCounter(tracks->size(), InDetPerfPlot_nTracks::ALLRECO, beamSpotWeight);
641  m_monPlots->fillCounter(nSelectedTruthTracks, InDetPerfPlot_nTracks::SELECTEDTRUTH, beamSpotWeight);
642  m_monPlots->fillCounter(nTruths, InDetPerfPlot_nTracks::ALLTRUTH, beamSpotWeight);
643  m_monPlots->fillCounter(nAssociatedTruth, InDetPerfPlot_nTracks::ALLASSOCIATEDTRUTH, beamSpotWeight);
644  m_monPlots->fillCounter(nSelectedMatchedTracks, InDetPerfPlot_nTracks::MATCHEDRECO, beamSpotWeight);
645 
646  // Tracking In Dense Environment
647  if (m_doTrackInJetPlots) {
649  getAsTruth,
650  truthParticlesVec,
651  *tracks,
652  primaryvertex,
653  beamSpotWeight) );
654  }
655  return StatusCode::SUCCESS;
656 }
657 
659  // Decorate outcome of track selection
661 }
662 
664  // Decorate outcome of truth selection
666 
667  // Decorate if selected by pileup switch
669 }
670 
672  if (!m_acc_hasTruthFilled.isAvailable(truth)) {
673  ATH_MSG_DEBUG("Truth particle not yet filled in ntuple");
674  return false;
675  }
676  return m_acc_hasTruthFilled(truth);
677 }
678 
680  if (!m_acc_selectedByPileupSwitch.isAvailable(truth)) {
681  ATH_MSG_DEBUG("Selected by pileup switch decoration requested from a truth particle but not available");
682  return false;
683  }
684  return m_acc_selectedByPileupSwitch(truth);
685 }
686 
687 void InDetPhysValMonitoringTool::markSelectedByPileupSwitch(const std::vector<const xAOD::TruthParticle*> & truthParticles) const{
688  for (const auto& thisTruth: truthParticles) {
689  m_dec_selectedByPileupSwitch(*thisTruth) = true;
690  }
691 }
692 
695  ATH_MSG_INFO("Booking hists " << name() << "with detailed level: " << m_detailLevel);
696  m_monPlots->initialize();
697  std::vector<HistData> hists = m_monPlots->retrieveBookedHistograms();
698  for (const auto& hist : hists) {
699  ATH_CHECK(regHist(hist.first, hist.second, all)); // ??
700  }
701  // do the same for Efficiencies, but there's a twist:
702  std::vector<EfficiencyData> effs = m_monPlots->retrieveBookedEfficiencies();
703  for (auto& eff : effs) {
704  // reg**** in the monitoring baseclass doesnt have a TEff version, but TGraph *
705  // pointers just get passed through, so we use that method after an ugly cast
706  ATH_CHECK(regGraph(reinterpret_cast<TGraph*>(eff.first), eff.second, all)); // ??
707  }
708  // register trees for ntuple writing
710  std::vector<TreeData> trees = m_monPlots->retrieveBookedTrees();
711  for (auto& t : trees) {
712  ATH_CHECK(regTree(t.first, t.second, all));
713  }
714  }
715 
716  return StatusCode::SUCCESS;
717 }
718 
721  ATH_MSG_INFO("Finalising hists " << name() << "...");
722  //TODO: ADD Printouts for Truth??
723  if (m_useTrackSelection) {
724  ATH_MSG_INFO("");
725  ATH_MSG_INFO("Now Cutflow for track cuts:");
726  ATH_MSG_INFO("");
727  for (int i = 0; i < (int) m_trackCutflow.size(); ++i) {
728  ATH_MSG_INFO("number after " << m_trackCutflowNames[i] << ": " << m_trackCutflow[i]);
729  }
730  }
731 
732  ATH_MSG_INFO("");
733  ATH_MSG_INFO("Cutflow for truth tracks:");
734  if (m_truthSelectionTool.get()) {
735  ATH_MSG_INFO("Truth selection report: " << m_truthCutFlow.report( m_truthSelectionTool->names()) );
736  }
737  if (endOfRunFlag()) {
738  m_monPlots->finalize();
739  }
740  ATH_MSG_INFO("Successfully finalized hists");
741  return StatusCode::SUCCESS;
742 }
743 
744 const std::vector<const xAOD::TruthParticle*>
745 InDetPhysValMonitoringTool::getTruthParticles(const EventContext& ctx) const {
746 
747  std::vector<const xAOD::TruthParticle*> tempVec {};
748 
749  if (m_pileupSwitch == "All") {
750  if (m_truthParticleName.key().empty()) {
751  return tempVec;
752  }
754  if (not truthParticleContainer.isValid()) {
755  return tempVec;
756  }
757  tempVec.insert(tempVec.begin(), truthParticleContainer->begin(), truthParticleContainer->end());
758  } else {
759  if (m_pileupSwitch == "HardScatter") {
760  // get truthevent container to separate out pileup and hardscatter truth particles
761  if (not m_truthEventName.key().empty()) {
763  const xAOD::TruthEvent* event = (truthEventContainer.isValid()) ? truthEventContainer->at(0) : nullptr;
764  if (not event) {
765  return tempVec;
766  }
767  const auto& links = event->truthParticleLinks();
768  tempVec.reserve(event->nTruthParticles());
769  for (const auto& link : links) {
770  if (link.isValid()){
771  tempVec.push_back(*link);
772  }
773  }
774  }
775  } else if (m_pileupSwitch == "PileUp") {
776  if (not m_truthPileUpEventName.key().empty()) {
777  ATH_MSG_VERBOSE("getting TruthPileupEvents container");
778  // get truth particles from all pileup events
780  if (truthPileupEventContainer.isValid()) {
781  const unsigned int nPileup = truthPileupEventContainer->size();
782  tempVec.reserve(nPileup * 200); // quick initial guess, will still save some time
783  for (unsigned int i(0); i != nPileup; ++i) {
784  const auto *eventPileup = truthPileupEventContainer->at(i);
785  // get truth particles from each pileup event
786  int ntruth = eventPileup->nTruthParticles();
787  ATH_MSG_VERBOSE("Adding " << ntruth << " truth particles from TruthPileupEvents container");
788  const auto& links = eventPileup->truthParticleLinks();
789  for (const auto& link : links) {
790  if (link.isValid()){
791  tempVec.push_back(*link);
792  }
793  }
794  }
795  } else {
796  ATH_MSG_ERROR("no entries in TruthPileupEvents container!");
797  }
798  }
799  } else {
800  ATH_MSG_ERROR("bad value for PileUpSwitch");
801  }
802  }
803  return tempVec;
804 }
805 
806 std::pair<const std::vector<const xAOD::TruthVertex*>, const std::vector<const xAOD::TruthVertex*>>
807 InDetPhysValMonitoringTool::getTruthVertices(const EventContext& ctx) const {
808 
809  std::vector<const xAOD::TruthVertex*> truthHSVertices = {};
810  truthHSVertices.reserve(5);
811  std::vector<const xAOD::TruthVertex*> truthPUVertices = {};
812  truthPUVertices.reserve(100);
813  const xAOD::TruthVertex* truthVtx = nullptr;
814 
815  bool doHS = false;
816  bool doPU = false;
817  if (m_pileupSwitch == "All") {
818  doHS = true;
819  doPU = true;
820  }
821  else if (m_pileupSwitch == "HardScatter") {
822  doHS = true;
823  }
824  else if (m_pileupSwitch == "PileUp") {
825  doPU = true;
826  }
827  else {
828  ATH_MSG_ERROR("Bad value for PileUpSwitch: " << m_pileupSwitch);
829  }
830 
831  if (doHS) {
832  if (not m_truthEventName.key().empty()) {
833  ATH_MSG_VERBOSE("Getting HS TruthEvents container.");
835  if (truthEventContainer.isValid()) {
836  for (const auto *const evt : *truthEventContainer) {
837  truthVtx = evt->signalProcessVertex();
838  if (truthVtx) {
839  truthHSVertices.push_back(truthVtx);
840  }
841  }
842  }
843  else {
844  ATH_MSG_ERROR("No entries in TruthEvents container!");
845  }
846  }
847  }
848 
849  if (doPU) {
850  if (not m_truthPileUpEventName.key().empty()) {
851  ATH_MSG_VERBOSE("Getting PU TruthEvents container.");
853  if (truthPileupEventContainer.isValid()) {
854  for (const auto *const evt : *truthPileupEventContainer) {
855  // Get the PU vertex
856  // In all cases tested i_vtx=2 for PU
857  // but better to keep something generic
858  truthVtx = nullptr;
859  size_t i_vtx = 0; size_t n_vtx = evt->nTruthVertices();
860  while(!truthVtx && i_vtx<n_vtx){
861  truthVtx = evt->truthVertex(i_vtx);
862  i_vtx++;
863  }
864 
865  if (truthVtx) {
866  truthPUVertices.push_back(truthVtx);
867  }
868  }
869  }
870  else {
871  ATH_MSG_DEBUG("No entries in TruthPileupEvents container");
872  }
873  }
874  }
875 
876  return std::make_pair<const std::vector<const xAOD::TruthVertex*>, const std::vector<const xAOD::TruthVertex*>>((const std::vector<const xAOD::TruthVertex*>)truthHSVertices, (const std::vector<const xAOD::TruthVertex*>)truthPUVertices);
877 
878 }
879 
880 void
883 }
884 
885 void
887  std::vector<int>& cutFlow) {
888  // initialise cutflows
889  if (cutFlow.empty()) {
890  names.emplace_back("preCut");
891  cutFlow.push_back(0);
892  for (unsigned int i = 0; i != accept.getNCuts(); ++i) {
893  cutFlow.push_back(0);
894  names.push_back((std::string) accept.getCutName(i));
895  }
896  }
897  // get cutflow
898  cutFlow[0] += 1;
899  bool cutPositive = true;
900  for (unsigned int i = 0; i != (accept.getNCuts() + 1); ++i) {
901  if (!cutPositive) {
902  continue;
903  }
904  if (accept.getCutResult(i)) {
905  cutFlow[i + 1] += 1;
906  } else {
907  cutPositive = false;
908  }
909  }
910  }
911 
913  double absEta = std::abs(truth.eta());
914  if (absEta > m_etaBins.value().back() || absEta < m_etaBins.value().front()) {
915  absEta = std::clamp(absEta, m_etaBins.value().front(), m_etaBins.value().back());
916  ATH_MSG_INFO("Requesting cut value outside of configured eta range: clamping eta = "
917  << std::abs(truth.eta()) << " to eta= " << absEta);
918  } else
919  absEta = std::clamp(absEta, m_etaBins.value().front(), m_etaBins.value().back());
920  const auto pVal = std::lower_bound(m_etaBins.value().begin(), m_etaBins.value().end(), absEta);
921  const int bin = std::distance(m_etaBins.value().begin(), pVal) - 1;
922  ATH_MSG_DEBUG("Checking (abs(eta)/bin) = (" << absEta << "," << bin << ")");
923  return bin;
924 }
925 
927  IDPVM::CachedGetAssocTruth& getAsTruth,
928  const std::vector<const xAOD::TruthParticle*>& truthParticles,
929  const xAOD::TrackParticleContainer& tracks,
930  const xAOD::Vertex* primaryvertex,
931  float beamSpotWeight) {
932  // Define accessors
933  static const SG::ConstAccessor<std::vector<ElementLink<xAOD::IParticleContainer> > > ghosttruth("GhostTruth");
934  static const SG::ConstAccessor<int> btagLabel("HadronConeExclTruthLabelID");
935 
936  if (truthParticles.empty()) {
937  ATH_MSG_WARNING("No entries in TruthParticles truth particle container. Skipping jet plots.");
938  return StatusCode::SUCCESS;
939  }
940 
942  if (not jetHandle.isValid()) {
943  ATH_MSG_WARNING("Cannot open jet container " << m_jetContainerName.key() << ". Skipping jet plots.");
944  return StatusCode::SUCCESS;
945  }
946  const xAOD::JetContainer* jets = jetHandle.cptr();
947 
948  // loop on jets
949  for (const xAOD::Jet *const thisJet: *jets) {
950  // pass jet cuts
951  if (not passJetCuts(*thisJet)) continue;
952  // check if b-jet
953  bool isBjet = false;
954  if (not btagLabel.isAvailable(*thisJet)){
955  ATH_MSG_WARNING("Failed to extract b-tag truth label from jet");
956  } else {
957  isBjet = (btagLabel(*thisJet) == 5);
958  }
959 
960  // Retrieve associated ghost truth particles
961  if(not ghosttruth.isAvailable(*thisJet)) {
962  ATH_MSG_WARNING("Failed to extract ghost truth particles from jet");
963  } else {
964  for(const ElementLink<xAOD::IParticleContainer>& el : ghosttruth(*thisJet)) {
965  if (not el.isValid()) continue;
966 
967  const xAOD::TruthParticle *truth = static_cast<const xAOD::TruthParticle*>(*el);
968  // Check delta R between track and jet axis
969  if (thisJet->p4().DeltaR(truth->p4()) > m_maxTrkJetDR) {
970  continue;
971  }
972  // Apply truth selection cuts
974  if(!accept) continue;
975 
976  bool isEfficient(false);
977 
978  for (const auto *thisTrack: tracks) {
979  if (m_useTrackSelection and not (m_trackSelectionTool->accept(*thisTrack, primaryvertex))) {
980  continue;
981  }
982 
983  const xAOD::TruthParticle* associatedTruth = getAsTruth.getTruth(thisTrack);
984  if (associatedTruth and associatedTruth == truth) {
985  float prob = getMatchingProbability(*thisTrack);
986  if (not std::isnan(prob) && prob > m_lowProb) {
987  isEfficient = true;
988  break;
989  }
990  }
991  }
992 
993  bool truthIsFromB = false;
994  if ( m_doTruthOriginPlots and m_trackTruthOriginTool->isFrom(truth, 5) ) {
995  truthIsFromB = true;
996  }
997  m_monPlots->fillEfficiency(*truth, *thisJet, isEfficient, isBjet, truthIsFromB, beamSpotWeight);
998  }
999  } // ghost truth
1000 
1001  // loop on tracks
1002  for (const xAOD::TrackParticle *thisTrack: tracks) {
1003  if (m_useTrackSelection and not (m_trackSelectionTool->accept(*thisTrack, primaryvertex))) {
1004  continue;
1005  }
1006 
1007  if (thisJet->p4().DeltaR(thisTrack->p4()) > m_maxTrkJetDR) {
1008  continue;
1009  }
1010 
1011  float prob = getMatchingProbability(*thisTrack);
1012  if(std::isnan(prob)) prob = 0.0;
1013 
1014  const xAOD::TruthParticle* associatedTruth = getAsTruth.getTruth(thisTrack);
1015  const bool unlinked = (associatedTruth==nullptr);
1016  const bool isFake = (associatedTruth && prob < m_lowProb);
1017  bool truthIsFromB = false;
1018  if ( m_doTruthOriginPlots and m_trackTruthOriginTool->isFrom(associatedTruth, 5) ) {
1019  truthIsFromB = true;
1020  }
1021  m_monPlots->fill(*thisTrack, *thisJet, isBjet, isFake, unlinked, truthIsFromB, beamSpotWeight);
1022  if (associatedTruth){
1023  m_monPlots->fillFakeRate(*thisTrack, *thisJet, isFake, isBjet, truthIsFromB, beamSpotWeight);
1024  }
1025  }
1026 
1027  } // loop on jets
1028 
1029  return StatusCode::SUCCESS;
1030 }
1031 
1032 bool
1034  const float jetPt = jet.pt();
1035  const float jetEta = std::abs(jet.eta());
1036 
1037  if (jetEta < m_jetAbsEtaMin) return false;
1038  if (jetEta > m_jetAbsEtaMax) return false;
1039  if (jetPt < m_jetPtMin) return false;
1040  if (jetPt > m_jetPtMax) return false;
1041  return true;
1042 }
InDetPhysValMonitoringTool::m_jetPtMax
FloatProperty m_jetPtMax
Definition: InDetPhysValMonitoringTool.h:201
InDetPhysValMonitoringTool::m_dec_passedTruthSelection
SG::AuxElement::Decorator< bool > m_dec_passedTruthSelection
Definition: InDetPhysValMonitoringTool.h:107
InDetPhysValMonitoringTool::decorateTrackParticle
void decorateTrackParticle(const xAOD::TrackParticle &track, const asg::AcceptData &passed) const
Definition: InDetPhysValMonitoringTool.cxx:658
InDetPhysValMonitoringTool::getIndexByEta
int getIndexByEta(const xAOD::TruthParticle &truth) const
Utility function for evaluation of technical efficiency.
Definition: InDetPhysValMonitoringTool.cxx:912
InDetPhysValMonitoringTool::m_fillTechnicalEfficiency
BooleanProperty m_fillTechnicalEfficiency
Definition: InDetPhysValMonitoringTool.h:186
InDetPhysValMonitoringTool::m_jetAbsEtaMin
FloatProperty m_jetAbsEtaMin
Definition: InDetPhysValMonitoringTool.h:198
InDetPhysValMonitoringTool::m_pileupSwitch
StringProperty m_pileupSwitch
Definition: InDetPhysValMonitoringTool.h:192
InDetPhysValMonitoringTool::m_usingSpecialPileupSwitch
bool m_usingSpecialPileupSwitch
Definition: InDetPhysValMonitoringTool.h:222
GeV
#define GeV
Definition: PhysicsAnalysis/TauID/TauAnalysisTools/Root/HelperFunctions.cxx:17
InDetPhysValMonitoringTool::m_grlTool
ToolHandle< IGoodRunsListSelectionTool > m_grlTool
Definition: InDetPhysValMonitoringTool.h:210
InDetPhysValMonitoringTool::m_hardScatterSelectionTool
ToolHandle< InDet::IInDetHardScatterSelectionTool > m_hardScatterSelectionTool
Definition: InDetPhysValMonitoringTool.h:209
InDetPhysValMonitoringTool::m_trackSelectionTool
ToolHandle< InDet::IInDetTrackSelectionTool > m_trackSelectionTool
Definition: InDetPhysValMonitoringTool.h:205
InDetPhysValMonitoringTool::m_monPlots
std::unique_ptr< InDetRttPlots > m_monPlots
histograms
Definition: InDetPhysValMonitoringTool.h:169
get_generator_info.result
result
Definition: get_generator_info.py:21
NSWL1::nVertices
int nVertices(const Polygon &p)
Definition: GeoUtils.cxx:35
InDetPhysValMonitoringTool::m_minHits
IntegerArrayProperty m_minHits
Definition: InDetPhysValMonitoringTool.h:196
InDetPhysValMonitoringTool::bookHistograms
virtual StatusCode bookHistograms()
An inheriting class should either override this function or bookHists().
Definition: InDetPhysValMonitoringTool.cxx:694
InDetRttPlotConfig::doResolutionsPerAuthor
bool doResolutionsPerAuthor
Definition: InDetRttPlots.h:105
TrigCompositeUtils::passed
bool passed(DecisionID id, const DecisionIDContainer &idSet)
checks if required decision ID is in the set of IDs in the container
Definition: TrigCompositeUtilsRoot.cxx:117
ATH_MSG_INFO
#define ATH_MSG_INFO(x)
Definition: AthMsgStreamMacros.h:31
SG::ReadHandle::cptr
const_pointer_type cptr()
Dereference the pointer.
CaloCellPos2Ntuple.int
int
Definition: CaloCellPos2Ntuple.py:24
InDetSecVtxTruthMatchUtils::isFake
bool isFake(int matchInfo)
Definition: InDetSecVtxTruthMatchTool.h:60
InDetRttPlotConfig::doTrkInJetPlots_matched_bjets
bool doTrkInJetPlots_matched_bjets
Definition: InDetRttPlots.h:94
ManagedMonitorToolBase
Provides functionality for users to implement and save histograms, ntuples, and summary data,...
Definition: ManagedMonitorToolBase.h:73
InDetRttPlotConfig::doResolutionPlotSecd
bool doResolutionPlotSecd
Definition: InDetRttPlots.h:78
IAthSelectionTool::CutResult
Definition: IAthSelectionTool.h:30
InDetPhysValMonitoringTool::m_useGRL
BooleanProperty m_useGRL
Definition: InDetPhysValMonitoringTool.h:184
SG::ReadHandle
Definition: StoreGate/StoreGate/ReadHandle.h:70
InDetPhysValMonitoringTool::m_doPRW
BooleanProperty m_doPRW
Definition: InDetPhysValMonitoringTool.h:187
ManagedMonitorToolBase::regTree
virtual StatusCode regTree(TTree *t, const std::string &system, Interval_t interval, MgmtAttr_t histo_mgmt=ATTRIB_MANAGED, const std::string &chain="", const std::string &merge="")
Registers a TTree to be included in the output stream using logical parameters that describe it.
Definition: ManagedMonitorToolBase.cxx:1547
InDetRttPlotConfig::doHitsUnlinkedTracksPlots
bool doHitsUnlinkedTracksPlots
Definition: InDetRttPlots.h:66
InDetPhysValMonitoringTool::m_maxTrkJetDR
FloatProperty m_maxTrkJetDR
Definition: InDetPhysValMonitoringTool.h:189
InDetRttPlotConfig::doHardScatterVertexTruthMatchingPlots
bool doHardScatterVertexTruthMatchingPlots
Definition: InDetRttPlots.h:88
InDetRttPlotConfig::doHardScatterVertexPlots
bool doHardScatterVertexPlots
Definition: InDetRttPlots.h:84
plotmaker.hist
hist
Definition: plotmaker.py:148
IDPVM::CachedGetAssocTruth
Definition: CachedGetAssocTruth.h:21
InDetPhysValMonitoringTool::m_truthParticleName
SG::ReadHandleKey< xAOD::TruthParticleContainer > m_truthParticleName
TruthParticle container's name.
Definition: InDetPhysValMonitoringTool.h:137
CutsMETMaker::accept
StatusCode accept(const xAOD::Muon *mu)
Definition: CutsMETMaker.cxx:18
RTTAlgmain.trees
list trees
Definition: RTTAlgmain.py:40
InDetPhysValMonitoringTool::passJetCuts
bool passJetCuts(const xAOD::Jet &jet) const
Definition: InDetPhysValMonitoringTool.cxx:1033
InDetRttPlotConfig::doNTracks
bool doNTracks
Definition: InDetRttPlots.h:56
ALFA_EventTPCnv_Dict::t1
std::vector< ALFA_RawDataCollection_p1 > t1
Definition: ALFA_EventTPCnvDict.h:43
TruthPileupEvent.h
InDetVertexTruthMatchUtils::classifyHardScatter
HardScatterType classifyHardScatter(const xAOD::VertexContainer &vxContainer)
Definition: InDetVertexTruthMatchUtils.cxx:70
InDetRttPlotConfig::doTrtExtensionPlots
bool doTrtExtensionPlots
Definition: InDetRttPlots.h:60
bin
Definition: BinsDiffFromStripMedian.h:43
checkTP.report
report
Definition: checkTP.py:127
safeDecorator.h
InDetPhysValMonitoringTool::getTruthParticles
const std::vector< const xAOD::TruthParticle * > getTruthParticles(const EventContext &ctx) const
Definition: InDetPhysValMonitoringTool.cxx:745
InDetPhysValMonitoringTool::fillHistograms
virtual StatusCode fillHistograms()
An inheriting class should either override this function or fillHists().
Definition: InDetPhysValMonitoringTool.cxx:301
InDetPhysValMonitoringTool::m_acc_selectedByPileupSwitch
SG::AuxElement::Accessor< bool > m_acc_selectedByPileupSwitch
Definition: InDetPhysValMonitoringTool.h:109
athena.value
value
Definition: athena.py:124
InDetPhysValMonitoringTool::m_useTrackSelection
BooleanProperty m_useTrackSelection
Properties to fine-tune the tool behaviour.
Definition: InDetPhysValMonitoringTool.h:173
InDetPhysValMonitoringTool::m_intTruthDecor
std::vector< SG::ReadDecorHandleKey< xAOD::TruthParticleContainer > > m_intTruthDecor
Definition: InDetPhysValMonitoringTool.h:165
InDetRttPlotConfig::doTrkInJetPlots_unlinked_bjets
bool doTrkInJetPlots_unlinked_bjets
Definition: InDetRttPlots.h:98
ManagedMonitorToolBase::regGraph
virtual StatusCode regGraph(TGraph *g, const std::string &system, Interval_t interval, MgmtAttr_t histo_mgmt=ATTRIB_MANAGED, const std::string &chain="", const std::string &merge="")
Registers a TGraph to be included in the output stream using logical parameters that describe the gra...
Definition: ManagedMonitorToolBase.cxx:1491
LArG4FSStartPointFilter.evt
evt
Definition: LArG4FSStartPointFilter.py:42
SG::ConstAccessor< float >
InDetPhysValMonitoringTool::m_eventInfoContainerName
SG::ReadHandleKey< xAOD::EventInfo > m_eventInfoContainerName
EventInfo container name.
Definition: InDetPhysValMonitoringTool.h:149
InDetRttPlotConfig::doHitEffPlot
bool doHitEffPlot
Definition: InDetRttPlots.h:58
InDetRttPlotConfig::doTrkInJetPlots_truthFromB
bool doTrkInJetPlots_truthFromB
Definition: InDetRttPlots.h:99
read_hist_ntuple.t
t
Definition: read_hist_ntuple.py:5
ATH_MSG_VERBOSE
#define ATH_MSG_VERBOSE(x)
Definition: AthMsgStreamMacros.h:28
SG::VarHandleKey::key
const std::string & key() const
Return the StoreGate ID for the referenced object.
Definition: AthToolSupport/AsgDataHandles/Root/VarHandleKey.cxx:141
InDetPerfPlot_nTracks::ALLASSOCIATEDTRUTH
@ ALLASSOCIATEDTRUTH
Definition: InDetPerfPlot_nTracks.h:25
InDetRttPlotConfig::doHitResidualPlot
bool doHitResidualPlot
Definition: InDetRttPlots.h:57
InDetRttPlotConfig::doTrkInJetPlots
bool doTrkInJetPlots
Plots for tracks in jets.
Definition: InDetRttPlots.h:91
InDetPhysValMonitoringTool::m_jetAbsEtaMax
FloatProperty m_jetAbsEtaMax
Definition: InDetPhysValMonitoringTool.h:199
covarianceTool.prob
prob
Definition: covarianceTool.py:678
InDetRttPlotConfig::doTrkInJetPlots_matched
bool doTrkInJetPlots_matched
Definition: InDetRttPlots.h:93
xAOD::EventInfo_v1::IS_SIMULATION
@ IS_SIMULATION
true: simulation, false: data
Definition: EventInfo_v1.h:151
x
#define x
TrackStateValidation.h
InDetPhysValMonitoringTool::m_intJetDecor
std::vector< SG::ReadDecorHandleKey< xAOD::JetContainer > > m_intJetDecor
Definition: InDetPhysValMonitoringTool.h:166
InDetPhysValMonitoringTool::m_truthVertexContainerName
SG::ReadHandleKey< xAOD::TruthVertexContainer > m_truthVertexContainerName
Truth vertex container's name.
Definition: InDetPhysValMonitoringTool.h:145
xAOD::TruthVertex_v1::y
float y() const
Vertex y displacement.
InDetPhysValMonitoringTool::m_jetPtMin
FloatProperty m_jetPtMin
Definition: InDetPhysValMonitoringTool.h:200
InDetPhysValMonitoringTool::m_lowProb
FloatProperty m_lowProb
Definition: InDetPhysValMonitoringTool.h:193
CutFlow::update
void update(bool)
Definition: CutFlow.h:192
InDetRttPlotConfig::doFakesPerAuthor
bool doFakesPerAuthor
Definition: InDetRttPlots.h:103
IDPVM::addReadDecoratorHandleKeys
void addReadDecoratorHandleKeys(T_Parent &parent, const SG::ReadHandleKey< T_Cont > &container_key, const std::string &prefix, const std::vector< std::string > &decor_names, std::vector< SG::ReadDecorHandleKey< T_Cont > > &decor_out)
Definition: safeDecorator.h:145
InDetPhysValMonitoringTool::m_jetContainerName
SG::ReadHandleKey< xAOD::JetContainer > m_jetContainerName
Definition: InDetPhysValMonitoringTool.h:158
InDetPhysValMonitoringTool::m_dec_passedTrackSelection
SG::AuxElement::Decorator< bool > m_dec_passedTrackSelection
Definition: InDetPhysValMonitoringTool.h:108
InDetPhysValMonitoringTool.h
InDetPhysValMonitoringTool::m_truthPileUpEventName
SG::ReadHandleKey< xAOD::TruthPileupEventContainer > m_truthPileUpEventName
Definition: InDetPhysValMonitoringTool.h:155
InDetPhysValMonitoringTool::isSelectedByPileupSwitch
bool isSelectedByPileupSwitch(const xAOD::TruthParticle &truth) const
Definition: InDetPhysValMonitoringTool.cxx:679
InDetVertexTruthMatchUtils.h
jet
Definition: JetCalibTools_PlotJESFactors.cxx:23
InDetPhysValMonitoringTool::markSelectedByPileupSwitch
void markSelectedByPileupSwitch(const std::vector< const xAOD::TruthParticle * > &truthParticles) const
Definition: InDetPhysValMonitoringTool.cxx:687
ATH_MSG_ERROR
#define ATH_MSG_ERROR(x)
Definition: AthMsgStreamMacros.h:33
CachedGetAssocTruth.h
SG::ReadDecorHandle
Handle class for reading a decoration on an object.
Definition: StoreGate/StoreGate/ReadDecorHandle.h:94
InDetPhysValMonitoringTool::m_doTruthOriginPlots
BooleanProperty m_doTruthOriginPlots
Definition: InDetPhysValMonitoringTool.h:174
ManagedMonitorToolBase::initialize
virtual StatusCode initialize()
Definition: ManagedMonitorToolBase.cxx:617
InDetRttPlotConfig::doTrkInJetPlots_bjets
bool doTrkInJetPlots_bjets
Definition: InDetRttPlots.h:92
MuonPhysValMonitoring::getMatchingProbability
float getMatchingProbability(const xAOD::TrackParticle &trackParticle)
Definition: MuonPhysValMonitoringTool.cxx:57
InDetPhysValMonitoringTool::m_doTrackInJetPlots
BooleanProperty m_doTrackInJetPlots
Definition: InDetPhysValMonitoringTool.h:177
event
POOL::TEvent event(POOL::TEvent::kClassAccess)
InDetPhysValMonitoringTool::m_trackCutflow
std::vector< int > m_trackCutflow
Definition: InDetPhysValMonitoringTool.h:220
lumiFormat.i
int i
Definition: lumiFormat.py:85
z
#define z
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
SG::ReadHandle::get
const_pointer_type get() const
Dereference the pointer, but don't cache anything.
DMTest::links
links
Definition: CLinks_v1.cxx:22
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
python.subdetectors.mmg.names
names
Definition: mmg.py:8
InDetRttPlotConfig
helper struct - steer the configuration from the parent tool's side
Definition: InDetRttPlots.h:51
InDetRttPlotConfig::doResolutionPlotPrim_truthFromB
bool doResolutionPlotPrim_truthFromB
Definition: InDetRttPlots.h:77
InDetRttPlots.h
InDetRttPlotConfig::doFakePlots
bool doFakePlots
Fake plots (and unlinked)
Definition: InDetRttPlots.h:63
xAOD::TruthParticle_v1
Class describing a truth particle in the MC record.
Definition: TruthParticle_v1.h:37
InDetPhysValMonitoringTool::initialize
virtual StatusCode initialize()
Definition: InDetPhysValMonitoringTool.cxx:116
InDetPhysValMonitoringTool::procHistograms
virtual StatusCode procHistograms()
An inheriting class should either override this function or finalHists().
Definition: InDetPhysValMonitoringTool.cxx:720
InDetPhysValMonitoringTool::getFilledPlotConfig
InDetRttPlotConfig getFilledPlotConfig() const
Generate an Rtt config struct based on the user-passed properties.
Definition: InDetPhysValMonitoringTool.cxx:171
TrackCollection.h
InDetPhysValMonitoringTool::m_floatTrkDecor
std::vector< SG::ReadDecorHandleKey< xAOD::TrackParticleContainer > > m_floatTrkDecor
Definition: InDetPhysValMonitoringTool.h:162
CutFlow
Definition: CutFlow.h:166
test_pyathena.parent
parent
Definition: test_pyathena.py:15
plotIsoValidation.el
el
Definition: plotIsoValidation.py:197
xAOD::TruthEvent_v1
Class describing a signal truth event in the MC record.
Definition: TruthEvent_v1.h:35
InDetPhysValMonitoringTool::m_onlyFillMatched
BooleanProperty m_onlyFillMatched
Definition: InDetPhysValMonitoringTool.h:182
IDPVM::CachedGetAssocTruth::getTruth
const xAOD::TruthParticle * getTruth(const xAOD::TrackParticle *const trackParticle)
Definition: CachedGetAssocTruth.cxx:22
ATH_CHECK
#define ATH_CHECK
Definition: AthCheckMacros.h:40
InDetPhysValMonitoringTool::m_truthSelectionTool
ToolHandle< IAthSelectionTool > m_truthSelectionTool
Definition: InDetPhysValMonitoringTool.h:207
MakeTH3DFromTH2Ds.hists
hists
Definition: MakeTH3DFromTH2Ds.py:72
hist_file_dump.f
f
Definition: hist_file_dump.py:135
InDetPhysValMonitoringTool::m_vertexContainerName
SG::ReadHandleKey< xAOD::VertexContainer > m_vertexContainerName
Primary vertex container's name.
Definition: InDetPhysValMonitoringTool.h:141
AthTruthSelectionTool.h
IDPVM::binIndex
unsigned int binIndex(const T &val, const std::vector< T > &partitions)
general utility function to return bin index given a value and the upper endpoints of each bin
Definition: InDetPhysValMonitoringUtilities.h:43
InDetPhysValMonitoringTool::m_useVertexTruthMatchTool
BooleanProperty m_useVertexTruthMatchTool
Definition: InDetPhysValMonitoringTool.h:181
SG::VarHandleKey::initialize
StatusCode initialize(bool used=true)
If this object is used as a property, then this should be called during the initialize phase.
Definition: AthToolSupport/AsgDataHandles/Root/VarHandleKey.cxx:103
InDetPhysValMonitoringTool::m_truthEventName
SG::ReadHandleKey< xAOD::TruthEventContainer > m_truthEventName
Definition: InDetPhysValMonitoringTool.h:152
InDetRttPlotConfig::doTrkInJetPlots_fake_bjets
bool doTrkInJetPlots_fake_bjets
Definition: InDetRttPlots.h:96
DataVector
Derived DataVector<T>.
Definition: DataVector.h:794
DeMoScan.partitions
dictionary partitions
Definition: DeMoScan.py:67
SG::ReadHandle::isValid
virtual bool isValid() override final
Can the handle be successfully dereferenced?
InDetRttPlotConfig::doEfficienciesPerAuthor
bool doEfficienciesPerAuthor
per author plots
Definition: InDetRttPlots.h:102
inRange
bool inRange(const double *boundaries, const double value, const double tolerance=0.02)
Definition: LArSCIdVsIdTest.cxx:5
InDetRttPlotConfig::doNtupleTruthToReco
bool doNtupleTruthToReco
Ntuple functionality.
Definition: InDetRttPlots.h:108
InDetPhysValMonitoringTool::~InDetPhysValMonitoringTool
virtual ~InDetPhysValMonitoringTool()
Destructor.
InDetPhysValMonitoringTool::InDetPhysValMonitoringTool
InDetPhysValMonitoringTool()
prevent default construction
TruthVertex.h
InDetPhysValMonitoringTool::m_fillTruthToRecoNtuple
BooleanProperty m_fillTruthToRecoNtuple
Definition: InDetPhysValMonitoringTool.h:180
InDetRttPlotConfig::doDuplicatePlots
bool doDuplicatePlots
Definition: InDetRttPlots.h:71
InDetPhysValMonitoringTool::fillCutFlow
static void fillCutFlow(const asg::AcceptData &accept, std::vector< std::string > &names, std::vector< int > &cutFlow)
Definition: InDetPhysValMonitoringTool.cxx:886
xAOD::TruthVertex_v1
Class describing a truth vertex in the MC record.
Definition: TruthVertex_v1.h:37
InDetRttPlotConfig::doHitsMatchedTracksPlots
bool doHitsMatchedTracksPlots
Definition: InDetRttPlots.h:79
InDetRttPlotConfig::doResolutionPlotPrim
bool doResolutionPlotPrim
Resolution and "matched track" plots - filled if both reco and truth exist.
Definition: InDetRttPlots.h:76
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:228
InDetPhysValMonitoringTool::m_weight_pileup_key
SG::ReadDecorHandleKey< xAOD::EventInfo > m_weight_pileup_key
Definition: InDetPhysValMonitoringTool.h:212
plotBeamSpotVxVal.bin
int bin
Definition: plotBeamSpotVxVal.py:83
InDetRttPlotConfig::doVertexTruthMatchingPlots
bool doVertexTruthMatchingPlots
Vertexing plots - truth requirement.
Definition: InDetRttPlots.h:87
InDetPhysValMonitoringTool::m_dirName
StringProperty m_dirName
Definition: InDetPhysValMonitoringTool.h:190
InDetRttPlotConfig::doMissingTruthFakePlots
bool doMissingTruthFakePlots
Definition: InDetRttPlots.h:64
xAOD::TruthParticle_v1::eta
virtual double eta() const override final
The pseudorapidity ( ) of the particle.
Definition: TruthParticle_v1.cxx:174
InDetRttPlotConfig::doTechEffPlots
bool doTechEffPlots
Definition: InDetRttPlots.h:72
IDPVM::safelyGetEta
float safelyGetEta(const T &pTrk, const float safePtThreshold=0.1)
Safely get eta.
Definition: InDetPhysValMonitoringUtilities.h:56
InDetRttPlotConfig::doVerticesVsMuPlots
bool doVerticesVsMuPlots
Definition: InDetRttPlots.h:83
InDetPhysValMonitoringTool::fillHistogramsTrackingInDenseEnvironment
StatusCode fillHistogramsTrackingInDenseEnvironment(const EventContext &ctx, IDPVM::CachedGetAssocTruth &getAsTruth, const std::vector< const xAOD::TruthParticle * > &truthParticles, const xAOD::TrackParticleContainer &tracks, const xAOD::Vertex *primaryvertex, float beamSpotWeight)
Definition: InDetPhysValMonitoringTool.cxx:926
InDetPhysValMonitoringTool::decorateTruthParticle
void decorateTruthParticle(const xAOD::TruthParticle &truth, const IAthSelectionTool::CutResult &passed) const
Definition: InDetPhysValMonitoringTool.cxx:663
TrackStateValidationContainer.h
xAOD::TruthVertex_v1::x
float x() const
Vertex x displacement.
DataVector::end
const_iterator end() const noexcept
Return a const_iterator pointing past the end of the collection.
InDetPhysValMonitoringTool::m_trackTruthOriginTool
ToolHandle< InDet::IInDetTrackTruthOriginTool > m_trackTruthOriginTool
Definition: InDetPhysValMonitoringTool.h:208
TrackParticle.h
DataVector::stdcont
const PtrVector & stdcont() const
Return the underlying std::vector of the container.
InDetRttPlotConfig::doHitsRecoTracksPlots
bool doHitsRecoTracksPlots
Definition: InDetRttPlots.h:59
xAOD::Jet_v1
Class describing a jet.
Definition: Jet_v1.h:57
ALFA_EventTPCnv_Dict::t2
std::vector< ALFA_RawDataContainer_p1 > t2
Definition: ALFA_EventTPCnvDict.h:44
InDetPhysValMonitoringTool::m_intTrkDecor
std::vector< SG::ReadDecorHandleKey< xAOD::TrackParticleContainer > > m_intTrkDecor
Definition: InDetPhysValMonitoringTool.h:163
InDetPhysValMonitoringTool::m_dec_hasTruthFilled
SG::AuxElement::Decorator< bool > m_dec_hasTruthFilled
Definition: InDetPhysValMonitoringTool.h:106
InDetRttPlotConfig::doEffPlots
bool doEffPlots
Efficiency and duplicate plots - require truth, optionally matching reco
Definition: InDetRttPlots.h:70
y
#define y
xAOD::Vertex_v1
Class describing a Vertex.
Definition: Vertex_v1.h:42
InDetPerfPlot_nTracks::MATCHEDRECO
@ MATCHEDRECO
Definition: InDetPerfPlot_nTracks.h:25
InDetPhysValMonitoringTool::fillTrackCutFlow
void fillTrackCutFlow(const asg::AcceptData &accept)
Definition: InDetPhysValMonitoringTool.cxx:881
InDetRttPlotConfig::doTrkInJetPlots_fake
bool doTrkInJetPlots_fake
Definition: InDetRttPlots.h:95
InDetRttPlotConfig::detailLevel
int detailLevel
detail level (kept for compatibility)
Definition: InDetRttPlots.h:111
ATH_MSG_WARNING
#define ATH_MSG_WARNING(x)
Definition: AthMsgStreamMacros.h:32
InDetPhysValMonitoringTool::m_trkParticleName
SG::ReadHandleKey< xAOD::TrackParticleContainer > m_trkParticleName
TrackParticle container's name.
Definition: InDetPhysValMonitoringTool.h:133
ManagedMonitorToolBase::endOfRunFlag
bool endOfRunFlag() const
Definition: ManagedMonitorToolBase.h:797
InDetPhysValMonitoringTool::m_doHitLevelPlots
BooleanProperty m_doHitLevelPlots
Definition: InDetPhysValMonitoringTool.h:178
InDetRttPlotConfig::doTrackParameters
bool doTrackParameters
Plots for (selected) tracks, not necessarily truth matched.
Definition: InDetRttPlots.h:55
Pythia8_RapidityOrderMPI.val
val
Definition: Pythia8_RapidityOrderMPI.py:14
python.CaloScaleNoiseConfig.type
type
Definition: CaloScaleNoiseConfig.py:78
xAOD::TruthVertex_v1::z
float z() const
Vertex longitudinal distance along the beam line form the origin.
InDetPhysValMonitoringTool::m_vtxValidTool
ToolHandle< IInDetVertexTruthMatchTool > m_vtxValidTool
Definition: InDetPhysValMonitoringTool.h:206
ManagedMonitorToolBase::all
@ all
Definition: ManagedMonitorToolBase.h:115
InDetPhysValMonitoringTool::m_etaBins
DoubleArrayProperty m_etaBins
Definition: InDetPhysValMonitoringTool.h:195
InDetPhysHitDecoratorAlg.h
InDetPhysValMonitoringTool::getTruthVertices
std::pair< const std::vector< const xAOD::TruthVertex * >, const std::vector< const xAOD::TruthVertex * > > getTruthVertices(const EventContext &ctx) const
Definition: InDetPhysValMonitoringTool.cxx:807
InDetPhysValMonitoringTool::m_folder
StringProperty m_folder
Definition: InDetPhysValMonitoringTool.h:191
TauGNNUtils::Variables::absEta
bool absEta(const xAOD::TauJet &tau, double &out)
Definition: TauGNNUtils.cxx:234
InDetPhysValMonitoringTool::m_doBjetPlots
BooleanProperty m_doBjetPlots
Definition: InDetPhysValMonitoringTool.h:179
InDetPhysValMonitoringTool::m_floatTruthDecor
std::vector< SG::ReadDecorHandleKey< xAOD::TruthParticleContainer > > m_floatTruthDecor
Definition: InDetPhysValMonitoringTool.h:164
SG::ConstAccessor::isAvailable
bool isAvailable(const ELT &e) const
Test to see if this variable exists in the store.
InDetPhysValMonitoringTool::m_doTRTExtensionPlots
BooleanProperty m_doTRTExtensionPlots
Definition: InDetPhysValMonitoringTool.h:183
TruthPileupEventAuxContainer.h
defineDB.jets
list jets
Definition: JetTagCalibration/share/defineDB.py:24
dqt_zlumi_alleff_HIST.eff
int eff
Definition: dqt_zlumi_alleff_HIST.py:113
ManagedMonitorToolBase::m_detailLevel
unsigned int m_detailLevel
Definition: ManagedMonitorToolBase.h:836
InDetPhysValMonitoringTool::m_mutex
std::mutex m_mutex
Definition: InDetPhysValMonitoringTool.h:214
xAOD::track
@ track
Definition: TrackingPrimitives.h:512
xAOD::TrackParticle_v1
Class describing a TrackParticle.
Definition: TrackParticle_v1.h:43
InDetPerfPlot_nTracks.h
DataVector::at
const T * at(size_type n) const
Access an element, as an rvalue.
xAOD::TruthParticle_v1::p4
virtual FourMom_t p4() const override final
The full 4-momentum of the particle.
Definition: TruthParticle_v1.cxx:196
ConstAccessor.h
Helper class to provide constant type-safe access to aux data.
InDetPerfPlot_nTracks::SELECTEDRECO
@ SELECTEDRECO
Definition: InDetPerfPlot_nTracks.h:25
TruthParticle.h
ITrackSelectorTool.h
asg::AcceptData
Definition: AcceptData.h:30
InDetPhysValMonitoringTool::hasTruthFilled
bool hasTruthFilled(const xAOD::TruthParticle &truth) const
Definition: InDetPhysValMonitoringTool.cxx:671
InDetPhysValMonitoringTool::m_doIDTIDEPlots
BooleanProperty m_doIDTIDEPlots
Definition: InDetPhysValMonitoringTool.h:185
xAOD::bool
setBGCode setTAP setLVL2ErrorBits bool
Definition: TrigDecision_v1.cxx:60
SG::ReadDecorHandle::isAvailable
bool isAvailable()
Test to see if this variable exists in the store, for the referenced object.
Amg::distance
float distance(const Amg::Vector3D &p1, const Amg::Vector3D &p2)
calculates the distance between two point in 3D space
Definition: GeoPrimitivesHelpers.h:54
InDetPhysValMonitoringTool::m_trackCutflowNames
std::vector< std::string > m_trackCutflowNames
Definition: InDetPhysValMonitoringTool.h:219
InDetRttPlotConfig::doVertexPlots
bool doVertexPlots
Vertexing plots - no truth requirement.
Definition: InDetRttPlots.h:82
DataVector::size
size_type size() const noexcept
Returns the number of elements in the collection.
xAOD::EventInfo_v1::beamSpotWeight
float beamSpotWeight() const
Weight for beam spot size reweighting.
Definition: EventInfo_v1.cxx:970
ManagedMonitorToolBase::regHist
virtual StatusCode regHist(TH1 *h, const std::string &system, Interval_t interval, MgmtAttr_t histo_mgmt=ATTRIB_MANAGED, const std::string &chain="", const std::string &merge="")
Registers a TH1 (including TH2, TH3, and TProfile) to be included in the output stream using logical ...
Definition: ManagedMonitorToolBase.cxx:1346
InDetPerfPlot_nTracks::ALLRECO
@ ALLRECO
Definition: InDetPerfPlot_nTracks.h:25
DataVector::empty
bool empty() const noexcept
Returns true if the collection is empty.
InDetPhysValMonitoringTool::m_doPerAuthorPlots
BooleanProperty m_doPerAuthorPlots
Definition: InDetPhysValMonitoringTool.h:176
TrackParticleContainer.h
InDetRttPlotConfig::doHitsFakeTracksPlots
bool doHitsFakeTracksPlots
Definition: InDetRttPlots.h:65
InDetRttPlotConfig::doTrackParametersPerAuthor
bool doTrackParametersPerAuthor
Definition: InDetRttPlots.h:104
InDetPhysValMonitoringTool::m_doDuplicatePlots
BooleanProperty m_doDuplicatePlots
Definition: InDetPhysValMonitoringTool.h:175
InDetPhysValMonitoringTool::m_acc_hasTruthFilled
SG::AuxElement::Accessor< bool > m_acc_hasTruthFilled
Definition: InDetPhysValMonitoringTool.h:105
TSU::T
unsigned long long T
Definition: L1TopoDataTypes.h:35
InDetPerfPlot_nTracks::ALLTRUTH
@ ALLTRUTH
Definition: InDetPerfPlot_nTracks.h:25
DataVector::begin
const_iterator begin() const noexcept
Return a const_iterator pointing at the beginning of the collection.
InDetPerfPlot_nTracks::SELECTEDTRUTH
@ SELECTEDTRUTH
Definition: InDetPerfPlot_nTracks.h:25
xAOD::EventInfo_v1::eventType
bool eventType(EventType type) const
Check for one particular bitmask value.
xAOD::EventInfo_v1::actualInteractionsPerCrossing
float actualInteractionsPerCrossing() const
Average interactions per crossing for the current BCID - for in-time pile-up.
Definition: EventInfo_v1.cxx:380
InDetPhysValMonitoringTool::m_dec_selectedByPileupSwitch
SG::AuxElement::Decorator< bool > m_dec_selectedByPileupSwitch
Definition: InDetPhysValMonitoringTool.h:110
InDetPhysValMonitoringTool::m_isITk
BooleanProperty m_isITk
Definition: InDetPhysValMonitoringTool.h:203
InDetRttPlotConfig::isITk
bool isITk
Definition: InDetRttPlots.h:52
InDetRttPlotConfig::doTrkInJetPlots_unlinked
bool doTrkInJetPlots_unlinked
Definition: InDetRttPlots.h:97