CMS 3D CMS Logo

GhostTrackVertexFinder.h
Go to the documentation of this file.
1 #ifndef RecoBTag_GhostTrackVertexFinder_h
2 #define RecoBTag_GhostTrackVertexFinder_h
3 
4 #include <memory>
5 #include <vector>
6 #include <set>
7 
11 
14 
16 
20 
23 
24 namespace reco {
25 
26  class GhostTrack;
27  class GhostTrackFitter;
28 
29  class GhostTrackVertexFinder { // : public VertexReconstructor
30  public:
32 
36 
37  std::vector<TransientVertex> vertices(const reco::Vertex &primaryVertex,
38  const GlobalVector &direction,
39  double coneRadius,
40  const std::vector<TransientTrack> &tracks) const;
41 
42  std::vector<TransientVertex> vertices(const GlobalPoint &primaryPosition,
43  const GlobalError &primaryError,
44  const GlobalVector &direction,
45  double coneRadius,
46  const std::vector<TransientTrack> &tracks) const;
47 
48  std::vector<TransientVertex> vertices(const reco::Vertex &primaryVertex,
49  const GlobalVector &direction,
50  double coneRadius,
51  const reco::BeamSpot &beamSpot,
52  const std::vector<TransientTrack> &tracks) const;
53 
54  std::vector<TransientVertex> vertices(const GlobalPoint &primaryPosition,
55  const GlobalError &primaryError,
56  const GlobalVector &direction,
57  double coneRadius,
58  const reco::BeamSpot &beamSpot,
59  const std::vector<TransientTrack> &tracks) const;
60 
61  std::vector<TransientVertex> vertices(const reco::Vertex &primaryVertex,
62  const GlobalVector &direction,
63  double coneRadius,
64  const reco::BeamSpot &beamSpot,
65  const std::vector<TransientTrack> &primaries,
66  const std::vector<TransientTrack> &tracks) const;
67 
68  std::vector<TransientVertex> vertices(const GlobalPoint &primaryPosition,
69  const GlobalError &primaryError,
70  const GlobalVector &direction,
71  double coneRadius,
72  const reco::BeamSpot &beamSpot,
73  const std::vector<TransientTrack> &primaries,
74  const std::vector<TransientTrack> &tracks) const;
75 
76  std::vector<TransientVertex> vertices(const reco::Vertex &primaryVertex,
77  const reco::Track &ghostTrack,
78  const std::vector<TransientTrack> &tracks,
79  const std::vector<float> &weights = std::vector<float>()) const;
80 
81  std::vector<TransientVertex> vertices(const reco::Vertex &primaryVertex,
82  const reco::Track &ghostTrack,
83  const reco::BeamSpot &beamSpot,
84  const std::vector<TransientTrack> &tracks,
85  const std::vector<float> &weights = std::vector<float>()) const;
86 
87  std::vector<TransientVertex> vertices(const reco::Vertex &primaryVertex,
88  const reco::Track &ghostTrack,
89  const reco::BeamSpot &beamSpot,
90  const std::vector<TransientTrack> &primaries,
91  const std::vector<TransientTrack> &tracks,
92  const std::vector<float> &weights = std::vector<float>()) const;
93 
94  std::vector<TransientVertex> vertices(const GlobalPoint &primaryPosition,
95  const GlobalError &primaryError,
96  const GhostTrack &ghostTrack) const;
97 
98  std::vector<TransientVertex> vertices(const GlobalPoint &primaryPosition,
99  const GlobalError &primaryError,
100  const reco::BeamSpot &beamSpot,
101  const GhostTrack &ghostTrack) const;
102 
103  std::vector<TransientVertex> vertices(const GlobalPoint &primaryPosition,
104  const GlobalError &primaryError,
105  const reco::BeamSpot &beamSpot,
106  const std::vector<TransientTrack> &primaries,
107  const GhostTrack &ghostTrack) const;
108 
109  std::vector<TransientVertex> vertices(const reco::Vertex &primaryVertex, const GhostTrack &ghostTrack) const;
110 
111  std::vector<TransientVertex> vertices(const reco::Vertex &primaryVertex,
112  const reco::BeamSpot &beamSpot,
113  const GhostTrack &ghostTrack) const;
114 
115  std::vector<TransientVertex> vertices(const reco::Vertex &primaryVertex,
116  const reco::BeamSpot &beamSpot,
117  const std::vector<TransientTrack> &primaries,
118  const GhostTrack &ghostTrack) const;
119 
120  std::vector<TransientVertex> vertices(const GhostTrack &ghostTrack,
121  const CachingVertex<5> &primary = CachingVertex<5>(),
122  const reco::BeamSpot &beamSpot = reco::BeamSpot(),
123  bool hasBeamSpot = false,
124  bool hasPrimaries = false) const;
125 
126  private:
127  struct FinderInfo;
128 
129  std::vector<CachingVertex<5> > initialVertices(const FinderInfo &info) const;
130 
132  const CachingVertex<5> &vertex2,
133  const FinderInfo &info,
134  bool isPrimary) const;
135 
136  bool recursiveMerge(std::vector<CachingVertex<5> > &vertices, const FinderInfo &info) const;
137 
138  bool reassignTracks(std::vector<CachingVertex<5> > &vertices, const FinderInfo &info) const;
139 
140  void refitGhostTrack(std::vector<CachingVertex<5> > &vertices, FinderInfo &info) const;
141 
143  VertexFitter<5> &vertexFitter(bool primary) const;
144 
145  static double vertexCompat(const CachingVertex<5> &vtx1,
146  const CachingVertex<5> &vtx2,
147  const FinderInfo &info,
148  double scale1 = 1.0,
149  double scale2 = 1.0);
150 
151  double maxFitChi2_;
153  double primcut_;
154  double seccut_;
156 
157  mutable std::unique_ptr<GhostTrackFitter> ghostTrackFitter_;
158  mutable std::unique_ptr<VertexFitter<5> > primVertexFitter_;
159  mutable std::unique_ptr<VertexFitter<5> > secVertexFitter_;
160  };
161 
162 } // namespace reco
163 #endif // RecoBTag_GhostTrackVertexFinder_h
static const TGPicture * info(bool iBackgroundIsBlack)
std::unique_ptr< VertexFitter< 5 > > primVertexFitter_
static double vertexCompat(const CachingVertex< 5 > &vtx1, const CachingVertex< 5 > &vtx2, const FinderInfo &info, double scale1=1.0, double scale2=1.0)
bool reassignTracks(std::vector< CachingVertex< 5 > > &vertices, const FinderInfo &info) const
bool recursiveMerge(std::vector< CachingVertex< 5 > > &vertices, const FinderInfo &info) const
std::vector< TransientVertex > vertices(const reco::Vertex &primaryVertex, const GlobalVector &direction, double coneRadius, const std::vector< TransientTrack > &tracks) const
ROOT::Math::DisplacementVector3D< ROOT::Math::Cartesian3D< float >, ROOT::Math::GlobalCoordinateSystemTag > GlobalVector
vector in glovbal coordinate system
Definition: Vector3D.h:28
CachingVertex< 5 > mergeVertices(const CachingVertex< 5 > &vertex1, const CachingVertex< 5 > &vertex2, const FinderInfo &info, bool isPrimary) const
std::unique_ptr< VertexFitter< 5 > > secVertexFitter_
std::vector< CachingVertex< 5 > > initialVertices(const FinderInfo &info) const
VertexFitter< 5 > & vertexFitter(bool primary) const
ROOT::Math::PositionVector3D< ROOT::Math::Cartesian3D< float >, ROOT::Math::GlobalCoordinateSystemTag > GlobalPoint
point in global coordinate system
Definition: Point3D.h:18
GhostTrackFitter & ghostTrackFitter() const
fixed size matrix
void refitGhostTrack(std::vector< CachingVertex< 5 > > &vertices, FinderInfo &info) const
std::unique_ptr< GhostTrackFitter > ghostTrackFitter_
primaryVertex
hltOfflineBeamSpot for HLTMON