ATLAS Offline Software
Loading...
Searching...
No Matches
MetSignificanceAlg.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//
10// includes
11//
12
15
16//
17// method implementations
18//
19namespace CP
20{
21
36
37
38
39 StatusCode MetSignificanceAlg ::
40 execute (const EventContext& ctx)
41 {
43
44 for (const auto& sys : m_systematicsList.systematicsVector())
45 {
46 // I'm not sure why this can't be const, but the interface
47 // requires a non-const object
49 ANA_CHECK (m_metHandle.getCopy (met, sys, ctx));
50
51 const xAOD::MissingET *totalMET = (*met)[m_totalMETName];
52 if (totalMET == nullptr)
53 {
54 ANA_MSG_ERROR ("could not find total MET term: " << m_totalMETName);
55 return StatusCode::FAILURE;
56 }
57
58 ANA_CHECK (m_significanceTool->varianceMET (met, evtInfo->averageInteractionsPerCrossing(), m_jetTermName, m_softTermName, m_totalMETName));
59
60 m_significanceDecorHandle.set(*totalMET, m_significanceTool->GetSignificance(), sys);
61
62 if (!m_sigDirectionalDecorHandle.empty())
63 m_sigDirectionalDecorHandle.set(*totalMET, m_significanceTool->GetSigDirectional(), sys);
64
66 m_metOverSqrtSumETDecorHandle.set(*totalMET, m_significanceTool->GetMETOverSqrtSumET(), sys);
67
68 if (!m_metOverSqrtHTDecorHandle.empty())
69 m_metOverSqrtHTDecorHandle.set(*totalMET, m_significanceTool->GetMETOverSqrtHT(), sys);
70 }
71
72 return StatusCode::SUCCESS;
73 }
74}
Handle class for reading from StoreGate.
#define ANA_MSG_ERROR(xmsg,...)
Macro printing error messages.
#define ANA_CHECK(EXP)
check whether the given expression was successful
ToolHandle< IMETSignificance > m_significanceTool
the smearing tool
Gaudi::Property< std::string > m_totalMETName
the key for the final met term
SysListHandle m_systematicsList
the systematics list we run
CP::SysWriteDecorHandle< float > m_sigDirectionalDecorHandle
the decoration for the directional significance
CP::SysWriteDecorHandle< float > m_significanceDecorHandle
the decoration for the significance
Gaudi::Property< std::string > m_softTermName
the key for the soft term
SysCopyHandle< xAOD::MissingETContainer > m_metHandle
the met collection we run on
Gaudi::Property< std::string > m_jetTermName
the key for the jets term
CP::SysWriteDecorHandle< float > m_metOverSqrtHTDecorHandle
the decoration for the METOverSqrtHT
CP::SysWriteDecorHandle< float > m_metOverSqrtSumETDecorHandle
the decoration for METOverSqrtSumET
StatusCode initialize() override
SG::ReadHandleKey< xAOD::EventInfo > m_eventInfoKey
the EventInfo key
Select isolated Photons, Electrons and Muons.
MissingET_v1 MissingET
Version control by type defintion.