21#include "MFTTracking/IOUtils.h"
30 : mIsAlignPointSet(
false),
31 mIsGlobalDerivativeDone(
false),
32 mIsLocalDerivativeDone(
false),
33 mIsTrackInitialParamSet(
false),
38 mGlobalRecoPosition(0., 0., 0.),
39 mLocalRecoPosition(0., 0., 0.),
40 mLocalMeasuredPosition(0., 0., 0.),
41 mLocalMeasuredPositionSigma(0., 0., 0),
42 mGlobalMeasuredPosition(0., 0., 0.),
43 mLocalResidual(0., 0., 0.)
48 o2::math_utils::bit2Mask(o2::math_utils::TransformType::T2L,
49 o2::math_utils::TransformType::L2G));
56 mChipHelper = std::make_unique<AlignSensorHelper>();
57 LOGF(
debug,
"AlignPointHelper instantiated");
66 "AlignPointHelper::computeLocalDerivatives() - no AlignSensorHelper found !");
71 "AlignPointHelper::computeLocalDerivatives() - no initial track param found !");
76 "AlignPointHelper::computeLocalDerivatives() - no align point coordinates set !");
92 "AlignPointHelper::computeGlobalDerivatives() - no AlignSensorHelper found !");
97 "AlignPointHelper::computeGlobalDerivatives() - no initial track param found !");
101 LOGF(
error,
"AlignPointHelper::computeGlobalDerivatives() - no align point coordinates set !");
116 "AlignPointHelper::getSensorId() - no AlignSensorHelper found !");
121 "AlignPointHelper::getSensorId() - no align point coordinates set !");
132 "AlignPointHelper::half() - no AlignSensorHelper found !");
137 "AlignPointHelper::half() - no align point coordinates set !");
148 "AlignPointHelper::disk() - no AlignSensorHelper found !");
153 "AlignPointHelper::disk() - no align point coordinates set !");
164 "AlignPointHelper::layer() - no AlignSensorHelper found !");
169 "AlignPointHelper::layer() - no align point coordinates set !");
207 gsl::span<const unsigned char>::iterator& pattIt,
215 "AlignPointHelper::convertCompactClusters() - no dictionary found !");
222 o2::math_utils::bit2Mask(o2::math_utils::TransformType::T2L,
223 o2::math_utils::TransformType::L2G));
224 outputLocalClusters.clear();
225 outputGlobalClusters.clear();
228 auto chipID = mftCluster.getChipID();
229 auto pattID = mftCluster.getPatternID();
253 auto& locCl3d = outputLocalClusters.emplace_back(chipID, locXYZ);
256 auto& gloCl3d = outputGlobalClusters.emplace_back(chipID, gloXYZ);
260 "AlignPointHelper::convertCompactClusters() - output vector size %d",
261 outputLocalClusters.size());
266 std::vector<unsigned char>::iterator& pattIt,
274 "AlignPointHelper::convertCompactClusters() - no dictionary found !");
281 o2::math_utils::bit2Mask(o2::math_utils::TransformType::T2L,
282 o2::math_utils::TransformType::L2G));
283 outputLocalClusters.clear();
284 outputGlobalClusters.clear();
287 auto chipID = mftCluster.getChipID();
288 auto pattID = mftCluster.getPatternID();
312 auto& locCl3d = outputLocalClusters.emplace_back(chipID, locXYZ);
315 auto& gloCl3d = outputGlobalClusters.emplace_back(chipID, gloXYZ);
319 "AlignPointHelper::convertCompactClusters() - output vector size %d",
320 outputLocalClusters.size());
330 double phi = mftTrack.
getPhi();
331 double tanLambda = mftTrack.
getTanl();
335 "AlignPointHelper::recordTrackInitialParam - x0 = %.3e, y0 = %.3e, z0 = %.3e, Tx = %.3e, Ty = %.3e",
347 "AlignPointHelper::setGlobalRecoPosition() - track x = %.3e, y = %.3e, z = %.3e",
353 "AlignPointHelper::setGlobalRecoPosition() - track x = %.3e, y = %.3e, z = %.3e, point x = %.3e, y = %.3e, z = %.3e",
369 localCluster.
getX(), localCluster.
getY(), localCluster.
getZ());
372 "AlignPointHelper::setMeasuredPosition() - sr %4d local x = %.3e, y = %.3e, z = %.3e",
380 globalCluster.
getX(), globalCluster.
getY(), globalCluster.
getZ());
383 "AlignPointHelper::setMeasuredPosition() - sr %4d global x = %.3e, y = %.3e, z = %.3e",
402 o2::math_utils::bit2Mask(o2::math_utils::TransformType::T2L,
403 o2::math_utils::TransformType::L2G));
411 "AlignPointHelper::setLocalResidual() - no align point coordinates set !");
425 "AlignPointHelper::setGlobalResidual() - no align point coordinates set !");
465 "computeLocalDerivativeX(): dX0 = %.3e, dTx = %.3e, dY0 = %.3e, dTy = %.3e",
473 "AlignPointHelper::computeLocalDerivativeX() - no sensor transform found !");
494 "computeLocalDerivativeY(): dX0 = %.3e, dTx = %.3e, dY0 = %.3e, dTy = %.3e",
502 "AlignPointHelper::computeLocalDerivativeY() - no sensor transform found !");
519 "computeLocalDerivativeZ(): dX0 = %.3e, dTx = %.3e, dY0 = %.3e, dTy = %.3e",
527 "AlignPointHelper::computeLocalDerivativeZ() - no sensor transform found !");
551 "computeGlobalDerivativeX(): dx = %.3e, dy = %.3e, dz = %.3e, dRz = %.3e",
559 "AlignPointHelper::computeGlobalDerivativeX() - no sensor transform found !");
583 "computeGlobalDerivativeY(): dx = %.3e, dy = %.3e, dz = %.3e, dRz = %.3e",
591 "AlignPointHelper::computeGlobalDerivativeY() - no sensor transform found !");
609 "computeGlobalDerivativeZ(): dx = %.3e, dy = %.3e, dz = %.3e, dRz = %.3e",
617 "AlignPointHelper::computeGlobalDerivativeZ() - no sensor transform found !");
ClassImp(o2::mft::AlignPointHelper)
Compute the local and global derivatives at an alignment point (track position, cluster position)
Helper class to access to the global coordinates of the center each MFT sensor.
configStandalone Reconstruction rec_tpc multiplier for the combined cluster track error during track following area in cm for the search of for z only used if decrease removal by when above this local occupancy rowx Shift of TPC revert cluster flag edge bit distance to edge exceeds this ZOffset for secondary multiple of radius max P of electron K BB bands crossing max P of electron p BB bands crossing max P of electron d BB bands crossing max P of electron t BB bands crossing min accepted dEdxMaxTPC of the track Additive extra cluster error for Y2 if edge flag set Additive extra cluster error for Y2 if single set Additive extra cluster error for Y2 if or single set Additive extra cluster error for Z2 if or single set Extra errors to add to track when crossing depending on addErrorsCECrossing Inner portion of y range in sector that is not used in searching for extrapolated track candidates factor2YS for track merging factor2K for track merging Margin in cm of Y position when rejecting edge clusters based on uncorrected track Y Max fraction of shared clusters for tracklet Except pad from cluster finding if total number of charges in a fragment is above this Except pad from cluster finding if number of consecutive charges in a fragment is above this Threshold where a timebin is considered disabling the noisy pad check for that pad Treat signal above this minimum as saturated Smoothing factor for the exponential Highly Ionising Particle tail filter Number of timebins to use for the averaging Add additional custom track errors when crossing relative as fraction of Do N fit passes in final fit of< 0:reject at max -n hits") AddOptionRTC(rejectIFCLowRadiusCluster, uint8_t, 1, "", 0, "Reject clusters that get the IFC mask error during refit") AddOptionRTC(dEdxTruncLow, uint8_t, 2, "", 0, "Low truncation threshold, fraction of 128") AddOptionRTC(dEdxTruncHigh, uint8_t, 77, "", 0, "High truncation threshold, fraction of 128") AddOptionRTC(extrapolationTracking, int8_t, 1, "", 0, "Enable Extrapolation Tracking(prolong tracks to adjacent sectors to find short segments)") AddOptionRTC(disableRefitAttachment, uint8_t, 0, "", 0, "Bitmask to disable certain attachment steps during refit(1:attachment, 2:propagation, 4:loop following, 8:mirroring)") AddOptionRTC(rejectionStrategy, uint8_t, o2::gpu::GPUSettings::RejectionStrategyA, "", 0, "Enable rejection of TPC clusters for compression(0=no, 1=strategy A, 2=strategy B)") AddOptionRTC(mergeLoopersAfterburner, uint8_t, 1, "", 0, "Run afterburner for additional looper merging") AddOptionRTC(compressionTypeMask, uint8_t, o2::gpu::GPUSettings::CompressionFull, "", 0, "TPC Compression mode bits(1=truncate charge/width LSB, 2=differences, 4=track-model)") AddOptionRTC(compressionSortOrder, uint8_t, o2::gpu::GPUSettings::SortTime, "", 0, "Sort order of TPC compression(0=time, 1=pad, 2=Z-time-pad, 3=Z-pad-time, 4=no sorting(use incoming order))") AddOptionRTC(sigBitsCharge, uint8_t, 4, "", 0, "Number of significant bits for TPC cluster charge in compression mode 1") AddOptionRTC(sigBitsWidth, uint8_t, 3, "", 0, "Number of significant bits for TPC cluster width in compression mode 1") AddOptionRTC(dropLoopers, uint8_t, 0, "", 0, "Drop looping tracks starting from second loop") AddOptionRTC(mergerInterpolateErrors, uint8_t, 1, "", 0, "Use interpolation instead of extrapolation for chi2 based cluster rejection") AddOptionRTC(mergerInterpolateRejectAlsoOnCurrentPosition, uint8_t, 1, "", 0, "When using mergerInterpolateErrors, reject based on chi2 twice computed with interpolated and current track position starting from NDF > mergerNonInterpolateRejectMinNDF Merge tracks accross the central electrode Enable PID response Add sub threshold clusters in TPC dEdx computation OR mask of TPC flags that will reject the cluster in alternative dEdx Reject edge clusters based on uncorrected track Y during track fit Increase decrease removal by when on this number of pads from the edge h configStandalone Reconstruction rec_trd Max chi2 for TRD tracklets to be matched to a track Chi2 cut for strict matching mode Number of sigmas for ITS TPC track time error estimate Addition to search road around track prolongation along Y in cm Optimal tracklet rphi resolution in maximum chi2 per attached tracklet for TRD tracks take into account the full likelihood of the slope including exponential tails Tracks with less attached tracklets are discarded after the tracking Post trigger Pile up integration time in BCs fits all iterations but the last one in projections Use material lookup table for TPC refit Apply workarounds to avoid cyclic merge should not be needed tpc dyn configStandalone Processing proc_rtc Replace constant variables static by constexpr expressions false
char error[CURL_ERROR_SIZE]
Definition of the SegmentationAlpide class.
std::int16_t getSensorID() const
const Mat3D & getMatrixL2G(int sensID) const
static constexpr unsigned short InvalidPatternID
static constexpr float SensorLayerThicknessEff
float getErrZ(int n) const
Returns the error on the z position of the COG for the n_th element.
math_utils::Point3D< T > getClusterCoordinates(const CompCluster &cl) const
float getErrX(int n) const
Returns the error on the x position of the COG for the n_th element.
bool isGroup(int n) const
Returns true if the element corresponds to a group of rare topologies.
Container of a single alignment point and methods to fill it.
LocalDerivative mLocalDerivativeX
first (X) component of the local derivatives
bool computeGlobalDerivativeY()
compute second (Y) component of the global derivatives
const o2::itsmft::TopologyDictionary * mDictionary
cluster patterns dictionary
bool mIsTrackInitialParamSet
boolean to indicate if the initial track parameters are recorded
void recordTrackInitialParam(o2::mft::TrackMFT &mftTrack)
store the track parameters at the initial z0 plane
GlobalDerivative mGlobalDerivativeZ
last (Z) component of the global derivatives
LocalDerivative mLocalDerivativeZ
last (Z) component of the local derivatives
LocalDerivative mLocalDerivativeY
second (Y) component of the local derivatives
bool computeGlobalDerivativeZ()
compute last (Z) component of the global derivatives
bool computeLocalDerivativeY()
compute second (Y) component of the local derivatives
o2::math_utils::Point3D< double > mLocalMeasuredPositionSigma
Estimated error on local position measurement.
bool computeLocalDerivativeZ()
compute last (Z) component of the local derivatives
o2::mft::GeometryTGeo * mGeometry
MFT geometry.
o2::math_utils::Point3D< double > mGlobalRecoPosition
Current cartesian position (cm, in Global ref. system) of the reconstructed track analytically propag...
bool mIsGlobalDerivativeDone
boolean to indicate if the global derivatives computaion is done
bool mIsClusterOk
boolean to check if cluster was exploitable to get coordinates
void resetGlobalDerivatives()
reset all elements to zero for the global derivatives
bool computeGlobalDerivativeX()
compute first (X) component of the global derivatives
UShort_t getSensorId() const
void setGlobalRecoPosition(o2::mft::TrackMFT &mftTrack)
void convertCompactClusters(gsl::span< const itsmft::CompClusterExt > clusters, gsl::span< const unsigned char >::iterator &pattIt, std::vector< o2::BaseCluster< double > > &outputLocalClusters, std::vector< o2::BaseCluster< double > > &outputGlobalClusters)
convert compact clusters (pixel coordinates in row, col) from workflow to base clusters with 3D posit...
void setMeasuredPosition(const o2::BaseCluster< double > &localCluster, const o2::BaseCluster< double > &globalCluster)
std::unique_ptr< o2::mft::AlignSensorHelper > mChipHelper
utility to access the sensor transform used in the computation of the derivatives
o2::math_utils::Point3D< double > mGlobalResidual
residual between track x-ing point and cluster in global ref. system
TrackParam mTrackInitialParam
Track parameters at the initial reference plane z = z0.
void computeGlobalDerivatives()
method to call the computation of all three components of the global derivative
void resetAlignPoint()
reset all quantities that define an alignment point to their default value
void computeLocalDerivatives()
method to call the computation of all three compnonents of the local derivative
GlobalDerivative mGlobalDerivativeY
second (Y) component of the global derivatives
bool mIsLocalDerivativeDone
boolean to indicate if the local derivatives computation is done
o2::math_utils::Point3D< double > mLocalResidual
residual between track x-ing point and cluster in local ref. system
void resetLocalDerivatives()
reset all elements to zero for the local derivatives
void resetTrackInitialParam()
reset all track parameters to their default value (zero)
o2::math_utils::Point3D< double > mLocalMeasuredPosition
Current cartesian position (cm, in Local ref. system) of the cluster.
bool computeLocalDerivativeX()
compute first (X) component of the local derivatives
GlobalDerivative mGlobalDerivativeX
first (X) component of the global derivatives
o2::math_utils::Point3D< double > mLocalRecoPosition
Current cartesian position (cm, in Local ref. system) of the reconstructed track analytically propaga...
AlignPointHelper()
constructor
bool mIsAlignPointSet
boolean to indicate if mGlobalRecoPosition and mLocalMeasuredPosition are set
o2::math_utils::Point3D< double > mGlobalMeasuredPosition
Current cartesian position (cm, in Global ref. system) of the cluster.
void fillMatrixCache(Int_t mask) override
static GeometryTGeo * Instance()
void reset()
reset all data members to default value (zero)
double mdDeltaY
derivative w.r.t. delta translation along global y-axis
double mdDeltaRz
derivative w.r.t. delta rotation angle around global z-axis
double mdDeltaZ
derivative w.r.t. delta translation along global z-axis
double mdDeltaX
derivative w.r.t. delta translation along global x-axis
double mdY0
derivative w.r.t. track param. y0
double mdTy
derivative w.r.t. track param. ty
void reset()
reset all data members to default value (zero)
double mdTx
derivative w.r.t. track param. tx
double mdX0
derivative w.r.t. track param. x0
Double_t getZ() const
return Z coordinate (cm)
constexpr float DefClusErrorCol
constexpr float DefClusErrorRow
std::vector< Cluster > clusters