ECCE @ EIC Software
Reference for
ECCE @ EIC
simulation and reconstruction software on GitHub
Home page
Related Pages
Modules
Namespaces
Classes
Files
External Links
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
Pages
SvtxHitEval.h
Go to the documentation of this file.
Or view
the newest version in sPHENIX GitHub for file SvtxHitEval.h
1
#ifndef G4EVAL_SVTXHITEVAL_H
2
#define G4EVAL_SVTXHITEVAL_H
3
4
#include "
SvtxTruthEval.h
"
5
6
#include <
trackbase/TrkrDefs.h
>
7
8
#include <map>
9
#include <set>
10
#include <utility>
11
12
class
PHCompositeNode
;
13
14
class
PHG4Hit
;
15
class
PHG4HitContainer
;
16
class
PHG4Particle
;
17
class
PHG4TruthInfoContainer
;
18
19
class
TrkrHitSetContainer
;
20
class
TrkrClusterContainer
;
21
class
TrkrHitTruthAssoc
;
22
23
class
SvtxHitEval
24
{
25
public
:
26
SvtxHitEval
(
PHCompositeNode
* topNode);
27
virtual
~SvtxHitEval
();
28
29
void
next_event
(
PHCompositeNode
* topNode);
30
void
do_caching
(
bool
do_cache)
31
{
32
_do_cache
= do_cache;
33
_trutheval
.
do_caching
(do_cache);
34
}
35
void
set_strict
(
bool
strict)
36
{
37
_strict
= strict;
38
_trutheval
.
set_strict
(strict);
39
}
40
void
set_verbosity
(
int
verbosity)
41
{
42
_verbosity
= verbosity;
43
_trutheval
.
set_verbosity
(verbosity);
44
}
45
46
// access the clustereval (and its cached values)
47
SvtxTruthEval
*
get_truth_eval
() {
return
&
_trutheval
; }
48
49
//PHG4Cell* get_cell(SvtxHit* hit);
50
51
// backtrace through to PHG4Hits
52
std::set<PHG4Hit*>
all_truth_hits
(
TrkrDefs::hitkey
hit_key);
53
PHG4Hit
*
max_truth_hit_by_energy
(
TrkrDefs::hitkey
hit_key);
54
55
// backtrace through to PHG4Particles
56
std::set<PHG4Particle*>
all_truth_particles
(
TrkrDefs::hitkey
hit_key);
57
PHG4Particle
*
max_truth_particle_by_energy
(
TrkrDefs::hitkey
hit_key);
58
59
// forwardtrace through to SvtxHits
60
std::set<TrkrDefs::hitkey>
all_hits_from
(
PHG4Particle
* truthparticle);
61
std::set<TrkrDefs::hitkey>
all_hits_from
(
PHG4Hit
* truthhit);
62
TrkrDefs::hitkey
best_hit_from
(
PHG4Hit
* truthhit);
63
64
// overlap calculations
65
float
get_energy_contribution
(
TrkrDefs::hitkey
,
PHG4Particle
* truthparticle);
66
float
get_energy_contribution
(
TrkrDefs::hitkey
,
PHG4Hit
* truthhit);
67
68
unsigned
int
get_errors
() {
return
_errors
+
_trutheval
.
get_errors
(); }
69
70
private
:
71
void
get_node_pointers
(
PHCompositeNode
* topNode);
72
bool
has_node_pointers
();
73
74
SvtxTruthEval
_trutheval
;
75
TrkrHitSetContainer
*
_hitmap
;
76
TrkrClusterContainer
*
_clustermap
;
77
TrkrHitTruthAssoc
*
_hit_truth_map
;
78
79
PHG4HitContainer
*
_g4hits_tpc
;
80
PHG4HitContainer
*
_g4hits_intt
;
81
PHG4HitContainer
*
_g4hits_mvtx
;
82
PHG4HitContainer
*
_g4hits_mms
;
83
84
PHG4TruthInfoContainer
*
_truthinfo
;
85
86
bool
_strict
;
87
int
_verbosity
;
88
unsigned
int
_errors
;
89
90
bool
_do_cache
;
91
std::map<TrkrDefs::hitkey, std::set<PHG4Hit*> >
_cache_all_truth_hits
;
92
std::map<TrkrDefs::hitkey, PHG4Hit*>
_cache_max_truth_hit_by_energy
;
93
std::map<TrkrDefs::hitkey, std::set<PHG4Particle*> >
_cache_all_truth_particles
;
94
std::map<TrkrDefs::hitkey, PHG4Particle*>
_cache_max_truth_particle_by_energy
;
95
std::map<PHG4Particle*, std::set<TrkrDefs::hitkey> >
_cache_all_hits_from_particle
;
96
std::map<PHG4Hit*, std::set<TrkrDefs::hitkey> >
_cache_all_hits_from_g4hit
;
97
std::map<PHG4Hit*, TrkrDefs::hitkey>
_cache_best_hit_from_g4hit
;
98
std::map<std::pair<TrkrDefs::hitkey, PHG4Particle*>,
float
>
_cache_get_energy_contribution_g4particle
;
99
std::map<std::pair<TrkrDefs::hitkey, PHG4Hit*>,
float
>
_cache_get_energy_contribution_g4hit
;
100
};
101
102
#endif // G4EVAL_SVTXHITEVAL_H
coresoftware
blob
master
simulation
g4simulation
g4eval
SvtxHitEval.h
Built by
Jin Huang
. updated:
Wed Jun 29 2022 17:24:43
using
1.8.2 with
ECCE GitHub integration