15#ifndef GPUTRDINTERFACES_H
16#define GPUTRDINTERFACES_H
31class propagatorInterface;
40GPUdi() trackInterface<
o2::track::
TrackParCov>::trackInterface(const GPUTPCGMMergedTrack& trk) {
set(trk.OuterParam().X, trk.OuterParam().alpha, trk.OuterParam().P, trk.OuterParam().C); }
52 GPUdi()
bool propagateToX(
float x,
float maxSnp,
float maxStep) {
return mProp->PropagateToXBxByBz(*mParam,
x, maxSnp, maxStep); }
53 GPUdi() int32_t getPropagatedYZ(
float x,
float& projY,
float& projZ) {
return static_cast<int32_t
>(mParam->getYZAt(
x, mProp->getNominalBz(), projY, projZ)); }
58 GPUdi() float getAlpha() {
return (mParam) ? mParam->getAlpha() : 99999.f; }
59 GPUdi() bool update(const
float p[2], const
float cov[3])
64 return mParam->update(pTmp, covTmp);
69 GPUdi() float getPredictedChi2(const
float p[2], const
float cov[3])
73 gpustd::array<float, 3> covTmp = {cov[0], cov[1], cov[2]};
74 return mParam->getPredictedChi2(pTmp, covTmp);
79 GPUdi() bool rotate(
float alpha) {
return (mParam) ? mParam->rotate(
alpha) :
false; }
81 trackInterface<o2::track::TrackParCov>* mParam{
nullptr};
106 for (int32_t
i = 0;
i < 5;
i++) {
109 for (int32_t
i = 0;
i < 15;
i++) {
117 SetX(
param.getParamOut().getX());
118 SetPar(0,
param.getParamOut().getY());
119 SetPar(1,
param.getParamOut().getZ());
120 SetPar(2,
param.getParamOut().getSnp());
121 SetPar(3,
param.getParamOut().getTgl());
122 SetPar(4,
param.getParamOut().getQ2Pt());
123 for (int32_t
i = 0;
i < 15;
i++) {
124 SetCov(
i,
param.getParamOut().getCov()[
i]);
129 SetX(
param.getParamOut().getX());
130 SetPar(0,
param.getParamOut().getY());
131 SetPar(1,
param.getParamOut().getZ());
132 SetPar(2,
param.getParamOut().getSnp());
133 SetPar(3,
param.getParamOut().getTgl());
134 SetPar(4,
param.getParamOut().getQ2Pt());
135 for (int32_t
i = 0;
i < 15;
i++) {
136 SetCov(
i,
param.getParamOut().getCov()[
i]);
144 GPUd() float getAlpha()
const {
return mAlpha; }
145 GPUd() float getY()
const {
return GetY(); }
146 GPUd() float getZ()
const {
return GetZ(); }
147 GPUd() float getSnp()
const {
return GetSinPhi(); }
148 GPUd() float getTgl()
const {
return GetDzDs(); }
149 GPUd() float getQ2Pt()
const {
return GetQPt(); }
150 GPUd() float getEta()
const {
return -CAMath::Log(CAMath::Tan(0.5f * (0.5f * M_PI - CAMath::ATan(getTgl())))); }
151 GPUd() float getPt()
const {
return CAMath::Abs(getQ2Pt()) > 0 ? CAMath::Abs(1.f / getQ2Pt()) : 99999.f; }
152 GPUd() float getSigmaY2()
const {
return GetErr2Y(); }
153 GPUd() float getSigmaZ2()
const {
return GetErr2Z(); }
155 GPUd() const
float* getPar()
const {
return GetPar(); }
156 GPUd() const
float* getCov()
const {
return GetCov(); }
157 GPUd()
void resetCovariance(
float s) { ResetCovariance(); }
158 GPUd()
void updateCovZ2(
float addZerror) { SetCov(2, GetErr2Z() + addZerror); }
163 for (int32_t
i = 0;
i < 5;
i++) {
166 for (int32_t
j = 0;
j < 15;
j++) {
187 this->SetMaterialTPC();
188 this->SetPolynomialField(pField);
190 this->SetToyMCEventsFlag(0);
191 this->SetFitInProjections(0);
198 SetTrack(trk, trk->getAlpha());
201 GPUd() bool propagateToX(
float x,
float maxSnp,
float maxStep)
204 int32_t
retVal = PropagateToXAlpha(
x, GetAlpha(),
true);
206 ok = mTrack->CheckNumericalQuality();
209 GPUd() int32_t getPropagatedYZ(
float x,
float& projY,
float& projZ) {
return GetPropagatedYZ(
x, projY, projZ); }
210 GPUd()
void setFitInProjections(
bool flag) { SetFitInProjections(flag); }
213 if (RotateToAlpha(
alpha) == 0) {
214 mTrack->setAlpha(
alpha);
215 return mTrack->CheckNumericalQuality();
219 GPUd() bool update(const
float p[2], const
float cov[3])
222 return Update(p[0], p[1], 0,
false, cov[0], cov[2]) == 0 ? true :
false;
224 GPUd() float getAlpha() {
return GetAlpha(); }
226 GPUd() float getPredictedChi2(const
float p[2], const
float cov[3])
const {
return PredictChi2(p[0], p[1], cov[0], cov[2]); }
#define GPUCA_MAX_SIN_PHI
o2::track::TrackParCov TrackParCov
Result of refitting TPC-ITS matched track.
@ TRD
outer TPC -> outer TRD
GPUd() bool rotate(float alpha)
GPUTPCGMPolynomialField propagatorParam
GPUd() int32_t getPropagatedYZ(float x
propagatorInterface & operator=(const propagatorInterface< GPUTPCGMPropagator > &)=delete
propagatorInterface(const propagatorInterface< GPUTPCGMPropagator > &)=delete
trackInterface< GPUTPCGMTrackParam > * mTrack
GPUd() void setTrack(trackInterface< GPUTPCGMTrackParam > *trk)
GPUd() bool propagateToX(float x
GPUd() void setFitInProjections(bool flag)
GPUd() propagatorInterface(const propagatorParam *pField)
GPUdi() int32_t getPropagatedYZ(float x
o2::base::Propagator propagatorParam
GPUd() propagatorInterface(const propagatorParam *prop)
GPUdi() void setFitInProjections(bool flag)
GPUdi() void setTrack(trackInterface< o2
const o2::base::Propagator * mProp
GPUd() float getY() const
GPUd() float getPt() const
GPUd() float getSigmaZ2() const
GPUd() float getSigmaY2() const
GPUd() float getZ() const
GPUdDefault() trackInterface(const trackInterface< GPUTPCGMTrackParam > ¶m)=default
GPUdDefault() trackInterface()=default
GPUd() float getQ2Pt() const
GPUd() const float *getCov() const
GPUd() void updateCovZ2(float addZerror)
GPUd() float getX() const
GPUd() float getAlpha() const
GPUd() trackInterface(const gputpcgmmergertypes
GPUd() trackInterface(const o2
GPUd() float getEta() const
GPUd() void resetCovariance(float s)
GPUd() float getSnp() const
GPUd() void setAlpha(float alpha)
GPUd() float getTgl() const
GPUTPCGMTrackParam baseClass
GPUd() const float *getPar() const
GLfloat GLfloat GLfloat alpha
typedef void(APIENTRYP PFNGLCULLFACEPROC)(GLenum mode)
GPUd() const expr uint32_t MultivariatePolynomialHelper< Dim
a couple of static helper functions to create timestamp values for CCDB queries or override obsolete ...