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>(),
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
pwdgSkimBPark_cfi.beamSpot
beamSpot
Definition: pwdgSkimBPark_cfi.py:5
reco::GhostTrackVertexFinder::ghostTrackFitter_
std::unique_ptr< GhostTrackFitter > ghostTrackFitter_
Definition: GhostTrackVertexFinder.h:157
CachingVertex< 5 >
reco::GhostTrackVertexFinder::kSingleTracksWithGhostTrack
Definition: GhostTrackVertexFinder.h:31
reco::GhostTrackVertexFinder::seccut_
double seccut_
Definition: GhostTrackVertexFinder.h:154
reco::GhostTrackVertexFinder::refitGhostTrack
void refitGhostTrack(std::vector< CachingVertex< 5 > > &vertices, FinderInfo &info) const
Definition: GhostTrackVertexFinder.cc:895
GhostTrackFitter.h
VertexReconstructor.h
VertexFitter.h
reco::GhostTrackVertexFinder::fitType_
FitType fitType_
Definition: GhostTrackVertexFinder.h:155
info
static const TGPicture * info(bool iBackgroundIsBlack)
Definition: FWCollectionSummaryWidget.cc:153
reco::GhostTrackVertexFinder::~GhostTrackVertexFinder
~GhostTrackVertexFinder()
Definition: GhostTrackVertexFinder.cc:268
reco::GhostTrackVertexFinder::secVertexFitter_
std::unique_ptr< VertexFitter< 5 > > secVertexFitter_
Definition: GhostTrackVertexFinder.h:159
reco
fixed size matrix
Definition: AlignmentAlgorithmBase.h:45
TransientTrack.h
ghostTrackVertexReco_cff.fitType
fitType
Definition: ghostTrackVertexReco_cff.py:10
VertexFitter< 5 >
HLT_FULL_cff.primcut
primcut
Definition: HLT_FULL_cff.py:51933
BeamMonitor_cff.primaryVertex
primaryVertex
hltOfflineBeamSpot for HLTMON
Definition: BeamMonitor_cff.py:7
reco::GhostTrackVertexFinder::mergeThreshold_
double mergeThreshold_
Definition: GhostTrackVertexFinder.h:152
reco::GhostTrackVertexFinder::vertexFitter
VertexFitter< 5 > & vertexFitter(bool primary) const
Definition: GhostTrackVertexFinder.cc:277
TrackFwd.h
BeamSpot.h
HLT_FULL_cff.weights
weights
Definition: HLT_FULL_cff.py:99170
reco::BeamSpot
Definition: BeamSpot.h:21
reco::Track
Definition: Track.h:27
ghostTrackVertexReco_cff.maxFitChi2
maxFitChi2
Definition: ghostTrackVertexReco_cff.py:6
reco::GhostTrackVertexFinder::ghostTrackFitter
GhostTrackFitter & ghostTrackFitter() const
Definition: GhostTrackVertexFinder.cc:270
tracks
const uint32_t *__restrict__ const HitContainer *__restrict__ TkSoA *__restrict__ tracks
Definition: CAHitNtupletGeneratorKernelsImpl.h:159
phase2tkutil::isPrimary
bool isPrimary(const SimTrack &simTrk, const PSimHit *simHit)
Definition: TrackerPhase2ValidationUtil.cc:2
math::GlobalVector
ROOT::Math::DisplacementVector3D< ROOT::Math::Cartesian3D< float >, ROOT::Math::GlobalCoordinateSystemTag > GlobalVector
vector in glovbal coordinate system
Definition: Vector3D.h:28
reco::GhostTrackVertexFinder::primVertexFitter_
std::unique_ptr< VertexFitter< 5 > > primVertexFitter_
Definition: GhostTrackVertexFinder.h:158
reco::GhostTrack
Definition: GhostTrack.h:16
reco::GhostTrackVertexFinder::vertices
std::vector< TransientVertex > vertices(const reco::Vertex &primaryVertex, const GlobalVector &direction, double coneRadius, const std::vector< TransientTrack > &tracks) const
Definition: GhostTrackVertexFinder.cc:334
reco::GhostTrackVertexFinder::initialVertices
std::vector< CachingVertex< 5 > > initialVertices(const FinderInfo &info) const
Definition: GhostTrackVertexFinder.cc:640
trackerHitRTTI::vector
Definition: trackerHitRTTI.h:21
GlobalError.h
GlobalErrorBase< double, ErrorMatrixTag >
reco::GhostTrackVertexFinder::recursiveMerge
bool recursiveMerge(std::vector< CachingVertex< 5 > > &vertices, const FinderInfo &info) const
Definition: GhostTrackVertexFinder.cc:713
reco::GhostTrackVertexFinder::maxFitChi2_
double maxFitChi2_
Definition: GhostTrackVertexFinder.h:151
reco::GhostTrackFitter
Definition: GhostTrackFitter.h:19
reco::GhostTrackVertexFinder::kRefitGhostTrackWithVertices
Definition: GhostTrackVertexFinder.h:31
TransientVertex.h
reco::GhostTrackVertexFinder::mergeVertices
CachingVertex< 5 > mergeVertices(const CachingVertex< 5 > &vertex1, const CachingVertex< 5 > &vertex2, const FinderInfo &info, bool isPrimary) const
Definition: GhostTrackVertexFinder.cc:681
reco::GhostTrackVertexFinder::GhostTrackVertexFinder
GhostTrackVertexFinder()
Definition: GhostTrackVertexFinder.cc:261
reco::GhostTrackVertexFinder
Definition: GhostTrackVertexFinder.h:29
reco::GhostTrackVertexFinder::vertexCompat
static double vertexCompat(const CachingVertex< 5 > &vtx1, const CachingVertex< 5 > &vtx2, const FinderInfo &info, double scale1=1.0, double scale2=1.0)
Definition: GhostTrackVertexFinder.cc:232
GlobalVector.h
reco::GhostTrackVertexFinder::FitType
FitType
Definition: GhostTrackVertexFinder.h:31
reco::GhostTrackVertexFinder::reassignTracks
bool reassignTracks(std::vector< CachingVertex< 5 > > &vertices, const FinderInfo &info) const
Definition: GhostTrackVertexFinder.cc:785
math::GlobalPoint
ROOT::Math::PositionVector3D< ROOT::Math::Cartesian3D< float >, ROOT::Math::GlobalCoordinateSystemTag > GlobalPoint
point in global coordinate system
Definition: Point3D.h:18
GhostTrack.h
HLT_FULL_cff.seccut
seccut
Definition: HLT_FULL_cff.py:51934
reco::GhostTrackVertexFinder::kAlwaysWithGhostTrack
Definition: GhostTrackVertexFinder.h:31
ghostTrackVertexReco_cff.mergeThreshold
mergeThreshold
Definition: ghostTrackVertexReco_cff.py:7
GlobalPoint.h
reco::GhostTrackVertexFinder::primcut_
double primcut_
Definition: GhostTrackVertexFinder.h:153
reco::Vertex
Definition: Vertex.h:35