ATLAS Offline Software
Toggle main menu visibility
Loading...
Searching...
No Matches
Tracking
Acts
ActsTrackReconstruction
src
detail
TruthClusterSplittingToolImpl.h
Go to the documentation of this file.
1
/*
2
Copyright (C) 2002-2026 CERN for the benefit of the ATLAS collaboration
3
*/
4
5
#ifndef ACTSTRACKRECONSTRUCTION_TRUTHCLUSTERSPLITTINGTOOL_IMPL_H
6
#define ACTSTRACKRECONSTRUCTION_TRUTHCLUSTERSPLITTINGTOOL_IMPL_H
7
8
#include "
AthenaBaseComps/AthAlgTool.h
"
9
#include "
InDetIdentifier/PixelID.h
"
10
#include "
InDetReadoutGeometry/SiDetectorElement.h
"
11
#include "
StoreGate/ReadHandleKey.h
"
12
#include "
InDetCondTools/ISiLorentzAngleTool.h
"
13
14
#include "
ActsToolInterfaces/IPixelOnTrackCalibratorTool.h
"
15
#include "
PixelClusterCalibrationToolBase.h
"
16
17
#include "
ActsEvent/MeasurementToTruthParticleAssociation.h
"
18
#include "
TrkTruthTrackInterfaces/IAthSelectionTool.h
"
19
20
21
namespace
ActsTrk::detail
{
22
23
template
<
typename
traj_t>
24
class
TruthClusterSplittingCalibrator
;
25
27
struct
TruthClusterSplittingCalibratorOptions
{
28
const
ActsTrk::MeasurementToTruthParticleAssociation
*
m_measToTruth
{};
29
const
IAthSelectionTool
*
m_truthSelectionTool
{};
30
};
31
33
template
<
typename
traj_t>
34
class
TruthClusterSplittingCalibrator
35
:
public
PixelClusterCalibratorBase
<TruthClusterSplittingCalibrator<traj_t>, traj_t>
36
{
37
public
:
38
using
BASE
=
PixelClusterCalibratorBase<TruthClusterSplittingCalibrator<traj_t>
, traj_t>;
39
friend
BASE
;
40
41
TruthClusterSplittingCalibrator
(
PixelClusterCalibratorOptionsBase
&&base_options,
42
TruthClusterSplittingCalibratorOptions
&&options)
43
:
BASE
(
std
::move(base_options)),
44
m_options
(
std
::move(options))
45
{}
46
47
std::tuple<typename TruthClusterSplittingCalibrator<traj_t>::BASE::Pos,
48
typename
TruthClusterSplittingCalibrator<traj_t>::BASE::Cov
,
49
unsigned
int
>
50
calibrate
(
const
EventContext& ctx,
51
const
Acts::GeometryContext& gctx,
52
const
Acts::CalibrationContext& cctx,
53
const
xAOD::PixelCluster
& cluster,
54
const
InDetDD::SiDetectorElement
& detElement,
55
const
std::pair<float, float>& angles,
56
const
Acts::Vector2& predicted_local_position)
const
;
57
58
protected
:
59
TruthClusterSplittingCalibratorOptions
m_options
;
60
};
61
67
template
<
typename
traj_t>
68
class
TruthClusterSplittingToolImpl
69
:
public
PixelClusterCalibrationToolBase
<traj_t> {
70
public
:
71
using
BASE
=
PixelClusterCalibrationToolBase<traj_t>
;
72
using
BASE::BASE;
73
74
virtual
StatusCode
initialize
()
override
;
75
76
virtual
std::unique_ptr<PixelOnBoundStateCalibratorBase >
create
(
const
EventContext &ctx)
const override
{
77
return
createOnTrackCalibrator
(ctx);
78
}
79
80
virtual
std::unique_ptr<PixelOnTrackCalibratorBase<traj_t> >
createOnTrackCalibrator
(
const
EventContext &ctx)
const override
{
81
return
std::make_unique<TruthClusterSplittingCalibrator<traj_t> >(this->
createBaseOptions
(ctx),
82
this->
createOptions
(ctx));
83
}
84
85
protected
:
86
87
virtual
TruthClusterSplittingCalibratorOptions
createOptions
(
const
EventContext &ctx)
const
{
88
TruthClusterSplittingCalibratorOptions
options{
89
.m_measToTruth=
getAssociationMap
(ctx),
90
.m_truthSelectionTool=
getTruthSelectionTool
()
91
};
92
return
options;
93
}
94
95
// Read handle key and tool handles
96
SG::ReadHandleKey<ActsTrk::MeasurementToTruthParticleAssociation>
m_associationMap_key
97
{
this
,
"AssociationMapOut"
,
"ITkPixelClustersToTruthParticles"
,
"Association map between measurements and truth particles"
};
98
const
ActsTrk::MeasurementToTruthParticleAssociation
*
getAssociationMap
(
const
EventContext &ctx)
const
;
99
100
ToolHandle<IAthSelectionTool>
m_truthSelectionTool
{
this
,
"TruthSelectionTool"
,
"AthTruthSelectionTool"
,
"Truth selection tool (for efficiencies and resolutions)"
};
101
const
IAthSelectionTool
*
getTruthSelectionTool
()
const
;
102
};
103
104
}
// namespace ActsTrk::detail
105
106
#include "
src/detail/TruthClusterSplittingToolImpl.icc
"
107
108
#endif
AthAlgTool.h
IAthSelectionTool.h
header file for interface of selection tools in this package
IPixelOnTrackCalibratorTool.h
ISiLorentzAngleTool.h
MeasurementToTruthParticleAssociation.h
PixelClusterCalibrationToolBase.h
PixelID.h
This is an Identifier helper class for the Pixel subdetector.
SiDetectorElement.h
ReadHandleKey.h
Property holding a SG store/key/clid from which a ReadHandle is made.
TruthClusterSplittingToolImpl.icc
ActsTrk::MeasurementToTruthParticleAssociation
Definition
MeasurementToTruthParticleAssociation.h:18
ActsTrk::detail::PixelClusterCalibrationToolBase
base class of a Pixel cluster calibration tool In addition to some common functionality provied by Pi...
Definition
PixelClusterCalibrationToolBase.h:138
ActsTrk::detail::PixelClusterCalibrationToolBase::createBaseOptions
PixelClusterCalibratorOptionsBase createBaseOptions(const EventContext &) const
create options needed by the calibrator base class.
Definition
PixelClusterCalibrationToolBase.h:156
ActsTrk::detail::PixelClusterCalibratorBase
Definition
PixelClusterCalibrationToolBase.h:95
ActsTrk::detail::PixelClusterCalibratorBase< TruthClusterSplittingCalibrator< traj_t >, traj_t >::Cov
BASE::Cov Cov
Definition
PixelClusterCalibrationToolBase.h:103
ActsTrk::detail::TruthClusterSplittingCalibrator
the Truth Cluster Splitting Calibrator
Definition
TruthClusterSplittingToolImpl.h:36
ActsTrk::detail::TruthClusterSplittingCalibrator::TruthClusterSplittingCalibrator
TruthClusterSplittingCalibrator(PixelClusterCalibratorOptionsBase &&base_options, TruthClusterSplittingCalibratorOptions &&options)
Definition
TruthClusterSplittingToolImpl.h:41
ActsTrk::detail::TruthClusterSplittingCalibrator::m_options
TruthClusterSplittingCalibratorOptions m_options
Definition
TruthClusterSplittingToolImpl.h:59
ActsTrk::detail::TruthClusterSplittingCalibrator::BASE
PixelClusterCalibratorBase< TruthClusterSplittingCalibrator< traj_t >, traj_t > BASE
Definition
TruthClusterSplittingToolImpl.h:38
ActsTrk::detail::TruthClusterSplittingCalibrator::calibrate
std::tuple< typename TruthClusterSplittingCalibrator< traj_t >::BASE::Pos, typename TruthClusterSplittingCalibrator< traj_t >::BASE::Cov, unsigned int > calibrate(const EventContext &ctx, const Acts::GeometryContext &gctx, const Acts::CalibrationContext &cctx, const xAOD::PixelCluster &cluster, const InDetDD::SiDetectorElement &detElement, const std::pair< float, float > &angles, const Acts::Vector2 &predicted_local_position) const
ActsTrk::detail::TruthClusterSplittingToolImpl
the tool to create the truth clustering calibrator.
Definition
TruthClusterSplittingToolImpl.h:69
ActsTrk::detail::TruthClusterSplittingToolImpl::initialize
virtual StatusCode initialize() override
initializes this base class (must be called by the derived class)
ActsTrk::detail::TruthClusterSplittingToolImpl::createOnTrackCalibrator
virtual std::unique_ptr< PixelOnTrackCalibratorBase< traj_t > > createOnTrackCalibrator(const EventContext &ctx) const override
Definition
TruthClusterSplittingToolImpl.h:80
ActsTrk::detail::TruthClusterSplittingToolImpl::m_truthSelectionTool
ToolHandle< IAthSelectionTool > m_truthSelectionTool
Definition
TruthClusterSplittingToolImpl.h:100
ActsTrk::detail::TruthClusterSplittingToolImpl::createOptions
virtual TruthClusterSplittingCalibratorOptions createOptions(const EventContext &ctx) const
Definition
TruthClusterSplittingToolImpl.h:87
ActsTrk::detail::TruthClusterSplittingToolImpl::m_associationMap_key
SG::ReadHandleKey< ActsTrk::MeasurementToTruthParticleAssociation > m_associationMap_key
Definition
TruthClusterSplittingToolImpl.h:97
ActsTrk::detail::TruthClusterSplittingToolImpl::create
virtual std::unique_ptr< PixelOnBoundStateCalibratorBase > create(const EventContext &ctx) const override
convenience class to create an OnBoundState calibrator from an OnTrack calibrator.
Definition
TruthClusterSplittingToolImpl.h:76
ActsTrk::detail::TruthClusterSplittingToolImpl::BASE
PixelClusterCalibrationToolBase< traj_t > BASE
Definition
TruthClusterSplittingToolImpl.h:71
ActsTrk::detail::TruthClusterSplittingToolImpl::getTruthSelectionTool
const IAthSelectionTool * getTruthSelectionTool() const
ActsTrk::detail::TruthClusterSplittingToolImpl::getAssociationMap
const ActsTrk::MeasurementToTruthParticleAssociation * getAssociationMap(const EventContext &ctx) const
IAthSelectionTool
IAthSelectionTool is a virtual baseclass for selection methods.
Definition
IAthSelectionTool.h:27
InDetDD::SiDetectorElement
Class to hold geometrical description of a silicon detector element.
Definition
SiDetectorElement.h:109
SG::ReadHandleKey
Property holding a SG store/key/clid from which a ReadHandle is made.
Definition
StoreGate/StoreGate/ReadHandleKey.h:40
ActsTrk::detail
Hash functions to pack the source link into unordered_maps / unordered_sets.
Definition
MeasurementCalibratorBase.h:31
std
STL namespace.
xAOD::PixelCluster
PixelCluster_v1 PixelCluster
Define the version of the pixel cluster class.
Definition
Event/xAOD/xAODInDetMeasurement/xAODInDetMeasurement/PixelCluster.h:13
ActsTrk::detail::PixelClusterCalibratorOptionsBase
the base options the options of the options of every PixelClusterCalibrator must be based on
Definition
PixelClusterCalibrationToolBase.h:21
ActsTrk::detail::TruthClusterSplittingCalibratorOptions
Options for the truth cluster splitting calibrator.
Definition
TruthClusterSplittingToolImpl.h:27
ActsTrk::detail::TruthClusterSplittingCalibratorOptions::m_measToTruth
const ActsTrk::MeasurementToTruthParticleAssociation * m_measToTruth
Definition
TruthClusterSplittingToolImpl.h:28
ActsTrk::detail::TruthClusterSplittingCalibratorOptions::m_truthSelectionTool
const IAthSelectionTool * m_truthSelectionTool
Definition
TruthClusterSplittingToolImpl.h:29
Generated on
for ATLAS Offline Software by
1.17.0