From 77d0f4e2c3ef53861a1e0233f83292d8ad4addf8 Mon Sep 17 00:00:00 2001 From: Felix Schlepper Date: Mon, 30 Oct 2023 16:15:58 +0100 Subject: [PATCH] fixup --- .../DetectorsVertexing/SVertexerParams.h | 34 +++++++++++-------- Detectors/Vertexing/src/SVertexer.cxx | 8 ++++- 2 files changed, 26 insertions(+), 16 deletions(-) diff --git a/Detectors/Vertexing/include/DetectorsVertexing/SVertexerParams.h b/Detectors/Vertexing/include/DetectorsVertexing/SVertexerParams.h index f6e0655cf4e20..d9b7c1534d1a8 100644 --- a/Detectors/Vertexing/include/DetectorsVertexing/SVertexerParams.h +++ b/Detectors/Vertexing/include/DetectorsVertexing/SVertexerParams.h @@ -51,20 +51,22 @@ struct SVertexerParams : public o2::conf::ConfigurableParamHelper minMomTPCdEdx are always accepted float minMomTPCdEdx = 0.8; // minimum p for tracks with dEdx > mMinTPCdEdx to be accepted diff --git a/Detectors/Vertexing/src/SVertexer.cxx b/Detectors/Vertexing/src/SVertexer.cxx index 8d535c979c515..6c9491462c292 100644 --- a/Detectors/Vertexing/src/SVertexer.cxx +++ b/Detectors/Vertexing/src/SVertexer.cxx @@ -519,6 +519,12 @@ void SVertexer::buildT2V(const o2::globaltracking::RecoContainer& recoData) // a //__________________________________________________________________ bool SVertexer::checkV0(const TrackCand& seedP, const TrackCand& seedN, int iP, int iN, int ithread) { + // Fast rough cuts on pairs before feeding to DCAFitter, tracks are not in the same Frame or at same X + bool isTPConly = seedP.gid.getSource() == GIndex::TPC && seedN.gid.getSource() == GIndex::TPC; + if (std::abs(seedP.getEta() - seedN.getEta()) > mSVParams->maxV0EtaAbsDiff || std::abs(seedP.getPhi() - seedN.getPhi()) > mSVParams->maxV0PhiAbsDiff) { + return false; + } + // auto& fitterV0 = mFitterV0[ithread]; int nCand = fitterV0.process(seedP, seedN); if (nCand == 0) { // discard this pair @@ -1123,7 +1129,7 @@ bool SVertexer::processTPCTrack(const o2::tpc::TrackTPC& trTPC, GIndex gid, int int posneg = trTPC.getSign() < 0 ? 1 : 0; auto& trLoc = mTracksPool[posneg].emplace_back(TrackCand{trTPC, gid, {vtxid, vtxid}, 0.}); auto err = correctTPCTrack(trLoc, trTPC, twe.getTimeStamp(), twe.getTimeStampError()); - if (err < 0) { + if (err < 0 || std::abs(trLoc.getX() * trLoc.getTgl() - trLoc.getZ() - vtx.getZ()) > mSVParams->mTPCTrack2Beam) { mTracksPool[posneg].pop_back(); // discard return true; // skip minR calculation to 'invalid' memory (trLoc will probably be still there and not be invalidated but we discarded it) }