ATLAS Offline Software
Loading...
Searching...
No Matches
PhotonsLoader.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3
4 This is a subclass of IConstituentsLoader. It is used to load the general Photons from the vertex
5 and extract their features for the NN evaluation.
6*/
7
8#ifndef INDET_PHOTONS_LOADER_H
9#define INDET_PHOTONS_LOADER_H
10
11// local includes
14
15// EDM includes
17#include "xAODEgamma/Photon.h"
19#include "xAODBase/IParticle.h"
20
21// STL includes
22#include <string>
23#include <vector>
24#include <functional>
25#include <exception>
26#include <type_traits>
27#include <regex>
28
30
31 // Subclass for Photons loader inherited from abstract IConstituentsLoader class
33 public:
35 std::tuple<std::string, FlavorTagInference::Inputs, std::vector<const xAOD::IParticle*>> getData(
36 const xAOD::Vertex& vertex) const override ;
37 std::string getName() const override;
38 ConstituentsType getType() const override;
39 protected:
40 // typedefs
42 typedef std::pair<std::string, double> NamedVar;
43 typedef std::pair<std::string, std::vector<double> > NamedSeq;
44 // iparticle typedefs
45 typedef std::vector<const xAOD::Photon*> Photons;
46 typedef std::vector<const xAOD::IParticle*> Particles;
47 typedef std::function<double(const xAOD::Photon*,
49
50 // usings for Photon getter
53 using PartLinks = std::vector<ElementLink<IPC>>;
54 using IPV = std::vector<const xAOD::Photon*>;
55
57
58 std::vector<const xAOD::Photon*> getPhotonsFromVertex(const xAOD::Vertex& vertex) const;
59
62 std::function<IPV(const Vertex&)> m_associator;
63 };
64}
65
66#endif
std::vector< ElementLink< IPC > > PartLinks
std::vector< const xAOD::Photon * > Photons
std::vector< const xAOD::Photon * > getPhotonsFromVertex(const xAOD::Vertex &vertex) const
getter_utils::CustomSequenceGetter< xAOD::Photon > m_customSequenceGetter
std::pair< std::string, std::vector< double > > NamedSeq
std::pair< std::string, double > NamedVar
std::vector< const xAOD::Photon * > IPV
std::vector< const xAOD::IParticle * > Particles
std::function< IPV(const Vertex &)> m_associator
ConstituentsType getType() const override
PhotonsLoader(const ConstituentsInputConfig &cfg)
std::tuple< std::string, FlavorTagInference::Inputs, std::vector< const xAOD::IParticle * > > getData(const xAOD::Vertex &vertex) const override
static PhotonSortVar iparticleSortVar(ConstituentsSortOrder)
std::function< double(const xAOD::Photon *, const Vertex &)> PhotonSortVar
Base class for elements of a container that can have aux data.
Definition AuxElement.h:483
PhotonContainer_v1 PhotonContainer
Definition of the current "photon container version".
Vertex_v1 Vertex
Define the latest version of the vertex class.
Photon_v1 Photon
Definition of the current "egamma version".