ATLAS Offline Software
Electrons.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 // This source file implements all of the functions related to Electrons
6 // in the SUSYObjDef_xAOD class
7 
8 // Local include(s):
10 
14 
25 
28 //disable #include "IsolationSelection/IIsolationLowPtPLVTool.h"
29 
31 
32 //disable #include "PATCore/TResult.h"
33 
34 // For getting the beam spot information
36 
37 #ifndef XAOD_STANDALONE // For now metadata is Athena-only
39 #endif
40 
41 namespace ST {
42 
43  const static SG::AuxElement::Decorator<char> dec_passSignalID("passSignalID");
44  const static SG::AuxElement::ConstAccessor<char> acc_passSignalID("passSignalID");
45 
46  const static SG::AuxElement::Decorator<char> dec_passChID("passChID");
47  const static SG::AuxElement::ConstAccessor<char> acc_passChID("passChID");
48  const static SG::AuxElement::Decorator<double> dec_ecisBDT("ecisBDT");
49 
50  const static SG::AuxElement::Decorator<float> dec_sfChIDEff("chargeIDEffiSF"); //tools' default
51  const static SG::AuxElement::ConstAccessor<float> acc_sfChIDEff("chargeIDEffiSF"); //tools' default
52 
53  const static SG::AuxElement::Decorator<float> dec_z0sinTheta("z0sinTheta");
54  const static SG::AuxElement::ConstAccessor<float> acc_z0sinTheta("z0sinTheta");
55  const static SG::AuxElement::Decorator<float> dec_d0sig("d0sig");
56  const static SG::AuxElement::ConstAccessor<float> acc_d0sig("d0sig");
57  const static SG::AuxElement::Decorator<char> dec_isLRT("isLRT");
58 
59  const static SG::AuxElement::ConstAccessor<float> acc_topoetcone20("topoetcone20");
60  const static SG::AuxElement::ConstAccessor<char> acc_passECIDS("DFCommonElectronsECIDS"); // Loose 97% WP
61 
62 
63 StatusCode SUSYObjDef_xAOD::MergeElectrons(const xAOD::ElectronContainer & electrons, xAOD::ElectronContainer* outputCol, const std::set<const xAOD::Electron *> &ElectronsToRemove) const{
64 
65  if (electrons.empty()) return StatusCode::SUCCESS;
66  for (const xAOD::Electron* electron: electrons) {
67  if (ElectronsToRemove.find(electron) != ElectronsToRemove.end()){
68  ATH_MSG_DEBUG( "Removing electron from output collection (isLRT?) : ("<< static_cast<int>(electron->auxdecor<char>("isLRT")) << ")" );
69  ATH_MSG_DEBUG( "ELECTRON cl eta: " << electron->caloCluster()->eta());
70  ATH_MSG_DEBUG( "ELECTRON cl phi: " << electron->caloCluster()->phi());
71  continue;
72  // add electron into output
73  } else {
74  ATH_MSG_DEBUG( "Adding electron to output collection (isLRT?) : (" << static_cast<int>(electron->auxdecor<char>("isLRT")) << ")" );
75  ATH_MSG_DEBUG( "ELECTRON cl eta: " << electron->caloCluster()->eta());
76  ATH_MSG_DEBUG( "ELECTRON cl phi: " << electron->caloCluster()->phi());
77  auto newElectron = new xAOD::Electron(*electron);
78 
79  if ( getOriginalObject(*electron) != nullptr ) {
81  } else {
82  setOriginalObjectLink(*electron, *newElectron);
83  }
84 
85  outputCol->push_back(newElectron);
86  }
87  }
88  return StatusCode::SUCCESS;
89 }
90 
91 
93  for (const xAOD::Electron *electron: *inElectrons){
94  const xAOD::TrackParticle* idtrack = electron->trackParticle();
95 
96  // Save electron if the id track passes the LRT filter
97  if ( idtrack->isAvailable<char>("passLRTFilter") )
98  {
99  if ( static_cast<int>(acc_lrtFilter(*idtrack) ) ){
100  std::unique_ptr<xAOD::Electron> copyElectron = std::make_unique<xAOD::Electron>(*electron);
101 
102  // transfer original electron link
103 
104  setOriginalObjectLink(*electron, *copyElectron);
105  copy->push_back( std::move(copyElectron) );
106  }
107  }
108  else // Keep electron if flag is not available
109  {
110  std::unique_ptr<xAOD::Electron> copyElectron = std::make_unique<xAOD::Electron>(*electron);
111 
112  setOriginalObjectLink(*electron, *copyElectron);
113  copy->push_back( std::move(copyElectron) );
114  }
115  }
116  return StatusCode::SUCCESS;
117 }
118 
119 
120 StatusCode SUSYObjDef_xAOD::GetElectrons(xAOD::ElectronContainer*& copy, xAOD::ShallowAuxContainer*& copyaux, bool recordSG, const std::string& elekey, const std::string& lrtelekey, const xAOD::ElectronContainer* containerToBeCopied)
121 {
122  if (!m_tool_init) {
123  ATH_MSG_ERROR("SUSYTools was not initialized!!");
124  return StatusCode::FAILURE;
125  }
126 
127  // Initializing prompt/LRT OR procedure
128  auto outputCol = std::make_unique<xAOD::ElectronContainer>();
129  std::unique_ptr<xAOD::ElectronAuxContainer> outputAuxCol;
130  outputAuxCol = std::make_unique<xAOD::ElectronAuxContainer>();
131  outputCol->setStore(outputAuxCol.get());
133 
134  if (bool(m_eleLRT) && !lrtelekey.empty() && evtStore()->contains<xAOD::ElectronContainer>(lrtelekey)){
135  ATH_MSG_DEBUG("Applying prompt/LRT electron OR procedure");
136 
137  // First identify if merged container has already been made (for instances where GetElectrons() is called more than once)
138  if (evtStore()->contains<xAOD::ElectronContainer>("StdWithLRTElectrons")) {
139  ATH_MSG_DEBUG("Merged prompt/LRT container already created in TStore");
140  } else {
141  ATH_MSG_DEBUG("Creating merged prompt/LRT container in TStore");
142 
143  // Retrieve prompt and LRT electrons from TStore
145  ATH_CHECK( evtStore()->retrieve(lrt_electrons, lrtelekey) );
146 
147  // Remove LRT electrons as flagged by filter for uncertainty
148  auto filtered_electrons = std::make_unique<xAOD::ElectronContainer>();
149  std::unique_ptr<xAOD::ElectronAuxContainer> filtered_electrons_aux = std::make_unique<xAOD::ElectronAuxContainer>();
150  filtered_electrons->setStore(filtered_electrons_aux.get());
151  ATH_CHECK(prepareLRTElectrons(lrt_electrons, filtered_electrons.get()));
152 
153  // Check overlap between prompt and LRT collections
154  std::set<const xAOD::Electron *> ElectronsToRemove;
155  m_elecLRTORTool->checkOverlap(*prompt_electrons, *filtered_electrons, ElectronsToRemove);
156 
157  // Decorate electrons with prompt/LRT
158  for (const xAOD::Electron* el : *prompt_electrons) dec_isLRT(*el) = 0;
159  for (const xAOD::Electron* el : *filtered_electrons) dec_isLRT(*el) = 1;
160 
161  // Create merged StdWithLRTElectrons container
162  outputCol->reserve(prompt_electrons->size() + filtered_electrons->size());
163  ATH_CHECK(MergeElectrons(*prompt_electrons, outputCol.get(), ElectronsToRemove ));
164  ATH_CHECK(MergeElectrons(*filtered_electrons, outputCol.get(), ElectronsToRemove ));
165 
166  // Save merged StdWithLRTElectrons container to TStore
167  ATH_CHECK(evtStore()->record(std::move(outputCol), m_outElectronLocation.key()));
168  ATH_CHECK(evtStore()->record(std::move(outputAuxCol), m_outElectronLocation.key() + "Aux.") );
169  }
170  } else if (!lrtelekey.empty()) {
171  if(evtStore()->contains<xAOD::ElectronContainer>(lrtelekey) == false && bool(m_eleLRT) == true) ATH_MSG_WARNING("prompt/LRT OR procedure attempted but " << lrtelekey << " not in ROOT file, check config!");
172  ATH_MSG_DEBUG("Not applying prompt/LRT electron OR procedure");
173  }
174 
175  if (m_isPHYSLITE && elekey.find("AnalysisElectrons")==std::string::npos){
176  ATH_MSG_ERROR("You are running on PHYSLITE derivation. Please change the Electrons container to 'AnalysisElectrons'");
177  return StatusCode::FAILURE;
178  }
179 
180  const xAOD::ElectronContainer* electrons = nullptr;
181  if (bool(m_eleLRT) && evtStore()->contains<xAOD::ElectronContainer>(lrtelekey)){
182  ATH_MSG_DEBUG("Using container: " << m_outElectronLocation.key());
184  }
185  else {
186  if (copy==nullptr) { // empty container provided
187  ATH_MSG_DEBUG("Empty container provided");
188  if (containerToBeCopied != nullptr) {
189  ATH_MSG_DEBUG("Containter to be copied not nullptr");
190  electrons = containerToBeCopied;
191  }
192  else {
193  ATH_MSG_DEBUG("Getting Electrons collection");
194  ATH_CHECK( evtStore()->retrieve(electrons, elekey) );
195  }
196  }
197  }
198 
199  std::pair<xAOD::ElectronContainer*, xAOD::ShallowAuxContainer*> shallowcopy = xAOD::shallowCopyContainer(*electrons);
200  copy = shallowcopy.first;
201  copyaux = shallowcopy.second;
202  bool setLinks = xAOD::setOriginalObjectLink(*electrons, *copy);
203  if (!setLinks) {
204  ATH_MSG_WARNING("Failed to set original object links on " << elekey);
205  } else { // use the user-supplied collection instead
206  ATH_MSG_DEBUG("Not retrieving electron collection, using existing one provided by user");
207  electrons=copy;
208  }
209 
210  for (const auto& electron : *copy) {
213  }
214 
215  if (recordSG) {
216  ATH_CHECK( evtStore()->record(copy, "STCalib" + elekey + m_currentSyst.name()) );
217  ATH_CHECK( evtStore()->record(copyaux, "STCalib" + elekey + m_currentSyst.name() + "Aux.") );
218  }
219  return StatusCode::SUCCESS;
220 }
221 
222 
224 
225  ATH_MSG_VERBOSE( "Starting FillElectron on el with pre-calibration pt=" << input.pt() );
226 
227  // According to https://twiki.cern.ch/twiki/bin/view/AtlasProtected/EGammaIdentificationRun2#Electron_identification:
228  // "Please apply the identification to uncalibrated electron object. ID scale factors are to be applied to calibrated objects."
229  dec_baseline(input) = false;
230  dec_selected(input) = 0;
231  dec_signal(input) = false;
232  dec_isol(input) = false;
233  dec_isolHighPt(input) = false;
234  dec_passSignalID(input) = false;
235  dec_passChID(input) = false;
236  dec_ecisBDT(input) = -999.;
237 
238  const xAOD::EventInfo* evtInfo = nullptr;
239  ATH_CHECK( evtStore()->retrieve( evtInfo, "EventInfo" ) );
240  const xAOD::Vertex* pv = this->GetPrimVtx();
241  const xAOD::TrackParticle* track = input.trackParticle();
242  if (!track) {
243  ATH_MSG_DEBUG("No primary track particle for this electron. Skipping.");
244  return StatusCode::SUCCESS;
245  }
246  double primvertex_z = pv ? pv->z() : 0;
247  double el_z0 = track->z0() + track->vz() - primvertex_z;
248  dec_z0sinTheta(input) = el_z0 * TMath::Sin(input.p4().Theta());
249  //protect against exception thrown for null or negative d0sig
250  try{
251  dec_d0sig(input) = xAOD::TrackingHelpers::d0significance( track , evtInfo->beamPosSigmaX(), evtInfo->beamPosSigmaY(), evtInfo->beamPosSigmaXY() );
252  }
253  catch(...){
254  float d0sigError = -99.;
255  ATH_MSG_WARNING("FillElectron : Exception catched from d0significance() calculation. Setting dummy decoration d0sig=" << d0sigError );
256  dec_d0sig(input) = d0sigError;
257  }
258 
259  // don't bother calibrating or computing WP
260  if ( input.pt() < 4e3 ) return StatusCode::SUCCESS;
261  if ( !input.caloCluster() ) { ATH_MSG_WARNING( "FillElectron: no caloCluster found: " << input.caloCluster() ); return StatusCode::SUCCESS; }
262 
263  //Check DeadHVCellRemoval
264  bool pass_deadHVTool = m_deadHVTool->accept(&input);
265 
266  if (m_debug) {
267  unsigned char el_nPixHits(0), el_nSCTHits(0);
268  input.trackParticle()->summaryValue(el_nPixHits, xAOD::numberOfPixelHits);
269  input.trackParticle()->summaryValue(el_nSCTHits, xAOD::numberOfSCTHits);
270 
271  ATH_MSG_INFO( "ELECTRON eta: " << input.eta());
272  ATH_MSG_INFO( "ELECTRON phi: " << input.phi());
273  ATH_MSG_INFO( "ELECTRON cl eta: " << input.caloCluster()->eta());
274  ATH_MSG_INFO( "ELECTRON cl phi: " << input.caloCluster()->phi());
275  ATH_MSG_INFO( "ELECTRON cl e: " << input.caloCluster()->e());
276  ATH_MSG_INFO( "ELECTRON trk eta: " << input.trackParticle()->eta());
277  ATH_MSG_INFO( "ELECTRON trk phi: " << input.trackParticle()->phi());
278  ATH_MSG_INFO( "ELECTRON author: " << input.author());
279  ATH_MSG_INFO( "ELECTRON OQ: " << acc_OQ(input));
280  ATH_MSG_INFO( "ELECTRON nPixHits: " << static_cast<int>(el_nPixHits));
281  ATH_MSG_INFO( "ELECTRON nSCTHits: " << static_cast<int>(el_nSCTHits));
282  ATH_MSG_INFO( "ELECTRON deadHVTools: " << static_cast<bool>(pass_deadHVTool));
283  }
284 
285  if (!pass_deadHVTool) return StatusCode::SUCCESS;
286  if (!input.isGoodOQ(xAOD::EgammaParameters::BADCLUSELECTRON)) return StatusCode::SUCCESS;
287 
289  ATH_MSG_ERROR("No baseline electron selector defined!");
290  return StatusCode::FAILURE;
291  }
292 
293  bool passBaseID = false;
294  if (m_eleIdExpert) {
295  passBaseID = bool(m_elecSelLikelihoodBaseline->accept(&input));
296  } else {
297  if (m_acc_eleIdBaseline.isAvailable(input)) {
298  passBaseID = m_acc_eleIdBaseline(input);
299  } else {
300  ATH_MSG_VERBOSE ("DFCommonElectronsLHxxx variables are not found. Calculating the ID from LH tool..");
301  passBaseID = bool(m_elecSelLikelihoodBaseline->accept(&input));
302  }
303  }
304 
305  if ( !passBaseID && !m_force_noElId ) return StatusCode::SUCCESS;
306 
307  //baseline ID decoration for TauEl OR
308  //dec_passBaseID(input) = true;
309 
310  // calibrate the electron 4-vector here only if within eta window
311  if (std::abs(input.caloCluster()->etaBE(2)) >= etacut) return StatusCode::SUCCESS;
312 
314  if ( std::abs( input.caloCluster()->etaBE(2) ) >1.37 && std::abs( input.caloCluster()->etaBE(2) ) <1.52) {
315  return StatusCode::SUCCESS;
316  }
317  }
318 
319  // corrections for R21 are back - https://twiki.cern.ch/twiki/bin/view/AtlasProtected/ElectronPhotonFourMomentumCorrection#Pre_recommendations_for_release
321  ATH_MSG_ERROR( "FillElectron: EgammaCalibTool applyCorrection failed ");
322 
324  ATH_MSG_ERROR("FillElectron: IsolationCorrectionTool applyCorrection failed");
325 
326  ATH_MSG_VERBOSE( "FillElectron: post-calibration pt=" << input.pt() );
327 
328  if (input.pt() < etcut) return StatusCode::SUCCESS;
329 
330  if (m_elebaselinez0>0. && std::abs(acc_z0sinTheta(input))>m_elebaselinez0) return StatusCode::SUCCESS;
331  if (m_elebaselined0sig>0. && std::abs(acc_d0sig(input))>m_elebaselined0sig) return StatusCode::SUCCESS;
332 
333  //--- Do baseline isolation check
334  if ( !( m_eleBaselineIso_WP.empty() ) && !( m_isoBaselineTool->accept(input) ) ) return StatusCode::SUCCESS;
335 
336  dec_baseline(input) = true;
337  dec_selected(input) = 2;
338  //disable if (!m_eleIso_WP.empty() && m_eleIso_WP.find("PLV")!=std::string::npos) ATH_CHECK( ->augmentPLV(input) );
339  if (!m_eleIso_WP.empty()) dec_isol(input) = bool(m_isoTool->accept(input));
340  if (!m_eleIsoHighPt_WP.empty()) dec_isolHighPt(input) = bool(m_isoHighPtTool->accept(input));
341 
342  //ChargeIDSelector
343  if( m_runECIS ){
344  if (acc_passECIDS.isAvailable(input)) {
345  dec_passChID(input) = acc_passECIDS(input); // Loose 97% WP!
346  } else {
347  dec_passChID(input) = bool(m_elecChargeIDSelectorTool->accept(&input));
348  //disable double bdt = m_elecChargeIDSelectorTool->calculate(&input).getResult("bdt");
349  //disable dec_ecisBDT(input) = bdt;
350  }
351  }
352  else{
353  dec_passChID(input) = true;
354  }
355 
356  ATH_MSG_VERBOSE( "FillElectron: passed baseline selection" );
357 
358  return StatusCode::SUCCESS;
359 }
360 
361 
362 bool SUSYObjDef_xAOD::IsSignalElectron(const xAOD::Electron & input, float etcut, float d0sigcut, float z0cut, float etacut) const
363 {
364  if (!acc_baseline(input)) return false;
365 
366  dec_passSignalID(input) = false;
367 
368  if (m_eleIdExpert) {
369  if ( !m_elecSelLikelihood.empty() && m_elecSelLikelihood->accept(&input) ) dec_passSignalID(input) = true;
370  }
371  else {
372  if (m_acc_eleId.isAvailable(input)) {
373  dec_passSignalID(input) = m_acc_eleId(input);
374  } else {
375  ATH_MSG_VERBOSE ("DFCommonElectronsLHxxx variables are not found. Calculating the ID from LH tool..");
376  if ( !m_elecSelLikelihood.empty() && m_elecSelLikelihood->accept(&input) ) dec_passSignalID(input) = true;
377  }
378  }
379 
380  //overwrite ID selection if forced by user
381  if(m_force_noElId) dec_passSignalID(input) = true;
382 
383  if (!acc_passSignalID(input)) return false;
384 
385  if (input.p4().Perp2() <= etcut * etcut || input.p4().Perp2() == 0) return false; // eT cut (might be necessary for leading electron to pass trigger)
386  if ( etacut==DUMMYDEF ){
387  if(std::abs(input.caloCluster()->etaBE(2)) > m_eleEta ) return false;
388  }
389  else if ( std::abs(input.caloCluster()->etaBE(2)) > etacut ) return false;
390 
391  if (m_eleCrackVeto){
392  if ( std::abs( input.caloCluster()->etaBE(2) ) >1.37 && std::abs( input.caloCluster()->etaBE(2) ) <1.52) {
393  return false;
394  }
395  }
396 
397  if (acc_d0sig(input) != 0) {
398  if (d0sigcut > 0.0 && std::abs(acc_d0sig(input)) > d0sigcut) return false; // transverse IP cut
399  }
400 
401  if (z0cut > 0.0 && std::abs(acc_z0sinTheta(input)) > z0cut) return false; // longitudinal IP cut
402 
403 
404  ATH_MSG_VERBOSE( "IsSignalElectron: " << m_eleId << " " << acc_passSignalID(input) << " d0sig " << acc_d0sig(input) << " z0 sin(theta) " << acc_z0sinTheta(input) );
405 
406  if (m_doElIsoSignal) {
407  if ( !( (acc_isol(input) && input.pt()<m_eleIsoHighPtThresh) || (acc_isolHighPt(input) && input.pt()>m_eleIsoHighPtThresh)) ) return false;
408  ATH_MSG_VERBOSE( "IsSignalElectron: passed isolation" );
409  }
410 
411  if(m_eleChID_signal && !acc_passChID(input)) return false; //add charge flip check to signal definition
412 
413  dec_signal(input) = true;
414 
415  ATH_MSG_VERBOSE( "IsSignalElectron: passed selection" );
416  return true;
417 }
418 
419 
421  const bool recoSF,
422  const bool idSF,
423  const bool triggerSF,
424  const bool isoSF,
425  const std::string& trigExpr,
426  const bool ecidsSF,
427  const bool cidSF ) {
428 
429  if ((m_eleId == "VeryLooseLLH" || m_eleId == "LooseLLH" || m_eleId == "Loose" || m_eleId == "Medium" || m_eleId == "Tight") && (idSF || triggerSF || isoSF)) {
430  ATH_MSG_ERROR("No signal electron ID or trigger scale factors provided for the selected working point!");
431  ATH_MSG_ERROR("I will now die messily.");
432  }
433 
434  //shortcut keys for trigger SF config
435  std::string singleLepStr = "singleLepton";
436  std::string diLepStr = "diLepton";
437  std::string multiLepStr = "multiLepton";
438 
439  float sf(1.);
440 
441  if (recoSF) {
442  double reco_sf(1.);
443 
445  switch (result) {
447  sf *= reco_sf;
448  break;
450  ATH_MSG_ERROR( "Failed to retrieve signal electron reco SF");
451  break;
453  ATH_MSG_VERBOSE( "OutOfValidityRange found for signal electron reco SF");
454  break;
455  default:
456  ATH_MSG_WARNING( "Don't know what to do for signal electron reco SF");
457  }
458  }
459 
460  if (idSF) {
461  double id_sf(1.);
462 
464  switch (result) {
466  sf *= id_sf;
467  break;
469  ATH_MSG_ERROR( "Failed to retrieve signal electron id SF");
470  break;
472  ATH_MSG_VERBOSE( "OutOfValidityRange found for signal electron id SF");
473  break;
474  default:
475  ATH_MSG_WARNING( "Don't know what to do for signal electron id SF");
476  }
477  }
478 
479  if (triggerSF) {
480 
481  std::vector<std::string> trigMChains={};
482  std::string theExpr ("");
483  if(trigExpr==singleLepStr) {
484  if (this->treatAsYear()==2015) trigMChains = m_v_trigs15_cache_singleEle;
485  else if (this->treatAsYear()==2016) trigMChains = m_v_trigs16_cache_singleEle;
486  else if (this->treatAsYear()==2017) trigMChains = m_v_trigs17_cache_singleEle;
487  else if (this->treatAsYear()==2018) trigMChains = m_v_trigs18_cache_singleEle;
488  else trigMChains = m_v_trigs22_cache_singleEle;
490  }
491  else{
492  ATH_MSG_WARNING( "Only single lepton trigger SFs are supported in GetSignalElecSF(). Use GetTriggerGlobalEfficiencySF() for dilepton or multilepton triggers!");
493  }
494 
495  //check matching
496  this->TrigMatch({&el}, trigMChains);
497 
498  if(!el.isAvailable<char>("trigmatched") or !acc_trigmatched(el)){
499  ATH_MSG_DEBUG( "Electron was not matched to trigger " << theExpr << " - scale factor does not apply (year " << this->treatAsYear() << ") Returning 1." );
500  }
501  else{ //is trig-matched electron, go for it!
502  if (trigExpr==multiLepStr || trigExpr==diLepStr) {
503  ATH_MSG_WARNING( "The dilepton or multilepton trigger SFs are not supported in GetSignalElecSF(). Use GetTriggerGlobalEfficiencySF()!");
504  }
505  else {
506  double trig_sf = GetEleTriggerEfficiencySF( el , theExpr );
507  sf *= trig_sf;
508  }
509  }
510  }
511 
512  if (isoSF) {
513  double iso_sf(1.);
515  if (acc_isolHighPt(el) && el.pt()>m_eleIsoHighPtThresh)
517  else
519 
520  switch (result) {
522  sf *= iso_sf;
523  break;
525  ATH_MSG_ERROR( "Failed to retrieve signal electron iso SF");
526  break;
528  ATH_MSG_VERBOSE( "OutOfValidityRange found for signal electron iso SF");
529  break;
530  default:
531  ATH_MSG_WARNING( "Don't know what to do for signal electron iso SF");
532  }
533  }
534 
535  // Charge flip SF: combined ECIDs & charge ID
536  if ( ecidsSF || cidSF ) {
537  double chf_sf(1.);
538  // 1. ECIDs SF
539  if ( ecidsSF ) {
540  sf *= chf_sf;
541  ATH_MSG_WARNING( "ECID SF ARE NOT YET SUPPORTED IN R22" );
542  }
543  // 2. CID SF
544  if ( cidSF ) {
545  sf *= chf_sf;
546  dec_sfChIDEff(el) = chf_sf;
547  ATH_MSG_WARNING( "CID SF ARE NOT YET SUPPORTED IN R22" );
548  }
549  }
550 
551  dec_effscalefact(el) = sf;
552  return sf;
553 }
554 
555 
556 double SUSYObjDef_xAOD::GetEleTriggerEfficiencySF(const xAOD::Electron& el, const std::string& trigExpr) const {
557 
558  double trig_sf(1.);
559 
560  std::string single_str = "SINGLE_E";
561  std::string single_str_2022 = "2022_";
562  std::string dilep_str = "DI_E";
563  std::string multi_str = "MULTI_L";
564 
566  if ( trigExpr.find(single_str) != std::string::npos || trigExpr.find(single_str_2022) != std::string::npos)
568  else if ( trigExpr.find(dilep_str) != std::string::npos )
569  ATH_MSG_ERROR( "Use GetTriggerGlobalEfficiency for logical OR of lepton triggers");
570  else if ( trigExpr.find(multi_str) != std::string::npos )
571  ATH_MSG_ERROR( "Use GetTriggerGlobalEfficiency for logical OR of lepton triggers");
572  else
573  ATH_MSG_ERROR( "The trigger expression (" << trigExpr << ") is not supported by the electron trigger SF!");
574 
575  switch (result) {
577  ATH_MSG_ERROR( "Failed to retrieve signal electron trigger SF");
578  return 1.;
580  ATH_MSG_VERBOSE( "OutOfValidityRange found for signal electron trigger SF");
581  return 1.;
582  default:
583  break;
584  }
585 
586  return trig_sf;
587 }
588 
589 
590 double SUSYObjDef_xAOD::GetEleTriggerEfficiency(const xAOD::Electron& el, const std::string& trigExpr) const {
591 
592  std::string single_str = "SINGLE_E";
593  std::string single_str_2022 = "2022_";
594  std::string dilep_str = "DI_E";
595  std::string multi_str = "MULTI_L";
596 
597  double trig_eff(1.);
598 
600  if ( trigExpr.find(single_str) != std::string::npos || trigExpr.find(single_str_2022) != std::string::npos)
602  else if ( trigExpr.find(dilep_str) != std::string::npos )
603  ATH_MSG_ERROR( "Use GetTriggerGlobalEfficiency for logical OR of lepton triggers");
604  else if ( trigExpr.find(multi_str) != std::string::npos )
605  ATH_MSG_ERROR( "Use GetTriggerGlobalEfficiency for logical OR of lepton triggers");
606  else
607  ATH_MSG_ERROR( "The trigger expression (" << trigExpr << ") is not supported by the electron trigger efficiency!");
608 
609  switch (result) {
611  ATH_MSG_ERROR( "Failed to retrieve signal electron trigger efficiency");
612  return 1.;
614  ATH_MSG_VERBOSE( "OutOfValidityRange found for signal electron trigger efficiency");
615  return 1.;
616  default:
617  break;
618  }
619 
620  return trig_eff;
621 }
622 
623 
624 
625  float SUSYObjDef_xAOD::GetTotalElectronSF(const xAOD::ElectronContainer& electrons, const bool recoSF, const bool idSF, const bool triggerSF, const bool isoSF, const std::string& trigExpr, const bool ecidsSF, const bool cidSF) {
626  float sf(1.);
627 
628  for (const xAOD::Electron* electron : electrons) {
629  if (!acc_passOR(*electron)) continue;
630  if (acc_signal(*electron)) { sf *= this->GetSignalElecSF(*electron, recoSF, idSF, triggerSF, isoSF, trigExpr, ecidsSF, cidSF); }
631  else { this->GetSignalElecSF(*electron, recoSF, idSF, triggerSF, isoSF, trigExpr, ecidsSF, cidSF); }
632  }
633 
634  return sf;
635 }
636 
637 
638  float SUSYObjDef_xAOD::GetTotalElectronSFsys(const xAOD::ElectronContainer& electrons, const CP::SystematicSet& systConfig, const bool recoSF, const bool idSF, const bool triggerSF, const bool isoSF, const std::string& trigExpr, const bool ecidsSF, const bool cidSF) {
639  float sf(1.);
640 
641  //Set the new systematic variation
643  if (ret != StatusCode::SUCCESS) {
644  ATH_MSG_ERROR("Cannot configure AsgElectronEfficiencyCorrectionTool (reco) for systematic var. " << systConfig.name() );
645  }
646 
648  if (ret != StatusCode::SUCCESS) {
649  ATH_MSG_ERROR("Cannot configure AsgElectronEfficiencyCorrectionTool (id) for systematic var. " << systConfig.name() );
650  }
651 
653  if (ret != StatusCode::SUCCESS) {
654  ATH_MSG_ERROR("Cannot configure AsgElectronEfficiencyCorrectionTool (trigger) for systematic var. " << systConfig.name() );
655  }
656 
658  if (ret != StatusCode::SUCCESS) {
659  ATH_MSG_ERROR("Cannot configure AsgElectronEfficiencyCorrectionTool (iso) for systematic var. " << systConfig.name() );
660  }
661 
663  if (ret != StatusCode::SUCCESS) {
664  ATH_MSG_ERROR("Cannot configure AsgElectronEfficiencyCorrectionTool (iso high-pt) for systematic var. " << systConfig.name() );
665  }
666 
668  if (ret != StatusCode::SUCCESS) {
669  ATH_MSG_ERROR("Cannot configure ElectronChargeEfficiencyCorrectionTool for systematic var. " << systConfig.name() );
670  }
671 
672 
673  //Get the total SF for new config
674  sf = GetTotalElectronSF(electrons, recoSF, idSF, triggerSF, isoSF, trigExpr, ecidsSF, cidSF);
675 
676  //Roll back to default
678  if (ret != StatusCode::SUCCESS) {
679  ATH_MSG_ERROR("Cannot configure AsgElectronEfficiencyCorrectionTool (reco) back to default.");
680  }
681 
683  if (ret != StatusCode::SUCCESS) {
684  ATH_MSG_ERROR("Cannot configure AsgElectronEfficiencyCorrectionTool (id) back to default.");
685  }
686 
688  if (ret != StatusCode::SUCCESS) {
689  ATH_MSG_ERROR("Cannot configure AsgElectronEfficiencyCorrectionTool (trigger) back to default.");
690  }
691 
693  if (ret != StatusCode::SUCCESS) {
694  ATH_MSG_ERROR("Cannot configure AsgElectronEfficiencyCorrectionTool (iso) back to default.");
695  }
696 
698  if (ret != StatusCode::SUCCESS) {
699  ATH_MSG_ERROR("Cannot configure AsgElectronEfficiencyCorrectionTool (iso high-pt) back to default.");
700  }
701 
703  if (ret != StatusCode::SUCCESS) {
704  ATH_MSG_ERROR("Cannot configure ElectronChargeEfficiencyCorrectionTool back to default.");
705  }
706 
707  return sf;
708 }
709 
710 }
python.PyKernel.retrieve
def retrieve(aClass, aKey=None)
Definition: PyKernel.py:110
ST::SUSYObjDef_xAOD::m_isoHighPtTool
asg::AnaToolHandle< CP::IIsolationSelectionTool > m_isoHighPtTool
Definition: SUSYObjDef_xAOD.h:955
ST::SUSYObjDef_xAOD::m_outElectronLocation
SG::WriteHandleKey< xAOD::ElectronContainer > m_outElectronLocation
Definition: SUSYObjDef_xAOD.h:876
ST::SUSYObjDef_xAOD::MergeElectrons
StatusCode MergeElectrons(const xAOD::ElectronContainer &electrons, xAOD::ElectronContainer *outputCol, const std::set< const xAOD::Electron * > &ElectronsToRemove) const override final
Definition: Electrons.cxx:63
ST::SUSYObjDef_xAOD::m_deadHVTool
asg::AnaToolHandle< IAsgDeadHVCellRemovalTool > m_deadHVTool
Definition: SUSYObjDef_xAOD.h:884
ST::SUSYObjDef_xAOD::m_eleIdExpert
bool m_eleIdExpert
Definition: SUSYObjDef_xAOD.h:639
ST::SUSYObjDef_xAOD::GetEleTriggerEfficiencySF
double GetEleTriggerEfficiencySF(const xAOD::Electron &el, const std::string &trigExpr="SINGLE_E_2015_e24_lhmedium_L1EM20VH_OR_e60_lhmedium_OR_e120_lhloose_2016_2018_e26_lhtight_nod0_ivarloose_OR_e60_lhmedium_nod0_OR_e140_lhloose_nod0") const override final
Definition: Electrons.cxx:556
xAOD::Electron
Electron_v1 Electron
Definition of the current "egamma version".
Definition: Event/xAOD/xAODEgamma/xAODEgamma/Electron.h:17
get_generator_info.result
result
Definition: get_generator_info.py:21
ST::SUSYObjDef_xAOD::IsSignalElectron
bool IsSignalElectron(const xAOD::Electron &input, const float etcut, const float d0sigcut, const float z0cut, const float etacut=DUMMYDEF) const override final
Definition: Electrons.cxx:362
ST::SUSYObjDef_xAOD::m_elecChargeEffCorrTool
asg::AnaToolHandle< IAsgElectronEfficiencyCorrectionTool > m_elecChargeEffCorrTool
Definition: SUSYObjDef_xAOD.h:896
TrackParticlexAODHelpers.h
ST::SUSYObjDef_xAOD::m_eleIsoHighPt_WP
std::string m_eleIsoHighPt_WP
Definition: SUSYObjDef_xAOD.h:647
ST::SUSYObjDef_xAOD::m_egammaCalibTool
asg::AnaToolHandle< CP::IEgammaCalibrationAndSmearingTool > m_egammaCalibTool
Combined electron collection.
Definition: SUSYObjDef_xAOD.h:879
ATH_MSG_INFO
#define ATH_MSG_INFO(x)
Definition: AthMsgStreamMacros.h:31
ST::SUSYObjDef_xAOD::prompt_electrons
const xAOD::ElectronContainer * prompt_electrons
Definition: SUSYObjDef_xAOD.h:210
CP::IIsolationCorrectionTool::applyCorrection
virtual CP::CorrectionCode applyCorrection(xAOD::Egamma &)=0
IAsgPhotonIsEMSelector.h
IAsgDeadHVCellRemovalTool::accept
virtual bool accept(const xAOD::Egamma *part) const =0
ST::SUSYObjDef_xAOD::GetTotalElectronSFsys
float GetTotalElectronSFsys(const xAOD::ElectronContainer &electrons, const CP::SystematicSet &systConfig, const bool recoSF=true, const bool idSF=true, const bool triggerSF=true, const bool isoSF=true, const std::string &trigExpr="singleLepton", const bool ecidsSF=false, const bool cidSF=false) override final
Definition: Electrons.cxx:638
ST::SUSYObjDef_xAOD::m_elecEfficiencySFTool_reco
asg::AnaToolHandle< IAsgElectronEfficiencyCorrectionTool > m_elecEfficiencySFTool_reco
Combined muon collection.
Definition: SUSYObjDef_xAOD.h:863
IAsgElectronEfficiencyCorrectionTool.h
ST::SUSYObjDef_xAOD::m_elecSelLikelihood
asg::AnaToolHandle< IAsgElectronLikelihoodTool > m_elecSelLikelihood
Definition: SUSYObjDef_xAOD.h:880
ITrigGlobalEfficiencyCorrectionTool.h
ConstDataVector.h
DataVector adapter that acts like it holds const pointers.
ST
Definition: Electrons.cxx:41
ST::SUSYObjDef_xAOD::m_doElIsoSignal
bool m_doElIsoSignal
Definition: SUSYObjDef_xAOD.h:778
ST::SUSYObjDef_xAOD::m_isoBaselineTool
asg::AnaToolHandle< CP::IIsolationSelectionTool > m_isoBaselineTool
Definition: SUSYObjDef_xAOD.h:954
ST::SUSYObjDef_xAOD::m_v_trigs17_cache_singleEle
std::vector< std::string > m_v_trigs17_cache_singleEle
Definition: SUSYObjDef_xAOD.h:454
xAOD::TrackingHelpers::d0significance
double d0significance(const xAOD::TrackParticle *tp, double d0_uncert_beam_spot_2)
Definition: TrackParticlexAODHelpers.cxx:42
xAOD::ShallowAuxContainer
Class creating a shallow copy of an existing auxiliary container.
Definition: ShallowAuxContainer.h:54
ST::SUSYObjDef_xAOD::FillElectron
StatusCode FillElectron(xAOD::Electron &input, const float etcut, const float etacut) override final
Definition: Electrons.cxx:223
CP::SystematicSet
Class to wrap a set of SystematicVariations.
Definition: SystematicSet.h:31
ST::SUSYObjDef_xAOD::GetTotalElectronSF
float GetTotalElectronSF(const xAOD::ElectronContainer &electrons, const bool recoSF=true, const bool idSF=true, const bool triggerSF=true, const bool isoSF=true, const std::string &trigExpr="singleLepton", const bool ecidsSF=false, const bool cidSF=false) override final
Definition: Electrons.cxx:625
ST::SUSYObjDef_xAOD::m_elePt
double m_elePt
Definition: SUSYObjDef_xAOD.h:677
ST::SUSYObjDef_xAOD::prepareLRTElectrons
StatusCode prepareLRTElectrons(const xAOD::ElectronContainer *inMuons, xAOD::ElectronContainer *copy) const override final
Definition: Electrons.cxx:92
DataVector::get
const T * get(size_type n) const
Access an element, as an rvalue.
CP::SystematicSet::name
std::string name() const
returns: the systematics joined into a single string.
Definition: SystematicSet.cxx:278
ST::SUSYObjDef_xAOD::GetSignalElecSF
float GetSignalElecSF(const xAOD::Electron &el, const bool recoSF=true, const bool idSF=true, const bool triggerSF=true, const bool isoSF=true, const std::string &trigExpr="singleLepton", const bool ecidsSF=false, const bool cidSF=false) override final
Definition: Electrons.cxx:420
xAOD::EventInfo_v1::beamPosSigmaX
float beamPosSigmaX() const
The width of the beam spot in the X direction.
ST::SUSYObjDef_xAOD::m_force_noElId
bool m_force_noElId
Definition: SUSYObjDef_xAOD.h:518
SUSYObjDef_xAOD.h
ST::SUSYObjDef_xAOD::m_acc_eleId
SG::AuxElement::ConstAccessor< char > m_acc_eleId
Definition: SUSYObjDef_xAOD.h:975
xAOD::numberOfPixelHits
@ numberOfPixelHits
these are the pixel hits, including the b-layer [unit8_t].
Definition: TrackingPrimitives.h:259
CP::IIsolationSelectionTool::accept
virtual asg::AcceptData accept(const xAOD::Photon &x) const =0
Declare the interface that the class provides.
ST::SUSYObjDef_xAOD::m_v_trigs18_cache_singleEle
std::vector< std::string > m_v_trigs18_cache_singleEle
Definition: SUSYObjDef_xAOD.h:455
xAOD::EgammaParameters::BADCLUSELECTRON
const uint32_t BADCLUSELECTRON
Definition: EgammaDefs.h:116
CP::IEgammaCalibrationAndSmearingTool::applyCorrection
virtual CP::CorrectionCode applyCorrection(xAOD::Egamma &) const =0
SG::ConstAccessor
Helper class to provide constant type-safe access to aux data.
Definition: ConstAccessor.h:54
ST::SUSYObjDef_xAOD::GetPrimVtx
const xAOD::Vertex * GetPrimVtx() const override final
Definition: SUSYObjDef_xAOD.cxx:2837
ST::SUSYObjDef_xAOD::m_eled0sig
double m_eled0sig
Definition: SUSYObjDef_xAOD.h:680
ST::SUSYObjDef_xAOD::m_v_trigs22_cache_singleEle
std::vector< std::string > m_v_trigs22_cache_singleEle
Definition: SUSYObjDef_xAOD.h:456
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
ST::SUSYObjDef_xAOD::m_elebaselined0sig
double m_elebaselined0sig
Definition: SUSYObjDef_xAOD.h:682
ST::SUSYObjDef_xAOD::m_debug
bool m_debug
Definition: SUSYObjDef_xAOD.h:532
ST::SUSYObjDef_xAOD::m_elecLRTORTool
asg::AnaToolHandle< CP::IElectronLRTOverlapRemovalTool > m_elecLRTORTool
Definition: SUSYObjDef_xAOD.h:875
ST::SUSYObjDef_xAOD::m_tool_init
bool m_tool_init
Definition: SUSYObjDef_xAOD.h:557
ST::SUSYObjDef_xAOD::m_v_trigs15_cache_singleEle
std::vector< std::string > m_v_trigs15_cache_singleEle
Definition: SUSYObjDef_xAOD.h:452
IEGammaAmbiguityTool.h
ST::SUSYObjDef_xAOD::m_elecEfficiencySFTool_isoHighPt
asg::AnaToolHandle< IAsgElectronEfficiencyCorrectionTool > m_elecEfficiencySFTool_isoHighPt
Definition: SUSYObjDef_xAOD.h:868
AthCommonDataStore< AthCommonMsg< AlgTool > >::evtStore
ServiceHandle< StoreGateSvc > & evtStore()
The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.
Definition: AthCommonDataStore.h:85
ST::SUSYObjDef_xAOD::m_isPHYSLITE
bool m_isPHYSLITE
Definition: SUSYObjDef_xAOD.h:789
IEgammaCalibrationAndSmearingTool.h
CP::CorrectionCode::OutOfValidityRange
@ OutOfValidityRange
Input object is out of validity range.
Definition: CorrectionCode.h:37
CP::CorrectionCode::Error
@ Error
Some error happened during the object correction.
Definition: CorrectionCode.h:36
IAsgElectronLikelihoodTool.h
IIsolationCorrectionTool.h
ATH_MSG_ERROR
#define ATH_MSG_ERROR(x)
Definition: AthMsgStreamMacros.h:33
ST::SUSYObjDef_xAOD::m_elecEfficiencySFTool_id
asg::AnaToolHandle< IAsgElectronEfficiencyCorrectionTool > m_elecEfficiencySFTool_id
Definition: SUSYObjDef_xAOD.h:864
CheckAppliedSFs.e3
e3
Definition: CheckAppliedSFs.py:264
ST::SUSYObjDef_xAOD::m_elez0
double m_elez0
Definition: SUSYObjDef_xAOD.h:681
ST::SUSYObjDef_xAOD::lrt_electrons
const xAOD::ElectronContainer * lrt_electrons
Definition: SUSYObjDef_xAOD.h:211
SG::Decorator
Helper class to provide type-safe access to aux data.
Definition: Decorator.h:58
ElectronAuxContainer.h
ret
T ret(T t)
Definition: rootspy.cxx:260
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
PlotPulseshapeFromCool.input
input
Definition: PlotPulseshapeFromCool.py:106
plotIsoValidation.el
el
Definition: plotIsoValidation.py:197
ATH_CHECK
#define ATH_CHECK
Definition: AthCheckMacros.h:40
ST::SUSYObjDef_xAOD::m_eleChID_signal
bool m_eleChID_signal
Definition: SUSYObjDef_xAOD.h:653
ST::SUSYObjDef_xAOD::m_runECIS
bool m_runECIS
Definition: SUSYObjDef_xAOD.h:654
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
IElectronLRTOverlapRemovalTool.h
DataVector
Derived DataVector<T>.
Definition: DataVector.h:581
IAsgDeadHVCellRemovalTool.h
ST::SUSYObjDef_xAOD::m_elecEfficiencySFTool_trigEff_singleLep
asg::AnaToolHandle< IAsgElectronEfficiencyCorrectionTool > m_elecEfficiencySFTool_trigEff_singleLep
Definition: SUSYObjDef_xAOD.h:866
ST::SUSYObjDef_xAOD::m_eleId
std::string m_eleId
Definition: SUSYObjDef_xAOD.h:634
CP::IElectronLRTOverlapRemovalTool::checkOverlap
virtual void checkOverlap(const xAOD::ElectronContainer &promptCollection, const xAOD::ElectronContainer &lrtCollection, std::set< const xAOD::Electron * > &ElectronsToRemove) const =0
Check the overlap between the prompt and LRT electron collections.
ST::SUSYObjDef_xAOD::m_eleIso_WP
std::string m_eleIso_WP
Definition: SUSYObjDef_xAOD.h:646
IAsgElectronEfficiencyCorrectionTool::getEfficiencyScaleFactor
virtual CP::CorrectionCode getEfficiencyScaleFactor(const xAOD::Electron &inputObject, double &efficiencyScaleFactor) const =0
ST::SUSYObjDef_xAOD::m_elecEfficiencySFTool_iso
asg::AnaToolHandle< IAsgElectronEfficiencyCorrectionTool > m_elecEfficiencySFTool_iso
Definition: SUSYObjDef_xAOD.h:867
xAOD::EventInfo_v1::beamPosSigmaY
float beamPosSigmaY() const
The width of the beam spot in the Y direction.
ST::SUSYObjDef_xAOD::m_eleLRT
bool m_eleLRT
Definition: SUSYObjDef_xAOD.h:650
ST::SUSYObjDef_xAOD::m_elecSelLikelihoodBaseline
asg::AnaToolHandle< IAsgElectronLikelihoodTool > m_elecSelLikelihoodBaseline
Definition: SUSYObjDef_xAOD.h:881
ST::SUSYObjDef_xAOD::GetEleTriggerEfficiency
double GetEleTriggerEfficiency(const xAOD::Electron &el, const std::string &trigExpr="SINGLE_E_2015_e24_lhmedium_L1EM20VH_OR_e60_lhmedium_OR_e120_lhloose_2016_2018_e26_lhtight_nod0_ivarloose_OR_e60_lhmedium_nod0_OR_e140_lhloose_nod0") const override final
Definition: Electrons.cxx:590
ST::SUSYObjDef_xAOD::TrigMatch
void TrigMatch(const xAOD::IParticle *p, std::initializer_list< std::string >::iterator, std::initializer_list< std::string >::iterator) override final
Definition: Trigger.cxx:247
IIsolationSelectionTool.h
ST::SUSYObjDef_xAOD::m_elecEfficiencySFTool_trig_singleLep
asg::AnaToolHandle< IAsgElectronEfficiencyCorrectionTool > m_elecEfficiencySFTool_trig_singleLep
Definition: SUSYObjDef_xAOD.h:865
DataVector::push_back
value_type push_back(value_type pElem)
Add an element to the end of the collection.
xAOD::Electron_v1
Definition: Electron_v1.h:34
xAOD::shallowCopyContainer
std::pair< std::unique_ptr< T >, std::unique_ptr< ShallowAuxContainer > > shallowCopyContainer(const T &cont, [[maybe_unused]] const EventContext &ctx)
Function making a shallow copy of a constant container.
Definition: ShallowCopy.h:110
xAOD::IParticle::isAvailable
bool isAvailable(const std::string &name, const std::string &clsname="") const
Check if a user property is available for reading or not.
Definition: Event/xAOD/xAODBase/xAODBase/IParticle.h:131
EventInfo.h
ST::SUSYObjDef_xAOD::m_elebaselinez0
double m_elebaselinez0
Definition: SUSYObjDef_xAOD.h:683
xAOD::EventInfo_v1
Class describing the basic event information.
Definition: EventInfo_v1.h:43
AthAnalysisHelper.h
ST::SUSYObjDef_xAOD::m_eleCrackVeto
bool m_eleCrackVeto
Definition: SUSYObjDef_xAOD.h:679
IAsgElectronIsEMSelector.h
CP::CorrectionCode::Ok
@ Ok
The correction was done successfully.
Definition: CorrectionCode.h:38
ST::SUSYObjDef_xAOD::m_elecChargeIDSelectorTool
asg::AnaToolHandle< IAsgElectronLikelihoodTool > m_elecChargeIDSelectorTool
Definition: SUSYObjDef_xAOD.h:895
xAOD::EventInfo_v1::beamPosSigmaXY
float beamPosSigmaXY() const
The beam spot shape's X-Y correlation.
ST::SUSYObjDef_xAOD::m_eleBaselineIso_WP
std::string m_eleBaselineIso_WP
Definition: SUSYObjDef_xAOD.h:638
xAOD::Vertex_v1
Class describing a Vertex.
Definition: Vertex_v1.h:42
mapkey::sf
@ sf
Definition: TElectronEfficiencyCorrectionTool.cxx:38
ATH_MSG_WARNING
#define ATH_MSG_WARNING(x)
Definition: AthMsgStreamMacros.h:32
xAOD::setOriginalObjectLink
bool setOriginalObjectLink(const IParticle &original, IParticle &copy)
This function should be used by CP tools when they make a deep copy of an object in their correctedCo...
Definition: IParticleHelpers.cxx:30
ST::SUSYObjDef_xAOD::m_eleEta
double m_eleEta
Definition: SUSYObjDef_xAOD.h:678
ST::SUSYObjDef_xAOD::m_acc_eleIdBaseline
SG::AuxElement::ConstAccessor< char > m_acc_eleIdBaseline
Definition: SUSYObjDef_xAOD.h:974
CP::CorrectionCode
Return value from object correction CP tools.
Definition: CorrectionCode.h:31
ST::SUSYObjDef_xAOD::m_currentSyst
CP::SystematicSet m_currentSyst
Definition: SUSYObjDef_xAOD.h:801
xAOD::EgammaParameters::electron
@ electron
Definition: EgammaEnums.h:18
python.changerun.pv
pv
Definition: changerun.py:81
ST::SUSYObjDef_xAOD::m_electronTriggerSFStringSingle
std::string m_electronTriggerSFStringSingle
Definition: SUSYObjDef_xAOD.h:630
xAOD::numberOfSCTHits
@ numberOfSCTHits
number of hits in SCT [unit8_t].
Definition: TrackingPrimitives.h:268
ST::SUSYObjDef_xAOD::m_eleBaselinePt
double m_eleBaselinePt
Definition: SUSYObjDef_xAOD.h:674
IParticleHelpers.h
xAOD::track
@ track
Definition: TrackingPrimitives.h:512
calibdata.copy
bool copy
Definition: calibdata.py:27
xAOD::TrackParticle_v1
Class describing a TrackParticle.
Definition: TrackParticle_v1.h:43
xAOD::getOriginalObject
const IParticle * getOriginalObject(const IParticle &copy)
This function can be used to conveniently get a pointer back to the original object from which a copy...
Definition: IParticleHelpers.cxx:140
IAsgElectronLikelihoodTool::accept
virtual asg::AcceptData accept(const xAOD::IParticle *part) const =0
accept with pointer to IParticle so as to not hide the IAsgSelectionTool one
ST::SUSYObjDef_xAOD::m_eleBaselineCrackVeto
bool m_eleBaselineCrackVeto
Definition: SUSYObjDef_xAOD.h:676
ST::SUSYObjDef_xAOD::GetElectrons
StatusCode GetElectrons(xAOD::ElectronContainer *&copy, xAOD::ShallowAuxContainer *&copyaux, const bool recordSG=true, const std::string &elekey="Electrons", const std::string &lrtelekey="LRTElectrons", const xAOD::ElectronContainer *containerToBeCopied=nullptr) override final
Definition: Electrons.cxx:120
ST::SUSYObjDef_xAOD::treatAsYear
int treatAsYear(const int runNumber=-1) const override final
Definition: SUSYObjDef_xAOD.cxx:3031
xAOD::bool
setBGCode setTAP setLVL2ErrorBits bool
Definition: TrigDecision_v1.cxx:60
CP::ISystematicsTool::applySystematicVariation
virtual StatusCode applySystematicVariation(const SystematicSet &systConfig)=0
effects: configure this tool for the given list of systematic variations.
asg::AnaToolHandle::empty
bool empty() const
whether this ToolHandle is completely empty, i.e.
DataVector::size
size_type size() const noexcept
Returns the number of elements in the collection.
ST::SUSYObjDef_xAOD::m_isoCorrTool
asg::AnaToolHandle< CP::IIsolationCorrectionTool > m_isoCorrTool
Definition: SUSYObjDef_xAOD.h:951
ST::SUSYObjDef_xAOD::m_v_trigs16_cache_singleEle
std::vector< std::string > m_v_trigs16_cache_singleEle
Definition: SUSYObjDef_xAOD.h:453
InDetDD::electrons
@ electrons
Definition: InDetDD_Defs.h:17
IEfficiencyScaleFactorTool.h
ST::SUSYObjDef_xAOD::m_eleBaselineEta
double m_eleBaselineEta
Definition: SUSYObjDef_xAOD.h:675
ST::SUSYObjDef_xAOD::m_eleIsoHighPtThresh
double m_eleIsoHighPtThresh
Definition: SUSYObjDef_xAOD.h:648
ST::SUSYObjDef_xAOD::m_isoTool
asg::AnaToolHandle< CP::IIsolationSelectionTool > m_isoTool
Definition: SUSYObjDef_xAOD.h:952