Main Page
Namespaces
Classes
Package Documentation
RecoLocalTracker
SiStripClusterizer
src
StripClusterizerAlgorithmFactory.cc
Go to the documentation of this file.
1
#include "
RecoLocalTracker/SiStripClusterizer/interface/StripClusterizerAlgorithmFactory.h
"
2
3
#include "
FWCore/ParameterSet/interface/ParameterSet.h
"
4
#include "
RecoLocalTracker/SiStripClusterizer/interface/StripClusterizerAlgorithm.h
"
5
#include "
RecoLocalTracker/SiStripClusterizer/interface/ThreeThresholdAlgorithm.h
"
6
#include "
RecoLocalTracker/SiStripClusterizer/interface/ClusterChargeCut.h
"
7
8
std::unique_ptr<StripClusterizerAlgorithm>
StripClusterizerAlgorithmFactory::
9
create
(
const
edm::ParameterSet
& conf) {
10
std::string
algorithm
= conf.
getParameter
<
std::string
>(
"Algorithm"
);
11
12
if
(algorithm ==
"ThreeThresholdAlgorithm"
) {
13
return
std::unique_ptr<StripClusterizerAlgorithm>(
14
new
ThreeThresholdAlgorithm
(
15
conf.
getParameter
<
double
>(
"ChannelThreshold"
),
16
conf.
getParameter
<
double
>(
"SeedThreshold"
),
17
conf.
getParameter
<
double
>(
"ClusterThreshold"
),
18
conf.
getParameter
<
unsigned
>(
"MaxSequentialHoles"
),
19
conf.
getParameter
<
unsigned
>(
"MaxSequentialBad"
),
20
conf.
getParameter
<
unsigned
>(
"MaxAdjacentBad"
),
21
conf.
getParameter
<
std::string
>(
"QualityLabel"
),
22
conf.
getParameter
<
bool
>(
"RemoveApvShots"
),
23
clusterChargeCut
(conf)
24
));
25
}
26
27
if
(algorithm ==
"OldThreeThresholdAlgorithm"
) {
28
throw
cms::Exception
(
"[StripClusterizerAlgorithmFactory] obsolete"
)
29
<< algorithm <<
" Obsolete since 7_3_0"
;
30
31
}
32
33
throw
cms::Exception
(
"[StripClusterizerAlgorithmFactory] Unregistered Algorithm"
)
34
<< algorithm <<
" is not a registered StripClusterizerAlgorithm"
;
35
}
edm::ParameterSet::getParameter
T getParameter(std::string const &) const
StripClusterizerAlgorithmFactory::create
static std::unique_ptr< StripClusterizerAlgorithm > create(const edm::ParameterSet &)
Definition:
StripClusterizerAlgorithmFactory.cc:9
StripClusterizerAlgorithmFactory.h
Exception
Definition:
hltDiff.cc:292
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition:
AlCaHLTBitMon_QueryRunRegistry.py:256
clusterChargeCut
float clusterChargeCut(const edm::ParameterSet &conf, const char *name="clusterChargeCut")
Definition:
ClusterChargeCut.h:7
ThreeThresholdAlgorithm.h
ParameterSet.h
ClusterChargeCut.h
edm::ParameterSet
Definition:
ParameterSet.h:36
electronCleaner_cfi.algorithm
algorithm
Definition:
electronCleaner_cfi.py:14
ThreeThresholdAlgorithm
Definition:
ThreeThresholdAlgorithm.h:6
StripClusterizerAlgorithm.h
Generated for CMSSW Reference Manual by
1.8.11