ATLAS Offline Software
Public Member Functions | Protected Member Functions | Private Types | Private Member Functions | Private Attributes | List of all members
VGammaORTool Class Reference

This tool can be used to identify the overlap of a V+jets and V+gamma sample or in fact between most V^n+gamma^m and V^n+gamma^(m-1) samples (e.g. More...

#include <VGammaORTool.h>

Inheritance diagram for VGammaORTool:
Collaboration diagram for VGammaORTool:

Public Member Functions

 VGammaORTool (const std::string &name)
 
virtual ~VGammaORTool () override
 
virtual StatusCode inOverlap (bool &result, const std::vector< TLorentzVector > *leptons=0, const std::vector< TLorentzVector > *photons=0, const std::vector< int > *lepton_origins=0, const std::vector< int > *photon_origins=0) const override
 Determine whether current event is in overlap region (set via reference). More...
 
virtual StatusCode photonPtsOutsideDr (std::vector< float > &result, const std::vector< TLorentzVector > *leptons=0, const std::vector< TLorentzVector > *photons=0, const std::vector< int > *lepton_origins=0, const std::vector< int > *photon_origins=0) const override
 Determine the pTs of photons outside the dR cut that is configured in tool initialization (dR_lepton_photon_cut). More...
 
virtual StatusCode photonPtsOutsideDrs (std::map< float, std::vector< float > > &result, const std::vector< TLorentzVector > *leptons=0, const std::vector< TLorentzVector > *photons=0, const std::vector< int > *lepton_origins=0, const std::vector< int > *photon_origins=0) const override
 Determine the pTs of photons outside of several dR cuts that are configured in tool initialization (dR_lepton_photon_cuts). More...
 
virtual bool frixioneIsolated (const xAOD::TruthParticle &photon, const xAOD::TruthParticleContainer &truthParticles, float dR0, float exponent, float epsilon) const override
 Function determining whether a photon is frixione isolated from truthParticles Parameters as defined in https://arxiv.org/pdf/hep-ph/9801442. More...
 
std::vector< TLorentzVector > getPhotonP4s (const xAOD::TruthParticleContainer &truthParticleContainer) const
 Get final state photons from truthParticleContainer A minimum pT cut and isolation is applied according to tool configuration Filter function is applied, only photons from relevant origins are kept. More...
 
std::vector< TLorentzVector > getLeptonP4s (const xAOD::TruthParticleContainer &truthParticleContainer) const
 Get final state leptons from truthParticleContainer Filter function is applied, only leptons from relevant origins are kept. More...
 
virtual StatusCode initialize ()
 Dummy implementation of the initialisation function. More...
 
virtual void print () const
 Print the state of the tool. More...
 
ServiceHandle< StoreGateSvc > & evtStore ()
 The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc. More...
 
const ServiceHandle< StoreGateSvc > & evtStore () const
 The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc. More...
 
const ServiceHandle< StoreGateSvc > & detStore () const
 The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc. More...
 
virtual StatusCode sysInitialize () override
 Perform system initialization for an algorithm. More...
 
virtual StatusCode sysStart () override
 Handle START transition. More...
 
virtual std::vector< Gaudi::DataHandle * > inputHandles () const override
 Return this algorithm's input handles. More...
 
virtual std::vector< Gaudi::DataHandle * > outputHandles () const override
 Return this algorithm's output handles. More...
 
Gaudi::Details::PropertyBase & declareProperty (Gaudi::Property< T > &t)
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, SG::VarHandleKey &hndl, const std::string &doc, const SG::VarHandleKeyType &)
 Declare a new Gaudi property. More...
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, SG::VarHandleBase &hndl, const std::string &doc, const SG::VarHandleType &)
 Declare a new Gaudi property. More...
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, SG::VarHandleKeyArray &hndArr, const std::string &doc, const SG::VarHandleKeyArrayType &)
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, T &property, const std::string &doc, const SG::NotHandleType &)
 Declare a new Gaudi property. More...
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, T &property, const std::string &doc="none")
 Declare a new Gaudi property. More...
 
void updateVHKA (Gaudi::Details::PropertyBase &)
 
MsgStream & msg () const
 
MsgStream & msg (const MSG::Level lvl) const
 
bool msgLvl (const MSG::Level lvl) const
 

Protected Member Functions

void renounceArray (SG::VarHandleKeyArray &handlesArray)
 remove all handles from I/O resolution More...
 
std::enable_if_t< std::is_void_v< std::result_of_t< decltype(&T::renounce)(T)> > &&!std::is_base_of_v< SG::VarHandleKeyArray, T > &&std::is_base_of_v< Gaudi::DataHandle, T >, void > renounce (T &h)
 
void extraDeps_update_handler (Gaudi::Details::PropertyBase &ExtraDeps)
 Add StoreName to extra input/output deps as needed. More...
 

Private Types

typedef ServiceHandle< StoreGateSvcStoreGateSvc_t
 

Private Member Functions

StatusCode photonPtsOutsideDrs (std::map< float, std::vector< float > > &result, const std::vector< float > &drCuts, const std::vector< TLorentzVector > *leptons=0, const std::vector< TLorentzVector > *photons=0, const std::vector< int > *lepton_origins=0, const std::vector< int > *photon_origins=0) const
 
StatusCode setInput (std::vector< TLorentzVector > &leptons_out, std::vector< TLorentzVector > &photons_out, const std::vector< TLorentzVector > *lepton_p4s, const std::vector< TLorentzVector > *photon_p4s, const std::vector< int > *lepton_origins, const std::vector< int > *photon_origins) const
 
std::vector< TLorentzVector > filterPhotonOrigins (const std::vector< TLorentzVector > &, const std::vector< int > &) const
 
std::vector< TLorentzVector > filterLeptonOrigins (const std::vector< TLorentzVector > &, const std::vector< int > &) const
 
bool isFromTau (const xAOD::TruthParticle &lepton, int nRecursions=0) const
 
bool checkPhotonPts (const std::vector< float > &photon_pts) const
 
float frixioneFunc (float dR, float dR0, float exponent, float epsilon) const
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
 specialization for handling Gaudi::Property<SG::VarHandleKey> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleKeyArrayType &)
 specialization for handling Gaudi::Property<SG::VarHandleKeyArray> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleType &)
 specialization for handling Gaudi::Property<SG::VarHandleBase> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &t, const SG::NotHandleType &)
 specialization for handling everything that's not a Gaudi::Property<SG::VarHandleKey> or a <SG::VarHandleKeyArray> More...
 

Private Attributes

asg::AnaToolHandle< MCTruthClassifierm_truthClassifier
 
int m_n_leptons
 
std::vector< int > m_lepton_pdgIds
 
std::vector< int > m_preferred_lepton_origins
 
std::vector< int > m_lepton_veto_origins
 
std::vector< int > m_veto_photon_origins
 
std::vector< float > m_photon_pT_cuts
 
float m_dR_lepton_photon_cut
 
std::vector< float > m_dR_lepton_photon_cuts
 
bool m_use_gamma_iso
 
float m_frixione_dR
 
float m_frixione_exponent
 
float m_frixione_epsilon
 
std::vector< int > m_abs_pdgids_excluded_from_iso
 
float m_min_considered_photon_pT
 
StoreGateSvc_t m_evtStore
 Pointer to StoreGate (event store by default) More...
 
StoreGateSvc_t m_detStore
 Pointer to StoreGate (detector store by default) More...
 
std::vector< SG::VarHandleKeyArray * > m_vhka
 
bool m_varHandleArraysDeclared
 

Detailed Description

This tool can be used to identify the overlap of a V+jets and V+gamma sample or in fact between most V^n+gamma^m and V^n+gamma^(m-1) samples (e.g.

V+gammagamma vs V+gamma or VV+gamma vs VV). It can either decide whether an event is in the overlap region for fixed cuts on photons and lepton or be used to extract relevant information from the event so that the overlap removal (OR) can be performed at a later stage with a simple 'if' statement.

The OR functions (inOverlap(result), photonPtsOutsideDr(result), or photonPtsOutsideDrs(result)), set the result via reference and return a status code. Usually the tool will take leptons and photons from the current event but this behavior can be overwritten by explicitly setting leptons and photons as additional arguments to the functions.

Further documented at https://twiki.cern.ch/twiki/bin/viewauth/AtlasProtected/VGammaORTool

Definition at line 37 of file VGammaORTool.h.

Member Typedef Documentation

◆ StoreGateSvc_t

typedef ServiceHandle<StoreGateSvc> AthCommonDataStore< AthCommonMsg< AlgTool > >::StoreGateSvc_t
privateinherited

Definition at line 388 of file AthCommonDataStore.h.

Constructor & Destructor Documentation

◆ VGammaORTool()

VGammaORTool::VGammaORTool ( const std::string &  name)

Definition at line 8 of file VGammaORTool.cxx.

10  m_truthClassifier("MCTruthClassifier",this) {
11 
12  declareProperty("n_leptons", m_n_leptons = -2);
13  declareProperty("lepton_pdgIds", m_lepton_pdgIds = {11, -11, 13, -13, 15, -15});
14  declareProperty("veto_lepton_origins", m_lepton_veto_origins = {3, 5, 6, 7, 8, 9, 23, 24, 25, 26, 27, 28, 29, 30, 31,
15  32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42});
16  declareProperty("preferred_lepton_origins", m_preferred_lepton_origins = {1, 2, 4, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21});
17 
18  declareProperty("veto_photon_origins", m_veto_photon_origins = {9, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 42});
19 
20  declareProperty("photon_pT_cuts", m_photon_pT_cuts = {});
21  declareProperty("dR_lepton_photon_cut", m_dR_lepton_photon_cut = 0.1);
22  declareProperty("dR_lepton_photon_cuts", m_dR_lepton_photon_cuts = {0.0, 0.05, 0.075, 0.1, 0.125, 0.15, 0.2});
23 
24  declareProperty("use_gamma_iso", m_use_gamma_iso = false);
25  declareProperty("frixione_dR", m_frixione_dR = 0.1);
26  declareProperty("frixione_exponent", m_frixione_exponent = 2);
27  declareProperty("frixione_epsilon", m_frixione_epsilon = 0.1);
28  declareProperty("abs_pdgids_excluded_from_iso", m_abs_pdgids_excluded_from_iso = {11, 12, 13, 14, 15, 16, 22});
29  declareProperty("min_considered_photon_pT", m_min_considered_photon_pT = 3.e3);
30 
31  for (int origin : m_preferred_lepton_origins) {
32  if (std::find(m_lepton_veto_origins.begin(), m_lepton_veto_origins.end(), origin) != m_lepton_veto_origins.end()) {
33  ATH_MSG_ERROR(origin << " in both lepton origin and lepton veto origin, this is not correct.");
34  break;
35  }
36  }
37  // pT cuts are sorted in descending order
38  std::sort(m_photon_pT_cuts.begin(), m_photon_pT_cuts.end(), std::greater<float>());
39 }

◆ ~VGammaORTool()

VGammaORTool::~VGammaORTool ( )
overridevirtual

Definition at line 41 of file VGammaORTool.cxx.

41  {
42 }

Member Function Documentation

◆ checkPhotonPts()

bool VGammaORTool::checkPhotonPts ( const std::vector< float > &  photon_pts) const
private

Definition at line 333 of file VGammaORTool.cxx.

333  {
334  if(m_photon_pT_cuts.size()==0){
335  ATH_MSG_ERROR("photon_pT_cuts needs to be a non-empty list, when inOverlap is called, set as property or in constructor.");
336  return false;
337  }
338  if(m_photon_pT_cuts.size()>photon_pts.size()){
339  return false;
340  }
341  for(uint i=0; i<m_photon_pT_cuts.size();i++){
342  if(photon_pts[i]<m_photon_pT_cuts[i]){
343  return false;
344  }
345  }
346  return true;
347 }

◆ declareGaudiProperty() [1/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T > &  hndl,
const SG::VarHandleKeyArrayType  
)
inlineprivateinherited

specialization for handling Gaudi::Property<SG::VarHandleKeyArray>

Definition at line 170 of file AthCommonDataStore.h.

172  {
173  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
174  hndl.value(),
175  hndl.documentation());
176 
177  }

◆ declareGaudiProperty() [2/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T > &  hndl,
const SG::VarHandleKeyType  
)
inlineprivateinherited

specialization for handling Gaudi::Property<SG::VarHandleKey>

Definition at line 156 of file AthCommonDataStore.h.

158  {
159  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
160  hndl.value(),
161  hndl.documentation());
162 
163  }

◆ declareGaudiProperty() [3/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T > &  hndl,
const SG::VarHandleType  
)
inlineprivateinherited

specialization for handling Gaudi::Property<SG::VarHandleBase>

Definition at line 184 of file AthCommonDataStore.h.

186  {
187  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
188  hndl.value(),
189  hndl.documentation());
190  }

◆ declareGaudiProperty() [4/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T > &  t,
const SG::NotHandleType  
)
inlineprivateinherited

specialization for handling everything that's not a Gaudi::Property<SG::VarHandleKey> or a <SG::VarHandleKeyArray>

Definition at line 199 of file AthCommonDataStore.h.

200  {
201  return PBASE::declareProperty(t);
202  }

◆ declareProperty() [1/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
SG::VarHandleBase hndl,
const std::string &  doc,
const SG::VarHandleType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
hndlObject holding the property value.
docDocumentation string for the property.

This is the version for types that derive from SG::VarHandleBase. The property value object is put on the input and output lists as appropriate; then we forward to the base class.

Definition at line 245 of file AthCommonDataStore.h.

249  {
250  this->declare(hndl.vhKey());
251  hndl.vhKey().setOwner(this);
252 
253  return PBASE::declareProperty(name,hndl,doc);
254  }

◆ declareProperty() [2/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
SG::VarHandleKey hndl,
const std::string &  doc,
const SG::VarHandleKeyType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
hndlObject holding the property value.
docDocumentation string for the property.

This is the version for types that derive from SG::VarHandleKey. The property value object is put on the input and output lists as appropriate; then we forward to the base class.

Definition at line 221 of file AthCommonDataStore.h.

225  {
226  this->declare(hndl);
227  hndl.setOwner(this);
228 
229  return PBASE::declareProperty(name,hndl,doc);
230  }

◆ declareProperty() [3/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
SG::VarHandleKeyArray hndArr,
const std::string &  doc,
const SG::VarHandleKeyArrayType  
)
inlineinherited

Definition at line 259 of file AthCommonDataStore.h.

263  {
264 
265  // std::ostringstream ost;
266  // ost << Algorithm::name() << " VHKA declareProp: " << name
267  // << " size: " << hndArr.keys().size()
268  // << " mode: " << hndArr.mode()
269  // << " vhka size: " << m_vhka.size()
270  // << "\n";
271  // debug() << ost.str() << endmsg;
272 
273  hndArr.setOwner(this);
274  m_vhka.push_back(&hndArr);
275 
276  Gaudi::Details::PropertyBase* p = PBASE::declareProperty(name, hndArr, doc);
277  if (p != 0) {
278  p->declareUpdateHandler(&AthCommonDataStore<PBASE>::updateVHKA, this);
279  } else {
280  ATH_MSG_ERROR("unable to call declareProperty on VarHandleKeyArray "
281  << name);
282  }
283 
284  return p;
285 
286  }

◆ declareProperty() [4/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
T &  property,
const std::string &  doc,
const SG::NotHandleType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
propertyObject holding the property value.
docDocumentation string for the property.

This is the generic version, for types that do not derive from SG::VarHandleKey. It just forwards to the base class version of declareProperty.

Definition at line 333 of file AthCommonDataStore.h.

337  {
338  return PBASE::declareProperty(name, property, doc);
339  }

◆ declareProperty() [5/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
T &  property,
const std::string &  doc = "none" 
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
propertyObject holding the property value.
docDocumentation string for the property.

This dispatches to either the generic declareProperty or the one for VarHandle/Key/KeyArray.

Definition at line 352 of file AthCommonDataStore.h.

355  {
356  typedef typename SG::HandleClassifier<T>::type htype;
357  return declareProperty (name, property, doc, htype());
358  }

◆ declareProperty() [6/6]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( Gaudi::Property< T > &  t)
inlineinherited

Definition at line 145 of file AthCommonDataStore.h.

145  {
146  typedef typename SG::HandleClassifier<T>::type htype;
148  }

◆ detStore()

const ServiceHandle<StoreGateSvc>& AthCommonDataStore< AthCommonMsg< AlgTool > >::detStore ( ) const
inlineinherited

The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 95 of file AthCommonDataStore.h.

95 { return m_detStore; }

◆ evtStore() [1/2]

ServiceHandle<StoreGateSvc>& AthCommonDataStore< AthCommonMsg< AlgTool > >::evtStore ( )
inlineinherited

The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 85 of file AthCommonDataStore.h.

85 { return m_evtStore; }

◆ evtStore() [2/2]

const ServiceHandle<StoreGateSvc>& AthCommonDataStore< AthCommonMsg< AlgTool > >::evtStore ( ) const
inlineinherited

The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 90 of file AthCommonDataStore.h.

90 { return m_evtStore; }

◆ extraDeps_update_handler()

void AthCommonDataStore< AthCommonMsg< AlgTool > >::extraDeps_update_handler ( Gaudi::Details::PropertyBase &  ExtraDeps)
protectedinherited

Add StoreName to extra input/output deps as needed.

use the logic of the VarHandleKey to parse the DataObjID keys supplied via the ExtraInputs and ExtraOuputs Properties to add the StoreName if it's not explicitly given

◆ filterLeptonOrigins()

std::vector< TLorentzVector > VGammaORTool::filterLeptonOrigins ( const std::vector< TLorentzVector > &  lepton_candidates,
const std::vector< int > &  lepton_origins 
) const
private

Definition at line 202 of file VGammaORTool.cxx.

203  {
204  // this should only happen if the user gives the wrong input
205  if (lepton_candidates.size() != lepton_origins.size()) {
207  "VGammaORTool::filterLeptonOrigins" << ": size of lepton candidates (" << lepton_candidates.size() << ") different from number of lepton origins (" << lepton_origins.size() <<
208  ").");
209  }
210  std::vector<TLorentzVector> lepton_p4s;
211  std::vector<TLorentzVector> leptons_not_vetoed_p4s;
212  // find both good photons and photons that are just not vetoed (lower quality, used as fall back)
213  for (uint i = 0; i < lepton_candidates.size(); i++) {
214  const TLorentzVector p4 = lepton_candidates[i];
215  const int p_origin = lepton_origins[i];
216  const bool use = std::find(m_preferred_lepton_origins.begin(), m_preferred_lepton_origins.end(), p_origin) != m_preferred_lepton_origins.end();
217  if (use) {
218  lepton_p4s.push_back(p4);
219  if (m_n_leptons>=0 && int(lepton_p4s.size()) >= m_n_leptons) {
220  // as soon as enough leptons are found, return them
221  // this is why the order of lepton candidates matters
222  // if this tool identifies the leptons, taus will be before mu/el and otherwise leptons are ordered by pT
223  // in most cases the origin should unambiguosly identify the lepton anyway
224  return lepton_p4s;
225  }
226  } else {
227  bool vetoed =
229  if (!vetoed) {
230  leptons_not_vetoed_p4s.push_back(p4);
231  }
232  }
233  }
234  // if not enough good leptons were found (or no expected number of leptons was set),
235  // the result is filled with leptons that were merely not vetoed
236  for (const auto& l : leptons_not_vetoed_p4s) {
237  lepton_p4s.push_back(l);
238  if (m_n_leptons>=0 && int(lepton_p4s.size()) >= m_n_leptons) break;
239  }
240  return lepton_p4s;
241 }

◆ filterPhotonOrigins()

std::vector< TLorentzVector > VGammaORTool::filterPhotonOrigins ( const std::vector< TLorentzVector > &  photon_candidates,
const std::vector< int > &  photon_origins 
) const
private

Definition at line 179 of file VGammaORTool.cxx.

180  {
181  // this should only happen if the user gives the wrong input
182  if (photon_candidates.size() != photon_origins.size()) {
184  "VGammaORTool::filterPhotonOrigins" << ": size of photon candidates (" << photon_candidates.size() << ") different from number of photon origins (" << photon_origins.size() <<
185  ").");
186  }
187  // filter out vetoed photons
188  std::vector<TLorentzVector> photon_p4s;
189  for (uint i = 0; i < photon_candidates.size(); i++) {
190  const TLorentzVector p4 = photon_candidates[i];
191  const int p_origin = photon_origins[i];
192  const bool vetoed =
194  if (!vetoed) {
195  photon_p4s.push_back(p4);
196  }
197  }
198 
199  return photon_p4s;
200 }

◆ frixioneFunc()

float VGammaORTool::frixioneFunc ( float  dR,
float  dR0,
float  exponent,
float  epsilon 
) const
private

Definition at line 392 of file VGammaORTool.cxx.

392  {
393  return epsilon * TMath::Power((1 - TMath::Cos(dR)) / (1 - TMath::Cos(dR0)), exponent);
394 }

◆ frixioneIsolated()

bool VGammaORTool::frixioneIsolated ( const xAOD::TruthParticle photon,
const xAOD::TruthParticleContainer truthParticles,
float  dR0,
float  exponent,
float  epsilon 
) const
overridevirtual

Function determining whether a photon is frixione isolated from truthParticles Parameters as defined in https://arxiv.org/pdf/hep-ph/9801442.

Implements IVGammaORTool.

Definition at line 350 of file VGammaORTool.cxx.

352  {
353  // all photons are isolated if dR is negative
354  if (dR0 <= 0.) {
355  return true;
356  }
357  // create map between hadron-photon dr and hadron pt
358  std::map<float, float> dr_to_pt;
359  for (const auto *p : truthParticles) {
360  if (!MC::isStable(p) || HepMC::is_simulation_particle(p)) continue;
361  // ignore what typically is leptons and photons
363  std::abs(p->pdgId())) != m_abs_pdgids_excluded_from_iso.end()) {
364  continue;
365  }
366  const float dRgamma = photon.p4().DeltaR(p->p4());
367  // consider only photons withon isolation cone dR0
368  if (dRgamma < dR0) {
369  // should two hadrons have the same dr they are added up
370  if (dr_to_pt.count(dRgamma) > 0) {
371  dr_to_pt[dRgamma] += p->pt();
372  }
373  dr_to_pt[dRgamma] = p->pt();
374  }
375  }
376  // use map to determine whether photon is Frixione isolated
377  // map is sorted from low to high dr
378  float sumPt = 0.;
379  for (const auto& pair : dr_to_pt) {
380  sumPt += pair.second;
381  const float dRgamma = pair.first;
382  // if for any dRgamma the sum of pt of hadrons with a distrance of <=dRgamma to photon
383  // does not fulfill the Frixione condition, the photon is not isolated
384  if (sumPt > photon.pt() * frixioneFunc(dRgamma, dR0, exponent, epsilon)) {
385  return false;
386  }
387  }
388  // otherwise the photon is isolated
389  return true;
390 }

◆ getKey()

SG::sgkey_t asg::AsgTool::getKey ( const void *  ptr) const
inherited

Get the (hashed) key of an object that is in the event store.

This is a bit of a special one. StoreGateSvc and xAOD::TEvent both provide ways for getting the SG::sgkey_t key for an object that is in the store, based on a bare pointer. But they provide different interfaces for doing so.

In order to allow tools to efficiently perform this operation, they can use this helper function.

See also
asg::AsgTool::getName
Parameters
ptrThe bare pointer to the object that the event store should know about
Returns
The hashed key of the object in the store. If not found, an invalid (zero) key.

Definition at line 119 of file AsgTool.cxx.

119  {
120 
121 #ifdef XAOD_STANDALONE
122  // In case we use @c xAOD::TEvent, we have a direct function call
123  // for this.
124  return evtStore()->event()->getKey( ptr );
125 #else
126  const SG::DataProxy* proxy = evtStore()->proxy( ptr );
127  return ( proxy == nullptr ? 0 : proxy->sgkey() );
128 #endif // XAOD_STANDALONE
129  }

◆ getLeptonP4s()

std::vector< TLorentzVector > VGammaORTool::getLeptonP4s ( const xAOD::TruthParticleContainer truthParticleContainer) const

Get final state leptons from truthParticleContainer Filter function is applied, only leptons from relevant origins are kept.

Definition at line 245 of file VGammaORTool.cxx.

245  {
246  std::vector<const xAOD::TruthParticle*> tau_candidates;
247  std::vector<const xAOD::TruthParticle*> elmu_candidates;
248  for (const auto *p : truthParticles) {
249  // ignore all particles created in Geant4
250  if (HepMC::is_simulation_particle(p)) continue;
251  // ignore all particles with the wrong pdgid
252  if (std::find(m_lepton_pdgIds.begin(), m_lepton_pdgIds.end(), p->pdgId()) == m_lepton_pdgIds.end()) continue;
253  // handle taus: use tau instances before decay into non-tau
254  if (MC::isTau(p)) {
255  bool childIsTau = false;
256  bool hasChildren = false;
257  // make sure tau has no tau children, i.e. is tau before decay
258  for (uint i = 0; i < p->nChildren(); i++) {
259  if (p->child(i) == nullptr) continue;
260  if (HepMC::is_same_particle(p->child(i),p)) continue;
261  hasChildren = true;
262  if (p->child(i)->pdgId() == p->pdgId()) {
263  childIsTau = true;
264  break;
265  }
266  }
267  if (hasChildren && !childIsTau) tau_candidates.push_back(p);
268  }
269  // electron and muons: use all status 1 not from tau
270  else if (MC::isStable(p) && !isFromTau(*p)) {
271  elmu_candidates.push_back(p);
272  }
273  }
274  // sort leptons by pT
275  sort(tau_candidates.begin(), tau_candidates.end(),
276  [](const xAOD::TruthParticle*& p1, const xAOD::TruthParticle*& p2) {
277  return p1->pt() > p2->pt();
278  });
279  sort(elmu_candidates.begin(), elmu_candidates.end(),
280  [](const xAOD::TruthParticle*& p1, const xAOD::TruthParticle*& p2) {
281  return p1->pt() > p2->pt();
282  });
283  // put taus before other leptons in a vector
284  std::vector<const xAOD::TruthParticle*> lepton_candidates(tau_candidates);
285  lepton_candidates.insert(lepton_candidates.end(), elmu_candidates.begin(), elmu_candidates.end());
286  // determine lepton origins
287  std::vector<TLorentzVector> lepton_p4s;
288  std::vector<int> lepton_origins;
289  static const SG::ConstAccessor<unsigned int> classifierParticleOriginAcc("classifierParticleOrigin");
290  for (const auto& p : lepton_candidates) {
291  const unsigned int origin = classifierParticleOriginAcc(*p);
292  lepton_origins.push_back(origin);
293  lepton_p4s.push_back(p->p4());
294  }
295  // filter out bad origins
296  return filterLeptonOrigins(lepton_p4s, lepton_origins);
297 }

◆ getName()

const std::string & asg::AsgTool::getName ( const void *  ptr) const
inherited

Get the name of an object that is / should be in the event store.

This is a bit of a special one. StoreGateSvc and xAOD::TEvent both provide ways for getting the std::string name for an object that is in the store, based on a bare pointer. But they provide different interfaces for doing so.

In order to allow tools to efficiently perform this operation, they can use this helper function.

See also
asg::AsgTool::getKey
Parameters
ptrThe bare pointer to the object that the event store should know about
Returns
The string name of the object in the store. If not found, an empty string.

Definition at line 106 of file AsgTool.cxx.

106  {
107 
108 #ifdef XAOD_STANDALONE
109  // In case we use @c xAOD::TEvent, we have a direct function call
110  // for this.
111  return evtStore()->event()->getName( ptr );
112 #else
113  const SG::DataProxy* proxy = evtStore()->proxy( ptr );
114  static const std::string dummy = "";
115  return ( proxy == nullptr ? dummy : proxy->name() );
116 #endif // XAOD_STANDALONE
117  }

◆ getPhotonP4s()

std::vector< TLorentzVector > VGammaORTool::getPhotonP4s ( const xAOD::TruthParticleContainer truthParticleContainer) const

Get final state photons from truthParticleContainer A minimum pT cut and isolation is applied according to tool configuration Filter function is applied, only photons from relevant origins are kept.

Definition at line 299 of file VGammaORTool.cxx.

299  {
300  std::vector<TLorentzVector> photon_p4s;
301  std::vector<int> photon_origins;
302  for (const auto *p : truthParticles) {
303  // consider only final state photons, not from geant, above a lower pt cut
305  // require photons to be isolated if use_gamma_iso is true
307  // determine photon origin
308  static const SG::ConstAccessor<unsigned int> classifierParticleOriginAcc("classifierParticleOrigin");
309  const unsigned int origin = classifierParticleOriginAcc(*p);
310  photon_origins.push_back(origin);
311  photon_p4s.push_back(p->p4());
312  }
313  // filter out bad photons
314  return filterPhotonOrigins(photon_p4s, photon_origins);
315 }

◆ getProperty()

template<class T >
const T* asg::AsgTool::getProperty ( const std::string &  name) const
inherited

Get one of the tool's properties.

◆ initialize()

virtual StatusCode asg::AsgTool::initialize ( )
inlinevirtualinherited

Dummy implementation of the initialisation function.

It's here to allow the dual-use tools to skip defining an initialisation function. Since many are doing so...

Reimplemented in SimpleMuonTriggerScaleFactors, Trig::TrigMuonMatching, CP::MuonTriggerScaleFactors, IHIEventShapeMapTool, ST::SUSYObjDef_xAOD, InDetSecVtxTruthMatchTool, JetGrooming::RecSoftDrop, met::METMaker, AsgForwardElectronIsEMSelector, JetGrooming::JetTrimming, ORUtils::BaseOverlapTool, PMGTools::PMGSherpa22VJetsWeightTool, AsgElectronEfficiencyCorrectionTool, CP::ElectronChargeEfficiencyCorrectionTool, AsgForwardElectronLikelihoodTool, CorrectPFOTool, CP::IsolationCorrectionTool, TauAnalysisTools::TauTruthMatchingTool, EGammaAmbiguityTool, InDetVertexTruthMatchTool, AthOnnx::OnnxRuntimeSessionToolCPU, AthOnnx::OnnxRuntimeSessionToolCUDA, PuppiWeightTool, CP::EgammaCalibrationAndSmearingTool, CP::FFJetSmearingTool, JetBalancePFlowJvtTool, JetIsolationTool, JetForwardPFlowJvtTool, MCTruthClassifier, InDet::InDetHardScatterSelectionTool, dRMatchingTool, xAOD::BPhysBlindingTool, JetVertexTaggerTool, tauRecTools::TrackRNN, LVL1::L1CaloOfflineTriggerTowerTools, TauAnalysisTools::TauSelectionTool, JetRecTool, met::METAssociationTool, CP::TrackVertexAssociationTool, met::METAssociator, xAOD::TrackIsolationTool, InDet::InDetTrackSelectionTool, egammaMVACalibTool, TrigConf::xAODConfigTool, JetCleaningTool, met::METCaloRegionsTool, ZDC::ZdcLEDAnalysisTool, ZDC::RpdSubtractCentroidTool, CP::MuonCalibTool, LVL1::L1CaloCells2TriggerTowers, IDTPM::TrackAnalysisInfoWriteTool, JetVertexFractionTool, LVL1BS::PpmByteStreamReadV1V2Tool, JetClusterer, JetForwardJvtToolBDT, CP::AsgFlagSelectionTool, TauTrackFinder, TauAnalysisTools::DiTauSelectionTool, JetClustererByVertex, BookkeeperTool, JetBadChanCorrTool, xAOD::BPhysTrackVertexMapTool, JetModifiedMassDrop, xAOD::CaloIsolationTool, EnhancedBiasWeighter, InDet::InDetUsedInFitTrackDecoratorTool, CP::AsgPtEtaSelectionTool, TauAnalysisTools::BuildTruthTaus, tauRecTools::TauTrackRNNClassifier, InDet::InDetSecVtxTrackSelectionTool, AthONNX::JSSMLTool, JetForwardJvtTool, JetPileupTag::JetVertexNNTagger, CP::EgammaIsGoodOQSelectionTool, CP::IsolationCloseByCorrectionTool, ElectronPhotonVariableCorrectionBase, CP::MuonCalibIntScaleSmearTool, JetFinder, AsgElectronIsEMSelector, CP::MuonCalibIntHighpTSmearTool, CP::MuonCalibIntSagittaTool, met::METBuilderTool, CP::AsgMaskSelectionTool, ECUtils::EventCleaningTool, TauAnalysisTools::TauTruthTrackMatchingTool, met::METSoftTermsTool, LVL1::L1CaloLArTowerEnergy, HiggsTruthCategoryTool, IDTPM::TrackRoiSelectionTool, TauAnalysisTools::CommonDiTauEfficiencyTool, HIJetConstituentSubtractionTool, JetTrackSumMomentsTool, JetGrooming::SoftDrop, JetTrackMomentsTool, met::METTruthTool, PMGTools::PMGSherpaVjetsSysTool, JetQGTaggerVariableTool, ClusterMatching::CaloClusterMatchingTool, AsgPhotonEfficiencyCorrectionTool, FlavorTagDiscriminants::MultifoldGNNTool, InDet::JetTrackFilterTool, DiTauRecTools::DiTauDiscriminantTool, asg::DataHandleTestTool, xAODMaker::FileMetaDataTool, InDet::InclusiveTrackFilterTool, InDet::InDetTrackTruthFilterTool, HIJetClusterSubtractorTool, CP::MVATrackVertexAssociationTool, IDTPM::RoiSelectionTool, IDTPM::VertexRoiSelectionTool, CP::BaseFakeBkgTool, ElectronPhotonVariableCorrectionTool, JetCalibrationTool, JetCaloQualityTool, JetOriginCorrectionTool, IDTPM::TrackObjectSelectionTool, InDet::InDetTrackBiasingTool, HIJetClusterIndexAssociationTool, TauWPDecorator, TrigGlobalEfficiencyCorrectionTool, ZdcRecChannelToolV2, InDetGNNHardScatterSelection::GNNTool, CP::BaseLinearFakeBkgTool, FlavorTagDiscriminants::GNNTool, CP::MuonSelectionTool, TauAnalysisTools::CommonDiTauSmearingTool, JSSTaggerBase, CP::LhoodMM_tools, AsgElectronLikelihoodTool, DiTauRecTools::DiTauIDVarCalculator, CP::JetQGTagger, Pileup1DResidualCalibStep, LVL1::L1CaloFcal23Cells2RxMappingTool, IDTPM::TrackQualitySelectionTool, IDTPM::VertexQualitySelectionTool, ORUtils::OverlapRemovalTool, Ringer::AsgRingerSelectorTool, InDet::InDetTrackSmearingTool, CP::JetJvtEfficiency, JetCopier, JetGrooming::JetGroomer, met::METPhotonAssociator, JetECPSFractionTool, JetPtAssociationTool, met::METElectronAssociator, met::METTauAssociator, PMGTools::PMGDecayProductsSelectionTool, WeightToolBase, HIJetDRAssociationTool, JetClusterMomentsTool, met::METJetAssocTool, TauVertexFinder, IDTPM::JsonPlotsDefReadTool, TauAnalysisTools::DiTauSmearingTool, BJetCorrectionTool, JetDRTrackAssocTool, JetReclusterer, TauDecayModeNNClassifier, BDTVertexWeightCalculator, asg::UnitTestTool1, ZDC::ZdcAnalysisTool, IDTPM::DeltaRMatchingToolBase< T, R >, AsgElectronSelectorTool, GSCCalibStep, EtaMassJESCalibStep, JetReclusteringTool, met::METMuonAssociator, TauPi0CreateROI, TauShotFinder, IDTPM::DeltaRMatchingToolBase< xAOD::TrackParticle, xAOD::TruthParticle >, IDTPM::DeltaRMatchingToolBase< xAOD::TruthParticle, xAOD::TrackParticle >, IDTPM::DeltaRMatchingToolBase< xAOD::TrackParticle >, ZdcRecChannelToolLucrod, PMGTools::PMGTruthWeightTool, JetCalibTool, SmearingCalibStep, JetVoronoiMomentsTool, Trig::MatchFromCompositeTool, asg::UnitTestTool3, IDTPM::TruthTrackMatchingTool, CP::ApplyFakeFactor, AsgElectronChargeIDSelectorTool, HIJetMaxOverMeanTool, PanTau::Tool_FeatureExtractor, TauElectronVetoVariables, ZDC::ZdcTrigValidTool, IDTPM::TruthQualitySelectionTool, CP::IsolationSelectionTool, WeightsAgregator, EL::UnitTestTool, FlavorTagDiscriminants::TrackClassifier, JetLArHVTool, IDTPM::EFTrackMatchingTool, IDTPM::OfflineTrackQualitySelectionTool, IDTPM::TrackTruthMatchingTool, HI::HIPileupTool, BTaggingSelectionTool, InDet::InDetTrackTruthOriginTool, JetHelper::VarTool, FlavorTagDiscriminants::DL2Tool, PileupAreaCalibStep, EnergyCorrelatorGeneralizedRatiosTool, EnergyCorrelatorGeneralizedTool, EnergyCorrelatorRatiosTool, EnergyCorrelatorTool, TauEleOverlapChecker, TauJetRNNEvaluator, asg::UnitTestTool2, JetTruthLabelingTool, ZDC::ZdcRecTool, HIJetConstituentModifierTool, TauCalibrateLC, TauGNNEvaluator, TauPi0ScoreCalculator, TauRecToolBase, Trig::TrigEgammaEmulationPrecisionElectronHypoTool, asg::UnitTestTool1A, PDFWeight, HIEventShapeJetIteration, HIJetSignificanceTool, CP::JetQGTaggerBDT, JetWidthTool, TauVertexVariables, Trig::TrigEgammaEmulationPrecisionPhotonHypoTool, Trig::TrigEgammaMatchingTool, Trig::R3IParticleRetrievalTool, JetPileupLabelingTool, JetFromPseudojet, JetTruthParticleSelectorTool, Trig::TrigEgammaEmulationBaseHypoTool, AthOnnx::OnnxRuntimeInferenceTool, ZDC::RPDAnalysisTool, CP::ApplyE2YFakeRate, ParticleScaleFactorTool, TauAnalysisTools::TauHFVetoTool, InDet::InDetTrackSystematicsTool, JetCaloQualityToolFE, Trig::MatchingTool, Trig::R3MatchingTool, JetParticleAssociation, JetHelper::HistoInput2D, Trig::TrigEgammaEmulationChain, Trig::TrigEgammaEmulationFastCaloHypoTool, xAODtoHepMCTool, HIEventShapeMapTool, HI::HIVertexSelectionTool, TauVertexedClusterDecorator, Trig::IParticleRetrievalTool, HI::HIEventSelectionTool, FlavorTagDiscriminants::HbbTagTool, JetConstituentFrac, JetGroomMRatio, Validator, JetHelper::HistoInput1D, JetHelper::TextInputMCJES, ExtendTrackToLayerTool, Trig::TypedScoringTool, TrackTruthSelectionTool, HIUEModulatorTool, JSSWTopTaggerANN, CP::JvtEfficiencyToolBase, JetEMScaleMomTool, MvaTESVariableDecorator, TauAODMuonRemovalTool, TauCombinedTES, CP::AsymptMatrixTool, ParticleJetDeltaRLabelTool, HIEventShapeSummaryTool, FlavorTagDiscriminants::BTagAugmenterTool, FlavorTagDiscriminants::VRJetOverlapDecoratorTool, JSSTaggerUtils, JetCaloEnergies, ParticleJetGhostLabelTool, FlavorTagDiscriminants::BTagMuonAugmenterTool, BTaggingEfficiencyJsonTool, MBTSTimeFilterTool, JSSWTopTaggerDNN, SmoothedTopTagger, MvaTESEvaluator, BoostedJetTaggerTool, CP::IsolationLowPtPLVTool, Trig::DRScoringTool, Trig::EgammaDRScoringTool, BTaggingSelectionJsonTool, SmoothedWZTagger, CP::FJvtEfficiencyTool, CP::JvtSelectionToolBase, CP::NNJvtSelectionTool, AthAsgExUnittestTool, CP::JvtSelectionTool, CP::FJvtSelectionTool, CP::JvtEfficiencyTool, CP::NNJvtEfficiencyTool, BookkeeperDumperTool, TrigFastCalibWithRings, BTaggingEfficiencyTool, BTaggingTruthTaggingTool, MissingCellListTool, JetVoronoiDiagramHelpers::Diagram, FastJetInterfaceTool, CP::PhotonVertexSelectionTool, met::METSystematicsTool, Trig::TrigEgammaEmulationToolMT, JetAttributeRatioSelector, BTaggingEigenVectorRecompositionTool, Trig::TrigDecisionTool, CP::PhotonPointingTool, met::METRecoTool, CP::PileupReweightingTool, LVL1::L1CaloxAODOfflineTriggerTowerTools, LVL1::TrigT1CaloMonErrorToolV1, met::METTrackFilterTool, LVL1::TrigT1CaloMonErrorTool, SoftKillerWeightTool, EventDensityTool, met::METSignificance, JetUncertaintiesTool, CP::JetTileCorrectionTool, xAODMaker::TriggerMenuMetaDataTool, D3PD::D3PDMCTruthClassifier, JetConstituentModSequence, HistoGroupBase, AsgPhotonIsEMSelector, JetAttributeSelector, TrackVertexAssociationTool, met::METRefinerTool, TauAnalysisTools::CommonSmearingTool, PanTau::Tool_DetailsArranger, LVL1::L1CaloMonitoringCaloTool, LVL1::L1CaloTTIdTools, JetInputElRemovalTool, GoodRunsListSelectionTool, TauAnalysisTools::CommonEfficiencyTool, PanTau::PanTauProcessor, xAODMaker::TruthMetaDataTool, EventShapeCopier, met::METJetTool, ZdcByteStreamReadV1V2Tool, FSR::FsrPhotonTool, Trig::StaticBunchCrossingTool, ZMassConstraint::ConstraintFit, TauAnalysisTools::TauEfficiencyCorrectionsTool, PanTau::Tool_DecayModeDeterminator, PanTau::Tool_ModeDiscriminator, CP::ElectronLRTOverlapRemovalTool, HIClusterSubtraction, JetAttributeHisto, JetPseudojetCopier, met::METEgammaAssociator, Trig::xAODBunchCrossingTool, TauAnalysisTools::DiTauEfficiencyCorrectionsTool, TauAnalysisTools::DiTauTruthMatchingTool, TauAnalysisTools::TauSmearingTool, met::METTruthAssociator, PanTau::Tool_InformationStore, HistoDefinitionTool, PanTau::Tool_InputConverter, DiTauMassTools::MissingMassTool, JetBottomUpSoftDrop, JetRecursiveSoftDrop, PMGTools::PMGCrossSectionTool, JetSoftDrop, TrigEgammaMatchingToolMT, JetConstituentsRetriever, VoronoiWeightTool, JetCaloCellQualityTool, JetContainerHistoFiller, ChargedHadronSubtractionTool, met::METRegionsTool, met::METSoftAssociator, PanTau::Tool_TauConstituentGetter, ConstituentSubtractorTool, JetHistoBase, JetSelectorAttributeRunII, JetSplitter, CaloClusterConstituentsOrigin, CP::MuonLRTOverlapRemovalTool, HistosForJetSelection, JetPruner, JetToolRunner, JetUsedInFitTrackDecoratorTool, JetTrimmer, NSubjettinessRatiosTool, CP::MuonEfficiencyScaleFactors, JetConstitFourMomTool, NSubjettinessTool, ZdcDataAccessV2, JetPseudojetRetriever, LVL1BS::TrigT1CaloDataAccessV2, PanTau::Tool_TauConstituentSelector, CopyTruthParticles, ClusterAtEMScaleTool, CP::IsolationHelper, HIEfficiencyResponseHistos, AsgDeadHVCellRemovalTool, EfficiencyResponseHistos, ConstitTimeCutTool, JetSelectorAttribute, HIJetUEMonitoring, JetSubStructureMomentToolsBase, AsgHelloTool, CopyTruthJetParticles, LeadingJetsRelations, and JetEventSelector.

Definition at line 133 of file AsgTool.h.

133 { return StatusCode::SUCCESS; }

◆ inOverlap()

StatusCode VGammaORTool::inOverlap ( bool &  result,
const std::vector< TLorentzVector > *  leptons = 0,
const std::vector< TLorentzVector > *  photons = 0,
const std::vector< int > *  lepton_origins = 0,
const std::vector< int > *  photon_origins = 0 
) const
overridevirtual

Determine whether current event is in overlap region (set via reference).

The overlap region is defined by dR_lepton_photon_cut, photon_pT_cut and many more configurable parameters. Note that the function returns a status code. The first agument is the result, the remaining arguments are optional:

  • If null pointers are given for leptons or photons, they will be taken from the event
  • One can override this behaviour by manually specifying vectors of lepton/photon
  • If lepton or photon origins are given in addition to the lepton four vectors, particles from irrelevant origins (e.g. decays) are filtered out This can be useful when working with derivations which store the origin but not the full truth record

Implements IVGammaORTool.

Definition at line 48 of file VGammaORTool.cxx.

52  {
53  std::vector<float> photon_pts;
54  ANA_CHECK(photonPtsOutsideDr(photon_pts,leptons,photons,lepton_origins,photon_origins));
55  result = checkPhotonPts(photon_pts);
56  return StatusCode::SUCCESS;
57 }

◆ inputHandles()

virtual std::vector<Gaudi::DataHandle*> AthCommonDataStore< AthCommonMsg< AlgTool > >::inputHandles ( ) const
overridevirtualinherited

Return this algorithm's input handles.

We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.

◆ isFromTau()

bool VGammaORTool::isFromTau ( const xAOD::TruthParticle lepton,
int  nRecursions = 0 
) const
private

Definition at line 317 of file VGammaORTool.cxx.

317  {
318  // avoid being stuck in some weird particle family tree
319  if(nRecursions>20){
320  return false;
321  }
322  for(uint i=0; i<lepton.nParents(); i++){
323  const xAOD::TruthParticle* parent=lepton.parent(i);
324  if (MC::isTau(parent)) return true;
325  if(parent->pdgId()==lepton.pdgId()){
326  return isFromTau(lepton, nRecursions+1);
327  }
328  }
329  return false;
330 
331 }

◆ msg() [1/2]

MsgStream& AthCommonMsg< AlgTool >::msg ( ) const
inlineinherited

Definition at line 24 of file AthCommonMsg.h.

24  {
25  return this->msgStream();
26  }

◆ msg() [2/2]

MsgStream& AthCommonMsg< AlgTool >::msg ( const MSG::Level  lvl) const
inlineinherited

Definition at line 27 of file AthCommonMsg.h.

27  {
28  return this->msgStream(lvl);
29  }

◆ msg_level_name()

const std::string & asg::AsgTool::msg_level_name ( ) const
inherited

A deprecated function for getting the message level's name.

Instead of using this, weirdly named function, user code should get the string name of the current minimum message level (in case they really need it...), with:

MSG::name( msg().level() )

This function's name doesn't follow the ATLAS coding rules, and as such will be removed in the not too distant future.

Returns
The string name of the current minimum message level that's printed

Definition at line 101 of file AsgTool.cxx.

101  {
102 
103  return MSG::name( msg().level() );
104  }

◆ msgLvl()

bool AthCommonMsg< AlgTool >::msgLvl ( const MSG::Level  lvl) const
inlineinherited

Definition at line 30 of file AthCommonMsg.h.

30  {
31  return this->msgLevel(lvl);
32  }

◆ outputHandles()

virtual std::vector<Gaudi::DataHandle*> AthCommonDataStore< AthCommonMsg< AlgTool > >::outputHandles ( ) const
overridevirtualinherited

Return this algorithm's output handles.

We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.

◆ photonPtsOutsideDr()

StatusCode VGammaORTool::photonPtsOutsideDr ( std::vector< float > &  result,
const std::vector< TLorentzVector > *  leptons = 0,
const std::vector< TLorentzVector > *  photons = 0,
const std::vector< int > *  lepton_origins = 0,
const std::vector< int > *  photon_origins = 0 
) const
overridevirtual

Determine the pTs of photons outside the dR cut that is configured in tool initialization (dR_lepton_photon_cut).

Calculates a vector of photon pts, ordered by descending pt. Once these values are calculated they can be stored and used to easily perform OR with arbitrary pT. Note that the function returns a status code. The first agument is the result, the remaining arguments are optional

  • If null pointers are given for leptons or photons, they will be taken from the event
  • One can override this behaviour by manually specifying vectors of lepton/photon
  • If lepton or photon origins are given in addition to the lepton four vectors, particles from irrelevant origins (e.g. decays) are filtered out This can be useful when working with derivations which store the origin but not the full truth record

Implements IVGammaORTool.

Definition at line 62 of file VGammaORTool.cxx.

66  {
67  std::map<float, std::vector<float> > photon_pt_map;
68  ANA_CHECK(photonPtsOutsideDrs(photon_pt_map,std::vector<float>(1, m_dR_lepton_photon_cut),leptons,photons,lepton_origins,photon_origins));
69  result = photon_pt_map[m_dR_lepton_photon_cut];
70  return StatusCode::SUCCESS;
71 }

◆ photonPtsOutsideDrs() [1/2]

StatusCode VGammaORTool::photonPtsOutsideDrs ( std::map< float, std::vector< float > > &  result,
const std::vector< float > &  drCuts,
const std::vector< TLorentzVector > *  leptons = 0,
const std::vector< TLorentzVector > *  photons = 0,
const std::vector< int > *  lepton_origins = 0,
const std::vector< int > *  photon_origins = 0 
) const
private

Definition at line 89 of file VGammaORTool.cxx.

94  {
95  std::vector<TLorentzVector> good_leptons;
96  std::vector<TLorentzVector> good_photons;
97  ANA_CHECK(setInput(good_leptons,good_photons,leptons,photons,lepton_origins,photon_origins));
98 
99  // the actual OR algorithm is here, pts of photon outside dRs are determined first
100  for (const auto& drCut : drCuts) {
101  result[drCut] = std::vector<float>();
102  for (const auto& photon : good_photons) {
103  bool tooCloseToLepton = false;
104  for (uint i_lep = 0; i_lep < good_leptons.size() && (m_n_leptons<0 || int(i_lep) < m_n_leptons); i_lep++) {
105  const float dr = photon.DeltaR(good_leptons[i_lep]);
106  if (dr < drCut) {
107  tooCloseToLepton = true;
108  break;
109  }
110  }
111  if (!tooCloseToLepton) result[drCut].push_back(photon.Pt());
112  }
113  // photon pts are sorted and returned
114  std::sort(result[drCut].begin(), result[drCut].end(), std::greater<float>());
115  }
116 
117  return StatusCode::SUCCESS;
118 }

◆ photonPtsOutsideDrs() [2/2]

StatusCode VGammaORTool::photonPtsOutsideDrs ( std::map< float, std::vector< float > > &  result,
const std::vector< TLorentzVector > *  leptons = 0,
const std::vector< TLorentzVector > *  photons = 0,
const std::vector< int > *  lepton_origins = 0,
const std::vector< int > *  photon_origins = 0 
) const
overridevirtual

Determine the pTs of photons outside of several dR cuts that are configured in tool initialization (dR_lepton_photon_cuts).

Calculates a mapping between dRs and vector of photon pts (ordered by descending pt). Once these values are calculated they can be stored and used to easily perform OR with arbitrary pT and multiple dR cuts. Note that the function returns a status code. The first agument is the result, the remaining arguments are optional

  • If null pointers are given for leptons or photons, they will be taken from the event
  • One can override this behaviour by manually specifying vectors of lepton/photon
  • If lepton or photon origins are given in addition to the lepton four vectors, particles from irrelevant origins (e.g. decays) are filtered out This can be useful when working with derivations which store the origin but not the full truth record

Implements IVGammaORTool.

Definition at line 76 of file VGammaORTool.cxx.

80  {
81  ANA_CHECK(photonPtsOutsideDrs(result,m_dR_lepton_photon_cuts,leptons,photons,lepton_origins,photon_origins));
82  return StatusCode::SUCCESS;
83 }

◆ print()

void asg::AsgTool::print ( ) const
virtualinherited

◆ renounce()

std::enable_if_t<std::is_void_v<std::result_of_t<decltype(&T::renounce)(T)> > && !std::is_base_of_v<SG::VarHandleKeyArray, T> && std::is_base_of_v<Gaudi::DataHandle, T>, void> AthCommonDataStore< AthCommonMsg< AlgTool > >::renounce ( T &  h)
inlineprotectedinherited

Definition at line 380 of file AthCommonDataStore.h.

381  {
382  h.renounce();
383  PBASE::renounce (h);
384  }

◆ renounceArray()

void AthCommonDataStore< AthCommonMsg< AlgTool > >::renounceArray ( SG::VarHandleKeyArray handlesArray)
inlineprotectedinherited

remove all handles from I/O resolution

Definition at line 364 of file AthCommonDataStore.h.

364  {
365  handlesArray.renounce();
366  }

◆ setInput()

StatusCode VGammaORTool::setInput ( std::vector< TLorentzVector > &  leptons_out,
std::vector< TLorentzVector > &  photons_out,
const std::vector< TLorentzVector > *  lepton_p4s,
const std::vector< TLorentzVector > *  photon_p4s,
const std::vector< int > *  lepton_origins,
const std::vector< int > *  photon_origins 
) const
private

Definition at line 122 of file VGammaORTool.cxx.

127  {
128 
129  // truth particles are retrieved from event if not given by user
130  const xAOD::TruthParticleContainer* truthMuons(nullptr);
131  const xAOD::TruthParticleContainer* truthElectrons(nullptr);
132  const xAOD::TruthParticleContainer* truthPhotons(nullptr);
133  if(lepton_p4s==0 || photon_p4s==0){
134  ANA_CHECK(evtStore()->retrieve(truthMuons,"TruthMuons"));
135  ANA_CHECK(evtStore()->retrieve(truthElectrons,"TruthElectrons"));
136  ANA_CHECK(evtStore()->retrieve(truthPhotons, "TruthPhotons"));
137  }
138 
139  // relevant photons and leptons identified
140  if(lepton_p4s==0){
141  std::vector<TLorentzVector> muonsOut=getLeptonP4s(*truthMuons);
142  std::vector<TLorentzVector> electronsOut=getLeptonP4s(*truthElectrons);
143  leptons_out.insert(leptons_out.end(),muonsOut.begin(),muonsOut.end());
144  leptons_out.insert(leptons_out.end(),electronsOut.begin(),electronsOut.end());
145  }
146  else{
147  if(lepton_origins!=0){
148  leptons_out = filterLeptonOrigins(*lepton_p4s,*lepton_origins);
149  }
150  else{
151  leptons_out = *lepton_p4s;
152  }
153  }
154  if(photon_p4s==0){
155  photons_out = getPhotonP4s(*truthPhotons);
156  }
157  else{
158  if(photon_origins!=0){
159  photons_out = filterPhotonOrigins(*photon_p4s,*photon_origins);
160  }
161  else{
162  photons_out = *photon_p4s;
163  }
164  }
165 
166  ATH_MSG_DEBUG("VGammaORTool::setInput" << ": Found " << photons_out.size() << " photons.");
167  ATH_MSG_DEBUG("VGammaORTool::setInput" << ": Found " << leptons_out.size() << " leptons.");
168 
169  if (m_n_leptons >=0 && int(leptons_out.size()) < m_n_leptons) {
171  "VGammaORTool::setInput" << ": Found " << leptons_out.size() << " leptons but expected " << m_n_leptons << ".");
172  }
173 
174  return StatusCode::SUCCESS;
175 }

◆ sysInitialize()

virtual StatusCode AthCommonDataStore< AthCommonMsg< AlgTool > >::sysInitialize ( )
overridevirtualinherited

Perform system initialization for an algorithm.

We override this to declare all the elements of handle key arrays at the end of initialization. See comments on updateVHKA.

Reimplemented in DerivationFramework::CfAthAlgTool, AthCheckedComponent< AthAlgTool >, AthCheckedComponent<::AthAlgTool >, and asg::AsgMetadataTool.

◆ sysStart()

virtual StatusCode AthCommonDataStore< AthCommonMsg< AlgTool > >::sysStart ( )
overridevirtualinherited

Handle START transition.

We override this in order to make sure that conditions handle keys can cache a pointer to the conditions container.

◆ updateVHKA()

void AthCommonDataStore< AthCommonMsg< AlgTool > >::updateVHKA ( Gaudi::Details::PropertyBase &  )
inlineinherited

Definition at line 308 of file AthCommonDataStore.h.

308  {
309  // debug() << "updateVHKA for property " << p.name() << " " << p.toString()
310  // << " size: " << m_vhka.size() << endmsg;
311  for (auto &a : m_vhka) {
312  std::vector<SG::VarHandleKey*> keys = a->keys();
313  for (auto k : keys) {
314  k->setOwner(this);
315  }
316  }
317  }

Member Data Documentation

◆ m_abs_pdgids_excluded_from_iso

std::vector<int> VGammaORTool::m_abs_pdgids_excluded_from_iso
private

Definition at line 193 of file VGammaORTool.h.

◆ m_detStore

StoreGateSvc_t AthCommonDataStore< AthCommonMsg< AlgTool > >::m_detStore
privateinherited

Pointer to StoreGate (detector store by default)

Definition at line 393 of file AthCommonDataStore.h.

◆ m_dR_lepton_photon_cut

float VGammaORTool::m_dR_lepton_photon_cut
private

Definition at line 180 of file VGammaORTool.h.

◆ m_dR_lepton_photon_cuts

std::vector<float> VGammaORTool::m_dR_lepton_photon_cuts
private

Definition at line 182 of file VGammaORTool.h.

◆ m_evtStore

StoreGateSvc_t AthCommonDataStore< AthCommonMsg< AlgTool > >::m_evtStore
privateinherited

Pointer to StoreGate (event store by default)

Definition at line 390 of file AthCommonDataStore.h.

◆ m_frixione_dR

float VGammaORTool::m_frixione_dR
private

Definition at line 187 of file VGammaORTool.h.

◆ m_frixione_epsilon

float VGammaORTool::m_frixione_epsilon
private

Definition at line 191 of file VGammaORTool.h.

◆ m_frixione_exponent

float VGammaORTool::m_frixione_exponent
private

Definition at line 189 of file VGammaORTool.h.

◆ m_lepton_pdgIds

std::vector<int> VGammaORTool::m_lepton_pdgIds
private

Definition at line 161 of file VGammaORTool.h.

◆ m_lepton_veto_origins

std::vector<int> VGammaORTool::m_lepton_veto_origins
private

Definition at line 169 of file VGammaORTool.h.

◆ m_min_considered_photon_pT

float VGammaORTool::m_min_considered_photon_pT
private

Definition at line 196 of file VGammaORTool.h.

◆ m_n_leptons

int VGammaORTool::m_n_leptons
private

Definition at line 158 of file VGammaORTool.h.

◆ m_photon_pT_cuts

std::vector<float> VGammaORTool::m_photon_pT_cuts
private

Definition at line 178 of file VGammaORTool.h.

◆ m_preferred_lepton_origins

std::vector<int> VGammaORTool::m_preferred_lepton_origins
private

Definition at line 166 of file VGammaORTool.h.

◆ m_truthClassifier

asg::AnaToolHandle<MCTruthClassifier> VGammaORTool::m_truthClassifier
private

Definition at line 150 of file VGammaORTool.h.

◆ m_use_gamma_iso

bool VGammaORTool::m_use_gamma_iso
private

Definition at line 185 of file VGammaORTool.h.

◆ m_varHandleArraysDeclared

bool AthCommonDataStore< AthCommonMsg< AlgTool > >::m_varHandleArraysDeclared
privateinherited

Definition at line 399 of file AthCommonDataStore.h.

◆ m_veto_photon_origins

std::vector<int> VGammaORTool::m_veto_photon_origins
private

Definition at line 175 of file VGammaORTool.h.

◆ m_vhka

std::vector<SG::VarHandleKeyArray*> AthCommonDataStore< AthCommonMsg< AlgTool > >::m_vhka
privateinherited

Definition at line 398 of file AthCommonDataStore.h.


The documentation for this class was generated from the following files:
python.PyKernel.retrieve
def retrieve(aClass, aKey=None)
Definition: PyKernel.py:110
VGammaORTool::filterLeptonOrigins
std::vector< TLorentzVector > filterLeptonOrigins(const std::vector< TLorentzVector > &, const std::vector< int > &) const
Definition: VGammaORTool.cxx:202
xAOD::TruthParticle_v1::parent
const TruthParticle_v1 * parent(size_t i=0) const
Retrieve the i-th mother (TruthParticle) of this TruthParticle.
Definition: TruthParticle_v1.cxx:131
VGammaORTool::m_photon_pT_cuts
std::vector< float > m_photon_pT_cuts
Definition: VGammaORTool.h:178
asg::AsgTool
Base class for the dual-use tool implementation classes.
Definition: AsgTool.h:47
get_generator_info.result
result
Definition: get_generator_info.py:21
StateLessPT_NewConfig.proxy
proxy
Definition: StateLessPT_NewConfig.py:392
ATH_MSG_INFO
#define ATH_MSG_INFO(x)
Definition: AthMsgStreamMacros.h:31
find
std::string find(const std::string &s)
return a remapped string
Definition: hcg.cxx:135
VGammaORTool::checkPhotonPts
bool checkPhotonPts(const std::vector< float > &photon_pts) const
Definition: VGammaORTool.cxx:333
AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T > &t)
Definition: AthCommonDataStore.h:145
TRTCalib_cfilter.p1
p1
Definition: TRTCalib_cfilter.py:130
PlotCalibFromCool.begin
begin
Definition: PlotCalibFromCool.py:94
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_evtStore
StoreGateSvc_t m_evtStore
Pointer to StoreGate (event store by default)
Definition: AthCommonDataStore.h:390
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_vhka
std::vector< SG::VarHandleKeyArray * > m_vhka
Definition: AthCommonDataStore.h:398
ANA_CHECK
#define ANA_CHECK(EXP)
check whether the given expression was successful
Definition: Control/AthToolSupport/AsgMessaging/AsgMessaging/MessageCheck.h:324
UploadAMITag.l
list l
Definition: UploadAMITag.larcaf.py:158
SG::ConstAccessor< unsigned int >
python.TurnDataReader.dr
dr
Definition: TurnDataReader.py:112
VGammaORTool::photonPtsOutsideDrs
virtual StatusCode photonPtsOutsideDrs(std::map< float, std::vector< float > > &result, const std::vector< TLorentzVector > *leptons=0, const std::vector< TLorentzVector > *photons=0, const std::vector< int > *lepton_origins=0, const std::vector< int > *photon_origins=0) const override
Determine the pTs of photons outside of several dR cuts that are configured in tool initialization (d...
Definition: VGammaORTool.cxx:76
read_hist_ntuple.t
t
Definition: read_hist_ntuple.py:5
dbg::ptr
void * ptr(T *p)
Definition: SGImplSvc.cxx:74
VGammaORTool::m_frixione_dR
float m_frixione_dR
Definition: VGammaORTool.h:187
HepMC::is_same_particle
bool is_same_particle(const T1 &p1, const T2 &p2)
Method to establish if two particles in the GenEvent actually represent the same particle.
Definition: MagicNumbers.h:367
VGammaORTool::m_dR_lepton_photon_cuts
std::vector< float > m_dR_lepton_photon_cuts
Definition: VGammaORTool.h:182
std::sort
void sort(typename DataModel_detail::iterator< DVL > beg, typename DataModel_detail::iterator< DVL > end)
Specialization of sort for DataVector/List.
Definition: DVL_algorithms.h:554
VGammaORTool::m_veto_photon_origins
std::vector< int > m_veto_photon_origins
Definition: VGammaORTool.h:175
mergePhysValFiles.end
end
Definition: DataQuality/DataQualityUtils/scripts/mergePhysValFiles.py:93
python.iconfTool.models.loaders.level
level
Definition: loaders.py:20
SG::VarHandleKeyArray::setOwner
virtual void setOwner(IDataHandleHolder *o)=0
IDTPMcnv.htype
htype
Definition: IDTPMcnv.py:29
AthCommonDataStore< AthCommonMsg< AlgTool > >::evtStore
ServiceHandle< StoreGateSvc > & evtStore()
The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.
Definition: AthCommonDataStore.h:85
VGammaORTool::getPhotonP4s
std::vector< TLorentzVector > getPhotonP4s(const xAOD::TruthParticleContainer &truthParticleContainer) const
Get final state photons from truthParticleContainer A minimum pT cut and isolation is applied accordi...
Definition: VGammaORTool.cxx:299
uint
unsigned int uint
Definition: LArOFPhaseFill.cxx:20
TRTCalib_cfilter.p2
p2
Definition: TRTCalib_cfilter.py:131
xAOD::TruthParticle_v1::nParents
size_t nParents() const
Number of parents of this particle.
Definition: TruthParticle_v1.cxx:122
python.utils.AtlRunQueryDQUtils.p
p
Definition: AtlRunQueryDQUtils.py:210
VGammaORTool::m_frixione_epsilon
float m_frixione_epsilon
Definition: VGammaORTool.h:191
AthCommonDataStore
Definition: AthCommonDataStore.h:52
ATH_MSG_ERROR
#define ATH_MSG_ERROR(x)
Definition: AthMsgStreamMacros.h:33
VGammaORTool::m_lepton_veto_origins
std::vector< int > m_lepton_veto_origins
Definition: VGammaORTool.h:169
CheckAppliedSFs.e3
e3
Definition: CheckAppliedSFs.py:264
HepMC::is_simulation_particle
bool is_simulation_particle(const T &p)
Method to establish if a particle (or barcode) was created during the simulation (TODO update to be s...
Definition: MagicNumbers.h:355
lumiFormat.i
int i
Definition: lumiFormat.py:85
VGammaORTool::photonPtsOutsideDr
virtual StatusCode photonPtsOutsideDr(std::vector< float > &result, const std::vector< TLorentzVector > *leptons=0, const std::vector< TLorentzVector > *photons=0, const std::vector< int > *lepton_origins=0, const std::vector< int > *photon_origins=0) const override
Determine the pTs of photons outside the dR cut that is configured in tool initialization (dR_lepton_...
Definition: VGammaORTool.cxx:62
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
xAOD::TruthParticle_v1
Class describing a truth particle in the MC record.
Definition: TruthParticle_v1.h:37
VGammaORTool::m_use_gamma_iso
bool m_use_gamma_iso
Definition: VGammaORTool.h:185
test_pyathena.parent
parent
Definition: test_pyathena.py:15
python.xAODType.dummy
dummy
Definition: xAODType.py:4
MSG::name
const std::string & name(Level lvl)
Convenience function for translating message levels to strings.
Definition: MsgLevel.cxx:19
VGammaORTool::m_truthClassifier
asg::AnaToolHandle< MCTruthClassifier > m_truthClassifier
Definition: VGammaORTool.h:150
VGammaORTool::isFromTau
bool isFromTau(const xAOD::TruthParticle &lepton, int nRecursions=0) const
Definition: VGammaORTool.cxx:317
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_detStore
StoreGateSvc_t m_detStore
Pointer to StoreGate (detector store by default)
Definition: AthCommonDataStore.h:393
VGammaORTool::frixioneFunc
float frixioneFunc(float dR, float dR0, float exponent, float epsilon) const
Definition: VGammaORTool.cxx:392
DataVector
Derived DataVector<T>.
Definition: DataVector.h:794
isTau
bool isTau(const T &p)
Definition: AtlasPID.h:173
SG::VarHandleKeyArray::renounce
virtual void renounce()=0
SG::HandleClassifier::type
std::conditional< std::is_base_of< SG::VarHandleKeyArray, T >::value, VarHandleKeyArrayType, type2 >::type type
Definition: HandleClassifier.h:54
VGammaORTool::getLeptonP4s
std::vector< TLorentzVector > getLeptonP4s(const xAOD::TruthParticleContainer &truthParticleContainer) const
Get final state leptons from truthParticleContainer Filter function is applied, only leptons from rel...
Definition: VGammaORTool.cxx:245
merge_scale_histograms.doc
string doc
Definition: merge_scale_histograms.py:9
VGammaORTool::setInput
StatusCode setInput(std::vector< TLorentzVector > &leptons_out, std::vector< TLorentzVector > &photons_out, const std::vector< TLorentzVector > *lepton_p4s, const std::vector< TLorentzVector > *photon_p4s, const std::vector< int > *lepton_origins, const std::vector< int > *photon_origins) const
Definition: VGammaORTool.cxx:122
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:228
VGammaORTool::m_abs_pdgids_excluded_from_iso
std::vector< int > m_abs_pdgids_excluded_from_iso
Definition: VGammaORTool.h:193
VGammaORTool::filterPhotonOrigins
std::vector< TLorentzVector > filterPhotonOrigins(const std::vector< TLorentzVector > &, const std::vector< int > &) const
Definition: VGammaORTool.cxx:179
MC::isStable
bool isStable(const T &p)
Identify if the particle is stable, i.e. has not decayed.
Definition: HepMCHelpers.h:45
xAOD::photon
@ photon
Definition: TrackingPrimitives.h:199
a
TList * a
Definition: liststreamerinfos.cxx:10
h
std::sort
void sort(typename std::reverse_iterator< DataModel_detail::iterator< DVL > > beg, typename std::reverse_iterator< DataModel_detail::iterator< DVL > > end, const Compare &comp)
Specialization of sort for DataVector/List.
Definition: DVL_algorithms.h:623
ATH_MSG_WARNING
#define ATH_MSG_WARNING(x)
Definition: AthMsgStreamMacros.h:32
xAOD::EgammaHelpers::isPhoton
bool isPhoton(const xAOD::Egamma *eg)
is the object a photon
Definition: EgammaxAODHelpers.cxx:21
AthCommonMsg< AlgTool >::msg
MsgStream & msg() const
Definition: AthCommonMsg.h:24
SG::VarHandleBase::vhKey
SG::VarHandleKey & vhKey()
Return a non-const reference to the HandleKey.
Definition: StoreGate/src/VarHandleBase.cxx:623
VGammaORTool::frixioneIsolated
virtual bool frixioneIsolated(const xAOD::TruthParticle &photon, const xAOD::TruthParticleContainer &truthParticles, float dR0, float exponent, float epsilon) const override
Function determining whether a photon is frixione isolated from truthParticles Parameters as defined ...
Definition: VGammaORTool.cxx:350
VGammaORTool::m_n_leptons
int m_n_leptons
Definition: VGammaORTool.h:158
python.Bindings.keys
keys
Definition: Control/AthenaPython/python/Bindings.py:798
xAOD::TruthParticle_v1::pdgId
int pdgId() const
PDG ID code.
SG::DataProxy
Definition: DataProxy.h:45
VGammaORTool::m_dR_lepton_photon_cut
float m_dR_lepton_photon_cut
Definition: VGammaORTool.h:180
AthCommonDataStore::declareGaudiProperty
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>
Definition: AthCommonDataStore.h:156
VGammaORTool::m_lepton_pdgIds
std::vector< int > m_lepton_pdgIds
Definition: VGammaORTool.h:161
VGammaORTool::m_frixione_exponent
float m_frixione_exponent
Definition: VGammaORTool.h:189
fitman.k
k
Definition: fitman.py:528
VGammaORTool::m_min_considered_photon_pT
float m_min_considered_photon_pT
Definition: VGammaORTool.h:196
VGammaORTool::m_preferred_lepton_origins
std::vector< int > m_preferred_lepton_origins
Definition: VGammaORTool.h:166