ATLAS Offline Software
Loading...
Searching...
No Matches
JetGhostMuonAssociationAlg.cxx
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2026 CERN for the benefit of the ATLAS collaboration
3*/
4
6
7//
8// includes
9//
10
13
14//
15// method implementations
16//
17
18namespace CP
19{
20 StatusCode JetGhostMuonAssociationAlg ::
21 initialize ()
22 {
25 ANA_CHECK (m_systematicsList.initialize());
26 return StatusCode::SUCCESS;
27 }
28
29
30 StatusCode JetGhostMuonAssociationAlg ::
31 execute (const EventContext& ctx)
32 {
33 for (const auto& sys : m_systematicsList.systematicsVector())
34 {
35 xAOD::JetContainer *jets = nullptr;
36 ANA_CHECK (m_jetHandle.getCopy (jets, sys, ctx));
37
38 // associate the ghost muons to the jets (needed by MET muon-jet OR later)
39 const xAOD::MuonContainer* muons = nullptr;
40 ANA_CHECK (m_muonHandle.retrieve (muons, sys, ctx));
41 met::addGhostMuonsToJets(*muons, *jets);
42 }
43
44 return StatusCode::SUCCESS;
45 }
46}
#define ANA_CHECK(EXP)
check whether the given expression was successful
SysCopyHandle< xAOD::JetContainer > m_jetHandle
the jet collection we run on
SysReadHandle< xAOD::MuonContainer > m_muonHandle
SysListHandle m_systematicsList
the systematics list we run
Select isolated Photons, Electrons and Muons.
void addGhostMuonsToJets(const xAOD::MuonContainer &muons, xAOD::JetContainer &jets)
JetContainer_v1 JetContainer
Definition of the current "jet container version".
MuonContainer_v1 MuonContainer
Definition of the current "Muon container version".