CbmRoot
Loading...
Searching...
No Matches
HitFinder2D.h
Go to the documentation of this file.
1/* Copyright (C) 2024 Facility for Antiproton and Ion Research in Europe, Darmstadt
2 SPDX-License-Identifier: GPL-3.0-only
3 Authors: Dominik Smith [committer], Alexandru Bercuci */
4
5#pragma once
6
7#include "CbmTrdDigi.h"
8#include "Cluster2D.h"
9#include "DigiRec.h"
10#include "Hit.h"
11#include "HitFactory2D.h"
12#include "HitFinder2DPars.h"
13#include "Math/Rotation3D.h"
14#include "Math/Vector3Dfwd.h"
15
16#include <cstdint>
17#include <tuple>
18#include <unordered_map>
19#include <vector>
20
21#define NANODE 9
22
23using std::vector;
24
25namespace cbm::algo::trd
26{
27
43 public:
44 typedef std::pair<Hit, std::vector<DigiRec>> resultType;
45
48
51
52 virtual ~HitFinder2D(){};
53
55 std::vector<resultType> operator()(std::vector<Cluster2D>* clusters);
56
57 std::pair<int, HitFactory2D> ProjectDigis(const Cluster2D* cluster);
61 bool BuildHit(Hit* h, HitFactory2D& hitF);
62
66 void SetHitTimeOffset(int dt) { fHitTimeOff = dt; }
67
68 private:
70 const HitFinder2D& operator=(const HitFinder2D& ref);
71
72 Hit MakeHit(int cId, const Cluster2D* cluster);
73
75
77
82 inline int GetPadRowCol(int address, int& c);
83
84 void CalibrateHit(Hit* h, const double dx, const double dy, const double edx, const double edy, const double edt,
85 const double time, const double tdrift, const double eloss, const HitFactory2D& hitF);
86
87 int fHitTimeOff = 0;
88
89 static Double_t fgDT[3];
90 };
91
92
93} // namespace cbm::algo::trd
Data class with information on a STS local track.
static float Clk(eCbmTrdAsicType ty)
DAQ clock accessor for each ASIC.
Definition CbmTrdDigi.h:109
Data Container for TRD clusters.
Definition Cluster2D.h:22
Cluster finding and hit reconstruction algorithms for the TRD(2D) module.
Definition HitFinder2D.h:42
HitFinder2D(const HitFinder2D &ref)
static Double_t fgDT[3]
hit time offset for synchronization
Definition HitFinder2D.h:89
HitFinder2DModPar fParams
Parameter container.
Definition HitFinder2D.h:76
Hit MakeHit(int cId, const Cluster2D *cluster)
void SetHitTimeOffset(int dt)
Time offset to synchronize TRD2D hits to the rest of detectors.
Definition HitFinder2D.h:66
void CalibrateHit(Hit *h, const double dx, const double dy, const double edx, const double edy, const double edt, const double time, const double tdrift, const double eloss, const HitFactory2D &hitF)
std::pair< Hit, std::vector< DigiRec > > resultType
Definition HitFinder2D.h:44
int GetPadRowCol(int address, int &c)
Addressing ASIC on module based on id.
const HitFinder2D & operator=(const HitFinder2D &ref)
std::vector< resultType > operator()(std::vector< Cluster2D > *clusters)
Steering routine for building hits.
HitFinder2D()
Default constructor.
Definition HitFinder2D.h:47
std::pair< int, HitFactory2D > ProjectDigis(const Cluster2D *cluster)
bool BuildHit(Hit *h, HitFactory2D &hitF)
Implement topologic cuts for hit merging.
A light-weight TRD hit class for online reconstruction, based on CbmTrdHit. .
A light-weight TRD hit class for online reconstruction, based on CbmTrdHit. .