25 McTrack other(std::move(*
this));
77 int currNofConsStationsWithHit = 0;
78 int currMaxNofHitsOnStation = 0;
82 int iSt = vHits[iH].iStation;
94 currMaxNofHitsOnStation++;
100 currMaxNofHitsOnStation = 1;
106 if (iSt - iStPrev == 1) {
107 currNofConsStationsWithHit++;
109 else if (iSt - iStPrev > 1) {
113 currNofConsStationsWithHit = 1;
134 int currMaxNofPointsOnStation = 0;
135 int currMaxNofPointsOnSensor = 0;
141 const auto& point = vPoints[iP];
142 int iSt = point.GetActiveStationId();
145 if (iSt == iStPrev) {
146 currMaxNofPointsOnStation++;
152 currMaxNofPointsOnStation = 1;
159 if (point.GetZ() == zPrev) {
160 currMaxNofPointsOnSensor++;
166 currMaxNofPointsOnSensor = 1;
170 zPrev = point.GetZ();
181 int currNofConsStationsWithPoint = 0;
185 int iSt = vPoints[iP].GetActiveStationId();
188 if (iSt - iStPrev == 1) {
189 currNofConsStationsWithPoint++;
191 else if (iSt - iStPrev > 1) {
195 currNofConsStationsWithPoint = 1;
198 if (iSt <= iStPrev) {
221 std::stringstream msg;
224 msg << setw(8) << setfill(
' ') <<
"ID" <<
' ';
225 msg << setw(8) << setfill(
' ') <<
"Mother" <<
' ';
226 msg << setw(8) << setfill(
' ') <<
"PDG" <<
' ';
228 msg << setw(8) << setfill(
' ') <<
"N h." <<
' ';
229 msg << setw(8) << setfill(
' ') <<
"N p." <<
' ';
230 msg << setw(8) << setfill(
' ') <<
"N r.tr." <<
' ';
232 msg << setw(8) << setfill(
' ') <<
"N t.tr." <<
' ';
234 msg << setw(12) << setfill(
' ') <<
"zVTX [cm]" <<
' ';
235 msg << setw(12) << setfill(
' ') <<
"t [ns]" <<
' ';
236 msg << setw(12) << setfill(
' ') <<
"p [GeV/c]" <<
' ';
238 msg << setw(8) << setfill(
' ') <<
"rec-able" <<
' ';
239 msg << setw(8) << setfill(
' ') <<
"rec-ed" <<
' ';
244 msg << setw(8) << setfill(
' ') <<
fId <<
' ';
245 msg << setw(8) << setfill(
' ') <<
fMotherId <<
' ';
246 msg << setw(8) << setfill(
' ') <<
fPdgCode <<
' ';
248 msg << setw(8) << setfill(
' ') <<
GetNofHits() <<
' ';
249 msg << setw(8) << setfill(
' ') <<
GetNofPoints() <<
' ';
254 msg << setw(12) << setfill(
' ') <<
GetStartZ() <<
' ';
255 msg << setw(12) << setfill(
' ') <<
GetStartT() <<
' ';
256 msg << setw(12) << setfill(
' ') <<
GetP() <<
' ';
261 msg <<
"\n\t- point indexes: ";
265 msg <<
"\n\t- hit indexes: ";
269 msg <<
"\n\t- reconstructed track indexes: ";
274 msg <<
"\n\t- touch track indexes: ";
Internal class describing a MC point for CA tracking QA and performance (header)
Class represents a MC track for CA tracking QA and performance (implementation)
void Clear()
Clears contents.
Class describes a unified MC-point, used in CA tracking QA analysis.
void SetCharge(double charge)
Sets particle charge [e].
void SetPdgCode(int pdg)
Sets PDG code.
void SetPy(double py)
Sets track momentum y component at reference z of station [GeV/c].
void SetYIn(double y)
Sets y coordinate at entrance to station [cm].
void SetZ(double z)
Sets z coordinate at reference z of station [cm].
void SetPx(double px)
Sets track momentum x component at reference z of station [GeV/c].
void SetYOut(double y)
Sets x coordinate at exit of station [cm].
void SetMass(double mass)
Sets particle mass [GeV/c2].
void SetXOut(double x)
Sets x coordinate at exit of station [cm].
void SetPxIn(double px)
Sets track momentum x component at entrance to station [GeV/c].
void SetPyIn(double py)
Sets track momentum y component at entrance to station [GeV/c].
void SetFileId(int fileId)
Sets index of MC file containing this point.
void SetTime(double time)
Sets time [ns].
void SetZIn(double z)
Sets z coordinate at entrance to station [cm].
void SetPzIn(double pz)
Sets track momentum z component at entrance to station [GeV/c].
void SetPyOut(double py)
Sets track momentum y component at exit of station [GeV/c].
void SetEventId(int eventId)
Sets index of MC event containing this point.
void SetPzOut(double pz)
Sets track momentum z component at exit of station [GeV/c].
void SetX(double x)
Sets x coordinate at reference z of station [cm].
void SetY(double y)
Sets y coordinate at reference z of station [cm].
void SetPxOut(double px)
Sets track momentum x component at exit of station [GeV/c].
void SetXIn(double x)
Sets x coordinate at entrance to station [cm].
void SetExternalId(int id)
Sets index of this point in external data structures.
void SetMotherId(int motherId)
Sets index of mother track in the internal CA data structures.
void SetId(int id)
Sets index of this point in the CA internal structure.
void SetPz(double pz)
Sets track momentum z component at reference z of station [GeV/c].
void SetZOut(double z)
Sets z coordinate at exit of station [cm].
int fMaxNofPointsOnSensor
Max number of MC points with same Z (means on same sensor)
void ClearRecoTrackIndexes()
Clears container of reconstructed track indexes.
int fPdgCode
PDG encoding.
double GetPx() const
Gets x component of momentum [GeV/c].
int fId
Index of MC track in internal container for TS/event.
bool IsReconstructed() const
McPoint GetVertexPoint() const
Creates an MC point from the track vertex.
bool IsReconstructable() const
ca::Vector< int > fvTouchTrackIndexes
void ClearHitIndexes()
Clears container of hit indexes.
double GetStartX() const
Gets x component of the track vertex [cm].
double GetStartZ() const
Gets z component of the track vertex [cm].
ca::Vector< int > fvRecoTrackIndexes
Indexes of associated reco tracks.
int GetNofHits() const
Gets number of hits.
std::string ToString(int verbose=1, bool header=false) const
Provides string representation of a track.
int GetNofTouchTracks() const
Gets number of reconstructed tracks, which contain hits from this MC track.
int fMotherId
Index of mother MC track in the external tracks container.
int GetNofRecoTracks() const
Gets number of assigned reconstructed tracks.
void InitHitsInfo(const ca::Vector< cbm::algo::ca::McHitInfo > &vHits)
Initializes information about MC track hits arrangement within stations Defines: #1) Number of statio...
ca::Vector< int > fvHitIndexes
Indexes of hits in int.container.
void SortPointIndexes(const std::function< bool(const int &lhs, const int &rhs)> &cmpFn)
int fNofConsStationsWithPoint
Number of consecutive stations with points.
int fMaxNofPointsOnStation
Max number of MC points on a station.
void ClearPointIndexes()
Clears container of point indexes.
int GetMotherId() const
Gets index of mother track in CA internal data structures.
double GetMass() const
Gets particle mass [GeV/c2].
int GetNofPoints() const
Gets number of points.
double GetCharge() const
Gets charge [e].
int fTotNofStationsWithPoint
Total number of stations with MC points.
int fNofConsStationsWithHit
Number of consecutive stations with hits.
int GetFileId() const
Gets index of MC file containing this track in external data structures.
int GetEventId() const
Gets index of MC event containing this track in external data structures.
double GetP() const
Gets absolute momentum [GeV/c].
void ClearTouchTrackIndexes()
int fTotNofStationsWithHit
Total number of stations with hits.
double GetStartT() const
Gets time of the track vertex [ns].
void InitPointsInfo(const ca::Vector< McPoint > &vPoints)
Initializes information about MC track points arrangement within stations Defines: #1) Number of stat...
ca::Vector< int > fvPointIndexes
Indexes of MC points in ext.container.
int fMaxNofHitsOnStation
Max number of hits on a station.
double GetPz() const
Gets x component of momentum [GeV/c].
double GetPy() const
Gets x component of momentum [GeV/c].
McTrack()=default
Default constructor.
int GetPdgCode() const
Gets PDG encoding.
double GetStartY() const
Gets y component of the track vertex [cm].