CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
AdaptiveVertexReconstructor.h
Go to the documentation of this file.
1 #ifndef _AdaptiveVertexReconstructor_H_
2 #define _AdaptiveVertexReconstructor_H_
3 
7 #include <set>
8 
10 public:
11  /***
12  *
13  * \paramname primcut sigma_cut for the first iteration
14  * (primary vertex)
15  * \paramname seccut sigma_cut for all subsequent vertex fits.
16  * \paramname minweight the minimum weight for a track to
17  * stay in a fitted vertex
18  * \paramname smoothing perform track smoothing?
19  */
20  AdaptiveVertexReconstructor(float primcut = 2.0, float seccut = 6.0, float minweight = 0.5, bool smoothing = false);
21 
23 
32 
33  std::vector<TransientVertex> vertices(const std::vector<reco::TransientTrack> &v) const override;
34 
35  std::vector<TransientVertex> vertices(const std::vector<reco::TransientTrack> &,
36  const reco::BeamSpot &) const override;
37 
38  std::vector<TransientVertex> vertices(const std::vector<reco::TransientTrack> &primaries,
39  const std::vector<reco::TransientTrack> &tracks,
40  const reco::BeamSpot &) const override;
41 
42  AdaptiveVertexReconstructor *clone() const override { return new AdaptiveVertexReconstructor(*this); }
43 
44 private:
48  std::vector<TransientVertex> vertices(const std::vector<reco::TransientTrack> &primaries,
49  const std::vector<reco::TransientTrack> &trks,
50  const reco::BeamSpot &,
51  bool has_primaries,
52  bool usespot) const;
53 
58  void erase(const TransientVertex &newvtx, std::set<reco::TransientTrack> &remainingtrks, float w) const;
59 
64  std::vector<TransientVertex> cleanUpVertices(const std::vector<TransientVertex> &) const;
65 
68  void setupFitters(float primcut, float primT, float primr, float seccut, float secT, float secr, bool smoothing);
69 
70  TransientVertex cleanUp(const TransientVertex &old) const;
71 
72 private:
73  AdaptiveVertexFitter *thePrimaryFitter; // one fitter for the primaries ...
74  AdaptiveVertexFitter *theSecondaryFitter; // ... and one for the rest.
75 
76  // the minimum weight for a track to stay in a vertex.
77  float theMinWeight;
78  // the minimum weight for a track to be considered "significant".
80 };
81 
82 #endif
AdaptiveVertexReconstructor(float primcut=2.0, float seccut=6.0, float minweight=0.5, bool smoothing=false)
TransientVertex cleanUp(const TransientVertex &old) const
auto const & tracks
cannot be loose
void setupFitters(float primcut, float primT, float primr, float seccut, float secT, float secr, bool smoothing)
std::vector< TransientVertex > cleanUpVertices(const std::vector< TransientVertex > &) const
AdaptiveVertexReconstructor * clone() const override
AdaptiveVertexFitter * theSecondaryFitter
std::vector< TransientVertex > vertices(const std::vector< reco::TransientTrack > &v) const override
T w() const
void erase(const TransientVertex &newvtx, std::set< reco::TransientTrack > &remainingtrks, float w) const