ATLAS Offline Software
Trigger
TrigMonitoring
TrigMuonMonitoring
src
L1MuonMon.cxx
Go to the documentation of this file.
1
/*
2
Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
3
*/
4
5
#include "
L1MuonMon.h
"
6
7
8
L1MuonMon :: L1MuonMon
(
const
std::string&
name
, ISvcLocator* pSvcLocator )
9
:
TrigMuonMonitorAlgorithm
(
name
, pSvcLocator)
10
{}
11
12
13
StatusCode
L1MuonMon :: initialize
(){
14
StatusCode
sc
=
TrigMuonMonitorAlgorithm::initialize
();
15
ATH_CHECK
(
m_MuonRoIContainerKey
.initialize() );
16
return
sc
;
17
}
18
19
20
StatusCode
L1MuonMon :: fillVariables
(
const
EventContext &ctx)
const
{
21
22
ATH_MSG_DEBUG
(
"Filling histograms for "
<<
name
() <<
"..."
);
23
24
SG::ReadHandle<xAOD::MuonRoIContainer>
rois
(
m_MuonRoIContainerKey
, ctx);
25
if
(!
rois
.isValid() ) {
26
ATH_MSG_ERROR
(
"evtStore() does not contain xAOD::MuonRoI collection with name "
<<
m_MuonRoIContainerKey
);
27
return
StatusCode::FAILURE;
28
}
29
30
// variables
31
auto
l1Thres =
Monitored::Scalar<double>
(
"l1Thres"
,-1.0);
32
auto
l1Eta =
Monitored::Scalar<double>
(
"l1Eta"
,-1.0);
33
auto
l1Phi =
Monitored::Scalar<double>
(
"l1Phi"
,-1.0);
34
35
for
(
const
auto
l1mu : *
rois
) {
36
l1Thres = (
float
)l1mu->getThrNumber();
37
l1Eta = l1mu->eta();
38
l1Phi = l1mu->phi();
39
fill
(
"L1MuonMon"
, l1Thres, l1Eta, l1Phi);
40
}
41
42
43
return
StatusCode::SUCCESS;
44
}
45
L1MuonMon::L1MuonMon
L1MuonMon(const std::string &name, ISvcLocator *pSvcLocator)
Definition:
L1MuonMon.cxx:8
SG::ReadHandle
Definition:
StoreGate/StoreGate/ReadHandle.h:70
L1MuonMon::m_MuonRoIContainerKey
SG::ReadHandleKey< xAOD::MuonRoIContainer > m_MuonRoIContainerKey
Definition:
L1MuonMon.h:27
L1MuonMon.h
AthenaPoolTestRead.sc
sc
Definition:
AthenaPoolTestRead.py:27
ATH_MSG_ERROR
#define ATH_MSG_ERROR(x)
Definition:
AthMsgStreamMacros.h:33
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition:
PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition:
AthMsgStreamMacros.h:29
ATH_CHECK
#define ATH_CHECK
Definition:
AthCheckMacros.h:40
TrigMuonMonitorAlgorithm
Base class from which analyzers can define a derived class to do specific analysis.
Definition:
TrigMuonMonitorAlgorithm.h:22
AthMonitorAlgorithm::fill
void fill(const ToolHandle< GenericMonitoringTool > &groupHandle, std::vector< std::reference_wrapper< Monitored::IMonitoredVariable >> &&variables) const
Fills a vector of variables to a group by reference.
name
std::string name
Definition:
Control/AthContainers/Root/debug.cxx:228
L1MuonMon::fillVariables
virtual StatusCode fillVariables(const EventContext &ctx) const override
Function that fills variables by just retrieving containers of trigger objects.
Definition:
L1MuonMon.cxx:20
TriggerTest.rois
rois
Definition:
TriggerTest.py:23
TrigMuonMonitorAlgorithm::initialize
virtual StatusCode initialize() override
initialize
Definition:
TrigMuonMonitorAlgorithm.cxx:13
L1MuonMon::initialize
virtual StatusCode initialize() override
initialize
Definition:
L1MuonMon.cxx:13
Monitored::Scalar
Declare a monitored scalar variable.
Definition:
MonitoredScalar.h:34
readCCLHist.float
float
Definition:
readCCLHist.py:83
Generated on Sun Dec 22 2024 21:13:07 for ATLAS Offline Software by
1.8.18