src
SimTracker
TrackHistory
src
Utils.cc
Go to the documentation of this file.
1
#include "
FWCore/MessageLogger/interface/MessageLogger.h
"
2
#include "
SimTracker/TrackHistory/interface/CMSProcessTypes.h
"
3
#include "
SimTracker/TrackHistory/interface/Utils.h
"
4
5
G4toCMSLegacyProcTypeMap::G4toCMSLegacyProcTypeMap
() {
6
// Geant4Process -> CmsProcess
7
m_map
[0] =
CMS::Primary
;
// "Primary" -> "Primary"
8
m_map
[91] =
CMS::Unknown
;
// "Transportation" -> "Unknown"
9
m_map
[92] =
CMS::Unknown
;
// "CoupleTrans" -> "Unknown" => DOUBLE-CHECK THIS
10
m_map
[1] =
CMS::Unknown
;
// "CoulombScat" -> "Unknown" => DOUBLE-CHECK THIS
11
m_map
[2] =
CMS::EIoni
;
// "Ionisation" -> "EIoni" => WHAT ABOUT MuIoni?
12
m_map
[3] =
CMS::EBrem
;
// "Brems" -> "EBrem" => WHAT ABOUT MuBrem?
13
m_map
[4] =
CMS::MuPairProd
;
// "PairProdCharged" -> "MuPairProd" => DOUBLE-CHECK THIS
14
m_map
[5] =
CMS::Annihilation
;
// "Annih" -> "Annihilation"
15
m_map
[6] =
CMS::Annihilation
;
// "AnnihToMuMu" -> "Annihilation"
16
m_map
[7] =
CMS::Annihilation
;
// "AnnihToHad" -> "Annihilation"
17
m_map
[8] =
CMS::Hadronic
;
// "NuclearStopp" -> "Hadronic" => DOUBLE-CHECK THIS
18
m_map
[10] =
CMS::Unknown
;
// "Msc" -> "Unknown" => DOUBLE-CHECK THIS
19
m_map
[11] =
CMS::Unknown
;
// "Rayleigh" -> "Unknown" => DOUBLE-CHECK THIS
20
m_map
[12] =
CMS::Photon
;
// "PhotoElectric" -> "Photon"
21
m_map
[13] =
CMS::Compton
;
// "Compton" -> "Compton"
22
m_map
[14] =
CMS::Conversions
;
// "Conv" -> "Conversions"
23
m_map
[15] =
CMS::Conversions
;
// "ConvToMuMu" -> "Conversions"
24
m_map
[21] =
CMS::Unknown
;
// "Cerenkov" -> "Unknown" => DOUBLE-CHECK THIS
25
m_map
[22] =
CMS::Unknown
;
// "Scintillation" -> "Unknown" => DOUBLE-CHECK THIS
26
m_map
[23] =
CMS::SynchrotronRadiation
;
// "SynchRad" -> "SynchrotronRadiation"
27
m_map
[24] =
CMS::SynchrotronRadiation
;
// "TransRad" -> "SynchrotronRadiation"
28
// => DOUBLE-CHECK THIS
29
m_map
[31] =
CMS::Unknown
;
// "OpAbsorp" -> "Unknown" => NOT USED IN CMS
30
m_map
[32] =
CMS::Unknown
;
// "OpBoundary" -> "Unknown" => NOT USED IN CMS
31
m_map
[33] =
CMS::Unknown
;
// "OpRayleigh" -> "Unknown" => NOT USED IN CMS
32
m_map
[34] =
CMS::Unknown
;
// "OpWLS" -> "Unknown" => NOT USED IN CMS
33
m_map
[35] =
CMS::Unknown
;
// "OpMieHG" -> "Unknown" => NOT USED IN CMS
34
m_map
[51] =
CMS::Unknown
;
// "DNAElastic" -> "Unknown" => NOT USED IN CMS
35
m_map
[52] =
CMS::Unknown
;
// "DNAExcit" -> "Unknown" => NOT USED IN CMS
36
m_map
[53] =
CMS::Unknown
;
// "DNAIonisation" -> "Unknown" => NOT USED IN CMS
37
m_map
[54] =
CMS::Unknown
;
// "DNAVibExcit" -> "Unknown" => NOT USED IN CMS
38
m_map
[55] =
CMS::Unknown
;
// "DNAAttachment" -> "Unknown" => NOT USED IN CMS
39
m_map
[56] =
CMS::Unknown
;
// "DNAChargeDec" -> "Unknown" => NOT USED IN CMS
40
m_map
[57] =
CMS::Unknown
;
// "DNAChargeInc" -> "Unknown" => NOT USED IN CMS
41
m_map
[111] =
CMS::Hadronic
;
// "HadElastic" -> "Hadronic"
42
m_map
[121] =
CMS::Hadronic
;
// "HadInelastic" -> "Hadronic"
43
m_map
[131] =
CMS::Hadronic
;
// "HadCapture" -> "Hadronic"
44
m_map
[141] =
CMS::Hadronic
;
// "HadFission" -> "Hadronic"
45
m_map
[151] =
CMS::Hadronic
;
// "HadAtRest" -> "Hadronic"
46
m_map
[161] =
CMS::Hadronic
;
// "HadCEX" -> "Hadronic"
47
m_map
[201] =
CMS::Decay
;
// "Decay" -> "Decay"
48
m_map
[202] =
CMS::Decay
;
// "DecayWSpin" -> "Decay"
49
m_map
[203] =
CMS::Decay
;
// "DecayPiWSpin" -> "Decay"
50
m_map
[210] =
CMS::Decay
;
// "DecayRadio" -> "Decay"
51
m_map
[211] =
CMS::Decay
;
// "DecayUnKnown" -> "Decay"
52
m_map
[231] =
CMS::Decay
;
// "DecayExt" -> "Decay"
53
m_map
[301] =
CMS::Unknown
;
// "GFlash" -> "Unknown"
54
m_map
[401] =
CMS::Unknown
;
// "StepLimiter" -> "Unknown"
55
m_map
[402] =
CMS::Unknown
;
// "UsrSpecCuts" -> "Unknown"
56
m_map
[403] =
CMS::Unknown
;
// "NeutronKiller" -> "Unknown"
57
}
58
59
const
unsigned
int
G4toCMSLegacyProcTypeMap::processId
(
unsigned
int
g4ProcessId)
const
{
60
MapType::const_iterator it =
m_map
.find(g4ProcessId);
61
62
if
(it ==
m_map
.end()) {
63
edm::LogError
(
"UnknownProcessType"
) <<
"Encountered an unknown process type: "
<< g4ProcessId
64
<<
". Mapping it to 'Undefined'."
;
65
return
CMS::Undefined
;
66
}
else
67
return
it->second;
68
}
MessageLogger.h
CMS::Hadronic
Definition:
CMSProcessTypes.h:10
edm::LogError
Log< level::Error, false > LogError
Definition:
MessageLogger.h:123
CMS::Compton
Definition:
CMSProcessTypes.h:12
G4toCMSLegacyProcTypeMap::processId
const unsigned int processId(unsigned int g4ProcessId) const
Definition:
Utils.cc:59
CMS::SynchrotronRadiation
Definition:
CMSProcessTypes.h:21
G4toCMSLegacyProcTypeMap::G4toCMSLegacyProcTypeMap
G4toCMSLegacyProcTypeMap()
Definition:
Utils.cc:5
CMS::Photon
Definition:
CMSProcessTypes.h:17
CMS::Undefined
Definition:
CMSProcessTypes.h:7
CMS::Annihilation
Definition:
CMSProcessTypes.h:13
Utils.h
CMS::Unknown
Definition:
CMSProcessTypes.h:8
CMS::Conversions
Definition:
CMSProcessTypes.h:19
CMS::EIoni
Definition:
CMSProcessTypes.h:14
CMS::Decay
Definition:
CMSProcessTypes.h:11
CMS::EBrem
Definition:
CMSProcessTypes.h:20
CMS::Primary
Definition:
CMSProcessTypes.h:9
CMSProcessTypes.h
G4toCMSLegacyProcTypeMap::m_map
MapType m_map
Definition:
Utils.h:44
CMS::MuPairProd
Definition:
CMSProcessTypes.h:18
Generated for CMSSW Reference Manual by
1.8.14