ATLAS Offline Software
Toggle main menu visibility
Loading...
Searching...
No Matches
Trigger
TrigT1
L1Topo
L1TopoAlgorithms
Root
METCut.cxx
Go to the documentation of this file.
1
/*
2
Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
3
*/
4
/*********************************
5
* METCut.cpp
6
* Created by Joerg Stelzer on 11/16/12.
7
*
8
* @brief algorithm calculates the phi-distance between one or two lists and applies delta-phi criteria
9
*
10
* @param NumberLeading
11
**********************************/
12
13
#include <cmath>
14
15
#include "
L1TopoAlgorithms/METCut.h
"
16
#include "
L1TopoCommon/Exception.h
"
17
#include "
L1TopoInterfaces/Decision.h
"
18
19
#include "
L1TopoEvent/MetTOB.h
"
20
21
REGISTER_ALG_TCS
(METCut)
22
23
24
TCS
::
METCut
::
METCut
(
const
std
::
string
&
name
) :
DecisionAlg
(
name
)
25
{
26
defineParameter
(
"XE"
,0);
27
setNumberOutputBits
(1);
28
}
29
30
TCS::METCut::~METCut
(){}
31
32
33
TCS::StatusCode
34
TCS::METCut::initialize
() {
35
p_XE
=
parameter
(
"XE"
).value();
36
TRG_MSG_INFO
(
"XE : "
<<
p_XE
);
37
TRG_MSG_INFO
(
"nummber output : "
<<
numberOutputBits
());
38
return
StatusCode::SUCCESS
;
39
}
40
41
42
43
TCS::StatusCode
44
TCS::METCut::processBitCorrect
(
const
std::vector<TCS::TOBArray const *> & input,
45
const
std::vector<TCS::TOBArray *> & output,
46
Decision
& decision )
47
48
{
49
return
process
(input,output,decision);
50
}
51
52
53
TCS::StatusCode
54
TCS::METCut::process
(
const
std::vector<TCS::TOBArray const *> & input,
55
const
std::vector<TCS::TOBArray *> &
/*output*/
,
56
Decision
& decision )
57
{
58
59
if
(input.size()!=1) {
60
TCS_EXCEPTION
(
"METCut alg must have exactly one input list (MET list), but got "
<< input.size());
61
}
62
63
if
(input[0]->
size
()!=1) {
64
TCS_EXCEPTION
(
"METCut alg needs input list with a single MET TOB, got "
<< input[0]->
size
());
65
}
66
67
const
TCS::GenericTOB
&
met
= (*input[0])[0];
68
69
TRG_MSG_DEBUG
(
"Comparing MET "
<<
met
.Et() <<
" with cut "
<<
p_XE
<<
". "
<< (
met
.Et() >=
p_XE
?
"Pass"
:
"Fail"
));
70
71
72
decision.
setBit
(0,
met
.Et() >=
p_XE
);
73
74
return
TCS::StatusCode::SUCCESS
;
75
}
REGISTER_ALG_TCS
#define REGISTER_ALG_TCS(CLASS)
Definition
AlgFactory.h:62
Decision.h
METCut.h
MetTOB.h
size
size_t size() const
Number of registered mappings.
TRG_MSG_INFO
#define TRG_MSG_INFO(x)
Definition
Trigger/TrigConfiguration/TrigConfBase/TrigConfBase/MsgStreamMacros.h:27
TRG_MSG_DEBUG
#define TRG_MSG_DEBUG(x)
Definition
Trigger/TrigConfiguration/TrigConfBase/TrigConfBase/MsgStreamMacros.h:25
Exception.h
TCS_EXCEPTION
#define TCS_EXCEPTION(MSG)
Definition
Trigger/TrigT1/L1Topo/L1TopoCommon/L1TopoCommon/Exception.h:15
TCS::ConfigurableAlg::name
const std::string & name() const
Definition
ConfigurableAlg.h:49
TCS::ConfigurableAlg::parameter
const Parameter & parameter(std::string_view parameterName) const
Definition
ConfigurableAlg.cxx:245
TCS::ConfigurableAlg::defineParameter
void defineParameter(std::string_view name, TCS::parType_t value)
Definition
ConfigurableAlg.cxx:203
TCS::DecisionAlg::setNumberOutputBits
void setNumberOutputBits(unsigned int numberOutputBits)
Definition
DecisionAlg.h:39
TCS::DecisionAlg::DecisionAlg
DecisionAlg(const std::string &name)
Definition
DecisionAlg.h:24
TCS::DecisionAlg::numberOutputBits
unsigned int numberOutputBits() const
Definition
DecisionAlg.h:38
TCS::Decision
Definition
Decision.h:19
TCS::Decision::setBit
void setBit(unsigned int index, bool value)
Definition
Decision.cxx:12
TCS::GenericTOB
Definition
GenericTOB.h:35
TCS::METCut::processBitCorrect
virtual StatusCode processBitCorrect(const std::vector< TCS::TOBArray const * > &input, const std::vector< TCS::TOBArray * > &output, Decision &decison)
Definition
METCut.cxx:44
TCS::METCut::METCut
METCut(const std::string &name)
Definition
METCut.cxx:24
TCS::METCut::process
virtual StatusCode process(const std::vector< TCS::TOBArray const * > &input, const std::vector< TCS::TOBArray * > &output, Decision &decison)
Definition
METCut.cxx:54
TCS::METCut::~METCut
virtual ~METCut()
Definition
METCut.cxx:30
TCS::METCut::initialize
virtual StatusCode initialize()
Definition
METCut.cxx:34
TCS::METCut::p_XE
parType_t p_XE
Definition
METCut.h:36
TCS::StatusCode
Definition
Trigger/TrigT1/L1Topo/L1TopoCommon/L1TopoCommon/StatusCode.h:15
TCS::StatusCode::SUCCESS
@ SUCCESS
Definition
Trigger/TrigT1/L1Topo/L1TopoCommon/L1TopoCommon/StatusCode.h:17
process
const std::string process
Definition
fbtTestBasics.cxx:76
const
TCS
Definition
AnomalyDetectionBDT.h:18
met
Definition
IMETSignificance.h:24
std
STL namespace.
Generated on
for ATLAS Offline Software by
1.17.0