RecoTracker
SiTrackerMRHTools
plugins
SiTrackerMultiRecHitUpdatorESProducer.cc
Go to the documentation of this file.
1
#include "
RecoTracker/SiTrackerMRHTools/plugins/SiTrackerMultiRecHitUpdatorESProducer.h
"
2
#include "
TrackingTools/Records/interface/TransientRecHitRecord.h
"
3
#include "
RecoTracker/Record/interface/CkfComponentsRecord.h
"
4
5
#include "
FWCore/Framework/interface/EventSetup.h
"
6
#include "
FWCore/Framework/interface/ESHandle.h
"
7
#include "
FWCore/Framework/interface/ModuleFactory.h
"
8
#include "
FWCore/Framework/interface/ESProducer.h
"
9
10
#include <string>
11
#include <memory>
12
13
using namespace
edm
;
14
15
SiTrackerMultiRecHitUpdatorESProducer::SiTrackerMultiRecHitUpdatorESProducer
(
const
edm::ParameterSet
&
p
) {
16
std::string
myname =
p
.getParameter<
std::string
>(
"ComponentName"
);
17
pset_ =
p
;
18
setWhatProduced(
this
, myname);
19
}
20
21
SiTrackerMultiRecHitUpdatorESProducer::~SiTrackerMultiRecHitUpdatorESProducer
() {}
22
23
std::unique_ptr<SiTrackerMultiRecHitUpdator>
SiTrackerMultiRecHitUpdatorESProducer::produce
(
24
const
MultiRecHitRecord
& iRecord) {
25
std::vector<double> annealingProgram = pset_.getParameter<std::vector<double> >(
"AnnealingProgram"
);
26
float
Chi2Cut1D = pset_.getParameter<
double
>(
"ChiSquareCut1D"
);
27
float
Chi2Cut2D = pset_.getParameter<
double
>(
"ChiSquareCut2D"
);
28
29
edm::ESHandle<TransientTrackingRecHitBuilder>
hbuilder;
30
std::string
sname = pset_.getParameter<
std::string
>(
"TTRHBuilder"
);
31
iRecord.
getRecord
<
TransientRecHitRecord
>().
get
(sname, hbuilder);
32
std::string
hitpropagator = pset_.getParameter<
std::string
>(
"HitPropagator"
);
33
edm::ESHandle<TrackingRecHitPropagator>
hhitpropagator;
34
iRecord.
getRecord
<
CkfComponentsRecord
>().getRecord<TrackingComponentsRecord>().
get
(hitpropagator, hhitpropagator);
35
36
bool
debug
= pset_.getParameter<
bool
>(
"Debug"
);
37
//_updator = std::make_unique<SiTrackerMultiRecHitUpdator>(pDD.product(), pp, sp, mp, annealingProgram);
38
// _updator = std::make_unique<SiTrackerMultiRecHitUpdator>(hhitpropagator.product(),annealingProgram);
39
return
std::make_unique<SiTrackerMultiRecHitUpdator>(
40
hbuilder.product(), hhitpropagator.product(), Chi2Cut1D, Chi2Cut2D, annealingProgram,
debug
);
41
}
edm::eventsetup::DependentRecordImplementation::getRecord
const DepRecordT getRecord() const
Definition:
DependentRecordImplementation.h:51
MultiRecHitRecord
Definition:
MultiRecHitRecord.h:12
ESHandle.h
edm
HLT enums.
Definition:
AlignableModifier.h:19
AlCaHLTBitMon_ParallelJobs.p
p
Definition:
AlCaHLTBitMon_ParallelJobs.py:153
TransientRecHitRecord.h
TransientRecHitRecord
Definition:
TransientRecHitRecord.h:14
ESProducer.h
CkfComponentsRecord.h
debug
#define debug
Definition:
HDRShower.cc:19
CkfComponentsRecord
Definition:
CkfComponentsRecord.h:22
edm::ESHandle< TransientTrackingRecHitBuilder >
edm::eventsetup::DependentRecordImplementation::get
ProductT const & get(ESGetToken< ProductT, DepRecordT > const &iToken) const
Definition:
DependentRecordImplementation.h:112
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition:
AlCaHLTBitMon_QueryRunRegistry.py:256
edm::ParameterSet
Definition:
ParameterSet.h:36
edm::get
T const & get(Event const &event, InputTag const &tag) noexcept(false)
Definition:
Event.h:669
SiTrackerMultiRecHitUpdatorESProducer::SiTrackerMultiRecHitUpdatorESProducer
SiTrackerMultiRecHitUpdatorESProducer(const edm::ParameterSet &p)
Definition:
SiTrackerMultiRecHitUpdatorESProducer.cc:15
SiTrackerMultiRecHitUpdatorESProducer::~SiTrackerMultiRecHitUpdatorESProducer
~SiTrackerMultiRecHitUpdatorESProducer() override
Definition:
SiTrackerMultiRecHitUpdatorESProducer.cc:21
SiTrackerMultiRecHitUpdatorESProducer.h
ModuleFactory.h
SiTrackerMultiRecHitUpdatorESProducer::produce
std::unique_ptr< SiTrackerMultiRecHitUpdator > produce(const MultiRecHitRecord &)
Definition:
SiTrackerMultiRecHitUpdatorESProducer.cc:23
EventSetup.h
Generated for CMSSW Reference Manual by
1.8.16