Skip to content

Commit 7a29cf1

Browse files
committed
ITS: add preliminary cell cuts
1 parent b3ee6aa commit 7a29cf1

File tree

5 files changed

+31
-3
lines changed

5 files changed

+31
-3
lines changed

Detectors/ITSMFT/ITS/tracking/CMakeLists.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ o2_add_library(ITStracking
3232
PRIVATE_LINK_LIBRARIES
3333
O2::Steer
3434
TBB::tbb)
35-
target_compile_options(${targetName} PRIVATE -O0 -g -fPIC -fno-omit-frame-pointer)
35+
# target_compile_options(${targetName} PRIVATE -O0 -g -fPIC -fno-omit-frame-pointer)
3636

3737
o2_add_library(ITSTrackingInterface
3838
TARGETVARNAME targetName
@@ -41,7 +41,7 @@ o2_add_library(ITSTrackingInterface
4141
O2::ITStracking
4242
O2::Framework
4343
O2::GPUTracking)
44-
target_compile_options(${targetName} PRIVATE -O0 -g -fPIC -fno-omit-frame-pointer)
44+
# target_compile_options(${targetName} PRIVATE -O0 -g -fPIC -fno-omit-frame-pointer)
4545

4646
o2_target_root_dictionary(ITStracking
4747
HEADERS include/ITStracking/Tracklet.h

Detectors/ITSMFT/ITS/tracking/include/ITStracking/Configuration.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,7 @@ struct TrackingParameters {
5757
int NTimeSlices{1};
5858
/// Trackleting cuts
5959
float TrackletMinPt = 0.3f;
60+
float TrackletNSigmaVtxZ{-1.f};
6061
/// Cell finding cuts
6162
float CellDeltaTanLambdaSigma = 0.007f;
6263
/// Fitter parameters
@@ -84,6 +85,8 @@ struct TrackingParameters {
8485
float SeedingMaxChi2Iter{3.f}; // maximum chi2 change required to end iteration
8586
float SeedingTukeyStartIter{5.f}; // start value for tukey scaling for iteration
8687
float SeedingMinWghTrk{0.05f}; // minimum weight a track has to have to be accounted
88+
float SeedingMinPtTrk{0.0}; // minimum pt for cells to enter pool
89+
float SeedingMaxTglTrk{6.f}; // maximum accepted tgl for cells to enter pool
8790
int SeedingMaxFitIter{3}; // maximum iterations for fit
8891
int SeedingMinTracksIter{50}; // minimum tracks needed for one iteration
8992
int SeedingDBScanMinPt{100}; // DBSCAN: minimum number of cluster points

Detectors/ITSMFT/ITS/tracking/include/ITStracking/MathUtils.h

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ GPUhdi() float computeCurvatureCentreX(float x1, float y1, float x2, float y2, f
7878

7979
GPUhdi() float computeTanDipAngle(float x1, float y1, float x2, float y2, float z1, float z2)
8080
{
81-
// in case the points vertically align we go to pos/neg inifinity.
81+
// in case the points vertically align we go to pos/neg infinity.
8282
const float d = o2::gpu::CAMath::Hypot(x1 - x2, y1 - y2);
8383
if (o2::gpu::CAMath::Abs(d) < o2::its::constants::Tolerance) {
8484
return ((z1 > z2) ? -1.f : 1.f) * o2::constants::math::VeryBig;
@@ -96,6 +96,11 @@ GPUhdi() float Sq(float v)
9696
return v * v;
9797
}
9898

99+
GPUhdi() float SqDiff(float x, float y)
100+
{
101+
return Sq(x - y);
102+
}
103+
99104
GPUhdi() float MSangle(float mass, float p, float xX0)
100105
{
101106
float beta = p / o2::gpu::CAMath::Hypot(mass, p);

Detectors/ITSMFT/ITS/tracking/src/Configuration.cxx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -198,6 +198,7 @@ std::vector<RecoIteration> TrackingMode::getRecoIterations(TrackingMode::Type mo
198198
recoIterations[0].steps.set(kRunTrackleting, kRunCellFinding, kRunCellSeeding, kUpdateClusters);
199199
recoIterations[0].params.NLayers = 3; // only do cell finding up until the third layer
200200
recoIterations[0].params.UseDiamond = true; // use the blown up diamond constrain to (e.g. luminous region)
201+
recoIterations[0].params.TrackletNSigmaVtxZ = 1.f; // since diamond is used restrict at least to fit within luminous
201202
recoIterations[0].params.CorrType = o2::base::PropagatorF::MatCorrType::USEMatCorrNONE; // do not use material
202203
recoIterations[0].params.SeedingDCATolerance = tc.seedingDCATolerance;
203204
recoIterations[0].params.SeedingDCAMaxPull = tc.seedingDCAMaxPull;

Detectors/ITSMFT/ITS/tracking/src/TrackerTraits.cxx

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -183,6 +183,18 @@ void TrackerTraits<NLayers>::computeLayerTracklets(const int iteration, const in
183183
((deltaPhi < mTimeFrame->getPhiCut(iLayer) || o2::gpu::GPUCommonMath::Abs(deltaPhi - o2::constants::math::TwoPI) < mTimeFrame->getPhiCut(iLayer)))) {
184184
const float phi{o2::gpu::CAMath::ATan2(currentCluster.yCoordinate - nextCluster.yCoordinate, currentCluster.xCoordinate - nextCluster.xCoordinate)};
185185
const float tanL = (currentCluster.zCoordinate - nextCluster.zCoordinate) / (currentCluster.radius - nextCluster.radius);
186+
187+
if (mRecoParams[iteration].params.TrackletNSigmaVtxZ > 0) {
188+
// Check if assumed line extrapolation is compatible with current vertex
189+
// use straighline approximation to vertex radius
190+
// TODO account for cluster z errs
191+
const float zAtVtx = nextCluster.zCoordinate + (tanL * (pv.getR() - nextCluster.radius));
192+
const float zChi2 = math_utils::SqDiff(nextCluster.zCoordinate, pv.getZ()) / (pv.getSigmaZ2());
193+
if (zChi2 > mRecoParams[iteration].params.TrackletNSigmaVtxZ) {
194+
continue;
195+
}
196+
}
197+
186198
if constexpr (decltype(Tag)::value == PassMode::OnePass::value) {
187199
tracklets.emplace_back(currentSortedIndex, mTimeFrame->getSortedIndex(targetROF, iLayer + 1, iNext), tanL, phi, pivotROF, targetROF);
188200
} else if constexpr (decltype(Tag)::value == PassMode::TwoPassCount::value) {
@@ -511,6 +523,13 @@ void TrackerTraits<NLayers>::findCellSeeds(const int iteration)
511523
tbb::parallel_for(size_t(0), cells.size(), [&](size_t iCell) {
512524
// relate each cell to the imposed mean vertex or assumed beamline if the former is not provided
513525
auto& cell = cells[iCell];
526+
// impose general quality cuts
527+
if (o2::gpu::CAMath::Abs(cell.getTgl()) > mRecoParams[iteration].params.SeedingMaxTglTrk) {
528+
return;
529+
}
530+
if (cell.getPt() < mRecoParams[iteration].params.SeedingMinPtTrk) {
531+
return;
532+
}
514533
dataformats::VertexBase vtx;
515534
dataformats::DCA dca;
516535
float z = cell.getZAt(0., getBz());

0 commit comments

Comments
 (0)