Fork me on GitHub

source: git/modules/VertexFinder4D.h@ ab3bdd9

ImprovedOutputFile Timing dual_readout llp
Last change on this file since ab3bdd9 was 8284b74, checked in by Michele Selvaggi <michele.selvaggi@…>, 9 years ago

added 4D vertexing

  • Property mode set to 100644
File size: 3.2 KB
Line 
1#ifndef VertexFinder4D_h
2#define VertexFinder4D_h
3
4/** \class VertexFinder4D
5 *
6 * Cluster vertices from tracks using deterministic annealing and timing information
7 *
8 * \authors M. Selvaggi
9 *
10 */
11
12
13
14#include "classes/DelphesModule.h"
15#include "classes/DelphesClasses.h"
16#include <utility>
17#include <algorithm>
18#include <stdexcept>
19#include <iostream>
20#include <vector>
21#include <unordered_map>
22
23using namespace std;
24
25class TObjArray;
26class Candidate;
27class TVector3;
28
29class VertexFinder4D: public DelphesModule
30{
31public:
32
33 VertexFinder4D();
34 ~VertexFinder4D();
35
36 void Init();
37 void Process();
38 void Finish();
39
40 struct track_t{
41 double z; // z-coordinate at point of closest approach to the beamline
42 double t; // t-coordinate at point of closest approach to the beamline
43 double dz2; // square of the error of z(pca)
44 double dtz; // covariance of z-t
45 double dt2; // square of the error of t(pca)
46 //const reco::TransientTrack* tt; // a pointer to the Transient Track
47 Candidate* tt; // a pointer to the Candidate Track
48 double Z; // Z[i] for DA clustering
49 double pi; // track weight
50};
51
52
53struct vertex_t{
54 double z; // z coordinate
55 double t; // t coordinate
56 double pk; // vertex weight for "constrained" clustering
57 // --- temporary numbers, used during update
58 double ei;
59 double sw;
60 double swz;
61 double swt;
62 double se;
63 // ---for Tc
64 double swE;
65 double Tc;
66};
67
68
69
70 void clusterize(const TObjArray & tracks, TObjArray & clusters);
71
72 std::vector< Candidate >
73 vertices(const TObjArray & tracks, const int verbosity=0);
74
75 std::vector<track_t> fill(const TObjArray & tracks)const;
76
77 bool split( double beta,
78 std::vector<track_t> & tks,
79 std::vector<vertex_t> & y,
80 double threshold ) const;
81
82 double update( double beta,
83 std::vector<track_t> & tks,
84 std::vector<vertex_t> & y ) const;
85
86 double update(double beta,
87 std::vector<track_t> & tks,
88 std::vector<vertex_t> & y,
89 double & )const;
90
91 void dump(const double beta, const std::vector<vertex_t> & y, const std::vector<track_t> & tks, const int verbosity=0) const;
92 bool merge(std::vector<vertex_t> &,int ) const;
93 bool merge(std::vector<vertex_t> &,double & ) const;
94 bool purge(std::vector<vertex_t> &, std::vector<track_t> & , double &, const double ) const;
95
96 void splitAll( std::vector<vertex_t> & y ) const;
97
98 double beta0(const double betamax,
99 std::vector<track_t> & tks,
100 std::vector<vertex_t> & y )const;
101
102 double Eik(const track_t & t, const vertex_t & k)const;
103
104
105private:
106
107 Double_t fSigma;
108 Double_t fMinPT;
109 Double_t fMaxEta;
110 Double_t fSeedMinPT;
111 Int_t fMinNDF;
112 Int_t fGrowSeeds;
113 Bool_t fVerbose;
114
115 bool useTc_;
116 float vertexSize_;
117 int maxIterations_;
118 double coolingFactor_;
119 float betamax_;
120 float betastop_;
121 double dzCutOff_;
122 double d0CutOff_;
123 double dtCutOff_; // for when the beamspot has time
124
125 TObjArray *fInputArray;
126 TIterator *fItInputArray;
127
128 TObjArray *fOutputArray;
129 TObjArray *fVertexOutputArray;
130
131 ClassDef(VertexFinder4D, 1)
132};
133
134#endif
Note: See TracBrowser for help on using the repository browser.