Project
Loading...
Searching...
No Matches
ResidualsControllerFast.h
Go to the documentation of this file.
1// Copyright 2019-2020 CERN and copyright holders of ALICE O2.
2// See https://alice-o2.web.cern.ch/copyright for details of the copyright holders.
3// All rights not expressly granted are reserved.
4//
5// This software is distributed under the terms of the GNU General Public
6// License v3 (GPL Version 3), copied verbatim in the file "COPYING".
7//
8// In applying this license CERN does not waive the privileges and immunities
9// granted to it by virtue of its status as an Intergovernmental Organization
10// or submit itself to any jurisdiction.
11
16
17#ifndef RESIDUALSCONTROLLERFAST_H
18#define RESIDUALSCONTROLLERFAST_H
19
20#include <TObject.h>
21
22namespace o2
23{
24namespace align
25{
26
27class ResidualsControllerFast final : public TObject
28{
29 public:
30 enum { kCosmicBit = BIT(14),
31 kVertexBit = BIT(15) };
32 //
35 //
36 void setNPoints(int n)
37 {
38 mNPoints = n;
39 resize(n);
40 }
41 void setNMatSol(int n) { mNMatSol = n; }
42 //
43 void setChi2(float v) { mChi2 = v; }
44 float getChi2() const { return mChi2; }
45 //
46 void setChi2Ini(float v) { mChi2Ini = v; }
47 float getChi2Ini() const { return mChi2Ini; }
48 //
49 bool isCosmic() const { return TestBit(kCosmicBit); }
50 bool hasVertex() const { return TestBit(kVertexBit); }
51 void setCosmic(bool v = true) { SetBit(kCosmicBit, v); }
52 void setHasVertex(bool v = true) { SetBit(kVertexBit, v); }
53 //
54 int getNPoints() const { return mNPoints; }
55 int getNMatSol() const { return mNMatSol; }
56 int getNBook() const { return mNBook; }
57 float getD0(int i) const { return mD0[i]; }
58 float getD1(int i) const { return mD1[i]; }
59 float getSig0(int i) const { return mSig0[i]; }
60 float getSig1(int i) const { return mSig1[i]; }
61 int getVolID(int i) const { return mVolID[i]; }
62 int getLabel(int i) const { return mLabel[i]; }
63 //
64 float* getTrCor() const { return (float*)mTrCorr; }
65 float* getD0() const { return (float*)mD0; }
66 float* getD1() const { return (float*)mD1; }
67 float* getSig0() const { return (float*)mSig0; }
68 float* getSig1() const { return (float*)mSig1; }
69 int* getVolID() const { return (int*)mVolID; }
70 int* getLaber() const { return (int*)mLabel; }
71 float* getSolMat() const { return (float*)mSolMat; }
72 float* getMatErr() const { return (float*)mMatErr; }
73 //
74 void setResSigMeas(int ip, int ord, float res, float sig);
75 void setMatCorr(int id, float res, float sig);
76 void setLabel(int ip, int lab, int vol);
77 //
78 void resize(int n);
79 void Clear(const Option_t* opt = "") final;
80 void Print(const Option_t* opt = "") const final;
81 //
83 //
84 // -------- dummies --------
87 //
89 //
90 int mNPoints; // n meas points
91 int mNMatSol; // n local params - ExtTrPar corrections
92 int mNBook;
93 float mChi2; // chi2
94 float mChi2Ini; // chi2 before local fit
95 //
96 float mTrCorr[5]; // correction to ExternalTrackParam
97 float* mD0; //[mNPoints] 1st residual (track - meas)
98 float* mD1; //[mNPoints] 2ns residual (track - meas)
99 float* mSig0; //[mNPoints] ort. error 0
100 float* mSig1; //[mNPoints] ort. errir 1
101 int* mVolID; //[mNPoints] volume id (0 for vertex constraint)
102 int* mLabel; //[mNPoints] label of the volume
103 //
104 float* mSolMat; //[mNMatSol] // material corrections
105 float* mMatErr; //[mNMatSol] // material corrections errors
106 //
108};
109} // namespace align
110} // namespace o2
111#endif
int32_t i
#define protected
uint32_t res
Definition RawData.h:0
void setLabel(int ip, int lab, int vol)
void setResSigMeas(int ip, int ord, float res, float sig)
void setMatCorr(int id, float res, float sig)
ClassDef(ResidualsControllerFast, 1)
void Clear(const Option_t *opt="") final
void Print(const Option_t *opt="") const final
GLdouble n
Definition glcorearb.h:1982
const GLdouble * v
Definition glcorearb.h:832
void align(gsl::span< ElinkEncoder< BareFormat, CHARGESUM > > elinks)
a couple of static helper functions to create timestamp values for CCDB queries or override obsolete ...