Analysis Software
Documentation for
sPHENIX
simulation software
Home page
Related Pages
Modules
Namespaces
Classes
Files
Examples
External Links
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
Pages
MeasurementCalibration.hpp
Go to the documentation of this file.
Or view
the newest version in sPHENIX GitHub for file MeasurementCalibration.hpp
1
// This file is part of the Acts project.
2
//
3
// Copyright (C) 2023 CERN for the benefit of the Acts project
4
//
5
// This Source Code Form is subject to the terms of the Mozilla Public
6
// License, v. 2.0. If a copy of the MPL was not distributed with this
7
// file, You can obtain one at http://mozilla.org/MPL/2.0/.
8
9
#pragma once
10
11
#include "
Acts/EventData/MultiTrajectory.hpp
"
12
#include "
Acts/EventData/SourceLink.hpp
"
13
#include "
Acts/EventData/VectorMultiTrajectory.hpp
"
14
#include "
Acts/Geometry/GeometryContext.hpp
"
15
#include "
Acts/Utilities/CalibrationContext.hpp
"
16
#include "
ActsExamples/EventData/Cluster.hpp
"
17
#include "
ActsExamples/EventData/IndexSourceLink.hpp
"
18
#include <
ActsExamples/EventData/Measurement.hpp
>
19
20
#include <cassert>
21
22
namespace
Acts {
23
class
VectorMultiTrajectory;
24
}
// namespace Acts
25
26
namespace
ActsExamples {
27
29
class
MeasurementCalibrator
{
30
public
:
31
virtual
void
calibrate
(
32
const
MeasurementContainer
& measurements,
33
const
ClusterContainer
*
clusters
,
const
Acts::GeometryContext
&
gctx
,
34
const
Acts::CalibrationContext
& cctx,
const
Acts::SourceLink
& sourceLink,
35
Acts::VectorMultiTrajectory::TrackStateProxy
& trackState)
const
= 0;
36
37
virtual
~MeasurementCalibrator
() =
default
;
38
virtual
bool
needsClusters
()
const
{
return
false
; }
39
};
40
41
// Calibrator to convert an index source link to a measurement as-is
42
class
PassThroughCalibrator
:
public
MeasurementCalibrator
{
43
public
:
49
void
calibrate
(
50
const
MeasurementContainer
& measurements,
51
const
ClusterContainer
*
clusters
,
const
Acts::GeometryContext
&
gctx
,
52
const
Acts::CalibrationContext
& cctx,
const
Acts::SourceLink
& sourceLink,
53
Acts::VectorMultiTrajectory::TrackStateProxy
& trackState)
const override
;
54
};
55
56
// Adapter class that wraps a MeasurementCalibrator to conform to the
57
// core ACTS calibration interface
58
class
MeasurementCalibratorAdapter
{
59
public
:
60
MeasurementCalibratorAdapter
(
const
MeasurementCalibrator
& calibrator,
61
const
MeasurementContainer
& measurements,
62
const
ClusterContainer
*
clusters
=
nullptr
);
63
64
MeasurementCalibratorAdapter
() =
delete
;
65
66
void
calibrate
(
const
Acts::GeometryContext
&
gctx
,
67
const
Acts::CalibrationContext
& cctx,
68
const
Acts::SourceLink
& sourceLink,
69
Acts::VectorMultiTrajectory::TrackStateProxy
trackState)
const
;
70
71
private
:
72
const
MeasurementCalibrator
&
m_calibrator
;
73
const
MeasurementContainer
&
m_measurements
;
74
const
ClusterContainer
*
m_clusters
;
75
};
76
77
}
// namespace ActsExamples
acts
blob
sPHENIX
Examples
Framework
include
ActsExamples
EventData
MeasurementCalibration.hpp
Built by
Jin Huang
. updated:
Sat Feb 17 2024 22:17:38
using
1.8.2 with
sPHENIX GitHub integration