Fork me on GitHub

source: git/modules/VertexFinderDA4D.h@ 2628d2b

ImprovedOutputFile Timing dual_readout llp
Last change on this file since 2628d2b was 29d662e, checked in by Michele Selvaggi <michele.selvaggi@…>, 8 years ago

renamed 4D vertexing module

  • Property mode set to 100644
File size: 3.1 KB
Line 
1#ifndef VertexFinderDA4D_h
2#define VertexFinderDA4D_h
3
4/** \class VertexFinderDA4D
5 *
6 * Cluster vertices from tracks using deterministic annealing and timing information
7 *
8 * \authors M. Selvaggi, L. Gray
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 VertexFinderDA4D: public DelphesModule
30{
31public:
32
33 VertexFinderDA4D();
34 ~VertexFinderDA4D();
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 double pt;
51 double eta;
52 double phi;
53
54};
55
56
57struct vertex_t{
58 double z; // z coordinate
59 double t; // t coordinate
60 double pk; // vertex weight for "constrained" clustering
61 // --- temporary numbers, used during update
62 double ei;
63 double sw;
64 double swz;
65 double swt;
66 double se;
67 // ---for Tc
68 double swE;
69 double Tc;
70};
71
72
73
74 void clusterize(const TObjArray & tracks, TObjArray & clusters);
75
76 std::vector< Candidate* > vertices();
77
78 std::vector<track_t> fill() const;
79
80 bool split( double beta,
81 std::vector<track_t> & tks,
82 std::vector<vertex_t> & y) const;
83
84 double update( double beta,
85 std::vector<track_t> & tks,
86 std::vector<vertex_t> & y ) const;
87
88 double update(double beta,
89 std::vector<track_t> & tks,
90 std::vector<vertex_t> & y,
91 double & )const;
92
93 void dump(const double beta, const std::vector<vertex_t> & y, const std::vector<track_t> & tks) const;
94 bool merge(std::vector<vertex_t> &) const;
95 bool merge(std::vector<vertex_t> &,double & ) const;
96 bool purge(std::vector<vertex_t> &, std::vector<track_t> & , double &, const double ) const;
97
98 void splitAll( std::vector<vertex_t> & y ) const;
99
100 double beta0(const double betamax,
101 std::vector<track_t> & tks,
102 std::vector<vertex_t> & y )const;
103
104 double Eik(const track_t & t, const vertex_t & k)const;
105
106
107private:
108
109 Bool_t fVerbose;
110 Double_t fMinPT;
111
112 Float_t fVertexSpaceSize;
113 Float_t fVertexTimeSize;
114 Bool_t fUseTc;
115 Float_t fBetaMax;
116 Float_t fBetaStop;
117 Double_t fCoolingFactor;
118 Int_t fMaxIterations;
119 Double_t fDzCutOff;
120 Double_t fD0CutOff;
121 Double_t fDtCutOff; // for when the beamspot has time
122
123 TObjArray *fInputArray;
124 TIterator *fItInputArray;
125
126 TObjArray *fOutputArray;
127 TObjArray *fVertexOutputArray;
128
129 ClassDef(VertexFinderDA4D, 1)
130};
131
132#endif
Note: See TracBrowser for help on using the repository browser.