ATLAS Offline Software
egamma.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2023 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 // INCLUDE HEADER FILES:
6 
7 #include "egammaEvent/egamma.h"
8 #include "egammaEvent/EMShower.h"
10 #include "egammaEvent/EMConvert.h"
11 #include "CaloEvent/CaloCluster.h"
14 #include "AthenaKernel/BaseInfo.h"
15 
16 #include <iomanip>
17 #include <iostream>
18 
19 // END OF HEADER FILES INCLUDE
20 
21 // ----------------------------
22 // Constructor
23 // ----------------------------
26  INavigable (),
27  I4Momentum (),
29  egammaImpl_t(),
30  m_author (egammaParameters::AuthorUnknown),
31  m_momentumCluster()
32 {
33  m_egPID = new egPID;
34 }
35 
36 // ==========================================================
37 egamma::egamma(unsigned int author) :
39  INavigable (),
40  I4Momentum (),
42  egammaImpl_t(),
43  m_author (author),
44  m_momentumCluster()
45 {
46  m_egPID = new egPID;
47 }
48 
49 // --------------------------
50 // Destructor
51 // --------------------------
53 {
54  if(m_egPID) {
55  delete m_egPID;
56  m_egPID = nullptr;
57  }
58 }
59 
60 // ==========================================================
61 // copy constructor
62 egamma::egamma(const egamma &rhs, bool copyDetails, bool copyMinimal):
63  IAthenaBarCode (rhs),
64  INavigable (rhs),
65  I4Momentum (rhs),
66  INavigable4Momentum (rhs),
67  egammaImpl_t (rhs),
68  m_author (rhs.m_author),
69  m_egPID (new egPID(*(rhs.m_egPID))),
70  m_momentumCluster (rhs.m_momentumCluster)
71 {
72  if (!copyMinimal) {
73  m_cluster = rhs.m_cluster;
76  if (copyDetails) {
78  }
79  }
80 }
81 
82 // ==========================================================
84 {
85  if (this != &rhs) {
86  IAthenaBarCode::operator=(rhs);
87  INavigable::operator=(rhs);
88  I4Momentum::operator=(rhs);
89  INavigable4Momentum::operator=(rhs);
91  m_author = rhs.m_author;
92  m_cluster = rhs.m_cluster;
95  if(m_egPID) delete m_egPID;
96  m_egPID = new egPID(*(rhs.m_egPID));
99  }
100  return *this;
101 }
102 
103 // ----------------------------
104 // print egamma object
105 // ----------------------------
106 void egamma::print() const
107 {
108  // loop over egDetails and print later.
109 }
110 
111 // four momentum methods
112 
114 // Navigation without parameters //
116 
117 void
119 {
120 
121  bool checkFlag = false;
122 
124  // First check on track //
126 
127  const Rec::TrackParticle* aTrack = this->trackParticle();
128  if ( aTrack != nullptr )
129  {
130  // check requested object type with token type
132  dynamic_cast< NavigationToken<Rec::TrackParticle>* >(&theToken);
133  if ( trackToken != nullptr )
134  {
135  // request is honored
136  trackToken->setObject(aTrack);
137  checkFlag = true;
138  }
139 
140  // alternative token type may phrase the same request
141  if ( ! checkFlag )
142  {
145  (&theToken);
146  if ( parTrackToken != nullptr )
147  {
148  parTrackToken->setObject(aTrack);
149  checkFlag = true;
150  }
151  }
152  }
153 
155  // At this point only a request for Rec::TrackParticle could have been
156  // honored. This is indicated by checkFlag = true. If checkFlag = false,
157  // a test on a request for CaloCluster is performed.
159 
160  // bail out if request for Rec::TrackParticle is already honored
161  if ( checkFlag ) return;
162 
164  // Check on cluster //
166 
167  const CaloCluster* aCluster = this->cluster();
168  if ( aCluster != nullptr )
169  {
170  // check on requested type
171  NavigationToken<CaloCluster>* clusToken =
172  dynamic_cast< NavigationToken<CaloCluster>* >(&theToken);
173  if ( clusToken != nullptr )
174  {
175  clusToken->setObject(aCluster);
176  checkFlag = true;
177  }
178  // allow for visitor with relational parameter type
179  if ( ! checkFlag )
180  {
182  dynamic_cast< NavigationToken<CaloCluster,double>* >(&theToken);
183  if ( parClusToken != nullptr )
184  {
185  parClusToken->setObject(aCluster);
186  checkFlag = true;
187  }
188  }
189  }
190 
191  // concrete type request for CaloCluster honored
192  if ( checkFlag ) return;
193 
195  // Pass on the token to composite constituents: ie. CaloCluster! //
197 
198  if ( aCluster!= nullptr ) aCluster->fillToken(theToken);
199 
201  // At this point no request for concrete egamma constituents has been
202  // submitted if checkFlag = false. Now we need to check if a generic
203  // type has been requested (i.e. a base type for tracks and clusters).
205 
206  // try for generic type requests
207  if ( aTrack != nullptr ) theToken.trySetObject(aTrack);
208  if ( aCluster!= nullptr ) theToken.trySetObject(aCluster);
209 }
210 
212 // Navigation with parameters //
214 
216  const std::any& theWeight) const
217 {
218  bool checkFlag = false;
219 
221  // First check on track //
223  const Rec::TrackParticle* aTrack = this->trackParticle();
224  if ( aTrack != nullptr )
225  {
226  // check requested object type with token type
228  dynamic_cast< NavigationToken<Rec::TrackParticle>* >(&theToken);
229  if ( trackToken != nullptr )
230  {
231  // request is honored
232  trackToken->setObject(aTrack);
233  checkFlag = true;
234  }
235 
236  // alternative token type may phrase the same request
237  if ( ! checkFlag )
238  {
241  (&theToken);
242  if ( parTrackToken != nullptr )
243  {
244  // no weight change in propagation
245  parTrackToken->setObject(aTrack,
246  std::any_cast<double>(theWeight));
247  checkFlag = true;
248  }
249  }
250  }
251 
252  // checks on track successful (see above)
253  if ( checkFlag ) return;
254 
256  // Check on cluster //
258 
259  const CaloCluster* aCluster = this->cluster();
260  if ( aCluster != nullptr )
261  {
262  // check on requested type
263  NavigationToken<CaloCluster>* clusToken =
264  dynamic_cast< NavigationToken<CaloCluster>* >(&theToken);
265  if ( clusToken != nullptr )
266  {
267  clusToken->setObject(aCluster);
268  checkFlag = true;
269  }
270  // allow for visitor with relational parameter type
271  if ( ! checkFlag )
272  {
274  dynamic_cast< NavigationToken<CaloCluster,double>* >(&theToken);
275  if ( parClusToken != nullptr )
276  {
277  parClusToken->setObject(aCluster,
278  std::any_cast<double>(theWeight));
279  checkFlag = true;
280  }
281  }
282  }
283 
284  // concrete check for CaloCluster honored
285  if ( checkFlag ) return;
286 
288  // Pass on the token to composite constituents: ie. CaloCluster! //
290 
291  if ( aCluster != nullptr ) aCluster->fillToken(theToken,theWeight);
292 
293 
295  // At this point no request for concrete egamma constituents has been
296  // submitted if checkFlag = false. Now we need to check if a generic
297  // type has been requested (i.e. a base type for tracks and clusters).
299 
300  // try for generic type requests
301  if ( aTrack != nullptr ) theToken.trySetObject(aTrack, theWeight);
302  if ( aCluster != nullptr ) theToken.trySetObject(aCluster,theWeight);
303 }
304 
305 // ==========================================================
306 // Don't use a default for the found parameter because PyROOT has
307 // problems passing bool* arguments.
308 double egamma::egammaID(egammaPIDObs::PID idflag, bool *found) const
309 {
310  //
311  // method to retrieve the PID
312  // set as double to work for IsEM but also for all weights as likelihood
313  //
314 
315  return m_egPID->egammaID(idflag, found);
316 }
317 
318 double egamma::egammaID(egammaPIDObs::PID idflag) const
319 {
320  //
321  // method to retrieve the PID
322  // set as double to work for IsEM but also for all weights as likelihood
323  //
324 
325  return m_egPID->egammaID(idflag, nullptr);
326 }
327 
328 // ==========================================================
330 {
331  //
332  // method to set the PID
333  // set as double to work for IsEM but also for all weights as likelihood
334  //
335 
336  return m_egPID->set_egammaID(idflag,result);
337 }
338 
339 // ==========================================================
341 {
342  //
343  // method to set the PID for ints directly
344  //
345 
346  return m_egPID->set_egammaIDint(idflag,result);
347 }
348 
349 // ==========================================================
350 bool egamma::author(const unsigned int author) const
351 {
352  //
353  // method to check the author
354  //
355 
356  return (m_author & author) != 0;
357 }
358 
359 // ==========================================================
361 {
362  //
363  // method to acces the cluster object
364  //
365 
366  return (m_cluster.isValid()) ? *m_cluster : nullptr;
367 }
368 
369 
370 const CaloRings* egamma::rings() const
371 {
372  //
373  // methods to access RingerRings
374  //
375 
376  return (m_rings.isValid()) ? *m_rings : nullptr;
377 }
378 
380 {
381  //
382  // methods to access RingerRings ElementLink
383  //
384  return m_rings;
385 }
386 
387 
388 // ==========================================================
389 
390 // ==========================================================
391 const Rec::TrackParticle* egamma::trackParticle (unsigned int index) const
392 {
393  //
394  // method to acces the track object
395  //
396 
397  if(index < m_trackParticle.size()){
398  return ((m_trackParticle.at(index)).isValid()) ? *(m_trackParticle.at(index)) : nullptr;
399  }
400  return nullptr;
401 
402 }
403 
404 // ==========================================================
405 unsigned int egamma::nTrackParticles() const
406 {
407  return m_trackParticle.size();
408 }
409 
410 // ==========================================================
411 const Trk::VxCandidate* egamma::conversion (unsigned int index) const
412 {
413  if(index < m_conversion.size()){
414  return ((m_conversion.at(index)).isValid()) ? *(m_conversion.at(index)) : nullptr;
415  }
416  return nullptr;
417 
418 }
419 
420 // ==========================================================
421 unsigned int egamma::nConversions() const
422 {
423  return m_conversion.size();
424 }
425 
426 // ==========================================================
428 {
429  return m_cluster;
430 }
431 
432 // ==========================================================
434 {
435  if(index < m_trackParticle.size()){
436  return m_trackParticle.at(index);
437  }
438  return {};
439 
440 }
441 
442 // ==========================================================
445 {
446  return m_trackParticle;
447 }
448 
449 // ==========================================================
451 {
452  if(index < m_conversion.size()){
453  return m_conversion.at(index);
454  }
455  return {};
456 
457 }
458 
459 // ==========================================================
462 {
463  return m_conversion;
464 }
465 
466 // ==========================================================
468 {
469  m_cluster.toIndexedElement( *pCont, index);
470 }
471 
472 // ==========================================================
473 void egamma::setRings(const CaloRingsContainer *pCont, int index)
474 {
475  m_rings.toIndexedElement( *pCont, index);
476 }
477 
478 // ==========================================================
480 {
481  m_rings.reset();
482 }
483 
484 // ==========================================================
485 void egamma::setRings (const CaloRingsContainer * pCont, const CaloRings* cluster)
486 {
488 }
489 
490 // ==========================================================
491 void
493 {
494  m_rings = link;
495 }
496 
497 
498 // ==========================================================
500 {
501  m_cluster.reset();
502 }
503 
504 // ==========================================================
505 void egamma::setCluster (const CaloClusterContainer * pCont, const CaloCluster* cluster)
506 {
508 }
509 
510 // ==========================================================
511 void
513 {
514  m_cluster = link;
515 }
516 
517 // ==========================================================
519 {
520  if(index < m_trackParticle.size()){
522  }
523 }
524 
525 // ==========================================================
527 {
529  link.toIndexedElement(*pCont, index);
530  m_trackParticle.push_back(link);
531 }
532 
533 // ==========================================================
535 {
537  link.toContainedElement(*pCont, track);
538  m_trackParticle.push_back(link);
539 }
540 
541 // ==========================================================
542 void
544 {
546 }
547 
548 // ==========================================================
549 void
551 {
552  m_trackParticle = v;
553 }
554 
555 // ==========================================================
556 void
558 {
559  m_trackParticle = std::move(v);
560 }
561 
562 // ==========================================================
563 void egamma::resetConversion(unsigned int index)
564 {
565  if(index < m_conversion.size()){
566  (m_conversion.at(index)).reset();
567  }
568 }
569 
570 // ==========================================================
571 void egamma::setConversion (const VxContainer * pCont, int index)
572 {
574  link.toIndexedElement(*pCont, index);
575  m_conversion.push_back(link);
576 }
577 
578 // ==========================================================
580 {
582  link.toContainedElement(*pCont, conv);
583  m_conversion.push_back(link);
584 }
585 
586 // ==========================================================
587 void
589 {
590  m_conversion.push_back(link);
591 }
592 
593 // ==========================================================
594 void
596 {
597  m_conversion = v;
598 }
599 
600 // ==========================================================
601 void
603 {
604  m_conversion = std::move(v);
605 }
606 
607 // ==========================================================
608 // methods to save the pointer to the different data objects in e/g data class
610  const egDetail* ptr)
611 {
613  link.toContainedElement( *cont, ptr);
614  m_egDetails.push_back( link );
615 }
616 
617 // ==========================================================
618 void
620 {
621  m_egDetails.push_back( link );
622 }
623 
624 
625 // ==========================================================
626 void
628 {
629  m_egDetails = v;
630 }
631 
632 
633 // ==========================================================
634 void
636 {
637  m_egDetails = std::move(v);
638 }
639 
640 
641 // ==========================================================
642 const egPID* egamma::pid() const
643 {
644  return m_egPID;
645 }
646 
647 // ==========================================================
649 {
650  if (m_egPID != nullptr) delete m_egPID;
651  m_egPID = ptr;
652 }
653 
654 // ==========================================================
655 bool egamma::isElectron(unsigned int mask,
657  bool *found) const
658 {
659  //
660  // boolean method to define if egamma object is identified
661  // by standard cut-based selection
662  //
663 
664  return (m_egPID->isEM(mask, pid, found)==0);
665 }
666 
667 // ==========================================================
668 bool egamma::isPhoton(unsigned int mask,
670  bool *found) const
671 {
672  //
673  // boolean method to define if egamma object is identified
674  // by standard cut-based selection
675  //
676 
677  return (m_egPID->isEM(mask, pid, found)==0);
678 }
679 
680 // ==========================================================
681 bool egamma::isSofte(unsigned int mask, bool *found) const
682 {
683  //
684  // boolean method to define if egamma object is identified
685  // by cut-based selection optimized for non-isolated objects
686  //
687 
688  return (m_egPID->isEMsofte(mask, found)==0);
689 }
690 
691 // ==========================================================
693 {
694  //
695  // boolean method to define if egamma object is identified
696  // by standard cut-based selection
697  //
698 
699  switch(id) {
706 
713 
720 
727 
734 
741 
750 
755 
757  return true;
758 
759  default:
760  return false;
761  }
762 }
763 
764 
765 // ==========================================================
766 // Note: We have two separate overloads here (and for isemse) rather
767 // than using a default for `found' because PyROOT complains about
768 // passing bool* arguments.
769 unsigned int egamma::isem(unsigned int mask,
770  egammaPIDObs::PID pid) const
771 {
772  //
773  // method which applies a mask to the isEM variable
774  // and returns the corresponding decoded value
775  //
776 
777  return m_egPID->isEM(mask, pid, nullptr);
778 }
779 
780 
781 unsigned int egamma::isem(unsigned int mask,
783  bool *found) const
784 {
785  //
786  // method which applies a mask to the isEM variable
787  // and returns the corresponding decoded value
788  //
789 
790  return m_egPID->isEM(mask, pid, found);
791 }
792 
793 // ==========================================================
794 unsigned int egamma::isemse(unsigned int mask) const
795 {
796  //
797  // method which applies a mask to the isEMsofte variable
798  // and returns the corresponding decoded value
799  //
800 
801  return m_egPID->isEMsofte(mask, nullptr);
802 }
803 
804 
805 unsigned int egamma::isemse(unsigned int mask, bool *found) const
806 {
807  //
808  // method which applies a mask to the isEMsofte variable
809  // and returns the corresponding decoded value
810  //
811 
812  return m_egPID->isEMsofte(mask, found);
813 }
814 
815 
816 // ==========================================================
817 bool egamma::isGoodOQ(unsigned int mask, bool *found) const
818 {
819  return (m_egPID->IsGoodOQ(mask, found) == 0);
820 }
821 
822 // ==========================================================
823 unsigned int egamma::isgoodoq(unsigned int mask, bool *found) const
824 {
825  //
826  // method which applies a mask to theIsGoodOQ variable
827  // and returns the corresponding decoded value
828  //
829 
830  return m_egPID->IsGoodOQ(mask, found);
831 }
832 
833 // ==========================================================
834 const egDetail* egamma::detail (int i) const
835 {
836  if (i < 0 || i >= (int)m_egDetails.size())
837  return nullptr;
838  return *m_egDetails[i];
839 }
840 
841 // ==========================================================
842 const egDetail* egamma::detail (const std::string& className,
843  const std::string& name /*= ""*/,
844  unsigned int index) const
845 {
846  size_t nsize = m_egDetails.size();
847 // const egDetail* ptr = 0;
848  for (size_t i = 0; i < nsize; i++) {
849  if (m_egDetails[i].isValid() &&
850  (*m_egDetails[i])->className() == className)
851  {
852  if (name.empty()) {
853 // if (ptr) //this is potentially highly confusing now with the ElementLinkVectors and the conversion refits, rather return the first match if there are multiple matches
854 // return 0;
855 // else
856  if((*m_egDetails[i])->linkIndex() == (int)index)
857  return *m_egDetails[i];
858 // ptr = *m_egDetails[i];
859  }
860  else if (m_egDetails.elementDataID(i) == name && (*m_egDetails[i])->linkIndex() == (int)index)
861  return *m_egDetails[i];
862  }
863  }
864 // return ptr;
865  return nullptr;
866 }
867 
868 // ==========================================================
870 {
871  if (i < 0 || i >= (int)m_egDetails.size())
872  return {};
873  return m_egDetails[i];
874 }
875 
876 // ==========================================================
878 {
879  return m_egDetails;
880 }
881 
882 // ==========================================================
883 std::string egamma::detailName (int i) const
884 {
885  if (i < 0 || i >= (int)m_egDetails.size())
886  return "";
887  return m_egDetails.elementDataID(i);
888 }
889 
890 // ==========================================================
891 int egamma::nDetails () const
892 {
893  return m_egDetails.size();
894 }
895 
896 
897 // ==========================================================
898 double
900  const std::string& name, unsigned int index) const
901 {
902  size_t nsize = m_egDetails.size();
903 
904  const egDetail* ptr = nullptr;
905  for (size_t i = 0; i < nsize; i++) {
906  if (m_egDetails[i].isValid()) {
907  if (name.empty()) {
908  ptr = *m_egDetails[i];
909  }
910  else if (m_egDetails.elementDataID(i) == name)
911  ptr = *m_egDetails[i];
912  }
913  if ( ptr && ptr->hasParameter(key) && ptr->linkIndex() == (int)index)
914  return ptr->parameter(key);
915  }
916 
918 }
919 
920 // ==========================================================
922 void
924 { m_momentumCluster.setE (ene); }
925 
926 // ==========================================================
928 void
931 
932 // ==========================================================
934 void
937 
938 // ==========================================================
940 void
942 { m_momentumCluster.setM (m); }
943 
944 // ==========================================================
946 void
949 
950 // ==========================================================
952 void
955 
956 // ==========================================================
958 void
959 egamma::setUncombined4Mom (const CLHEP::HepLorentzVector & hlv )
961 
962 
963 // ==========================================================
965 {
966  return momentumBase().errors();
967 }
968 
969 // ==========================================================
971 {
972  const unsigned int Nrows =thematrix.rows();
973  CLHEP::HepSymMatrix thematrixCLHEP(Nrows,0);
974 
975  for (unsigned int i=0; i<Nrows;++i) {
976  for (unsigned int j=0; j<Nrows;++j){
977  thematrixCLHEP[i][j]= thematrix(i,j);
978  }
979  }
980  this->momentumBase().setErrors(thematrixCLHEP);
981 }
982 
983 // ==========================================================
985 {
986  //This should be symmetrix in any case
987  const unsigned int Nrows =thematrix.rows();
988  CLHEP::HepSymMatrix thematrixCLHEP(Nrows,0);
989 
990 for (unsigned int i=0; i<Nrows;++i) {
991  for (unsigned int j=0; j<Nrows;++j){
992  thematrixCLHEP[i][j]= thematrix(i,j);
993  }
994  }
995  m_momentumCluster.setErrors(thematrixCLHEP);
996 }
997 
998 
egamma::trackParticle
const Rec::TrackParticle * trackParticle(unsigned int index=0) const
pointer to TrackParticle
Definition: egamma.cxx:391
egamma::setConversionElementLinkVector
void setConversionElementLinkVector(const ElementLinkVector< VxContainer > &link)
Definition: egamma.cxx:595
egamma::resetCluster
void resetCluster()
Reset Cluster.
Definition: egamma.cxx:499
egammaPIDObs::PhotonLooseAR
const unsigned int PhotonLooseAR
Loose photon selection with Ambiguity resolver.
Definition: egammaPIDdefsObs.h:577
egammaPIDObs::ElectronLoosePP
const unsigned int ElectronLoosePP
Loose++ electron selection.
Definition: egammaPIDdefsObs.h:368
egammaPIDdefsObs.h
egammaPIDObs::IsEM
@ IsEM
cut-based identification for egamma objects (cluster and track-based)
Definition: egammaPIDdefsObs.h:55
egamma::resetConversion
void resetConversion(unsigned int index=0)
Reset Conversion.
Definition: egamma.cxx:563
I4Momentum
Definition: I4Momentum.h:31
egamma::setDetailElementLinkVector
void setDetailElementLinkVector(const ElementLinkVector< egDetailContainer > &v)
Definition: egamma.cxx:627
egamma::setUncombinedE
void setUncombinedE(double theE)
set uncombined energy data member
Definition: egamma.cxx:923
egammaPIDObs::IsEMLoose
@ IsEMLoose
cut-based identification for egamma objects (Loose)
Definition: egammaPIDdefsObs.h:84
Amg::MatrixX
Eigen::Matrix< double, Eigen::Dynamic, Eigen::Dynamic > MatrixX
Dynamic Matrix - dynamic allocation.
Definition: EventPrimitives.h:29
egamma::set_egammaIDint
bool set_egammaIDint(egammaPIDObs::PID id, unsigned int result)
set_egamma ID, for usigned int values
Definition: egamma.cxx:340
egamma::errors
virtual const I4MomentumError * errors() const
override standard errors to allow lazy loading (lazy loading NOW DISABLED)
Definition: egamma.cxx:964
egammaPIDObs::ElectronMediumPP
const unsigned int ElectronMediumPP
Medium++ electron selecton.
Definition: egammaPIDdefsObs.h:378
get_generator_info.result
result
Definition: get_generator_info.py:21
egamma::setUncombinedPhi
void setUncombinedPhi(double thePhi)
set uncombined phi data member
Definition: egamma.cxx:935
python.SystemOfUnits.m
int m
Definition: SystemOfUnits.py:91
egamma::trackParticleElementLink
ElementLink< Rec::TrackParticleContainer > trackParticleElementLink(unsigned int index=0) const
element link to trackParticle
Definition: egamma.cxx:433
egammaPIDObs::ElectronIDLoose
@ ElectronIDLoose
Definition: egammaPIDdefsObs.h:97
phi
Scalar phi() const
phi method
Definition: AmgMatrixBasePlugin.h:64
egamma::setErrorMatrix
void setErrorMatrix(Amg::MatrixX)
Definition: egamma.cxx:970
egammaPIDObs::PhotonIDTightAR
@ PhotonIDTightAR
Definition: egammaPIDdefsObs.h:106
egammaPIDObs::PhotonIDLoose
@ PhotonIDLoose
Definition: egammaPIDdefsObs.h:103
egammaPIDObs::PhotonIDTightIso
@ PhotonIDTightIso
Definition: egammaPIDdefsObs.h:114
egammaPIDObs::ElectronMediumPPIso
const unsigned int ElectronMediumPPIso
Medium++ electron selecton with isolation.
Definition: egammaPIDdefsObs.h:385
egammaPIDObs::PhotonIDTight
@ PhotonIDTight
Definition: egammaPIDdefsObs.h:104
eta
Scalar eta() const
pseudorapidity method
Definition: AmgMatrixBasePlugin.h:79
egammaPIDObs::ElectronIDMedium
@ ElectronIDMedium
Definition: egammaPIDdefsObs.h:99
index
Definition: index.py:1
egammaPIDObs::PhotonLooseARIso
const unsigned int PhotonLooseARIso
Loose photon selection with Ambiguity resolver and Isolation.
Definition: egammaPIDdefsObs.h:580
egammaParameters
Definition: egammaParamDefs.h:36
egammaPIDObs::PhotonLoose
const unsigned int PhotonLoose
Loose photon selection.
Definition: egammaPIDdefsObs.h:591
egamma::detailName
std::string detailName(int i) const
name of detail i
Definition: egamma.cxx:883
CaloClusterContainer
Storable container for CaloCluster.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloClusterContainer.h:37
egamma::egamma
egamma()
Default constructor.
Definition: egamma.cxx:24
egamma::setCluster
void setCluster(const CaloClusterContainer *, int)
Set cluster.
Definition: egamma.cxx:467
egammaPIDObs::PID
PID
Definition: egammaPIDdefsObs.h:53
P4ImplEEtaPhiM::errors
virtual const I4MomentumError * errors() const
Definition: P4ImplEEtaPhiM.h:216
CSV_InDetExporter.new
new
Definition: CSV_InDetExporter.py:145
egamma::setDetailElementLink
void setDetailElementLink(const ElementLink< egDetailContainer > &link)
set detailElementLink
Definition: egamma.cxx:619
egamma::setDetail
void setDetail(const egDetailContainer *, const egDetail *)
set detail
Definition: egamma.cxx:609
egamma::detailElementLink
ElementLink< egDetailContainer > detailElementLink(int i) const
ElementLink for detail i.
Definition: egamma.cxx:869
egammaPIDObs::PhotonIDLooseAR
@ PhotonIDLooseAR
Definition: egammaPIDdefsObs.h:105
P4ImplEEtaPhiM::setM
void setM(const double theM)
set mass data member
Definition: P4ImplEEtaPhiM.h:236
CaloRingsContainer
Definition: Reconstruction/egamma/egammaEvent/egammaEvent/CaloRingsContainer.h:15
egammaParameters::ParamDef
ParamDef
Definition: egammaParamDefs.h:99
egammaPIDObs::PhotonIDMediumAR
@ PhotonIDMediumAR
Definition: egammaPIDdefsObs.h:121
egPID::set_egammaID
bool set_egammaID(egammaPIDObs::PID, double)
set egamma ID, as double to work double values and all possible weights as likelihood
Definition: egPID.cxx:78
egamma.h
egammaPIDObs::PhotonTightIso
const unsigned int PhotonTightIso
Tight photon selection with isolation.
Definition: egammaPIDdefsObs.h:602
egamma::ringsElementLink
const ElementLink< CaloRingsContainer > & ringsElementLink() const
element link to rings
Definition: egamma.cxx:379
CaloRings
Definition: Reconstruction/egamma/egammaEvent/egammaEvent/CaloRings.h:58
egamma::isSofte
bool isSofte(unsigned int mask=egammaPIDObs::ALL, bool *found=nullptr) const
uses special softe cuts
Definition: egamma.cxx:681
isValid
bool isValid(const T &p)
Definition: AtlasPID.h:214
egammaParameters::EgParamUndefined
const double EgParamUndefined
Definition: egammaParamDefs.h:78
egammaPIDObs::frwdElectronIDTight
@ frwdElectronIDTight
Definition: egammaPIDdefsObs.h:118
egammaPIDObs::PhotonLooseIso
const unsigned int PhotonLooseIso
Loose photon selection with Isolation.
Definition: egammaPIDdefsObs.h:594
egamma::m_rings
ElementLink< CaloRingsContainer > m_rings
Definition: egamma.h:303
egamma::detailValue
double detailValue(egammaParameters::ParamDef key, const std::string &name="", unsigned int index=0) const
get the float value of key in the container name
Definition: egamma.cxx:899
egamma::conversionElementLinkVector
const ElementLinkVector< VxContainer > & conversionElementLinkVector() const
Definition: egamma.cxx:461
egPID::set_egammaIDint
bool set_egammaIDint(egammaPIDObs::PID, unsigned int)
set egamma ID, for unsigned int values
Definition: egPID.cxx:114
egamma::fillToken
virtual void fillToken(INavigationToken &thisToken) const
fill token
Definition: egamma.cxx:118
egamma::passID
bool passID(egammaPIDObs::egammaIDQuality id) const
does electron/photon pass the given quality
Definition: egamma.cxx:692
egamma::set_pid
void set_pid(egPID *)
set particle ID
Definition: egamma.cxx:648
egamma::detail
const T * detail(const std::string &name="", unsigned int index=0) const
retrieve eg-detail objects:
Definition: egamma.h:318
egamma::print
void print() const
print method
Definition: egamma.cxx:106
egamma::isem
unsigned int isem(unsigned int mask=egammaPIDObs::ALL, egammaPIDObs::PID pid=egammaPIDObs::IsEM) const
ID flag with cuts, 0:e, >1:jet
Definition: egamma.cxx:769
ParticleImpl< egammaNavigation, P4ImplEEtaPhiM >::operator=
ParticleImpl & operator=(const ParticleImpl &rhs)
Assignment operator.
Definition: ParticleImpl.h:356
ElementLinkVector::push_back
void push_back(const ElemLink &link)
Definition: AthLinks/ElementLinkVector.h:316
P4ImplEEtaPhiM::setEta
void setEta(const double theEta)
set eta data member
Definition: P4ImplEEtaPhiM.h:226
python.utils.AtlRunQueryLookup.mask
string mask
Definition: AtlRunQueryLookup.py:460
egammaPIDObs::ElectronIDLooseIso
@ ElectronIDLooseIso
Definition: egammaPIDdefsObs.h:107
egamma
Definition: egamma.h:58
egammaPIDObs::ElectronTightIso
const unsigned int ElectronTightIso
Tight electron selection with isolation requirement.
Definition: egammaPIDdefsObs.h:479
egammaPIDObs::IsEMTight
@ IsEMTight
cut-based identification for egamma objects (Tight)
Definition: egammaPIDdefsObs.h:88
egamma::m_egDetails
ElementLinkVector< egDetailContainer > m_egDetails
Definition: egamma.h:302
egammaPIDObs::ElectronIDLoosePPIso
@ ElectronIDLoosePPIso
Definition: egammaPIDdefsObs.h:108
egammaPIDObs::ElectronLooseIso
const unsigned int ElectronLooseIso
Loose electron selecton with isolation.
Definition: egammaPIDdefsObs.h:411
P4ImplEEtaPhiM::set4Mom
void set4Mom(const I4Momentum &theI4Mom)
set all 4-mom from another I4Momentum reference
Definition: P4ImplEEtaPhiM.h:241
egammaPIDObs::ElectronLoose
const unsigned int ElectronLoose
Loose electron selection.
Definition: egammaPIDdefsObs.h:407
egammaPIDObs::PhotonIDLooseARIso
@ PhotonIDLooseARIso
Definition: egammaPIDdefsObs.h:115
ParticleImpl< egammaNavigation, P4ImplEEtaPhiM >::m
virtual double m() const
mass
Definition: ParticleImpl.h:464
ParticleImpl< egammaNavigation, P4ImplEEtaPhiM >
JetTagCalibConfig.className
string className
Definition: JetTagCalibConfig.py:31
egamma::m_egPID
egPID * m_egPID
Definition: egamma.h:307
egDetail::parameter
virtual double parameter(egammaParameters::ParamDef) const
Definition: egDetail.cxx:9
egammaPIDObs::ElectronIDMediumPP
@ ElectronIDMediumPP
Definition: egammaPIDdefsObs.h:100
egammaPIDObs::PhotonMedium
const unsigned int PhotonMedium
Medium photon selection.
Definition: egammaPIDdefsObs.h:597
ParticleGun_EoverP_Config.mom
mom
Definition: ParticleGun_EoverP_Config.py:63
egamma::operator=
egamma & operator=(const egamma &rhs)
Definition: egamma.cxx:83
egammaPIDObs::ElectronIDTightIso
@ ElectronIDTightIso
Definition: egammaPIDdefsObs.h:111
egammaPIDObs::NoIDCut
@ NoIDCut
Definition: egammaPIDdefsObs.h:119
egamma::m_cluster
ElementLink< CaloClusterContainer > m_cluster
Definition: egamma.h:299
egamma::nTrackParticles
unsigned int nTrackParticles() const
Definition: egamma.cxx:405
SG_ADD_BASE
SG_ADD_BASE(egamma, SG_VIRTUAL(IAthenaBarCode))
egamma::detailElementLinkVector
const ElementLinkVector< egDetailContainer > & detailElementLinkVector() const
Definition: egamma.cxx:877
egamma::m_trackParticle
ElementLinkVector< Rec::TrackParticleContainer > m_trackParticle
Definition: egamma.h:300
egammaPIDObs::ElectronMediumIso
const unsigned int ElectronMediumIso
MediumIso electron selecton.
Definition: egammaPIDdefsObs.h:432
INavigationToken::trySetObject
virtual bool trySetObject(const INavigable *child)=0
egamma::resetRings
void resetRings()
Reset Cluster.
Definition: egamma.cxx:479
egamma::pid
const egPID * pid() const
Definition: egamma.cxx:642
lumiFormat.i
int i
Definition: lumiFormat.py:92
BaseInfo.h
Provide an interface for finding inheritance information at run time.
I4MomentumError
Definition: I4MomentumError.h:28
egammaPIDObs::frwdElectronIDLoose
@ frwdElectronIDLoose
Definition: egammaPIDdefsObs.h:117
egamma::cluster
const CaloCluster * cluster() const
pointer to CaloCluster
Definition: egamma.cxx:360
egPID::egammaID
double egammaID(egammaPIDObs::PID, bool *found=nullptr) const
retrieve egamma ID, as double to work for IsEM and all possible weights as likelihood; found,...
Definition: egPID.cxx:39
egammaPIDObs::ElectronIDTight
@ ElectronIDTight
Definition: egammaPIDdefsObs.h:101
ParticleGun_EoverP_Config.pid
pid
Definition: ParticleGun_EoverP_Config.py:62
egammaPIDObs::PhotonIDTightARIso
@ PhotonIDTightARIso
Definition: egammaPIDdefsObs.h:116
INavigationToken
Definition: INavigationToken.h:24
ElementLinkVector::elementDataID
ID_type elementDataID(size_type index) const
dataID (long ref) of an element, given its ElementLinkVector index. O(1)
Definition: AthLinks/ElementLinkVector.h:155
egPID::isEM
unsigned int isEM(const unsigned int mask=egammaPIDObs::ALL, egammaPIDObs::PID=egammaPIDObs::IsEM, bool *found=nullptr) const
Metod to define isEM variable.
Definition: egPID.cxx:139
ParticleImpl< egammaNavigation, P4ImplEEtaPhiM >::phi
virtual double phi() const
phi in [-pi,pi[
Definition: ParticleImpl.h:524
CaloCluster
Principal data class for CaloCell clusters.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:79
EMErrorDetail.h
egammaPIDObs::PhotonTightAR
const unsigned int PhotonTightAR
Tight photon selection with Ambiguity resolver.
Definition: egammaPIDdefsObs.h:586
INavigable
Definition: INavigable.h:18
ParticleImpl< egammaNavigation, P4ImplEEtaPhiM >::eta
virtual double eta() const
pseudo rapidity
Definition: ParticleImpl.h:514
egPID::isEMsofte
unsigned int isEMsofte(const unsigned int mask=egammaPIDObs::ALL, bool *found=nullptr) const
Method to define isEMse variable.
Definition: egPID.cxx:151
VxContainer
Definition: VxContainer.h:28
CaloClusterNavigable::fillToken
virtual void fillToken(INavigationToken &iToken) const
fill token for navigation
Definition: CaloClusterNavigable.h:390
egamma::setTrackParticleElementLink
void setTrackParticleElementLink(const ElementLink< Rec::TrackParticleContainer > &link)
Set Track Particle Link.
Definition: egamma.cxx:543
NavigationToken::setObject
void setObject(const_child_ptr data)
Definition: NavigationToken.h:252
egammaPIDObs::PhotonIDLooseIso
@ PhotonIDLooseIso
Definition: egammaPIDdefsObs.h:113
egamma::isGoodOQ
bool isGoodOQ(unsigned int mask=egammaPIDObs::ALLOQ, bool *found=nullptr) const
OQ flag
Definition: egamma.cxx:817
egammaPIDObs::ElectronIDMediumIso
@ ElectronIDMediumIso
Definition: egammaPIDdefsObs.h:109
ParticleImpl< egammaNavigation, P4ImplEEtaPhiM >::momentumBase
const momentum_type & momentumBase() const
access to underlying base type (I4Momentum-like)
Definition: ParticleImpl.h:393
IAthenaBarCode
Definition: AthenaKernel/AthenaKernel/IAthenaBarCode.h:48
ParticleImpl< egammaNavigation, P4ImplEEtaPhiM >::hlv
virtual CLHEP::HepLorentzVector hlv() const
CLHEP HepLorentzVector.
Definition: ParticleImpl.h:635
egammaPIDObs::egammaIDQuality
egammaIDQuality
Definition: egammaPIDdefsObs.h:96
egamma::isemse
unsigned int isemse(unsigned int mask=egammaPIDObs::ALL) const
ID flag with cuts for softe, 0:e, >1:jet.
Definition: egamma.cxx:794
egamma::author
unsigned int author() const
Reconstruction Author
Definition: egamma.h:244
ElementLinkVector< Rec::TrackParticleContainer >
egamma::setRings
void setRings(const CaloRingsContainer *, int)
Set rings object.
Definition: egamma.cxx:473
P4ImplEEtaPhiM::setErrors
void setErrors(const ErrorMatrixEEtaPhiM &err)
set the errors
Definition: P4ImplEEtaPhiM.h:269
egamma::setTrackParticleElementLinkVector
void setTrackParticleElementLinkVector(const ElementLinkVector< Rec::TrackParticleContainer > &v)
Definition: egamma.cxx:550
egamma::isPhoton
bool isPhoton(unsigned int mask=egammaPIDObs::ALL, egammaPIDObs::PID pid=egammaPIDObs::IsEM, bool *found=nullptr) const
Definition: egamma.cxx:668
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:192
egamma::rings
const CaloRings * rings() const
pointer to CaloRings
Definition: egamma.cxx:370
egamma::m_author
unsigned int m_author
Definition: egamma.h:305
Rec::TrackParticleContainer
Definition: Reconstruction/Particle/Particle/TrackParticleContainer.h:33
egamma::conversionElementLink
ElementLink< VxContainer > conversionElementLink(unsigned int index=0) const
element link to conversion
Definition: egamma.cxx:450
NavigationToken
Definition: NavigationToken.h:50
egPID::IsGoodOQ
unsigned int IsGoodOQ(const unsigned int mask=egammaPIDObs::ALLOQ, bool *found=nullptr) const
Method to define Object quality variable.
Definition: egPID.cxx:161
EMShower.h
ElementLinkVector::at
const_reference at(size_type n) const
Definition: AthLinks/ElementLinkVector.h:307
egamma::set_egammaID
bool set_egammaID(egammaPIDObs::PID id, double result)
set_egamma ID, for doubles and all possible weights as likelihood
Definition: egamma.cxx:329
egamma::egammaID
double egammaID(egammaPIDObs::PID, bool *found) const
access to PID information, as double to work for IsEM and all possible weights as likelihood
Definition: egamma.cxx:308
egamma::isElectron
bool isElectron(unsigned int mask=egammaPIDObs::ALL, egammaPIDObs::PID pid=egammaPIDObs::IsEM, bool *found=nullptr) const
ID flag with cuts, true:e/phot, false:bkg
Definition: egamma.cxx:655
Rec::TrackParticle
Definition: Reconstruction/Particle/Particle/TrackParticle.h:47
egamma::setConversion
void setConversion(const VxContainer *, int)
Set Conversion.
Definition: egamma.cxx:571
egamma::setUncombinedEta
void setUncombinedEta(double theEta)
set uncombined eta data member
Definition: egamma.cxx:929
python.PyAthena.v
v
Definition: PyAthena.py:157
P4ImplEEtaPhiM::setE
void setE(const double theE)
set energy data member
Definition: P4ImplEEtaPhiM.h:221
egamma::setClusterElementLink
void setClusterElementLink(const ElementLink< CaloClusterContainer > &link)
Set Cluster Element Link.
Definition: egamma.cxx:512
ElementLinkVector::size
size_type size() const
Definition: AthLinks/ElementLinkVector.h:292
egammaPIDObs::ElectronIDLoosePP
@ ElectronIDLoosePP
Definition: egammaPIDdefsObs.h:98
egamma::setUncombinedErrorMatrix
void setUncombinedErrorMatrix(Amg::MatrixX)
Definition: egamma.cxx:984
egammaPIDObs::ElectronIDTightPP
@ ElectronIDTightPP
Definition: egammaPIDdefsObs.h:102
CondAlgsOpts.found
int found
Definition: CondAlgsOpts.py:101
egamma::conversion
const Trk::VxCandidate * conversion(unsigned int index=0) const
pointer to Conversion
Definition: egamma.cxx:411
egamma::resetTrackParticle
void resetTrackParticle(unsigned int index=0)
Reset Track Particle.
Definition: egamma.cxx:518
egammaPIDObs::ElectronMedium
const unsigned int ElectronMedium
Medium electron selecton.
Definition: egammaPIDdefsObs.h:430
Trk::VxCandidate
Definition: VxCandidate.h:27
INavigable4Momentum
Definition: INavigable4Momentum.h:21
CaloCondBlobAlgs_fillNoiseFromASCII.author
string author
Definition: CaloCondBlobAlgs_fillNoiseFromASCII.py:26
SG_VIRTUAL
#define SG_VIRTUAL(T)
Used to mark virtual derivation.
Definition: Control/AthenaKernel/AthenaKernel/BaseInfo.h:211
CxxUtils::reset
constexpr std::enable_if_t< is_bitmask_v< E >, E & > reset(E &lhs, E rhs)
Convenience function to clear bits in a class enum bitmask.
Definition: bitmask.h:243
egammaPIDObs::ElectronTightPP
const unsigned int ElectronTightPP
Tight++ electron selecton.
Definition: egammaPIDdefsObs.h:390
egammaPIDObs::PhotonIDMedium
@ PhotonIDMedium
Definition: egammaPIDdefsObs.h:120
egamma::setUncombinedM
void setUncombinedM(double theM)
set uncombined mass data member
Definition: egamma.cxx:941
egammaPIDObs::PhotonMediumAR
const unsigned int PhotonMediumAR
Medium photon selection.
Definition: egammaPIDdefsObs.h:583
egammaPIDObs::IsEMMedium
@ IsEMMedium
cut-based identification for egamma objects (Medium)
Definition: egammaPIDdefsObs.h:86
egamma::~egamma
virtual ~egamma()
Destructor.
Definition: egamma.cxx:52
egamma::isgoodoq
unsigned int isgoodoq(unsigned int mask=egammaPIDObs::ALLOQ, bool *found=nullptr) const
Definition: egamma.cxx:823
egammaPIDObs::PhotonTight
const unsigned int PhotonTight
Tight photon selection.
Definition: egammaPIDdefsObs.h:600
egamma::clusterElementLink
const ElementLink< CaloClusterContainer > & clusterElementLink() const
element link to cluster
Definition: egamma.cxx:427
egammaPIDObs::ElectronIDTightPPIso
@ ElectronIDTightPPIso
Definition: egammaPIDdefsObs.h:112
egamma::m_conversion
ElementLinkVector< VxContainer > m_conversion
Definition: egamma.h:301
egammaPIDObs::frwdElectronLoose
const unsigned int frwdElectronLoose
Definition: egammaPIDdefsObs.h:625
egamma::setTrackParticle
void setTrackParticle(const Rec::TrackParticleContainer *, int)
Set Track Particle.
Definition: egamma.cxx:526
egammaParameters::linkIndex
@ linkIndex
link index for multiple track and vertex matches
Definition: egammaParamDefs.h:574
xAOD::track
@ track
Definition: TrackingPrimitives.h:512
egDetail::linkIndex
virtual int linkIndex() const
Definition: egDetail.cxx:46
P4ImplEEtaPhiM::setPhi
void setPhi(const double thePhi)
set phi data member
Definition: P4ImplEEtaPhiM.h:231
egamma::nConversions
unsigned int nConversions() const
Definition: egamma.cxx:421
xAOD::EgammaParameters::AuthorUnknown
const uint16_t AuthorUnknown
for the Authors of the egamma objects
Definition: EgammaDefs.h:22
egamma::nDetails
int nDetails() const
number of details in egamma object
Definition: egamma.cxx:891
egamma::m_momentumCluster
momentum_type m_momentumCluster
Definition: egamma.h:313
egDetail::hasParameter
virtual bool hasParameter(egammaParameters::ParamDef) const
Definition: egDetail.cxx:24
egammaPIDObs::PhotonTightARIso
const unsigned int PhotonTightARIso
Tight photon selection with isolation and Ambiguity resolver.
Definition: egammaPIDdefsObs.h:588
egDetail
Definition: egDetail.h:29
EMTrackMatch.h
egPID
Definition: egPID.h:32
egDetailContainer
Definition: egDetailContainer.h:18
EMConvert.h
egammaPIDObs::frwdElectronTight
const unsigned int frwdElectronTight
forward electron flavours
Definition: egammaPIDdefsObs.h:624
egammaPIDObs::ElectronTight
const unsigned int ElectronTight
Tight electron selection.
Definition: egammaPIDdefsObs.h:475
egamma::setConversionElementLink
void setConversionElementLink(const ElementLink< VxContainer > &link)
Set Conversion.
Definition: egamma.cxx:588
egamma::trackParticleElementLinkVector
const ElementLinkVector< Rec::TrackParticleContainer > & trackParticleElementLinkVector() const
Definition: egamma.cxx:444
egamma::setRingsElementLink
void setRingsElementLink(const ElementLink< CaloRingsContainer > &link)
Set Rings Element Link.
Definition: egamma.cxx:492
pdg_comparison.conv
conv
Definition: pdg_comparison.py:321
mapkey::key
key
Definition: TElectronEfficiencyCorrectionTool.cxx:37
egamma::setUncombined4Mom
void setUncombined4Mom(const I4Momentum &theI4Mom)
set uncombined all 4-mom from another I4Momentum reference
Definition: egamma.cxx:947
egammaPIDObs::ElectronTightPPIso
const unsigned int ElectronTightPPIso
Tight++ electron selecton with isolation.
Definition: egammaPIDdefsObs.h:398
egammaPIDObs::ElectronIDMediumPPIso
@ ElectronIDMediumPPIso
Definition: egammaPIDdefsObs.h:110