ATLAS Offline Software
Toggle main menu visibility
Loading...
Searching...
No Matches
PhysicsAnalysis
Algorithms
JetAnalysisAlgorithms
Root
JetSelectionAlg.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
//
9
// includes
10
//
11
12
#include <
JetAnalysisAlgorithms/JetSelectionAlg.h
>
13
14
//
15
// method implementations
16
//
17
18
namespace
CP
19
{
20
21
StatusCode JetSelectionAlg ::
22
initialize ()
23
{
24
ANA_CHECK
(
m_selectionTool
.retrieve());
25
ANA_CHECK
(
m_jetHandle
.initialize (
m_systematicsList
));
26
ANA_CHECK
(
m_preselection
.initialize (
m_systematicsList
,
m_jetHandle
,
SG::AllowEmpty
));
27
ANA_CHECK
(
m_selectionHandle
.initialize (
m_systematicsList
,
m_jetHandle
));
28
ANA_CHECK
(
m_systematicsList
.initialize());
29
30
return
StatusCode::SUCCESS;
31
}
32
33
34
35
StatusCode JetSelectionAlg ::
36
execute (
const
EventContext& ctx)
37
{
38
for
(
const
auto
& sys :
m_systematicsList
.systematicsVector())
39
{
40
const
xAOD::JetContainer
*jets =
nullptr
;
41
ANA_CHECK
(
m_jetHandle
.retrieve (jets, sys, ctx));
42
for
(
const
xAOD::Jet
*
jet
: *jets)
43
{
44
if
(
m_preselection
.getBool (*
jet
, sys))
45
{
46
m_selectionHandle
.setBool
47
(*
jet
,
m_selectionTool
->keep(*
jet
), sys);
48
}
49
else
50
{
51
m_selectionHandle
.setBool (*
jet
,
false
, sys);
52
}
53
}
54
}
55
56
return
StatusCode::SUCCESS;
57
}
58
}
ANA_CHECK
#define ANA_CHECK(EXP)
check whether the given expression was successful
Definition
Control/AthToolSupport/AsgMessaging/AsgMessaging/MessageCheck.h:325
JetSelectionAlg.h
CP::JetSelectionAlg::m_selectionTool
ToolHandle< IJetSelector > m_selectionTool
the selection tool
Definition
JetSelectionAlg.h:35
CP::JetSelectionAlg::m_jetHandle
SysReadHandle< xAOD::JetContainer > m_jetHandle
the jet collection we run on
Definition
JetSelectionAlg.h:43
CP::JetSelectionAlg::m_preselection
SysReadSelectionHandle m_preselection
the preselection we apply to our input
Definition
JetSelectionAlg.h:48
CP::JetSelectionAlg::m_systematicsList
SysListHandle m_systematicsList
the systematics list we run
Definition
JetSelectionAlg.h:39
CP::JetSelectionAlg::m_selectionHandle
SysWriteSelectionHandle m_selectionHandle
the decoration for the jet selection
Definition
JetSelectionAlg.h:53
CP
Select isolated Photons, Electrons and Muons.
Definition
Control/xAODRootAccess/xAODRootAccess/TEvent.h:27
SG::AllowEmpty
@ AllowEmpty
Definition
StoreGate/StoreGate/VarHandleKey.h:29
jet
Definition
JetCalibTools_PlotJESFactors.cxx:23
xAOD::Jet
Jet_v1 Jet
Definition of the current "jet version".
Definition
Event/xAOD/xAODJet/xAODJet/Jet.h:17
xAOD::JetContainer
JetContainer_v1 JetContainer
Definition of the current "jet container version".
Definition
JetContainer.h:17
Generated on
for ATLAS Offline Software by
1.17.0