ATLAS Offline Software
Loading...
Searching...
No Matches
TrackCaloClusterRecValidationTool.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
3*/
4#ifndef TRACKCALOCLUSTERREC_TRACKCALOCLUSTERRECVALIDATION_TRACKCALOCLUSTERRECVALIDATIONTOOL_H
5#define TRACKCALOCLUSTERREC_TRACKCALOCLUSTERRECVALIDATION_TRACKCALOCLUSTERRECVALIDATIONTOOL_H
12
14
15//#gaudi includes
16#include "GaudiKernel/ToolHandle.h"
17//EDM includes
19//Athena
20
21//STL includes
22#include <string>
23#include <vector>
24
29
30class TCCPlots;
32
37public:
39 TrackCaloClusterRecValidationTool(const std::string & type, const std::string & name, const IInterface* parent);
45 virtual StatusCode initialize();
46 virtual StatusCode bookHistograms();
47 virtual StatusCode fillHistograms();
48 virtual StatusCode procHistograms();
50private:
53
55 ToolHandleArray<IJetCalibrationTool> m_jetCalibrationTools;
56 std::vector< std::string > m_jetCalibrationCollections;
58
60 const xAOD::JetContainer* calibrateAndRecordShallowCopyJetCollection(const xAOD::JetContainer * jetContainer, const std::string& name);
61
63 const xAOD::Jet* ClusterMatched(const xAOD::Jet* jet, const xAOD::JetContainer* jets);
64 const xAOD::Jet* ClusterMatched(const xAOD::Jet* jet, const std::vector<const xAOD::Jet*>& jets) const;
65
66 // Get a data container; implementation at end of this header file
67 template<class T> const T* getContainer( const std::string & containerName);
68
73
74 std::vector<std::string> m_jetContainerNames;
75
77
80
82 std::string m_dirName;
84 float m_maxEta;
85 float m_minPt;
86 float m_minMass;
87 float m_maxMass;
88
89 std::string m_folder;
90
92
96
97 std::vector<float> m_jetPtBins ;
98 std::vector<float> m_jetMassOverPtBins ;
99 std::vector<float> m_trackPtBins ;
100 std::vector<float> m_trackProdRadiusBins ;
101
105
107 std::vector<std::string> m_TCCCombinedCollectionNames;
110
111 //histograms
112 std::map<std::string, TCCPlots*> m_tccPlots;
113
114 // EventInfo
115 SG::ReadHandleKey<xAOD::EventInfo> m_evt {this, "EvtInfo", "EventInfo", "EventInfo name"};
116};
117
118template<class T>
119inline const T* TrackCaloClusterRecValidationTool::getContainer(const std::string & containerName){
120 const T * ptr = evtStore()->retrieve< const T >( containerName );
121 if (!ptr) {
122 ATH_MSG_WARNING("Container '"<<containerName<<"' could not be retrieved");
123 }
124 return ptr;
125}
126
127#endif //TRACKCALOCLUSTERREC_TRACKCALOCLUSTERRECVALIDATION_TRACKCALOCLUSTERRECVALIDATIONTOOL_H
#define ATH_MSG_WARNING(x)
Property holding a SG store/key/clid from which a ReadHandle is made.
ServiceHandle< StoreGateSvc > & evtStore()
class IJetCalibrationTool
ManagedMonitorToolBase(const std::string &type, const std::string &name, const IInterface *parent)
Property holding a SG store/key/clid from which a ReadHandle is made.
TrackCaloClusterRecValidationTool(const std::string &type, const std::string &name, const IInterface *parent)
Constructor with parameters.
ToolHandleArray< IJetCalibrationTool > m_jetCalibrationTools
calibration tool
virtual ~TrackCaloClusterRecValidationTool()
Destructor.
virtual StatusCode procHistograms()
An inheriting class should either override this function or finalHists().
virtual StatusCode fillHistograms()
An inheriting class should either override this function or fillHists().
virtual StatusCode bookHistograms()
An inheriting class should either override this function or bookHists().
TrackCaloClusterRecValidationTool()
prevent default construction
const xAOD::Jet * ClusterMatched(const xAOD::Jet *jet, const xAOD::JetContainer *jets)
Get the matched jet.
const T * getContainer(const std::string &containerName)
SG::ReadHandleKey< xAOD::EventInfo > m_evt
const xAOD::JetContainer * calibrateAndRecordShallowCopyJetCollection(const xAOD::JetContainer *jetContainer, const std::string &name)
Calibrate and record a shallow copy of a given jet container.
std::map< std::string, TCCPlots * > m_tccPlots
std::string m_truthJetContainerName
Truth jet container's name.
Jet_v1 Jet
Definition of the current "jet version".
JetContainer_v1 JetContainer
Definition of the current "jet container version".