ATLAS Offline Software
xAODJetRetriever.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2025 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 #ifndef JIVEXML_XAODJETRETRIEVER_H
6 #define JIVEXML_XAODJETRETRIEVER_H
7 
8 #include <string>
9 #include <vector>
10 #include <map>
11 
12 #include "JiveXML/IDataRetriever.h"
14 #include "xAODJet/JetContainer.h"
15 #include "AsgTools/AnaToolHandle.h"
17 
18 
19 namespace JiveXML{
20 
36  class xAODJetRetriever : virtual public IDataRetriever,
37  public AthAlgTool {
38 
39  public:
40 
42  xAODJetRetriever(const std::string& type,const std::string& name,const IInterface* parent);
43 
44  virtual StatusCode retrieve(ToolHandle<IFormatTool> &FormatTool);
45  virtual StatusCode initialize();
47  const DataMap getData(const xAOD::JetContainer*, const std::string &jetkey);
49  virtual std::string dataTypeName() const { return m_typeName; };
50 
51  private:
52 
54  const std::string m_typeName = "Jet";
55 
56  SG::ReadHandleKeyArray<xAOD::JetContainer> m_keys {this,"JetCollections", {"AntiKt4EMPFlowJets","AntiKt4EMTopoJets", "AntiKt4LCTopoJets", "AntiKt10LCTopoJets", "AntiKt10UFOCSSKJets"}, "Name of the Jet containers that will be written out to the JiveXML file"};
57 
58  Gaudi::Property<bool> m_writeJetQuality{
59  this, "WriteJetQuality", false, "Write out extended jet quality information. False by default."};
60  Gaudi::Property<std::string> m_tracksName{
61  this, "TracksName", "InDetTrackParticles_xAOD", "Name of the track container to be retrieved"};
62  Gaudi::Property<std::vector<std::string>> m_bTaggerNames{
63  this, "BTaggerNames", {"DL1dv01", "GN2v01"}, "Names of the b-taggers to be retrieved"};
64  Gaudi::Property<std::vector<std::string>> m_CDIPaths{
65  this, "CDIPaths", {"xAODBTaggingEfficiency/13p6TeV/2023-22-13p6TeV-MC21-CDI_Test_2023-08-1_v1.root", "xAODBTaggingEfficiency/13p6TeV/2023-02_MC23_CDI_GN2v01-noSF.root"}, "Paths to the CDI files storing the b-tagger properties"};
66 
67  std::unordered_map<std::string, asg::AnaToolHandle<IBTaggingSelectionTool>> m_btagSelTools;
68  unsigned int m_nTaggers=0;
69 
70  };
71 }
72 #endif
JiveXML::xAODJetRetriever::m_nTaggers
unsigned int m_nTaggers
Definition: xAODJetRetriever.h:68
JiveXML::xAODJetRetriever::m_btagSelTools
std::unordered_map< std::string, asg::AnaToolHandle< IBTaggingSelectionTool > > m_btagSelTools
Definition: xAODJetRetriever.h:67
JiveXML::xAODJetRetriever::getData
const DataMap getData(const xAOD::JetContainer *, const std::string &jetkey)
Puts the variables into a DataMap.
Definition: xAODJetRetriever.cxx:84
SG::HandleKeyArray
Definition: StoreGate/StoreGate/HandleKeyArray.h:38
JiveXML::xAODJetRetriever::m_typeName
const std::string m_typeName
The data type that is generated by this retriever.
Definition: xAODJetRetriever.h:54
JiveXML::DataMap
std::map< std::string, DataVect > DataMap
Definition: DataType.h:59
python.CaloAddPedShiftConfig.type
type
Definition: CaloAddPedShiftConfig.py:42
JiveXML::xAODJetRetriever
Retrieves the Jet objects (AntiKt4TopoEMJets etc.)
Definition: xAODJetRetriever.h:37
JiveXML::xAODJetRetriever::initialize
virtual StatusCode initialize()
Definition: xAODJetRetriever.cxx:28
JiveXML::xAODJetRetriever::xAODJetRetriever
xAODJetRetriever(const std::string &type, const std::string &name, const IInterface *parent)
Standard Constructor.
Definition: xAODJetRetriever.cxx:25
JiveXML::xAODJetRetriever::m_writeJetQuality
Gaudi::Property< bool > m_writeJetQuality
Definition: xAODJetRetriever.h:58
IBTaggingSelectionTool.h
JiveXML::xAODJetRetriever::retrieve
virtual StatusCode retrieve(ToolHandle< IFormatTool > &FormatTool)
For each jet collections retrieve basic parameters.
Definition: xAODJetRetriever.cxx:57
JiveXML::xAODJetRetriever::m_tracksName
Gaudi::Property< std::string > m_tracksName
Definition: xAODJetRetriever.h:60
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
AthAlgTool.h
test_pyathena.parent
parent
Definition: test_pyathena.py:15
JiveXML::IDataRetriever
Interface for all DataRetriever classes, that extract event data from StoreGate and pass them on to a...
Definition: IDataRetriever.h:25
DataVector
Derived DataVector<T>.
Definition: DataVector.h:794
AnaToolHandle.h
JiveXML
This header is shared inbetween the C-style server thread and the C++ Athena ServerSvc.
Definition: BadLArRetriever.cxx:22
JiveXML::xAODJetRetriever::dataTypeName
virtual std::string dataTypeName() const
Return the name of the data type that is generated by this retriever.
Definition: xAODJetRetriever.h:49
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:240
JiveXML::xAODJetRetriever::m_keys
SG::ReadHandleKeyArray< xAOD::JetContainer > m_keys
Definition: xAODJetRetriever.h:56
JetContainer.h
JiveXML::xAODJetRetriever::m_CDIPaths
Gaudi::Property< std::vector< std::string > > m_CDIPaths
Definition: xAODJetRetriever.h:64
AthAlgTool
Definition: AthAlgTool.h:26
JiveXML::xAODJetRetriever::m_bTaggerNames
Gaudi::Property< std::vector< std::string > > m_bTaggerNames
Definition: xAODJetRetriever.h:62
IDataRetriever.h