CbmRoot
L1Algo.h
Go to the documentation of this file.
1 #ifndef L1Algo_h
2 #define L1Algo_h 1
3 
4 // #define TBB // TODO: Doesn't work now. Renew
5 
7 // #define PULLS // triplets pulls
8 // #define TRIP_PERFORMANCE // triplets efficiencies
9 // #define DOUB_PERFORMANCE // doublets efficiencies
10 //#define DRAW // event display
11 #ifdef DRAW
12 class L1AlgoDraw;
13 #include "CbmL1Track.h"
14 #endif
15 //#define XXX // time debug
16 //#define COUNTERS // diff counters (hits, doublets, ... )
17 
18 //#define MERGE_CLONES
19 // #define TRACKS_FROM_TRIPLETS_ITERATION kAllPrimIter
20 
21 //#define HitErrors
22 //#define GLOBAL
23 //#define mCBM
24 
25 #define LAST_ITERATION kAllSecIter
26 #define FIND_GAPED_TRACKS // use triplets with gaps
27 #define USE_RL_TABLE
28 #ifndef TRACKS_FROM_TRIPLETS
29 #define EXTEND_TRACKS
30 #endif
31 //#define USE_EVENT_NUMBER
32 //#endif
33 //#define MERGE_CLONES
34 
35 
36 #include "L1Branch.h"
37 #include "L1Field.h"
38 #include "L1Station.h"
39 #include "L1StsHit.h"
40 #include "L1Track.h"
41 #include "L1TrackPar.h"
42 #include "L1TrackParFit.h"
43 #include "L1Triplet.h"
44 
45 #include "L1Grid.h"
46 #include "L1HitPoint.h"
47 #include "L1HitsSortHelper.h"
48 #include "L1Portion.h"
49 #include "L1Strip.h"
50 
51 
52 #include <iomanip>
53 #include <iostream>
54 #include <map>
55 #include <vector>
56 
57 #ifdef _OPENMP
58 #include "omp.h"
59 #endif
60 
61 using std::map;
62 using std::vector;
63 
64 #ifdef PULLS
65 #define TRIP_PERFORMANCE
66 class L1AlgoPulls;
67 #endif
68 #ifdef TRIP_PERFORMANCE
69 template<Tindex NHits>
71 #endif
72 #ifdef DOUB_PERFORMANCE
73 template<Tindex NHits>
75 #endif
76 typedef int Tindex;
77 
78 
79 class L1Algo {
80 public:
81  // L1Algo(int nThreads=7):
82  L1Algo(int nThreads = 1, int TypicalSize = 200000)
83  : n_g1()
84  , FirstHit()
85  , LastHit()
86  , FirstHitIndex()
87  , LastHitIndex()
88  , Neighbour()
89  , TrackChi2()
90  , vRecoHitsNew()
91  , vTracksNew()
92  , NStations(0)
93  , // number of all detector stations
94  NMvdStations(0)
95  , // number of mvd stations
96  NStsStations(0)
97  , NFStations(0)
98  , fRadThick()
99  , vStsStrips(0)
100  , // strips positions created from hits. Front strips
101  vStsStripsB(0)
102  , // back strips
103  vStsZPos(0)
104  , // all possible z-positions of hits
105  vStsHits(0)
106  , // hits as a combination of front-, backstrips and z-position
107  vSFlag(0)
108  , // information of hits station & using hits in tracks(),
109  vSFlagB(0)
110  , CATime(0)
111  , // time of trackfinding
112  vTracks(40000)
113  , // reconstructed tracks
114  vRecoHits(400000)
115  , // packed hits of reconstructed tracks
116  StsHitsStartIndex(nullptr)
117  , StsHitsStopIndex(nullptr)
118  , NHitsIsecAll(0)
119  , NTracksIsecAll(0)
120  , vStsDontUsedHits_A(TypicalSize)
121  , vStsDontUsedHits_B(TypicalSize)
122  , vStsDontUsedHits_Buf(TypicalSize)
123  , vStsDontUsedHitsxy_A(TypicalSize)
124  , vStsDontUsedHitsxy_buf(TypicalSize)
125  , vStsDontUsedHitsxy_B(TypicalSize)
126  , RealIHit_v(TypicalSize)
127  , RealIHit_v_buf(TypicalSize)
128  , RealIHit_v_buf2(TypicalSize)
129  ,
130 
131 #ifdef _OPENMP
132  hitToBestTrackF(TypicalSize)
133  , hitToBestTrackB(TypicalSize)
134  ,
135 #endif
136  vStripToTrack(TypicalSize)
137  , vStripToTrackB(TypicalSize)
138  ,
139  //sh (),
140  fNThreads(nThreads)
141  , fUseHitErrors(0)
142  , fmCBMmode(0)
143  , fGlobal(0)
144  , isec(0)
145  , vStsHitsUnused()
146  , RealIHitP()
147  , RealIHitPBuf()
149  , RealIHit(nullptr)
150  , FIRSTCASTATION()
152  , TRACK_CHI2_CUT(10.)
153  , TRIPLET_CHI2_CUT(5.)
154  , DOUBLET_CHI2_CUT(5.)
155  , TIME_CUT1(0.)
156  , TIME_CUT2(0.)
157  , MaxDZ(0.)
158  ,
159 #ifdef DRAW
160  draw(0)
161  ,
162 #endif
163  Pick_gather(0)
164  , PickNeighbour(0)
165  , // (PickNeighbour < dp/dp_error) => triplets are neighbours
166  MaxInvMom(0)
167  , // max considered q/p for tracks
168  MaxSlope(0)
169  , targX(0)
170  , targY(0)
171  , targZ(0)
172  , // target coor
173  targB()
174  , // field in the target point
175  TargetXYInfo()
176  , // target constraint [cm]
177  vtxFieldRegion()
178  , // really doesn't used
179  vtxFieldValue()
180  , // field at teh vertex position.
181  //vTripletsP(), // container for triplets got in finding
182  fTrackingLevel(0)
183  , fGhostSuppression(0)
184  , // really doesn't used
185  fMomentumCutOff(0) // really doesn't used
186  {
187 
188  n_g1.resize(100000);
189 
190  for (int i = 0; i < fNThreads; i++) {
191 
192  vTracks_local[i].resize(100000);
193  vRecoHits_local[i].resize(400000);
194 
195 
197  SavedCand[i] = 0;
198  SavedHits[i] = 0;
199 
200  TripForHit[0].resize(TypicalSize);
201  TripForHit[1].resize(TypicalSize);
202  CandidatesTrack[i].resize(10000);
203 
204  fT_3[i].reserve(MaxPortionTriplets / fvecLen);
205  fhitsl_3[i].reserve(MaxPortionTriplets);
206  fhitsm_3[i].reserve(MaxPortionTriplets);
207  fhitsr_3[i].reserve(MaxPortionTriplets);
209  fu_back3[i].reserve(MaxPortionTriplets / fvecLen);
210  fz_pos3[i].reserve(MaxPortionTriplets / fvecLen);
211  fTimeR[i].reserve(MaxPortionTriplets / fvecLen);
212  fTimeER[i].reserve(MaxPortionTriplets / fvecLen);
213  dx[i].reserve(MaxPortionTriplets / fvecLen);
214  dy[i].reserve(MaxPortionTriplets / fvecLen);
215  du[i].reserve(MaxPortionTriplets / fvecLen);
216  dv[i].reserve(MaxPortionTriplets / fvecLen);
217 
218  for (int j = 0; j < MaxNStations; j++)
219  TripletsLocal1[j][i].resize(400000);
220  }
221 
222  for (int i = 0; i < MaxNStations; i++)
223  vGridTime[i].AllocateMemory(fNThreads);
224 
225 #ifdef _OPENMP
226 
227  for (unsigned int j = 0; j < hitToBestTrackB.size(); j++) {
228  omp_init_lock(&hitToBestTrackB[j]);
229  omp_init_lock(&hitToBestTrackF[j]);
230  }
231 
232 #endif
233 
234 
235  for (int i = 0; i < nThreads; i++)
236  for (int k = 0; k < MaxNStations; k++)
237  nTripletsThread[k][i] = 0;
238 
239  NTracksIsecAll = 20000;
240  NHitsIsecAll = TypicalSize;
241 
242 
243  FirstHit.resize(NTracksIsecAll);
244  LastHit.resize(NTracksIsecAll);
247  // IsUsed.resize(NTracksIsecAll);
248  TrackChi2.resize(NTracksIsecAll);
249  Neighbour.resize(NTracksIsecAll);
250  // IsNext.resize(NTracksIsecAll);
251  }
252 
253  L1Algo(const L1Algo&) = delete;
254  L1Algo operator=(const L1Algo&) = delete;
255 
256  static const int nTh = 1;
257  static const int nSta = 25;
258 
261 
264 
265 
268 
270 
272 
273  //for merger
280  // L1Vector<bool> IsNext;
281  // L1Vector<bool> IsUsed;
284 
285 
286 #ifdef DRAW
287  L1AlgoDraw* draw;
288  void DrawRecoTracksTime(const vector<CbmL1Track>& tracks);
289 #endif
290 
291 
292  void
293  Init(const vector<fscal>& geo, const bool UseHitErrors, const bool mCBMmode);
294 
295  // void SetData( const vector< L1StsHit > & StsHits_,
296  // const vector< L1Strip > & StsStrips_,
297  // const vector< L1Strip > & StsStripsB_,
298  // const vector< fscal > & StsZPos_,
299  // const vector< unsigned char > & SFlag_,
300  // const vector< unsigned char > & SFlagB_,
301  // const THitI* StsHitsStartIndex_,
302  // const THitI* StsHitsStopIndex_ );
303 
304  void SetData(const vector<L1StsHit>& StsHits_,
305  const vector<L1Strip>& StsStrips_,
306  const vector<L1Strip>& StsStripsB_,
307  const vector<fscal>& StsZPos_,
308  const vector<unsigned char>& SFlag_,
309  const vector<unsigned char>& SFlagB_,
310  const THitI* StsHitsStartIndex_,
311  const THitI* StsHitsStopIndex_
312 
313  );
314  void PrintHits();
315 
317  void CATrackFinder();
318 
320  void
321  KFTrackFitter_simple(); // version, which use procedured used during the reconstruction
322  void L1KFTrackFitter(); // version from SIMD-KF benchmark
323 
324  void L1KFTrackFitterMuch();
325 
327  // filled in CbmL1::ReadEvent();
328 
329  void SetNThreads(int n = 1) { fNThreads = n; }
330 
331  enum { MaxNStations = 25 };
332 
333  int NStations, // number of all detector stations
334  NMvdStations, // number of mvd stations
336  L1Station vStations[MaxNStations] _fvecalignment; // station info
337  vector<L1Material> fRadThick; // material for each station
338 
339  const vector<L1Strip>
340  *vStsStrips, // strips positions created from hits. Front strips
341  *vStsStripsB; // back strips
342  const vector<fscal>* vStsZPos; // all possible z-positions of hits
343  const vector<L1StsHit>*
344  vStsHits; // hits as a combination of front-, backstrips and z-position
346  [MaxNStations]; // hits as a combination of front-, backstrips and z-position
348 
349  const vector<unsigned char>
350  *vSFlag, // information of hits station & using hits in tracks;
352 
353  double CATime; // time of trackfinding
354 
357 
359  *StsHitsStopIndex; // station-bounders in vStsHits array
360 
361 
362  // L1Branch* pointer;
363  unsigned int NHitsIsecAll;
364  unsigned int NTracksIsecAll;
365 
366  vector<L1StsHit> vStsDontUsedHits_A;
367  vector<L1StsHit> vStsDontUsedHits_B;
368  vector<L1StsHit> vStsDontUsedHits_Buf;
369  vector<L1HitPoint> vStsDontUsedHitsxy_A;
370  vector<L1HitPoint> vStsDontUsedHitsxy_buf;
371  vector<L1HitPoint> vStsDontUsedHitsxy_B;
374 
375  vector<THitI> RealIHit_v;
376  vector<THitI> RealIHit_v_buf;
377  vector<THitI> RealIHit_v_buf2;
378 
379 #ifdef _OPENMP
380 
381  L1Vector<omp_lock_t> hitToBestTrackF;
382  L1Vector<omp_lock_t> hitToBestTrackB;
383 
384 #endif
385 
388 
391  bool fmCBMmode;
392  bool fGlobal;
393 
396 
397 
399  enum {
400  multiCoeff = 1, // central - 1, mbias
401 
402 
403  coeff = 64 / 4,
404 
405  Portion = 1024 / coeff, // portion of left hits
406 
407  MaxPortionDoublets = 10000 / 5 * 64 / 2 / coeff /*/ multiCoeff*/ * 1,
408  MaxPortionTriplets = 10000 * 5 * 64 / 2 / coeff /*/ multiCoeff*/ * 1,
410 
411 
412  MaxArrSize =
414  / MaxNStations //200000, // standart size of big arrays // mas be 40000 for normal work in cbmroot!
415  };
416 
417 
419 
420  int isec; // iteration
421  vector<L1StsHit>* vStsHitsUnused;
422  vector<THitI>* RealIHitP;
423  vector<THitI>* RealIHitPBuf;
424  vector<L1HitPoint>* vStsHitPointsUnused;
425  THitI* RealIHit; // index in vStsHits indexed by index in vStsHitsUnused
430 
431 
432  vector<int> TripForHit[2];
433 
434 
435  // fvec u_front[Portion/fvecLen], u_back[Portion/fvecLen];
436  // fvec zPos[Portion/fvecLen];
437  // fvec fHitTime[Portion/fvecLen];
438 
440 
441  vector<THitI> fhitsl_3[nTh], fhitsm_3[nTh], fhitsr_3[nTh];
442 
445 
446 
447  // Tindex NHits_l[MaxNStations];
448  // Tindex NHits_l_P[MaxNStations];
450 
451  friend class CbmL1;
452 
453  const L1FieldValue& GetVtxFieldValue() const { return vtxFieldValue; }
454  const L1FieldRegion& GetVtxFieldRegion() const { return vtxFieldRegion; }
456 
457  void GetHitCoor(const L1StsHit& _h,
458  fscal& _x,
459  fscal& _y,
460  fscal& _z,
461  const L1Station& sta);
462 
463  void dUdV_to_dY(const fvec& u, const fvec& v, fvec& _y, const L1Station& sta);
464 
465  void dUdV_to_dX(const fvec& u, const fvec& v, fvec& _x, const L1Station& sta);
466 
467  void
468  dUdV_to_dXdY(const fvec& u, const fvec& v, fvec& _xy, const L1Station& sta);
469 
470  void GetHitCoor(const L1StsHit& _h, fscal& _x, fscal& _y, char iS);
471  void StripsToCoor(
472  const fscal& u,
473  const fscal& v,
474  fscal& x,
475  fscal& y,
476  const L1Station& sta) const; // convert strip positions to coordinates
477  void StripsToCoor(
478  const fscal& u,
479  const fscal& v,
480  fvec& x,
481  fvec& y,
482  const L1Station& sta) const; // convert strip positions to coordinates
483  void StripsToCoor(const fvec& u,
484  const fvec& v,
485  fvec& x,
486  fvec& y,
487  const L1Station& sta) const;
488  L1HitPoint
489  CreateHitPoint(const L1StsHit& hit,
490  char ista); // full the hit point by hit information.
491 
492  void CreateHitPoint(const L1StsHit& hit, char ista, L1HitPoint& point);
493  inline int PackIndex(const int& a, const int& b, const int& c);
494 
495  inline int UnPackIndex(const int& i, int& a, int& b, int& c);
497  inline __attribute__((always_inline)) static unsigned char
498  GetFStation(unsigned char flag) {
499  return flag / 4;
500  }
501  inline __attribute__((always_inline)) static bool
502  GetFUsed(unsigned char flag) {
503  return (flag & 0x02) != 0;
504  }
505  // bool GetFUsedD ( unsigned char flag ){ return (flag&0x01)!=0; }
506 
507 private:
509 
511 
512  void CAFindTrack(int ista,
513  L1Branch& best_tr,
514  unsigned char& best_L,
515  fscal& best_chi2,
516  const L1Triplet* curr_trip,
517  L1Branch& curr_tr,
518  unsigned char& curr_L,
519  fscal& curr_chi2,
520  unsigned char min_best_l,
521  L1Branch* new_tr);
522 
523 
530  void BranchFitterFast(const L1Branch& t,
531  L1TrackPar& T,
532  const bool dir,
533  const fvec qp0 = 0.,
534  const bool initParams = true);
535 
537  void BranchFitter(const L1Branch& t,
538  L1TrackPar& T,
539  const bool dir,
540  const fvec qp0 = 0.,
541  const bool initParams = true);
542 
548  void FindMoreHits(L1Branch& t,
549  L1TrackPar& T,
550  const bool dir,
551  const fvec qp0 = 0.0);
552 
556 
558  void InvertCholetsky(fvec a[15]);
559  void MultiplySS(fvec const C[15], fvec const V[15], fvec K[5][5]);
560  void MultiplyMS(fvec const C[5][5], fvec const V[15], fvec K[15]);
561  void MultiplySR(fvec const C[15], fvec const r_in[5], fvec r_out[5]);
562  void FilterTracks(fvec const r[5],
563  fvec const C[15],
564  fvec const m[5],
565  fvec const V[15],
566  fvec R[5],
567  fvec W[15],
568  fvec* chi2);
569  void CAMergeClones();
570 
571 
572  inline __attribute__((always_inline)) void
573  PackLocation(unsigned int& location,
574  unsigned int& triplet,
575  unsigned int iStation,
576  unsigned int& thread) {
577  location = (triplet << 11) | (thread << 3) | iStation;
578  }
579 
580  inline __attribute__((always_inline)) void
581  UnPackStation(unsigned int& location, unsigned int& iStation) {
582  iStation = location & 0x7;
583  }
584 
585  inline __attribute__((always_inline)) void
586  UnPackThread(unsigned int& location, unsigned int& thread) {
587  thread = (location >> 3) & 0xFF;
588  }
589 
590  inline __attribute__((always_inline)) void
591  UnPackTriplet(unsigned int& location, unsigned int& triplet) {
592  triplet = (location >> 11);
593  }
594 
595  inline __attribute__((always_inline)) void
596  SetFStation(unsigned char& flag, unsigned int iStation) {
597  flag = iStation * 4 + (flag % 4);
598  }
599  inline __attribute__((always_inline)) void SetFUsed(unsigned char& flag) {
600  flag |= 0x02;
601  }
602  // void SetFUsedD ( unsigned char &flag ){ flag |= 0x01; }
603  inline __attribute__((always_inline)) void SetFUnUsed(unsigned char& flag) {
604  flag &= 0xFC;
605  }
606  // void SetFUnUsedD ( unsigned char &flag ){ flag &= 0xFE; }
607 
609  void f10( // input
610  Tindex start_lh,
611  Tindex n1_l,
612  L1HitPoint* StsHits_l,
613  // output
614  fvec* u_front_l,
615  fvec* u_back_l,
616  fvec* zPos_l,
617  THitI* hitsl,
618  fvec* HitTime_l,
619  fvec* HitTimeEr,
620  fvec* Event_l,
621  fvec* d_x,
622  fvec* d_y,
623  fvec* d_xy,
624  fvec* d_u,
625  fvec* d_v);
626 
628  void f11( // input
629  int istal,
630  int istam,
631  Tindex n1_V,
632 
633  fvec* u_front_l,
634  fvec* u_back_l,
635  fvec* zPos_l,
636  fvec* HitTime_l,
637  fvec* HitTimeEr,
638  // output
639  L1TrackPar* T_1,
640  L1FieldRegion* fld_1,
641  fvec* d_x,
642  fvec* d_y,
643  fvec* d_xy,
644  fvec* d_u,
645  fvec* d_v);
646 
648  void f20( // input
649  Tindex n1,
650  L1Station& stam,
651  L1HitPoint* vStsHits_m,
652  L1TrackPar* T_1,
653  THitI* hitsl_1,
654 
655  // output
656  Tindex& n2,
657  vector<THitI>& i1_2,
658 
659 #ifdef DOUB_PERFORMANCE
660  vector<THitI>& hitsl_2,
661 #endif // DOUB_PERFORMANCE
662  vector<THitI>& hitsm_2,
663  fvec* Event,
664  vector<bool>& lmDuplets);
665 
668  void f30( // input
669  L1HitPoint* vStsHits_r,
670  L1Station& stam,
671  L1Station& star,
672 
673  int istam,
674  int istar,
675  L1HitPoint* vStsHits_m,
676  L1TrackPar* T_1,
677  L1FieldRegion* fld_1,
678  THitI* hitsl_1,
679 
680  Tindex n2,
681  vector<THitI>& hitsm_2,
682  vector<THitI>& i1_2,
683 
684  const vector<bool>& mrDuplets,
685  // output
686  Tindex& n3,
688  vector<THitI>& hitsl_3,
689  vector<THitI>& hitsm_3,
690  vector<THitI>& hitsr_3,
691  nsL1::vector<fvec>::TSimd& u_front_3,
692  nsL1::vector<fvec>::TSimd& u_back_3,
693  nsL1::vector<fvec>::TSimd& z_Pos_3,
694  // nsL1::vector<fvec>::TSimd& dx_,
695  // nsL1::vector<fvec>::TSimd& dy_,
699  nsL1::vector<fvec>::TSimd& timeER);
700 
702  void f31( // input
703  Tindex n3_V,
704  L1Station& star,
705  nsL1::vector<fvec>::TSimd& u_front_3,
706  nsL1::vector<fvec>::TSimd& u_back_3,
707  nsL1::vector<fvec>::TSimd& z_Pos_3,
708  // nsL1::vector<fvec>::TSimd& dx_,
709  // nsL1::vector<fvec>::TSimd& dy_,
714  // output
716 
718  void f32( // input
719  Tindex n3,
720  int istal,
722  vector<THitI>& hitsl_3,
723  vector<THitI>& hitsm_3,
724  vector<THitI>& hitsr_3,
725  int nIterations = 0);
726 
728  void f4( // input
729  Tindex n3,
730  int istal,
731  int istam,
732  int istar,
734  vector<THitI>& hitsl_3,
735  vector<THitI>& hitsm_3,
736  vector<THitI>& hitsr_3,
737  // output
738  Tindex& nstaltriplets,
739  vector<THitI>* hitsn_3 = 0,
740  vector<THitI>* hitsr_5 = 0
741 
742  // #ifdef XXX
743  // ,unsigned int &stat_n_trip
744  // #endif
745  );
746 
747 
749  void f5( // input
750  // output
751  int* nlevel);
752 
753 
755  void DupletsStaPort( // input
756  int istal,
757  int istam,
758  Tindex ip,
759  vector<Tindex>& n_g,
760  Tindex* portionStopIndex_,
761 
762  // output
763  L1TrackPar* T_1,
764  L1FieldRegion* fld_1,
765  THitI* hitsl_1,
766 
767  vector<bool>& lmDuplets,
768 
769 
770  Tindex& n_2,
771  vector<THitI>& i1_2,
772  vector<THitI>& hitsm_2);
773 
775  void TripletsStaPort( // input
776  int istal,
777  int istam,
778  int istar,
779  Tindex& nstaltriplets,
780  L1TrackPar* T_1,
781  L1FieldRegion* fld_1,
782  THitI* hitsl_1,
783 
784  Tindex& n_2,
785  vector<THitI>& i1_2,
786  vector<THitI>& hitsm_2,
787 
788  const vector<bool>& mrDuplets
789 
790  // output
791 
792 
793  );
794 
795 
797 
798  void GuessVec(L1TrackPar& t,
799  fvec* xV,
800  fvec* yV,
801  fvec* zV,
802  fvec* Sy,
803  fvec* wV,
804  int NHits,
805  fvec* zCur = 0);
806  void GuessVec(L1TrackParFit& t,
807  fvec* xV,
808  fvec* yV,
809  fvec* zV,
810  fvec* Sy,
811  fvec* wV,
812  int NHits,
813  fvec* zCur = 0,
814  fvec* timeV = 0,
815  fvec* w_time = 0);
816 
817  void FilterFirst(L1TrackPar& track, fvec& x, fvec& y, L1Station& st);
818  void
819  FilterFirst(L1TrackParFit& track, fvec& x, fvec& y, fvec& t, L1Station& st);
820  void FilterFirst(L1TrackParFit& track,
821  fvec& x,
822  fvec& y,
823  fvec& t,
824  fvec& t_er,
825  L1Station& st);
826 
827  void FilterFirst(L1TrackParFit& track,
828  fvec& x,
829  fvec& y,
830  fvec& t,
831  fvec& t_er,
832  L1Station& st,
833  fvec& dx,
834  fvec& dy,
835  fvec& dxy);
836  void FilterFirstL(L1TrackParFit& track,
837  fvec& x,
838  fvec& y,
839  fvec& t,
840  fvec& t_er,
841  L1Station& st,
842  fvec& dx,
843  fvec& dy,
844  fvec& dxy);
845 
846 
847 #ifdef TBB
848  enum {
849  nthreads = 3, // number of threads
850  nblocks = 1 // number of stations on one thread
851  };
852 
853  friend class ParalleledDup;
854  friend class ParalleledTrip;
855 #endif // TBB
856 #ifdef TBB2
857 public:
858  Tindex thrId;
859 #endif // TBB2
860 private:
862 
864 
865  Tindex FIRSTCASTATION; //first station used in CA
866 
867  // fNFindIterations - set number of interation for trackfinding
868  // itetation of finding:
869 #ifdef FIND_GAPED_TRACKS
870  enum {
871  kFastPrimIter, // primary fast tracks
872  kAllPrimIter, // primary all tracks
873  kAllPrimJumpIter, // primary tracks with jumped triplets
874  kAllSecIter, // secondary all tracks
875  kAllPrimEIter, // primary all electron tracks
876  kAllSecEIter, // secondary all electron tracks
877 
878  kFastPrimJumpIter, // primary fast tracks with jumped triplets
880  kAllSecJumpIter // secondary tracks with jumped triplets
881  };
882 #ifdef TRACKS_FROM_TRIPLETS
883  enum {
884  fNFindIterations = TRACKS_FROM_TRIPLETS_ITERATION + 1
885  }; // TODO investigate kAllPrimJumpIter & kAllSecJumpIter
886 #else
887 
888  enum {
889  fNFindIterations = 4
890  }; // TODO investigate kAllPrimJumpIter & kAllSecJumpIter
891 
892 
893 #endif
894 #else
895  enum {
896  kFastPrimIter = 0, // primary fast tracks
897  kAllPrimIter, // primary all tracks
898  kAllSecIter, // secondary all tracks
899  kFastPrimJumpIter, // disabled
900  kAllPrimJumpIter, // disabled
905  };
906 #endif // FIND_GAPED_TRACKS
907 
908  map<int, int> threadNumberToCpuMap;
909 
910 
912  float
913  TRIPLET_CHI2_CUT; // = 5.0; // cut for selecting triplets before collecting tracks.per one DoF
916 
917  fvec
918  MaxDZ; // correction in order to take into account overlaping and iff z. if sort by y then it is max diff between same station's modules (~0.4cm)
919 
921 
922  float Pick_gather; // same for attaching additional hits to track
923  float
924  PickNeighbour; // (PickNeighbour < dp/dp_error) => triplets are neighbours
925  fvec MaxInvMom; // max considered q/p for tracks
926  fvec MaxSlope; // max slope (tx\ty) in prim vertex
927  fvec targX, targY, targZ; // target coor
928  L1FieldValue targB _fvecalignment; // field in the target point
929  L1XYMeasurementInfo TargetXYInfo _fvecalignment; // target constraint [cm]
930 
931 
932  L1FieldRegion vtxFieldRegion _fvecalignment; // really doesn't used
933  L1FieldValue vtxFieldValue _fvecalignment; // field at teh vertex position.
934 
935  // vector <L1Triplet> vTriplets; // container for triplets got in finding
936  // vector<L1Triplet*> vTripletsP;
937  int numPortions[12];
938  vector<L1Triplet*>* TripletsLocal[MaxNStations - 2];
939 
940 
941  // int TripNumThread;
942 
943  int fTrackingLevel, fGhostSuppression; // really doesn't used
944  float fMomentumCutOff; // really doesn't used
945 
947 #ifdef PULLS
948  L1AlgoPulls* fL1Pulls;
949 #endif
950 #ifdef TRIP_PERFORMANCE
951  L1AlgoEfficiencyPerformance<3>* fL1Eff_triplets;
952  L1AlgoEfficiencyPerformance<3>* fL1Eff_triplets2;
953 #endif
954 #ifdef DOUB_PERFORMANCE
955  L1AlgoEfficiencyPerformance<2>* fL1Eff_doublets;
956 #endif
957 #ifdef DRAW
958  friend class L1AlgoDraw;
959 #endif
960 
962 
963 #endif
L1Algo::vStsZPos
const vector< fscal > * vStsZPos
Definition: L1Algo.h:342
L1Algo::kAllPrimIter
@ kAllPrimIter
Definition: L1Algo.h:872
L1Algo::SavedCand
int SavedCand[nTh]
Definition: L1Algo.h:266
L1Algo::triplet
unsigned int & triplet
Definition: L1Algo.h:574
L1Algo::vStsHitsUnused
vector< L1StsHit > * vStsHitsUnused
Definition: L1Algo.h:421
L1Algo::fGhostSuppression
int fGhostSuppression
Definition: L1Algo.h:943
L1Algo::vStsHits
const vector< L1StsHit > * vStsHits
Definition: L1Algo.h:344
L1Portion.h
fscal
float fscal
Definition: L1/vectors/P4_F32vec4.h:250
L1Algo::TripletsLocal1
L1Vector< L1Triplet > TripletsLocal1[nSta][nTh]
Definition: L1Algo.h:259
L1Algo::fmCBMmode
bool fmCBMmode
Definition: L1Algo.h:391
L1Algo::f4
void f4(Tindex n3, int istal, int istam, int istar, nsL1::vector< L1TrackPar >::TSimd &T_3, vector< THitI > &hitsl_3, vector< THitI > &hitsm_3, vector< THitI > &hitsr_3, Tindex &nstaltriplets, vector< THitI > *hitsn_3=0, vector< THitI > *hitsr_5=0)
Select triplets. Save them into vTriplets.
Definition: L1CATrackFinder.cxx:1173
L1Algo::LastHit
L1Vector< unsigned short > LastHit
Definition: L1Algo.h:275
L1HitPoint
contain strips positions and coordinates of hit
Definition: L1HitPoint.h:6
L1Algo::vGridTime
L1Grid vGridTime[MaxNStations]
Definition: L1Algo.h:347
L1Algo::CAMergeClones
void CAMergeClones()
Definition: L1CAMergeClones.cxx:255
L1Algo::_fvecalignment
L1FieldValue targB _fvecalignment
Definition: L1Algo.h:928
L1Algo::fNThreads
int fNThreads
Definition: L1Algo.h:389
L1Algo::MaxArrSize
@ MaxArrSize
Definition: L1Algo.h:412
L1Algo::fz_pos3
nsL1::vector< fvec >::TSimd fz_pos3[nTh]
Definition: L1Algo.h:443
L1Algo::GuessVec
void GuessVec(L1TrackPar &t, fvec *xV, fvec *yV, fvec *zV, fvec *Sy, fvec *wV, int NHits, fvec *zCur=0)
---— Subroutines used by L1Algo::KFTrackFitter() ---—
Definition: L1TrackFitter.cxx:1447
L1Algo::NStsStations
int NStsStations
Definition: L1Algo.h:335
L1Algo::vStsDontUsedHits_Buf
vector< L1StsHit > vStsDontUsedHits_Buf
Definition: L1Algo.h:368
L1Algo::dUdV_to_dY
void dUdV_to_dY(const fvec &u, const fvec &v, fvec &_y, const L1Station &sta)
Definition: L1Algo.cxx:279
F32vec4
Definition: L1/vectors/P4_F32vec4.h:47
L1Algo::Err
fvec Err[nTh][nTh]
Definition: L1Algo.h:395
L1Algo::FindMoreHits
void FindMoreHits(L1Branch &t, L1TrackPar &T, const bool dir, const fvec qp0=0.0)
Definition: L1TrackExtender.cxx:199
L1Algo::fu_back3
nsL1::vector< fvec >::TSimd fu_back3[nTh]
Definition: L1Algo.h:443
L1Station.h
L1Algo::f20
void f20(Tindex n1, L1Station &stam, L1HitPoint *vStsHits_m, L1TrackPar *T_1, THitI *hitsl_1, Tindex &n2, vector< THitI > &i1_2, vector< THitI > &hitsm_2, fvec *Event, vector< bool > &lmDuplets)
Find the doublets. Reformat data in the portion of doublets.
Definition: L1CATrackFinder.cxx:435
L1Algo::vStripToTrackB
L1Vector< int > vStripToTrackB
Definition: L1Algo.h:387
L1Algo::CandidatesTrack
L1Vector< L1Branch > CandidatesTrack[nTh]
Definition: L1Algo.h:260
L1Algo::StripsToCoor
void StripsToCoor(const fscal &u, const fscal &v, fscal &x, fscal &y, const L1Station &sta) const
Definition: L1Algo.cxx:249
L1Triplet
Definition: L1Triplet.h:4
L1Grid
Definition: L1Grid.h:39
L1Station
Definition: L1Station.h:9
L1Field.h
L1Algo::FirstHitIndex
L1Vector< THitI > FirstHitIndex
Definition: L1Algo.h:276
L1Algo::MultiplySS
void MultiplySS(fvec const C[15], fvec const V[15], fvec K[5][5])
Definition: L1CAMergeClones.cxx:99
L1Algo::__attribute__
__attribute__((always_inline)) void PackLocation(unsigned int &location
L1AlgoPulls
Definition: L1AlgoPulls.h:81
L1Algo::Pick_gather
float Pick_gather
parameters which are different for different iterations. Set in the begin of CAL1TrackFinder
Definition: L1Algo.h:922
L1Algo::GetVtxFieldValue
const L1FieldValue & GetVtxFieldValue() const
Definition: L1Algo.h:453
L1Algo::UnPackIndex
int UnPackIndex(const int &i, int &a, int &b, int &c)
L1Algo::StsHitsUnusedStopIndex
THitI StsHitsUnusedStopIndex[MaxNStations+1]
Definition: L1Algo.h:427
L1Algo::f30
void f30(L1HitPoint *vStsHits_r, L1Station &stam, L1Station &star, int istam, int istar, L1HitPoint *vStsHits_m, L1TrackPar *T_1, L1FieldRegion *fld_1, THitI *hitsl_1, Tindex n2, vector< THitI > &hitsm_2, vector< THitI > &i1_2, const vector< bool > &mrDuplets, Tindex &n3, nsL1::vector< L1TrackPar >::TSimd &T_3, vector< THitI > &hitsl_3, vector< THitI > &hitsm_3, vector< THitI > &hitsr_3, nsL1::vector< fvec >::TSimd &u_front_3, nsL1::vector< fvec >::TSimd &u_back_3, nsL1::vector< fvec >::TSimd &z_Pos_3, nsL1::vector< fvec >::TSimd &du_, nsL1::vector< fvec >::TSimd &dv_, nsL1::vector< fvec >::TSimd &timeR, nsL1::vector< fvec >::TSimd &timeER)
Definition: L1CATrackFinder.cxx:609
L1Algo::iStation
unsigned int unsigned int iStation
Definition: L1Algo.h:575
L1Algo::vStsDontUsedHitsxy_B
vector< L1HitPoint > vStsDontUsedHitsxy_B
Definition: L1Algo.h:371
L1Algo::Neighbour
L1Vector< unsigned short > Neighbour
Definition: L1Algo.h:278
L1Algo::vStsDontUsedHits_B
vector< L1StsHit > vStsDontUsedHits_B
Definition: L1Algo.h:367
L1Algo::TIME_CUT1
float TIME_CUT1
Definition: L1Algo.h:915
L1Algo::vRecoHits_local
L1Vector< THitI > vRecoHits_local[nTh]
Definition: L1Algo.h:373
L1Algo::StsHitsStartIndex
const THitI * StsHitsStartIndex
Definition: L1Algo.h:358
L1Algo::MaxPortionTriplets
@ MaxPortionTriplets
Definition: L1Algo.h:408
L1Algo::vStsDontUsedHitsxy_A
vector< L1HitPoint > vStsDontUsedHitsxy_A
Definition: L1Algo.h:369
L1Algo::dUdV_to_dX
void dUdV_to_dX(const fvec &u, const fvec &v, fvec &_x, const L1Station &sta)
Definition: L1Algo.cxx:287
L1Algo::L1Algo
L1Algo(const L1Algo &)=delete
i
int i
Definition: L1/vectors/P4_F32vec4.h:25
L1Algo::EventTime
fvec EventTime[nTh][nTh]
Definition: L1Algo.h:394
L1Algo::MultiplySR
void MultiplySR(fvec const C[15], fvec const r_in[5], fvec r_out[5])
Definition: L1CAMergeClones.cxx:193
L1Algo::dx
nsL1::vector< fvec >::TSimd dx[nTh]
Definition: L1Algo.h:444
L1Algo::vStsDontUsedHits_A
vector< L1StsHit > vStsDontUsedHits_A
Definition: L1Algo.h:366
L1Algo::portionStopIndex
Tindex portionStopIndex[nSta]
Definition: L1Algo.h:262
L1Algo::fTimeR
nsL1::vector< fvec >::TSimd fTimeR[nTh]
Definition: L1Algo.h:444
L1Algo::thread
unsigned int unsigned int unsigned int & thread
Definition: L1Algo.h:576
L1Algo::MaxDZ
fvec MaxDZ
Definition: L1Algo.h:918
L1Algo::vStsStrips
const vector< L1Strip > * vStsStrips
Definition: L1Algo.h:340
L1Algo::RealIHitPBuf
vector< THitI > * RealIHitPBuf
Definition: L1Algo.h:423
L1Algo::KFTrackFitter_simple
void KFTrackFitter_simple()
Track fitting procedures.
Definition: L1TrackFitter.cxx:39
L1Algo::StsHitsStopIndex
const THitI * StsHitsStopIndex
Definition: L1Algo.h:359
L1Algo::Portion
@ Portion
Definition: L1Algo.h:405
L1Algo::vTracks_local
L1Vector< L1Track > vTracks_local[nTh]
Definition: L1Algo.h:372
L1StsHit
Definition: L1StsHit.h:12
L1Algo::StsHitsUnusedStartIndex
THitI StsHitsUnusedStartIndex[MaxNStations+1]
Definition: L1Algo.h:426
L1Algo::fu_front3
nsL1::vector< fvec >::TSimd fu_front3[nTh]
Definition: L1Algo.h:443
L1Algo::TrackChi2
L1Vector< float > TrackChi2
Definition: L1Algo.h:279
L1Algo::vRecoHitsNew
L1Vector< THitI > vRecoHitsNew
Definition: L1Algo.h:282
L1Algo::nTripletsThread
int nTripletsThread[nSta][nTh]
Definition: L1Algo.h:271
L1Algo::TripletsStaPort
void TripletsStaPort(int istal, int istam, int istar, Tindex &nstaltriplets, L1TrackPar *T_1, L1FieldRegion *fld_1, THitI *hitsl_1, Tindex &n_2, vector< THitI > &i1_2, vector< THitI > &hitsm_2, const vector< bool > &mrDuplets)
Find triplets on station.
Definition: L1CATrackFinder.cxx:1576
L1Algo::targY
fvec targY
Definition: L1Algo.h:927
L1Algo::vStsStripsB
const vector< L1Strip > * vStsStripsB
Definition: L1Algo.h:341
L1Algo::fUseHitErrors
bool fUseHitErrors
Definition: L1Algo.h:390
L1Algo::StsHitsUnusedStartIndexEnd
THitI StsHitsUnusedStartIndexEnd[MaxNStations+1]
Definition: L1Algo.h:428
L1Strip.h
L1Algo::operator=
L1Algo operator=(const L1Algo &)=delete
L1Algo::__attribute__
__attribute__((always_inline)) void UnPackStation(unsigned int &location
L1Algo::coeff
@ coeff
Definition: L1Algo.h:403
L1Algo::GetVtxFieldRegion
const L1FieldRegion & GetVtxFieldRegion() const
Definition: L1Algo.h:454
L1Algo::MaxInvMom
fvec MaxInvMom
Definition: L1Algo.h:925
L1Algo::NFStations
int NFStations
Definition: L1Algo.h:335
L1Algo::_fvecalignment
L1FieldRegion vtxFieldRegion _fvecalignment
Definition: L1Algo.h:932
L1Vector< L1Triplet >
L1Track.h
L1Algo::FirstHit
L1Vector< unsigned short > FirstHit
Definition: L1Algo.h:274
L1Algo::SavedHits
int SavedHits[nTh]
Definition: L1Algo.h:267
L1AlgoEfficiencyPerformance
Definition: L1AlgoEfficiencyPerformance.h:123
L1Algo::BranchExtender
fscal BranchExtender(L1Branch &t)
Try to extrapolate and find additional hits on other stations.
Definition: L1TrackExtender.cxx:396
L1Algo::vStsHitPointsUnused
vector< L1HitPoint > * vStsHitPointsUnused
Definition: L1Algo.h:424
L1Algo::kFastPrimJumpIter
@ kFastPrimJumpIter
Definition: L1Algo.h:878
L1Algo::fMomentumCutOff
float fMomentumCutOff
Definition: L1Algo.h:944
L1Algo::kAllPrimEIter
@ kAllPrimEIter
Definition: L1Algo.h:875
L1Algo::_fvecalignment
L1FieldValue vtxFieldValue _fvecalignment
Definition: L1Algo.h:933
L1Algo::NTracksIsecAll
unsigned int NTracksIsecAll
Definition: L1Algo.h:364
THitI
unsigned int THitI
Definition: L1StsHit.h:8
L1Algo::__attribute__
__attribute__((always_inline)) void SetFUnUsed(unsigned char &flag)
Definition: L1Algo.h:603
L1Algo::vTracksNew
L1Vector< L1Track > vTracksNew
Definition: L1Algo.h:283
L1Algo::L1KFTrackFitterMuch
void L1KFTrackFitterMuch()
Definition: L1TrackFitter.cxx:775
L1Algo::vSFlagB
const vector< unsigned char > * vSFlagB
Definition: L1Algo.h:351
L1Algo::NStations
int NStations
Definition: L1Algo.h:333
_fvecalignment
class L1Algo _fvecalignment
L1Algo::FilterFirstL
void FilterFirstL(L1TrackParFit &track, fvec &x, fvec &y, fvec &t, fvec &t_er, L1Station &st, fvec &dx, fvec &dy, fvec &dxy)
Definition: L1TrackFitter.cxx:1751
L1Algo::targX
fvec targX
Definition: L1Algo.h:927
L1FieldRegion
Definition: L1Field.h:85
L1Algo::fT_3
nsL1::vector< L1TrackPar >::TSimd fT_3[nTh]
Definition: L1Algo.h:439
fvecLen
const int fvecLen
Definition: L1/vectors/P4_F32vec4.h:251
L1Algo::__attribute__
__attribute__((always_inline)) void UnPackTriplet(unsigned int &location
L1Algo::kFastPrimIter2
@ kFastPrimIter2
Definition: L1Algo.h:879
L1Algo::NHitsIsecAll
unsigned int NHitsIsecAll
Definition: L1Algo.h:363
L1Algo::RealIHit_v_buf2
vector< THitI > RealIHit_v_buf2
Definition: L1Algo.h:377
L1Algo::InvertCholetsky
void InvertCholetsky(fvec a[15])
--— Subroutines used by L1Algo::CAMergeClones() ---—
Definition: L1CAMergeClones.cxx:26
L1Algo::L1Algo
L1Algo(int nThreads=1, int TypicalSize=200000)
Definition: L1Algo.h:82
L1Algo::__attribute__
__attribute__((always_inline)) void UnPackThread(unsigned int &location
L1Algo::multiCoeff
@ multiCoeff
Definition: L1Algo.h:400
L1Algo::fTimeER
nsL1::vector< fvec >::TSimd fTimeER[nTh]
Definition: L1Algo.h:444
tracks
TClonesArray * tracks
Definition: Analyze_matching.h:17
L1Algo::vStsDontUsedHitsxy_buf
vector< L1HitPoint > vStsDontUsedHitsxy_buf
Definition: L1Algo.h:370
L1TrackParFit.h
L1Algo::MaxNPortion
@ MaxNPortion
Definition: L1Algo.h:409
L1Algo::dv
nsL1::vector< fvec >::TSimd dv[nTh]
Definition: L1Algo.h:444
L1Algo::numberCandidateThread
int numberCandidateThread[nTh]
Definition: L1Algo.h:269
L1Algo::PickNeighbour
float PickNeighbour
Definition: L1Algo.h:924
L1Algo::targZ
fvec targZ
Definition: L1Algo.h:927
L1XYMeasurementInfo
Definition: L1XYMeasurementInfo.h:7
L1Algo::f10
void f10(Tindex start_lh, Tindex n1_l, L1HitPoint *StsHits_l, fvec *u_front_l, fvec *u_back_l, fvec *zPos_l, THitI *hitsl, fvec *HitTime_l, fvec *HitTimeEr, fvec *Event_l, fvec *d_x, fvec *d_y, fvec *d_xy, fvec *d_u, fvec *d_v)
Prepare the portion of left hits data.
Definition: L1CATrackFinder.cxx:73
L1TrackPar.h
L1Algo::TRACK_CHI2_CUT
float TRACK_CHI2_CUT
Definition: L1Algo.h:911
L1Algo::fhitsm_3
vector< THitI > fhitsm_3[nTh]
Definition: L1Algo.h:441
L1HitPoint.h
L1Algo::CAFindTrack
void CAFindTrack(int ista, L1Branch &best_tr, unsigned char &best_L, fscal &best_chi2, const L1Triplet *curr_trip, L1Branch &curr_tr, unsigned char &curr_L, fscal &curr_chi2, unsigned char min_best_l, L1Branch *new_tr)
================================= FUNCTIONAL PART =================================
Definition: L1CATrackFinder.cxx:2902
L1Algo::vSFlag
const vector< unsigned char > * vSFlag
Definition: L1Algo.h:350
L1Algo::vTracks
L1Vector< L1Track > vTracks
Definition: L1Algo.h:355
L1Algo::StsHitsUnusedStopIndexEnd
THitI StsHitsUnusedStopIndexEnd[MaxNStations+1]
Definition: L1Algo.h:429
L1Algo::__attribute__
__attribute__((always_inline)) void SetFUsed(unsigned char &flag)
Definition: L1Algo.h:599
L1Algo::kAllSecEIter
@ kAllSecEIter
Definition: L1Algo.h:876
L1Branch
Definition: L1Branch.h:27
L1Algo::BranchFitter
void BranchFitter(const L1Branch &t, L1TrackPar &T, const bool dir, const fvec qp0=0., const bool initParams=true)
Fit track. more precise than FitterFast.
Definition: L1TrackExtender.cxx:181
CbmL1Track.h
L1Algo::_fvecalignment
L1XYMeasurementInfo TargetXYInfo _fvecalignment
Definition: L1Algo.h:929
L1Algo::RealIHit
THitI * RealIHit
Definition: L1Algo.h:425
L1Algo::vStripToTrack
L1Vector< int > vStripToTrack
Definition: L1Algo.h:386
L1Algo
Definition: L1Algo.h:79
L1Algo::MaxSlope
fvec MaxSlope
Definition: L1Algo.h:926
L1Algo::RealIHit_v_buf
vector< THitI > RealIHit_v_buf
Definition: L1Algo.h:376
L1Algo::numPortions
int numPortions[12]
Definition: L1Algo.h:937
L1Algo::FIRSTCASTATION
Tindex FIRSTCASTATION
================================= DATA PART =================================
Definition: L1Algo.h:865
L1Algo::dy
nsL1::vector< fvec >::TSimd dy[nTh]
Definition: L1Algo.h:444
L1Algo::TripletsLocal
vector< L1Triplet * > * TripletsLocal[MaxNStations - 2]
Definition: L1Algo.h:938
L1Algo::fhitsl_3
vector< THitI > fhitsl_3[nTh]
Definition: L1Algo.h:441
L1Algo::__attribute__
__attribute__((always_inline)) void SetFStation(unsigned char &flag
L1Algo::TRIPLET_CHI2_CUT
float TRIPLET_CHI2_CUT
Definition: L1Algo.h:913
L1Algo::fhitsr_3
vector< THitI > fhitsr_3[nTh]
Definition: L1Algo.h:441
L1Algo::Init
void Init(const vector< fscal > &geo, const bool UseHitErrors, const bool mCBMmode)
Definition: L1Algo.cxx:5
L1Algo::threadNumberToCpuMap
map< int, int > threadNumberToCpuMap
Definition: L1Algo.h:908
L1Algo::RealIHit_v
vector< THitI > RealIHit_v
Definition: L1Algo.h:375
L1Algo::MaxPortionDoublets
@ MaxPortionDoublets
Definition: L1Algo.h:407
L1Algo::TripForHit
vector< int > TripForHit[2]
Definition: L1Algo.h:432
L1HitsSortHelper.h
L1Algo::CATime
double CATime
Definition: L1Algo.h:353
L1Algo::__attribute__
__attribute__((always_inline)) static bool GetFUsed(unsigned char flag)
Definition: L1Algo.h:501
L1Algo::DupletsStaPort
void DupletsStaPort(int istal, int istam, Tindex ip, vector< Tindex > &n_g, Tindex *portionStopIndex_, L1TrackPar *T_1, L1FieldRegion *fld_1, THitI *hitsl_1, vector< bool > &lmDuplets, Tindex &n_2, vector< THitI > &i1_2, vector< THitI > &hitsm_2)
Find doublets on station.
Definition: L1CATrackFinder.cxx:1446
L1Algo::vRecoHits
L1Vector< THitI > vRecoHits
Definition: L1Algo.h:356
L1Algo::RealIHitP
vector< THitI > * RealIHitP
Definition: L1Algo.h:422
L1Algo::NMvdStations
int NMvdStations
Definition: L1Algo.h:334
L1Algo::vGrid
L1Grid vGrid[MaxNStations]
Definition: L1Algo.h:346
Tindex
int Tindex
Definition: L1Algo.h:76
v
__m128 v
Definition: L1/vectors/P4_F32vec4.h:1
L1Algo::_fvecalignment
L1Station vStations[MaxNStations] _fvecalignment
Definition: L1Algo.h:336
L1Algo::L1KFTrackFitter
void L1KFTrackFitter()
Definition: L1TrackFitter.cxx:335
L1Algo::nTh
static const int nTh
Definition: L1Algo.h:256
x
Double_t x
Definition: CbmMvdSensorDigiToHitTask.cxx:68
L1Algo::n_g1
L1Vector< Tindex > n_g1
Definition: L1Algo.h:263
L1Algo::FilterTracks
void FilterTracks(fvec const r[5], fvec const C[15], fvec const m[5], fvec const V[15], fvec R[5], fvec W[15], fvec *chi2)
Definition: L1CAMergeClones.cxx:206
L1Algo::PackIndex
int PackIndex(const int &a, const int &b, const int &c)
L1TrackPar
Definition: L1TrackPar.h:6
L1StsHit.h
L1Algo::f31
void f31(Tindex n3_V, L1Station &star, nsL1::vector< fvec >::TSimd &u_front_3, nsL1::vector< fvec >::TSimd &u_back_3, nsL1::vector< fvec >::TSimd &z_Pos_3, nsL1::vector< fvec >::TSimd &du_, nsL1::vector< fvec >::TSimd &dv_, nsL1::vector< fvec >::TSimd &timeR, nsL1::vector< fvec >::TSimd &timeER, nsL1::vector< L1TrackPar >::TSimd &T_3)
Add the right hits to parameters estimation.
Definition: L1CATrackFinder.cxx:950
nsL1::vector::TSimd
std::vector< T > TSimd
Definition: L1/vectors/PSEUDO_F32vec1.h:148
m
__m128 m
Definition: L1/vectors/P4_F32vec4.h:26
y
Double_t y
Definition: CbmMvdSensorDigiToHitTask.cxx:68
L1Algo::__attribute__
__attribute__((always_inline)) static unsigned char GetFStation(unsigned char flag)
– Flags routines –
Definition: L1Algo.h:497
L1TrackParFit
Definition: L1TrackParFit.h:12
L1Algo::dUdV_to_dXdY
void dUdV_to_dXdY(const fvec &u, const fvec &v, fvec &_xy, const L1Station &sta)
Definition: L1Algo.cxx:295
L1Algo::nSta
static const int nSta
Definition: L1Algo.h:257
L1Algo::kAllPrimJumpIter
@ kAllPrimJumpIter
Definition: L1Algo.h:873
L1Algo::MultiplyMS
void MultiplyMS(fvec const C[5][5], fvec const V[15], fvec K[15])
Definition: L1CAMergeClones.cxx:156
L1Algo::kFastPrimIter
@ kFastPrimIter
Definition: L1Algo.h:871
L1Branch.h
L1Algo::fNFindIterations
@ fNFindIterations
Definition: L1Algo.h:889
L1Algo::kAllSecIter
@ kAllSecIter
Definition: L1Algo.h:874
L1Algo::MaxNStations
@ MaxNStations
Definition: L1Algo.h:331
L1Algo::TIME_CUT2
float TIME_CUT2
Definition: L1Algo.h:915
L1Algo::du
nsL1::vector< fvec >::TSimd du[nTh]
Definition: L1Algo.h:444
L1Algo::f11
void f11(int istal, int istam, Tindex n1_V, fvec *u_front_l, fvec *u_back_l, fvec *zPos_l, fvec *HitTime_l, fvec *HitTimeEr, L1TrackPar *T_1, L1FieldRegion *fld_1, fvec *d_x, fvec *d_y, fvec *d_xy, fvec *d_u, fvec *d_v)
Get the field approximation. Add the target to parameters estimation. Propagate to middle station.
Definition: L1CATrackFinder.cxx:124
L1Algo::PrintHits
void PrintHits()
L1Algo::f32
void f32(Tindex n3, int istal, nsL1::vector< L1TrackPar >::TSimd &T_3, vector< THitI > &hitsl_3, vector< THitI > &hitsm_3, vector< THitI > &hitsr_3, int nIterations=0)
Refit Triplets.
Definition: L1CATrackFinder.cxx:1004
L1AlgoDraw
Definition: L1AlgoDraw.h:29
CbmL1
Definition: CbmL1.h:113
L1Algo::isec
int isec
— data used during finding iterations
Definition: L1Algo.h:420
L1Algo::SetNThreads
void SetNThreads(int n=1)
--— Input data --—
Definition: L1Algo.h:329
L1Algo::fRadThick
vector< L1Material > fRadThick
Definition: L1Algo.h:337
DRAW
#define DRAW
Definition: CbmTrdFASP.cxx:25
L1Algo::GetHitCoor
void GetHitCoor(const L1StsHit &_h, fscal &_x, fscal &_y, fscal &_z, const L1Station &sta)
--— Hit-point-strips conversion routines ---—
Definition: L1Algo.cxx:235
L1FieldValue
Definition: L1Field.h:11
L1Triplet.h
L1Algo::CreateHitPoint
L1HitPoint CreateHitPoint(const L1StsHit &hit, char ista)
full the hit point by hit information: takes hit as input (2 strips) and creates hit_point with all c...
Definition: L1Algo.cxx:318
L1Algo::DOUBLET_CHI2_CUT
float DOUBLET_CHI2_CUT
Definition: L1Algo.h:914
L1Algo::fGlobal
bool fGlobal
Definition: L1Algo.h:392
L1Algo::CATrackFinder
void CATrackFinder()
The main procedure - find tracks.
Definition: L1CATrackFinder.cxx:1786
L1Algo::fTrackingLevel
int fTrackingLevel
Definition: L1Algo.h:943
L1Algo::SetData
void SetData(const vector< L1StsHit > &StsHits_, const vector< L1Strip > &StsStrips_, const vector< L1Strip > &StsStripsB_, const vector< fscal > &StsZPos_, const vector< unsigned char > &SFlag_, const vector< unsigned char > &SFlagB_, const THitI *StsHitsStartIndex_, const THitI *StsHitsStopIndex_)
Definition: L1Algo.cxx:179
L1Algo::LastHitIndex
L1Vector< THitI > LastHitIndex
Definition: L1Algo.h:277
L1Algo::BranchFitterFast
void BranchFitterFast(const L1Branch &t, L1TrackPar &T, const bool dir, const fvec qp0=0., const bool initParams=true)
Definition: L1TrackExtender.cxx:25
L1Algo::f5
void f5(int *nlevel)
Find neighbours of triplets. Calculate level of triplets.
Definition: L1CATrackFinder.cxx:1338
L1Grid.h
L1Algo::kAllSecJumpIter
@ kAllSecJumpIter
Definition: L1Algo.h:880
L1Algo::FilterFirst
void FilterFirst(L1TrackPar &track, fvec &x, fvec &y, L1Station &st)
Definition: L1TrackFitter.cxx:1611