ATLAS Offline Software
Toggle main menu visibility
Loading...
Searching...
No Matches
PhysicsAnalysis
Algorithms
JetAnalysisAlgorithms
Root
JetGhostMuonAssociationAlg.cxx
Go to the documentation of this file.
1
/*
2
Copyright (C) 2002-2023 CERN for the benefit of the ATLAS collaboration
3
*/
4
6
7
//
8
// includes
9
//
10
11
#include <
JetAnalysisAlgorithms/JetGhostMuonAssociationAlg.h
>
12
#include <
METUtilities/METHelpers.h
>
13
14
//
15
// method implementations
16
//
17
18
namespace
CP
19
{
20
JetGhostMuonAssociationAlg ::
21
JetGhostMuonAssociationAlg (
const
std::string&
name
,
22
ISvcLocator* pSvcLocator)
23
:
AnaAlgorithm
(
name
, pSvcLocator)
24
{
25
}
26
27
28
StatusCode JetGhostMuonAssociationAlg ::
29
initialize ()
30
{
31
ANA_CHECK
(
m_jetHandle
.initialize (
m_systematicsList
));
32
ANA_CHECK
(
m_muonHandle
.initialize (
m_systematicsList
));
33
ANA_CHECK
(
m_systematicsList
.initialize());
34
return
StatusCode::SUCCESS;
35
}
36
37
38
StatusCode JetGhostMuonAssociationAlg ::
39
execute (
const
EventContext& ctx)
40
{
41
for
(
const
auto
& sys :
m_systematicsList
.systematicsVector())
42
{
43
xAOD::JetContainer
*jets =
nullptr
;
44
ANA_CHECK
(
m_jetHandle
.getCopy (jets, sys, ctx));
45
46
// associate the ghost muons to the jets (needed by MET muon-jet OR later)
47
const
xAOD::MuonContainer
* muons =
nullptr
;
48
ANA_CHECK
(
m_muonHandle
.retrieve (muons, sys, ctx));
49
met::addGhostMuonsToJets
(*muons, *jets);
50
}
51
52
return
StatusCode::SUCCESS;
53
}
54
}
ANA_CHECK
#define ANA_CHECK(EXP)
check whether the given expression was successful
Definition
Control/AthToolSupport/AsgMessaging/AsgMessaging/MessageCheck.h:324
JetGhostMuonAssociationAlg.h
METHelpers.h
CP::JetGhostMuonAssociationAlg::m_jetHandle
SysCopyHandle< xAOD::JetContainer > m_jetHandle
the jet collection we run on
Definition
JetGhostMuonAssociationAlg.h:42
CP::JetGhostMuonAssociationAlg::m_muonHandle
SysReadHandle< xAOD::MuonContainer > m_muonHandle
Definition
JetGhostMuonAssociationAlg.h:46
CP::JetGhostMuonAssociationAlg::m_systematicsList
SysListHandle m_systematicsList
the systematics list we run
Definition
JetGhostMuonAssociationAlg.h:38
EL::AnaAlgorithm::AnaAlgorithm
AnaAlgorithm(const std::string &name, ISvcLocator *pSvcLocator)
constructor with parameters
Definition
AnaAlgorithm.cxx:40
CP
Select isolated Photons, Electrons and Muons.
Definition
Control/xAODRootAccess/xAODRootAccess/TEvent.h:27
met::addGhostMuonsToJets
void addGhostMuonsToJets(const xAOD::MuonContainer &muons, xAOD::JetContainer &jets)
Definition
METHelpers.cxx:33
xAOD::name
name
Definition
TriggerMenuJson_v1.cxx:29
xAOD::JetContainer
JetContainer_v1 JetContainer
Definition of the current "jet container version".
Definition
JetContainer.h:17
xAOD::MuonContainer
MuonContainer_v1 MuonContainer
Definition of the current "Muon container version".
Definition
Event/xAOD/xAODMuon/xAODMuon/MuonContainer.h:14
Generated on
for ATLAS Offline Software by
1.17.0