1515// / \author ruben.shahoayn@cern.ch
1616
1717#include " TPCFastTransformPOD.h"
18+ #include " GPUDebugStreamer.h"
1819#if !defined(GPUCA_GPUCODE)
1920#include < TRandom.h>
2021#endif
@@ -23,6 +24,7 @@ namespace GPUCA_NAMESPACE
2324{
2425namespace gpu
2526{
27+
2628#if !defined(GPUCA_GPUCODE)
2729
2830size_t TPCFastTransformPOD::estimateSize (const TPCFastTransform& src)
@@ -63,6 +65,7 @@ const TPCFastTransformPOD& TPCFastTransformPOD::create(char* buff, size_t buffSi
6365 assert (buffSize > sizeof (TPCFastTransformPOD));
6466 const auto & origCorr = src.getCorrection ();
6567 auto & podMap = getNonConst (buff);
68+ podMap.mApplyCorrections = true ; // by default always apply corrections
6669
6770 // copy fixed size data --- start
6871 podMap.mNumberOfScenarios = origCorr.mNumberOfScenarios ;
@@ -78,6 +81,14 @@ const TPCFastTransformPOD& TPCFastTransformPOD::create(char* buff, size_t buffSi
7881 }
7982 podMap.mInterpolationSafetyMargin = origCorr.fInterpolationSafetyMargin ;
8083 podMap.mTimeStamp = origCorr.mTimeStamp ;
84+
85+ podMap.mVdrift = src.getVDrift ();
86+ podMap.mT0 = src.getT0 ();
87+ podMap.mVdriftCorrY = src.getVdriftCorrY ();
88+ podMap.mLdriftCorr = src.getLdriftCorr ();
89+ podMap.mTOFcorr = src.getTOFCorr ();
90+ podMap.mPrimVtxZ = src.getPrimVtxZ ();
91+
8192 // copy fixed size data --- end
8293
8394 size_t nextDynOffs = alignOffset (sizeof (TPCFastTransformPOD));
@@ -207,10 +218,10 @@ bool TPCFastTransformPOD::test(const TPCFastTransform& src, int npoints) const
207218 }
208219 }
209220 //
210- LOGP (info, " (ns per call) original this Nmissmatch" );
211- LOGP (info, " getCorrection {:.3e} {:.3e} {}" , double (origEnd[0 ] - origStart[0 ]) / npoints, double (thisEnd[0 ] - thisStart[0 ]) / npoints, ndiff[0 ]);
212- LOGP (info, " getCorrectionInvCorrectedX {:.3e} {:.3e} {}" , double (origEnd[1 ] - origStart[1 ]) / npoints, double (thisEnd[1 ] - thisStart[1 ]) / npoints, ndiff[1 ]);
213- LOGP (info, " getCorrectionInvUV {:.3e} {:.3e} {}" , double (origEnd[2 ] - origStart[2 ]) / npoints, double (thisEnd[2 ] - thisStart[2 ]) / npoints, ndiff[2 ]);
221+ LOGP (info, " (ns per call) original this Nmissmatch" );
222+ LOGP (info, " getCorrection {:.3e} {:.3e} {}" , double (origEnd[0 ] - origStart[0 ]) / npoints * 1000 . , double (thisEnd[0 ] - thisStart[0 ]) / npoints * 1000 . , ndiff[0 ]);
223+ LOGP (info, " getCorrectionInvCorrectedX {:.3e} {:.3e} {}" , double (origEnd[1 ] - origStart[1 ]) / npoints * 1000 . , double (thisEnd[1 ] - thisStart[1 ]) / npoints * 1000 . , ndiff[1 ]);
224+ LOGP (info, " getCorrectionInvUV {:.3e} {:.3e} {}" , double (origEnd[2 ] - origStart[2 ]) / npoints * 1000 . , double (thisEnd[2 ] - thisStart[2 ]) / npoints * 1000 . , ndiff[2 ]);
214225 return ndiff[0 ] == 0 && ndiff[1 ] == 0 && ndiff[2 ] == 0 ;
215226}
216227
0 commit comments