|
ATLAS Offline Software
|
Go to the documentation of this file.
24 bool isDummyVal(
float x)
26 const float epsilon = 1
e-5;
27 const float dummyVal = -999;
28 return std::abs(
x - dummyVal) < epsilon;
45 m_useTrackMatch(true),
46 m_useClusterMatch(false),
47 m_clusterDeltaEta(3*0.025),
48 m_clusterDeltaPhi(5*0.025)
51 "Match electrons by shared track");
53 "Match electrons by cluster proximity");
55 "Cluster matching delta eta");
57 "Cluster matching delta phi");
72 ATH_MSG_ERROR(
"You must enable at least one: UseTrackMatch or UseClusterMatch");
73 return StatusCode::FAILURE;
76 return StatusCode::SUCCESS;
88 if(&cont1 != &cont2) {
89 ATH_MSG_ERROR(
"This tool expects both electron containers to be the " <<
91 return StatusCode::FAILURE;
97 return StatusCode::FAILURE;
101 return StatusCode::SUCCESS;
119 if(!
m_decHelper->isSurvivingObject(*el1))
continue;
121 if(el1 == el2)
continue;
122 if(!
m_decHelper->isSurvivingObject(*el2))
continue;
130 catch(
const DummyValError&
e) {
131 ATH_MSG_ERROR(
"Cluster 2nd sampling eta/phi values are -999. " <<
132 "It seems you are missing the neccesary variables to "
133 "do the requested electron-electron cluster matching");
134 return StatusCode::FAILURE;
139 return StatusCode::SUCCESS;
159 const unsigned layer = 2;
162 const float phi1 = clus1.phiBE(
layer);
163 const float phi2 = clus2.phiBE(
layer);
166 if(isDummyVal(
eta1) || isDummyVal(
eta2) ||
167 isDummyVal(phi1) || isDummyVal(phi2)) {
168 throw DummyValError();
203 if(el1.
pt() < el2.
pt())
return true;
DataVector adapter that acts like it holds const pointers.
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T > &t)
setSAddress setEtaMS setDirPhiMS setDirZMS setBarrelRadius setEndcapAlpha setEndcapRadius setInterceptInner setEtaMap setEtaBin setIsTgcFailure setDeltaPt deltaPhi
uint16_t author(uint16_t bitmask=EgammaParameters::AuthorALL) const
Get author.
double deltaPhi(double phiA, double phiB)
delta Phi in range [-pi,pi[
setEt setPhi setE277 setWeta2 eta1
const ElementLink< TrackParticleContainer > & trackParticleLink(size_t index=0) const
ElementLink to the xAOD::TrackParticle/s that match the electron candidate.
const uint16_t AuthorAmbiguous
Object Reconstructed by standard cluster-based algorithm.
::StatusCode StatusCode
StatusCode definition for legacy code.
bool dPhi(const xAOD::TauJet &tau, const xAOD::TauTrack &track, double &out)
const xAOD::CaloCluster * caloCluster(size_t index=0) const
Pointer to the xAOD::CaloCluster/s that define the electron candidate.
DataVector adapter that acts like it holds const pointers.
virtual double pt() const override final
The transverse momentum ( ) of the particle.
bool dEta(const xAOD::TauJet &tau, const xAOD::TauTrack &track, double &out)
const uint16_t AuthorElectron
Object Reconstructed by standard cluster-based algorithm.