diff --git a/Detectors/TPC/qc/include/TPCQC/Tracks.h b/Detectors/TPC/qc/include/TPCQC/Tracks.h index f6cff7c2b8090..ff215b68ce3b1 100644 --- a/Detectors/TPC/qc/include/TPCQC/Tracks.h +++ b/Detectors/TPC/qc/include/TPCQC/Tracks.h @@ -81,19 +81,26 @@ class Tracks mUseCutMaxAbsDCArOnHistos = useCutMaxAbsDCArOnHistos; } + // Set PV position + void setPVposition(const o2::math_utils::Point3D meanVtxPoint3D) + { + mPositionOfPV = meanVtxPoint3D; + } + /// get ratios of 1D histograms std::unordered_map>& getMapHist() { return mMapHist; } const std::unordered_map>& getMapHist() const { return mMapHist; } private: - float mCutAbsEta = 1.f; // Eta cut - int mCutMinnCls = 60; // minimum N clusters - float mCutMindEdxTot = 20.f; // dEdxTot min value - float mCutMinPtDCAr = 1.5f; // minimum pT for DCAr plots DCAr vs. phi, eta, nCluster - float mSamplingFractionDCAr = 0.1f; // sampling rate for calculation of DCAr - bool mTurnOffHistosForAsync = false; // Decide whether to turn off some histograms for async to reduce memory - float mCutMaxAbsDCAr = 1.f; // maximum DCAr - bool mUseCutMaxAbsDCArOnHistos = false; // Decide whether to use the cut on maximum DCAr for the histograms + float mCutAbsEta = 1.f; // Eta cut + int mCutMinnCls = 60; // minimum N clusters + float mCutMindEdxTot = 20.f; // dEdxTot min value + float mCutMinPtDCAr = 1.5f; // minimum pT for DCAr plots DCAr vs. phi, eta, nCluster + float mSamplingFractionDCAr = 0.1f; // sampling rate for calculation of DCAr + bool mTurnOffHistosForAsync = false; // Decide whether to turn off some histograms for async to reduce memory + float mCutMaxAbsDCAr = 1.f; // maximum DCAr + bool mUseCutMaxAbsDCArOnHistos = false; // Decide whether to use the cut on maximum DCAr for the histograms + o2::math_utils::Point3D mPositionOfPV{}; // Position of the PV std::unordered_map> mMapHist; std::vector mHist1D{}; ///< Initialize vector of 1D histograms diff --git a/Detectors/TPC/qc/src/Tracks.cxx b/Detectors/TPC/qc/src/Tracks.cxx index 9f1d9aabf9523..8e6f0d702df1b 100644 --- a/Detectors/TPC/qc/src/Tracks.cxx +++ b/Detectors/TPC/qc/src/Tracks.cxx @@ -180,9 +180,8 @@ bool Tracks::processTrack(const o2::tpc::TrackTPC& track) if (propagator->getMatLUT() && propagator->hasMagFieldSet()) { // ---| fill DCA histos |--- o2::gpu::gpustd::array dca; - const o2::math_utils::Point3D refPoint{0, 0, 0}; o2::track::TrackPar propTrack(track); - if (propagator->propagateToDCABxByBz(refPoint, propTrack, 2.f, o2::base::Propagator::MatCorrType::USEMatCorrLUT, &dca)) { + if (propagator->propagateToDCABxByBz(mPositionOfPV, propTrack, 2.f, o2::base::Propagator::MatCorrType::USEMatCorrLUT, &dca)) { const auto phi = o2::math_utils::to02PiGen(track.getPhi()); dcaHistPT->Fill(pt, dca[0]); dcaHist->Fill(phi, dca[0]);