Loading [MathJax]/extensions/tex2jax.js
ATLAS Offline Software
Main Page
Related Pages
Modules
Namespaces
Namespace List
Namespace Members
All
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Functions
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Variables
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Typedefs
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
z
Enumerations
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
z
Enumerator
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Classes
Class List
Class Index
Class Hierarchy
Class Members
All
:
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
~
Functions
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
~
Variables
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Typedefs
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Enumerations
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Enumerator
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Properties
Related Functions
:
a
b
c
d
e
f
g
h
i
j
l
m
n
o
p
r
s
t
v
w
x
z
Files
File List
File Members
All
$
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Functions
_
a
b
c
d
e
f
g
h
i
j
l
m
n
o
p
q
r
s
t
u
v
w
x
z
Variables
$
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Typedefs
a
b
c
d
e
f
g
h
i
j
l
m
n
o
p
q
r
s
t
u
v
w
x
z
Enumerations
a
b
c
d
e
f
g
h
i
l
m
n
o
p
r
s
t
v
x
z
Enumerator
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Macros
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
GitLab
LXR
•
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Properties
Friends
Macros
Modules
Pages
DataQuality
dqm_algorithms
src
AFP_SiTEfficiency.cxx
Go to the documentation of this file.
1
/*
2
Copyright (C) 2002-2025 CERN for the benefit of the ATLAS collaboration
3
*/
4
5
#include "
dqm_algorithms/AFP_SiTEfficiency.h
"
6
7
#include <
dqm_algorithms/tools/AlgorithmHelper.h
>
8
#include <dqm_core/AlgorithmManager.h>
9
#include "dqm_core/AlgorithmConfig.h"
10
#include <dqm_core/exceptions.h>
11
12
#include <TDirectory.h>
13
#include <TH1.h>
14
#include <TH2.h>
15
#include <TEfficiency.h>
16
#include <TFile.h>
17
18
namespace
{
19
static
dqm_algorithms::AFP_SiTEfficiency
instance
;
20
}
21
22
dqm_algorithms::AFP_SiTEfficiency::AFP_SiTEfficiency
() {
23
dqm_core::AlgorithmManager::instance
().registerAlgorithm(
"AFP_SiTEfficiency"
,
this
);
24
}
25
26
dqm_algorithms::AFP_SiTEfficiency::~AFP_SiTEfficiency
() {
27
}
28
29
dqm_algorithms::AFP_SiTEfficiency
*
30
dqm_algorithms::AFP_SiTEfficiency::clone
() {
31
return
new
AFP_SiTEfficiency
();
32
}
33
34
dqm_core::Result
*
35
dqm_algorithms::AFP_SiTEfficiency::execute
(
const
std::string&
name
,
36
const
TObject&
object
,
37
const
dqm_core::AlgorithmConfig&
config
) {
38
if
( !
object
.
IsA
()->InheritsFrom(
"TEfficiency"
) ) {
39
throw
dqm_core::BadConfig( ERS_HERE,
name
,
"does not inherit from TEfficiency"
);
40
}
41
42
auto
histogram
=
static_cast<
const
TEfficiency*
>
( &
object
);
43
44
auto
gthreshold =
static_cast<
uint32_t
>
(
dqm_algorithms::tools::GetFromMap
(
"NEfficiency"
,
config
.getGreenThresholds() ) );
45
auto
rthreshold =
static_cast<
uint32_t
>
(
dqm_algorithms::tools::GetFromMap
(
"NEfficiency"
,
config
.getRedThresholds() ) );
46
float
efficiency
= 0;
47
48
TH1* h_total =
histogram
->GetCopyTotalHisto();
49
TH1* h_passed =
histogram
->GetCopyPassedHisto();
50
51
float
n_total =
float
( h_total->GetEntries() );
52
float
n_passed =
float
( h_passed->GetEntries() );
53
efficiency
= n_passed/n_total*100;
54
55
auto
result
=
new
dqm_core::Result
();
56
57
// publish problematic bins
58
result
->tags_[
"Plane efficiency = "
] =
efficiency
;
59
60
if
(
efficiency
== 0 )
61
result
->status_ =
dqm_core::Result::Undefined
;
62
else
if
(
efficiency
> gthreshold )
63
result
->status_ =
dqm_core::Result::Green
;
64
else
if
( (
efficiency
<= gthreshold ) && (
efficiency
> rthreshold) )
65
result
->status_ = dqm_core::Result::Yellow;
66
else
67
result
->status_ =
dqm_core::Result::Red
;
68
69
return
result
;
70
}
71
72
void
dqm_algorithms::AFP_SiTEfficiency::printDescriptionTo
( std::ostream&
out
) {
73
out
<<
"AFP_SiTEfficiency: Print out if general plane efficiency is less than limit"
<< std::endl;
74
}
dqm_algorithms::AFP_SiTEfficiency::clone
AFP_SiTEfficiency * clone() override
Definition:
AFP_SiTEfficiency.cxx:30
Undefined
@ Undefined
Definition:
MaterialTypes.h:8
get_generator_info.result
result
Definition:
get_generator_info.py:21
IsA
#define IsA
Declare the TObject style functions.
Definition:
xAODTEventBranch.h:59
xAOD::uint32_t
setEventNumber uint32_t
Definition:
EventInfo_v1.cxx:127
python.AthDsoLogger.out
out
Definition:
AthDsoLogger.py:71
dqm_algorithms::AFP_SiTEfficiency::AFP_SiTEfficiency
AFP_SiTEfficiency()
Definition:
AFP_SiTEfficiency.cxx:22
config
Definition:
PhysicsAnalysis/AnalysisCommon/AssociationUtils/python/config.py:1
instance
std::map< std::string, double > instance
Definition:
Run_To_Get_Tags.h:8
efficiency
void efficiency(std::vector< double > &bins, std::vector< double > &values, const std::vector< std::string > &files, const std::string &histname, const std::string &tplotname, const std::string &label="")
Definition:
dependence.cxx:128
dqm_algorithms::AFP_SiTEfficiency::printDescriptionTo
void printDescriptionTo(std::ostream &out) override
Definition:
AFP_SiTEfficiency.cxx:72
dqm_algorithms::AFP_SiTEfficiency::execute
dqm_core::Result * execute(const std::string &name, const TObject &object, const dqm_core::AlgorithmConfig &config) override
Definition:
AFP_SiTEfficiency.cxx:35
Result
ICscStripFitter::Result Result
Definition:
CalibCscStripFitter.cxx:13
python.handimod.Green
int Green
Definition:
handimod.py:524
dqm_algorithms::AFP_SiTEfficiency
Definition:
AFP_SiTEfficiency.h:21
python.handimod.Red
Red
Definition:
handimod.py:551
name
std::string name
Definition:
Control/AthContainers/Root/debug.cxx:240
AFP_SiTEfficiency.h
dqm_algorithms::AFP_SiTEfficiency::~AFP_SiTEfficiency
~AFP_SiTEfficiency()
Definition:
AFP_SiTEfficiency.cxx:26
AlgorithmHelper.h
dqm_algorithms::tools::GetFromMap
const T & GetFromMap(const std::string &pname, const std::map< std::string, T > ¶ms)
Definition:
AlgorithmHelper.h:114
pickleTool.object
object
Definition:
pickleTool.py:30
histogram
std::string histogram
Definition:
chains.cxx:52
python.LArMinBiasAlgConfig.float
float
Definition:
LArMinBiasAlgConfig.py:65
Generated on Tue Apr 22 2025 21:06:55 for ATLAS Offline Software by
1.8.18