CMS 3D CMS Logo

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Modules Pages
ConfigurableMultiVertexFitter.cc
Go to the documentation of this file.
4 // #include "RecoVertex/ConfigurableVertexReco/interface/ConfigurableTrimmedKalmanFinder.h"
6 
7 namespace {
8  edm::ParameterSet mydefaults() {
10  ret.addParameter<double>("sigmacut", 9.0);
11  ret.addParameter<double>("Tini", 8.0);
12  ret.addParameter<double>("ratio", 0.25);
13  ret.addParameter<int>("cheat", 0);
14  edm::ParameterSet nest;
15  nest.addParameter<std::string>("finder", "mbs");
16  ret.addParameter<edm::ParameterSet>("ini", nest);
17  return ret;
18  }
19 
21  return new GeometricAnnealing(
22  m.getParameter<double>("sigmacut"), m.getParameter<double>("Tini"), m.getParameter<double>("ratio"));
23  }
24 
25  const VertexReconstructor* initialiser(const edm::ParameterSet& p) {
26  // std::cout << "[ConfigurableMultiVertexFitter] ini: " << p << std::endl;
28  }
29 } // namespace
30 
32  : theRector(new MultiVertexReconstructor(MultiVertexBSeeder())), theCheater(0) {}
33 
36  m.augment(mydefaults());
37  // print ( m );
38  const AnnealingSchedule* ann = schedule(m);
39  const VertexReconstructor* ini = initialiser(m.getParameter<edm::ParameterSet>("ini"));
40  if (theRector)
41  delete theRector;
42  theRector = new MultiVertexReconstructor(*ini, *ann);
43  theCheater = m.getParameter<int>("cheat");
44  delete ann;
45  delete ini;
46 }
47 
49  if (theRector)
50  delete theRector;
51 }
52 
54  : theRector(o.theRector->clone()), theCheater(o.theCheater) {}
55 
57  return new ConfigurableMultiVertexFitter(*this);
58 }
59 
60 std::vector<TransientVertex> ConfigurableMultiVertexFitter::vertices(const std::vector<reco::TransientTrack>& t,
61  const reco::BeamSpot& s) const {
62  return theRector->vertices(t, s);
63 }
64 
65 std::vector<TransientVertex> ConfigurableMultiVertexFitter::vertices(const std::vector<reco::TransientTrack>& prims,
66  const std::vector<reco::TransientTrack>& secs,
67  const reco::BeamSpot& s) const {
68  return theRector->vertices(prims, secs, s);
69 }
70 
71 std::vector<TransientVertex> ConfigurableMultiVertexFitter::vertices(const std::vector<reco::TransientTrack>& t) const {
72  return theRector->vertices(t);
73 }
74 
76 
78 
79 namespace {
80  const ConfRecoBuilder<ConfigurableMultiVertexFitter> t("mvf", "Multi Vertex Fitter");
81 }
ret
prodAgent to be discontinued
std::vector< TransientVertex > vertices(const std::vector< reco::TransientTrack > &t) const override
void configure(const edm::ParameterSet &) override
void addParameter(std::string const &name, T const &value)
Definition: ParameterSet.h:136
std::vector< TransientVertex > vertices(const std::vector< reco::TransientTrack > &, const reco::BeamSpot &) const override
TEveGeoShape * clone(const TEveElement *element, TEveElement *parent)
Definition: eve_macros.cc:135
ConfigurableMultiVertexFitter * clone() const override
edm::ParameterSet defaults() const override
const MultiVertexReconstructor * theRector