forked from eic/fun4all_eicdetectors
/
EICPIDDefs.h
61 lines (50 loc) · 1.17 KB
/
EICPIDDefs.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
// Tell emacs that this is a C++ source
// -*- C++ -*-.
#ifndef EICPID_EICPIDDefs_H
#define EICPID_EICPIDDefs_H
#include <climits>
#include <map>
#include <string>
namespace EICPIDDefs
{
// sync PID particle keys to the key of tracks
typedef unsigned int keytype;
static const keytype INVALID_KEY = UINT_MAX;
enum PIDDetector
{
PIDAll = 0,
mRICH = 1,
DIRC = 2,
dRICH_AeroGel = 3,
dRICH_Gas = 4,
GasRICH = 5,
ETTL = 11,
CTTL = 12,
FTTL = 13,
InvalidDetector = -1
};
const std::map<std::string, PIDDetector> PIDDetectorNameMap = {
{"PIDAll", PIDAll},
{"mRICH", mRICH},
{"DIRC", DIRC},
{"dRICH_AeroGel", dRICH_AeroGel},
{"dRICH_Gas", dRICH_Gas},
{"GasRICH", GasRICH},
{"ETTL", ETTL},
{"CTTL", CTTL},
{"FTTL", FTTL}};
// consistent with PDG encoding
enum PIDCandidate
{
ElectronCandiate = 11,
MuonCandiate = 13,
PionCandiate = 211,
KaonCandiate = 321,
ProtonCandiate = 2212,
InvalidCandiate = 0
};
//! convert PID detector node names in to ID number for the container.
PIDDetector getPIDDetector(const std::string& name);
const std::string& getPIDDetectorName(const PIDDetector det);
} // namespace EICPIDDefs
#endif