ATLAS Offline Software
Loading...
Searching...
No Matches
egammaMonitorSuperClusterAlgorithm.cxx
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
3 */
4
6
7egammaMonitorSuperClusterAlgorithm::egammaMonitorSuperClusterAlgorithm( const std::string& name, ISvcLocator* pSvcLocator ):
8 egammaMonitorBaseAlgorithm( name, pSvcLocator )
9
10{}
11
13{
14
16 if (!m_monTool.empty()) CHECK(m_monTool.retrieve());
18 return StatusCode::SUCCESS;
19}
20
21StatusCode egammaMonitorSuperClusterAlgorithm::execute(const EventContext& ctx) const
22{
23
25
26 return StatusCode::SUCCESS;
27}
28
29
31
33 ATH_MSG_DEBUG("Fill cluster quantities: ");
34
35 std::vector<float> et_vec, eta_vec, phi_vec, clusterSize_vec, signalState_vec;
36
37 auto et_col = Monitored::Collection("et" , et_vec);
38 auto eta_col = Monitored::Collection("eta" , eta_vec);
39 auto phi_col = Monitored::Collection("phi", phi_vec);
40 auto clusterSize_col = Monitored::Collection("clusterSize" ,clusterSize_vec);
41 auto signalState_col = Monitored::Collection("signalState" ,signalState_vec);
42
43 for (const auto *const eg : *egammaRec) {
44
45 et_vec.push_back(eg->caloCluster()->et()/Gaudi::Units::GeV);
46 eta_vec.push_back(eg->caloCluster()->eta());
47 phi_vec.push_back(eg->caloCluster()->phi());
48 clusterSize_vec.push_back(eg->caloCluster()->clusterSize());
49 signalState_vec.push_back(eg->caloCluster()->signalState());
50
51 }
52 auto mon = Monitored::Group(m_monTool, et_col,eta_col,phi_col, clusterSize_col,signalState_col);
53 ATH_MSG_DEBUG("SuperCluster - Online Monitoring in Reconstruction ...");
54
55}
#define ATH_CHECK
Evaluate an expression and check for errors.
#define ATH_MSG_DEBUG(x)
#define CHECK(...)
Evaluate an expression and check for errors.
Group of local monitoring quantities and retain correlation when filling histograms
egammaMonitorBaseAlgorithm(const std::string &name, ISvcLocator *pSvcLocator)
virtual StatusCode initialize() override
ToolHandle< GenericMonitoringTool > m_monTool
virtual StatusCode execute(const EventContext &ctx) const override
void fillSuperClusterQuantities(const EventContext &ctx) const
SG::ReadHandleKey< EgammaRecContainer > m_inputEgammaRecContainerKey
egammaMonitorSuperClusterAlgorithm(const std::string &name, ISvcLocator *pSvcLocator)
Represent an egamma object for internal egamma usage during reconstruction.
Definition egammaRec.h:31
ValuesCollection< T > Collection(std::string name, const T &collection)
Declare a monitored (double-convertible) collection.