ATLAS Offline Software
Tracking
TrkTools
TrkTruthCreatorTools
src
CommonTruthMatchWeights.cxx
Go to the documentation of this file.
1
/*
2
Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
3
*/
4
5
#include "
TrkTruthCreatorTools/CommonTruthMatchWeights.h
"
6
#include "
TrkTruthData/SubDetHitStatistics.h
"
7
8
namespace
Trk
{
9
10
//================================================================
11
CommonTruthMatchWeights::CommonTruthMatchWeights
(
const
std::string&
type
,
12
const
std::string&
name
,
13
const
IInterface*
parent
)
14
:
AthAlgTool
(
type
,
name
,
parent
)
15
, m_subDetWeights(
SubDetHitStatistics
::NUM_SUBDETECTORS)
16
{
17
declareProperty
(
"WeightPixel"
,
m_subDetWeights
[
SubDetHitStatistics::Pixel
] = 1.);
18
declareProperty
(
"WeightSCT"
,
m_subDetWeights
[
SubDetHitStatistics::SCT
] = 1.);
19
declareProperty
(
"WeightTRT"
,
m_subDetWeights
[
SubDetHitStatistics::TRT
] = 1.);
20
declareProperty
(
"WeightMDT"
,
m_subDetWeights
[
SubDetHitStatistics::MDT
] = 1.);
21
declareProperty
(
"WeightRPC"
,
m_subDetWeights
[
SubDetHitStatistics::RPC
] = 1.);
22
declareProperty
(
"WeightTGC"
,
m_subDetWeights
[
SubDetHitStatistics::TGC
] = 1.);
23
declareProperty
(
"WeightCSC"
,
m_subDetWeights
[
SubDetHitStatistics::CSC
] = 1.);
24
}
25
26
//================================================================
27
StatusCode
CommonTruthMatchWeights::initialize
() {
28
MsgStream&
log
=
msg
(MSG::INFO);
29
log
<<
"Weights = ("
;
30
for
(
unsigned
i
=0;
i
<
SubDetHitStatistics::NUM_SUBDETECTORS
;
i
++) {
31
log
<<
m_subDetWeights
[
i
]<<
" "
;
32
}
33
log
<<
")"
<<
endmsg
;
34
35
return
StatusCode::SUCCESS;
36
}
37
38
//================================================================
39
40
}
// namespace Trk
SubDetHitStatistics::SCT
@ SCT
Definition:
SubDetHitStatistics.h:74
AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T > &t)
Definition:
AthCommonDataStore.h:145
SubDetHitStatistics::NUM_SUBDETECTORS
@ NUM_SUBDETECTORS
Definition:
SubDetHitStatistics.h:74
SubDetHitStatistics
Definition:
SubDetHitStatistics.h:34
CommonTruthMatchWeights.h
SubDetHitStatistics::CSC
@ CSC
Definition:
SubDetHitStatistics.h:74
lumiFormat.i
int i
Definition:
lumiFormat.py:85
Trk::CommonTruthMatchWeights::initialize
virtual StatusCode initialize() override
Definition:
CommonTruthMatchWeights.cxx:27
endmsg
#define endmsg
Definition:
AnalysisConfig_Ntuple.cxx:63
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition:
PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
SubDetHitStatistics::MDT
@ MDT
Definition:
SubDetHitStatistics.h:74
test_pyathena.parent
parent
Definition:
test_pyathena.py:15
Trk
Ensure that the ATLAS eigen extensions are properly loaded.
Definition:
FakeTrackBuilder.h:9
SubDetHitStatistics::TGC
@ TGC
Definition:
SubDetHitStatistics.h:74
name
std::string name
Definition:
Control/AthContainers/Root/debug.cxx:221
SubDetHitStatistics.h
SubDetHitStatistics::RPC
@ RPC
Definition:
SubDetHitStatistics.h:74
SubDetHitStatistics::TRT
@ TRT
Definition:
SubDetHitStatistics.h:74
python.CaloScaleNoiseConfig.type
type
Definition:
CaloScaleNoiseConfig.py:78
AthCommonMsg< AlgTool >::msg
MsgStream & msg() const
Definition:
AthCommonMsg.h:24
python.CaloCondTools.log
log
Definition:
CaloCondTools.py:20
Trk::CommonTruthMatchWeights::m_subDetWeights
std::vector< double > m_subDetWeights
Definition:
CommonTruthMatchWeights.h:29
AthAlgTool
Definition:
AthAlgTool.h:26
SubDetHitStatistics::Pixel
@ Pixel
Definition:
SubDetHitStatistics.h:74
Trk::CommonTruthMatchWeights::CommonTruthMatchWeights
CommonTruthMatchWeights(const std::string &type, const std::string &name, const IInterface *parent)
Definition:
CommonTruthMatchWeights.cxx:11
Generated on Thu Nov 7 2024 21:12:10 for ATLAS Offline Software by
1.8.18