ATLAS Offline Software
HbbTag.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 #ifndef HBB_TAG_H
6 #define HBB_TAG_H
7 
8 namespace lwt {
9  class LightweightGraph;
10 }
11 
13 
14 #include "xAODJet/JetContainer.h"
15 
16 #include <functional>
17 #include <memory>
18 #include <map>
19 
20 namespace FlavorTagDiscriminants {
21 
22  class HbbTag
23  {
24  public:
25  HbbTag(const HbbTagConfig& config);
27  ~HbbTag();
28  void decorate(const xAOD::Jet& jet) const;
29 
30  private:
31  // reading stuff
34  using PartLink = std::vector<ElementLink<xAOD::IParticleContainer>>;
36  using Pg = std::function<std::pair<std::string, double>(const xAOD::Jet&)>;
37  std::vector<Pg> m_fat_jet_getters;
38  std::vector<Pg> m_subjet_getters;
39  size_t m_n_subjets;
41 
42  // calculating stuff
43  std::unique_ptr<lwt::LightweightGraph> m_graph;
44  std::map<std::string, std::map<std::string,double>> m_defaults;
45 
46  // writeing stuff
47  template <typename T>
49  using NodeWriter = std::vector<std::pair<std::string, Decorator<float>>>;
50  std::vector<std::pair<std::string, NodeWriter>> m_outputs;
51  };
52 
53 }
54 
55 #endif
FlavorTagDiscriminants::HbbTag::decorate
void decorate(const xAOD::Jet &jet) const
Definition: HbbTag.cxx:96
FlavorTagDiscriminants::HbbTag::Pg
std::function< std::pair< std::string, double >(const xAOD::Jet &)> Pg
Definition: HbbTag.h:36
FlavorTagDiscriminants::HbbTag::m_defaults
std::map< std::string, std::map< std::string, double > > m_defaults
Definition: HbbTag.h:44
HbbTagConfig.h
FlavorTagDiscriminants::HbbTag::m_outputs
std::vector< std::pair< std::string, NodeWriter > > m_outputs
Definition: HbbTag.h:50
FlavorTagDiscriminants
This file contains "getter" functions used for accessing tagger inputs from the EDM.
Definition: AssociationEnums.h:11
FlavorTagDiscriminants::HbbTag::m_graph
std::unique_ptr< lwt::LightweightGraph > m_graph
Definition: HbbTag.h:43
FlavorTagDiscriminants::HbbTag::m_fat_jet_getters
std::vector< Pg > m_fat_jet_getters
Definition: HbbTag.h:37
FlavorTagDiscriminants::HbbTag::NodeWriter
std::vector< std::pair< std::string, Decorator< float > >> NodeWriter
Definition: HbbTag.h:49
FlavorTagDiscriminants::HbbTag::PartLink
std::vector< ElementLink< xAOD::IParticleContainer > > PartLink
Definition: HbbTag.h:34
SG::ConstAccessor
Helper class to provide constant type-safe access to aux data.
Definition: ConstAccessor.h:54
config
Definition: PhysicsAnalysis/AnalysisCommon/AssociationUtils/python/config.py:1
jet
Definition: JetCalibTools_PlotJESFactors.cxx:23
SG::Decorator
Helper class to provide type-safe access to aux data.
Definition: Decorator.h:58
FlavorTagDiscriminants::HbbTag::m_n_subjets
size_t m_n_subjets
Definition: HbbTag.h:39
FlavorTagDiscriminants::HbbTag::~HbbTag
~HbbTag()
Definition: HbbTag.cxx:94
lwt
Definition: NnClusterizationFactory.h:52
FlavorTagDiscriminants::HbbTag::HbbTag
HbbTag(HbbTag &&)
FlavorTagDiscriminants::HbbTag::m_parent_link
SG::AuxElement::ConstAccessor< JetLink > m_parent_link
Definition: HbbTag.h:33
FlavorTagDiscriminants::HbbTag::HbbTag
HbbTag(const HbbTagConfig &config)
Definition: HbbTag.cxx:49
xAOD::Jet_v1
Class describing a jet.
Definition: Jet_v1.h:57
FlavorTagDiscriminants::HbbTagConfig
Definition: HbbTagConfig.h:13
JetContainer.h
FlavorTagDiscriminants::HbbTag::m_subjet_getters
std::vector< Pg > m_subjet_getters
Definition: HbbTag.h:38
FlavorTagDiscriminants::HbbTag
Definition: HbbTag.h:23
FlavorTagDiscriminants::HbbTag::m_subjet_link_getter
SG::AuxElement::ConstAccessor< PartLink > m_subjet_link_getter
Definition: HbbTag.h:35
FlavorTagDiscriminants::HbbTag::m_min_subjet_pt
double m_min_subjet_pt
Definition: HbbTag.h:40