Belle II Software development
PXDResultVarSet.h
1/**************************************************************************
2 * basf2 (Belle II Analysis Software Framework) *
3 * Author: The Belle II Collaboration *
4 * *
5 * See git log for contributors and copyright holders. *
6 * This file is licensed under LGPL-3.0, see LICENSE.md. *
7 **************************************************************************/
8#pragma once
9
10#include <tracking/trackFindingCDC/varsets/VarSet.h>
11#include <tracking/trackFindingCDC/varsets/VarNames.h>
12#include <tracking/trackFindingCDC/varsets/FixedSizeNamedFloatTuple.h>
13
14#include <tracking/ckf/pxd/utilities/PXDAdvancer.h>
15
16namespace Belle2 {
21 class CKFToPXDResult;
22
24 constexpr
25 static char const* const pxdResultVarNames[] = {
26 "chi2_vxd_max",
27 "chi2_vxd_min",
28 "chi2_seed",
29 "chi2",
30
31 "number_of_hits",
32
33 "pt",
34 "theta",
35
36 "number_of_holes",
37
38 "last_hit_layer",
39 "first_hit_layer",
40
41 "weight_sum",
42
43 "has_missing_layer_1",
44 "has_missing_layer_2",
45 "has_missing_layer_3",
46 "has_missing_layer_4",
47 "has_missing_layer_5",
48 "has_missing_layer_6",
49
50 "number_of_overlap_hits",
51
52 "distance_to_seed_track",
53 "distance_to_seed_track_xy",
54 };
55
57 class PXDResultVarNames : public TrackFindingCDC::VarNames<CKFToPXDResult> {
58
59 public:
61 // we shouldn't use public member variables but we do want to rewrite all related code using setters/getters
62 // at least tell cppcheck that everything is fine
63 // cppcheck-suppress duplInheritedMember
64 static const size_t nVars = TrackFindingCDC::size(pxdResultVarNames);
65
67 constexpr
68 static char const* getName(int iName)
69 {
70 return pxdResultVarNames[iName];
71 }
72 };
73
78 class PXDResultVarSet : public TrackFindingCDC::VarSet<PXDResultVarNames> {
81
82 public:
83 PXDResultVarSet();
84
85 void initialize() override;
86
88 bool extract(const CKFToPXDResult* object) final;
89
90 private:
93 };
94
95}
Specialized CKF Result for extrapolating into the PXD.
Vehicle class to transport the variable names.
static const size_t nVars
Number of variables to be generated.
static constexpr char const * getName(int iName)
Get the name of the column.
TrackFindingCDC::VarSet< PXDResultVarNames > Super
Type of the base class.
void initialize() override
Receive and dispatch signal before the start of the event processing.
PXDAdvancer m_advancer
Findlet for advancing.
bool extract(const CKFToPXDResult *object) final
Generate and assign the variables from the object.
Class that specifies the names of the variables.
Definition VarNames.h:21
Generic class that generates some named float values from a given object.
Definition VarSet.h:36
static constexpr char const *const pxdResultVarNames[]
Names of the variables to be generated.
Advancer PXDAdvancer
The PXD advancer is just a synonym of the normal advancer (but may change in the future).
Definition PXDAdvancer.h:18
Abstract base class for different kinds of events.