19#include "GaudiKernel/MsgStream.h"
20#include "GaudiKernel/StatusCode.h"
29#include "GaudiKernel/SystemOfUnits.h"
30using Gaudi::Units::GeV;
77 return StatusCode::SUCCESS;
122 bookTH2F(
m_hEtaPhi, *
m_electronGroup,
"electronTagAndProbeEtaPhi",
"Probe electron #eta,#phi map", 64, -3.2, 3.2,
m_PhiBinning, -3.2, 3.2);
149 std::string hname = std::string(
"LBEvoNZcandidates");
150 std::string hlongname = std::string(
"Number of Z candidates vs LB");
153 return StatusCode::SUCCESS;
158 ATH_MSG_DEBUG(
"ZeeTaPMonTool::fillHistograms(const EventContext& ctx)");
160 if (!
hasGoodTrigger(
"Zee T&P electron"))
return StatusCode::SUCCESS;
165 return StatusCode::RECOVERABLE;
188 ATH_MSG_DEBUG(
"Number of electrons: " << electron_container->size());
196 for (; e_iter!=e_end; ++e_iter) {
198 if(!(*e_iter))
continue;
205 bool passed = (*e_iter)->passSelection(isGood,
"LHLoose");
206 if(
passed || !isGood )
ATH_MSG_DEBUG(
"not a good LHLoose electron candidate found in TDS");
219 float et = (*e_iter)->pt();
225 }
else if(
et>subl_et) {
238 if (ngood_el<2)
return StatusCode::SUCCESS;
245 float mass = (lead_el->
p4()+subl_el->
p4()).M();
247 if(mass<m_MassLowerCut || mass>
m_MassUpperCut)
return StatusCode::SUCCESS;
250 float lead_eta = lead_el->
eta();
251 float lead_phi = lead_el->
phi();
252 float subl_eta = subl_el->
eta();
253 float subl_phi = subl_el->
phi();
254 ATH_MSG_DEBUG(
"Leading electron (eta,phi,et,q): (" << lead_eta <<
", " << lead_phi <<
", " << lead_et <<
", " << lead_el->
charge() <<
")");
255 ATH_MSG_DEBUG(
"Subleading electron (eta,phi,et,q): (" << subl_eta <<
", " << subl_phi <<
", " << subl_et <<
", " << subl_el->
charge() <<
")");
258 if(fabs(lead_eta)>2.47 || fabs(subl_eta)>2.47)
return StatusCode::SUCCESS;
261 if (lead_el->
charge()*subl_el->
charge()>=0)
return StatusCode::SUCCESS;
263 bool lead_isLHTight =
false;
264 if ( !lead_el->
passSelection(lead_isLHTight,
"LHTight") )
return StatusCode::FAILURE;
266 bool subl_isLHTight =
false;
267 if ( !subl_el->
passSelection(subl_isLHTight,
"LHTight") )
return StatusCode::FAILURE;
269 bool EventZcandidateUsed =
false;
274 EventZcandidateUsed =
true;
277 bool subl_isIsolated =
false;
279 if ( topoetcone40 < 4.5*
GeV ) subl_isIsolated =
true;
288 bool lead_isIsolated =
false;
290 if ( topoetcone40 < 4.5*
GeV ) lead_isIsolated =
true;
297 return StatusCode::SUCCESS;
304 float eta = el->eta();
305 float phi = el->phi();
334 if (isTight && isIso) {
348 float deltaEta1 = -999.0;
352 float deltaPhi2 = -999.0;
378 float Re233e237 = 0.0;
380 Re233e237 = e233 / e237;
383 float Re237e277 = 0.0;
385 if(e277!=0) Re237e277 = e237 / e277;
403 unsigned char numberOfInnermostPixelLayerHits=-1;
404 unsigned char numberOfPixelHits=-1;
405 unsigned char numberOfSCTHits=-1;
406 unsigned char numberOfTRTHits=-1;
408 trackp = t->pt()*cosh(t->eta());
419 }
else ATH_MSG_DEBUG(
"Error attempting to retrieve associated track");
425 if(trackp !=0) ep = aCluster->
e()/trackp;
427 double ec = aCluster->
et()*cosh(aCluster->
eta());
429 if(ec!=0) f2 = aCluster->
energyBE(2)/ec;
445 return StatusCode::SUCCESS;
Scalar eta() const
pseudorapidity method
Scalar phi() const
phi method
#define ATH_CHECK
Evaluate an expression and check for errors.
#define ATH_MSG_WARNING(x)
A number of constexpr particle constants to avoid hardcoding them directly in various places.
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T, V, H > &t)
DataModel_detail::const_iterator< DataVector > const_iterator
virtual bool isValid() override final
Can the handle be successfully dereferenced?
virtual double eta() const
The pseudorapidity ( ) of the particle.
virtual double e() const
The total energy of the particle.
float energyBE(const unsigned layer) const
Get the energy in one layer of the EM Calo.
virtual double eta() const override final
The pseudorapidity ( ) of the particle.
bool passSelection(bool &value, const std::string &menu) const
Check if the egamma object pass a selection menu (using the name) If the menu decision is stored in t...
bool isolationValue(float &value, const Iso::IsolationType information) const
old Accessor for Isolation values.
virtual FourMom_t p4() const override final
The full 4-momentum of the particle as a TLoretzVector.
virtual double phi() const override final
The azimuthal angle ( ) of the particle.
float charge() const
Obtain the charge of the object.
int ir
counter of the current depth
constexpr double ZMassInMeV
the mass of the Z0 boson (in MeV)
@ deltaPhi2
difference between the cluster phi (second sampling) and the phi of the track extrapolated to the sec...
@ deltaEta1
difference between the cluster eta (first sampling) and the eta of the track extrapolated to the firs...
const uint16_t AuthorElectron
Object Reconstructed by standard cluster-based algorithm.
const uint16_t AuthorAmbiguous
Object Reconstructed by standard cluster-based algorithm.
@ e277
uncalibrated energy (sum of cells) of the middle sampling in a rectangle of size 7x7
@ e237
uncalibrated energy (sum of cells) of the middle sampling in a rectangle of size 3x7
@ f3
fraction of energy reconstructed in 3rd sampling
@ ecore
core energy in em calo E(core) = E0(3x3) + E1(15x2) + E2(5x5) + E3(3x5)
@ f1
E1/E = fraction of energy reconstructed in the first sampling, where E1 is energy in all strips belon...
@ ehad1
E leakage into 1st sampling of had calo (CaloSampling::HEC0 + CaloSampling::TileBar0 + CaloSampling::...
@ e233
uncalibrated energy (sum of cells) of the middle sampling in a rectangle of size 3x3 (in cell units e...
@ ptcone20
Track isolation.
CaloCluster_v1 CaloCluster
Define the latest version of the calorimeter cluster class.
TrackParticle_v1 TrackParticle
Reference the current persistent version:
@ numberOfTRTHits
number of TRT hits [unit8_t].
@ numberOfSCTHits
number of hits in SCT [unit8_t].
@ numberOfInnermostPixelLayerHits
these are the hits in the 0th pixel barrel layer
@ numberOfPixelHits
these are the pixel hits, including the b-layer [unit8_t].
Electron_v1 Electron
Definition of the current "egamma version".
Extra patterns decribing particle interation process.