File indexing completed on 2024-04-06 12:29:07
0001 #include "RecoVertex/GaussianSumVertexFit/interface/AdaptiveGsfVertexFitter.h"
0002 #include "RecoVertex/VertexTools/interface/DummyVertexSmoother.h"
0003 #include "RecoVertex/GaussianSumVertexFit/interface/GsfVertexSmoother.h"
0004 #include "RecoVertex/GaussianSumVertexFit/interface/MultiPerigeeLTSFactory.h"
0005 #include "RecoVertex/GaussianSumVertexFit/interface/GsfVertexTrackCompatibilityEstimator.h"
0006 #include "RecoVertex/VertexTools/interface/GeometricAnnealing.h"
0007
0008 AdaptiveGsfVertexFitter::AdaptiveGsfVertexFitter(const edm::ParameterSet& pSet, const LinearizationPointFinder& linP) {
0009 bool limitComponents_ = pSet.getParameter<bool>("limitComponents");
0010
0011 DeepCopyPointerByClone<GsfVertexMerger> theMerger;
0012
0013 if (limitComponents_) {
0014 theMerger = new GsfVertexMerger(pSet.getParameter<edm::ParameterSet>("GsfMergerParameters"));
0015 }
0016
0017 theFitter = new AdaptiveVertexFitter(GeometricAnnealing(),
0018 linP,
0019 GsfVertexUpdator(limitComponents_, &*theMerger),
0020 GsfVertexTrackCompatibilityEstimator(),
0021 GsfVertexSmoother(limitComponents_, &*theMerger),
0022 MultiPerigeeLTSFactory());
0023 theFitter->gsfIntermediarySmoothing(true);
0024
0025
0026
0027
0028
0029
0030
0031
0032
0033
0034
0035
0036 theFitter->setParameters(pSet.getParameter<double>("maxshift"),
0037 pSet.getParameter<double>("maxlpshift"),
0038 pSet.getParameter<int>("maxstep"),
0039 pSet.getParameter<double>("weightthreshold"));
0040 }
0041
0042 AdaptiveGsfVertexFitter::AdaptiveGsfVertexFitter(const AdaptiveGsfVertexFitter& original) {
0043 theFitter = original.theFitter->clone();
0044 }
0045
0046 AdaptiveGsfVertexFitter::~AdaptiveGsfVertexFitter() { delete theFitter; }