16#ifndef ALICEO2_GLOQC_MATCHITSTPC_QC_
17#define ALICEO2_GLOQC_MATCHITSTPC_QC_
23#include <TEfficiency.h>
33#include "GPUParam.inc"
35#include <unordered_map>
71 void setDataRequest(
const std::shared_ptr<o2::globaltracking::DataRequest>& dr) { mDataRequest = dr; }
152 template <
typename T>
157 publisher->startPublishing(mPtNum[
i]);
158 publisher->startPublishing(mPtDen[
i]);
159 publisher->startPublishing(mFractionITSTPCmatch[
i]);
161 publisher->startPublishing(mPtNum_noEta0[
i]);
162 publisher->startPublishing(mPtDen_noEta0[
i]);
163 publisher->startPublishing(mFractionITSTPCmatch_noEta0[
i]);
166 publisher->startPublishing(mPhiNum[
i]);
167 publisher->startPublishing(mPhiDen[
i]);
168 publisher->startPublishing(mFractionITSTPCmatchPhi[
i]);
170 publisher->startPublishing(mPhiVsPtNum[
i]);
171 publisher->startPublishing(mPhiVsPtDen[
i]);
172 publisher->startPublishing(mFractionITSTPCmatchPhiVsPt[
i]);
175 publisher->startPublishing(mEtaNum[
i]);
176 publisher->startPublishing(mEtaDen[
i]);
177 publisher->startPublishing(mFractionITSTPCmatchEta[
i]);
179 publisher->startPublishing(mEtaVsPtNum[
i]);
180 publisher->startPublishing(mEtaVsPtDen[
i]);
181 publisher->startPublishing(mFractionITSTPCmatchEtaVsPt[
i]);
184 publisher->startPublishing(mClsVsPtNum[
i]);
185 publisher->startPublishing(mClsVsPtDen[
i]);
186 publisher->startPublishing(mFractionITSTPCmatchClsVsPt[
i]);
189 publisher->startPublishing(mChi2VsPtNum[
i]);
190 publisher->startPublishing(mChi2VsPtDen[
i]);
191 publisher->startPublishing(mFractionITSTPCmatchChi2VsPt[
i]);
194 publisher->startPublishing(m1OverPtNum[
i]);
195 publisher->startPublishing(m1OverPtDen[
i]);
196 publisher->startPublishing(mFractionITSTPCmatch1OverPt[
i]);
199 publisher->startPublishing(mEtaPhiPtNum[
i]);
200 publisher->startPublishing(mEtaPhiPtDen[
i]);
203 for (
int j = 0;
j < o2::track::PID::NIDs; ++
j) {
205 publisher->startPublishing(mPtNumVsTrkPID[
i][
j]);
206 publisher->startPublishing(mPtDenVsTrkPID[
i][
j]);
207 publisher->startPublishing(mFractionITSTPCmatchPtVsTrkPID[
i][
j]);
210 publisher->startPublishing(mPhiNumVsTrkPID[
i][
j]);
211 publisher->startPublishing(mPhiDenVsTrkPID[
i][
j]);
212 publisher->startPublishing(mFractionITSTPCmatchPhiVsTrkPID[
i][
j]);
215 publisher->startPublishing(mEtaNumVsTrkPID[
i][
j]);
216 publisher->startPublishing(mEtaDenVsTrkPID[
i][
j]);
217 publisher->startPublishing(mFractionITSTPCmatchEtaVsTrkPID[
i][
j]);
222 publisher->startPublishing(mPhiPhysPrimNum[
i]);
223 publisher->startPublishing(mPhiPhysPrimDen[
i]);
224 publisher->startPublishing(mFractionITSTPCmatchPhiPhysPrim[
i]);
225 publisher->startPublishing(mPtPhysPrimNum[
i]);
226 publisher->startPublishing(mPtPhysPrimDen[
i]);
227 publisher->startPublishing(mFractionITSTPCmatchPhysPrim[
i]);
228 publisher->startPublishing(mEtaPhysPrimNum[
i]);
229 publisher->startPublishing(mEtaPhysPrimDen[
i]);
230 publisher->startPublishing(mFractionITSTPCmatchEtaPhysPrim[
i]);
231 publisher->startPublishing(m1OverPtPhysPrimNum[
i]);
232 publisher->startPublishing(m1OverPtPhysPrimDen[
i]);
233 publisher->startPublishing(mFractionITSTPCmatchPhysPrim1OverPt[
i]);
236 publisher->startPublishing(mChi2Matching);
237 publisher->startPublishing(mChi2Refit);
238 publisher->startPublishing(mTimeResVsPt);
239 publisher->startPublishing(mResidualPt);
240 publisher->startPublishing(mResidualPhi);
241 publisher->startPublishing(mResidualEta);
242 publisher->startPublishing(mDCAr);
243 publisher->startPublishing(mDCArVsPtNum);
244 publisher->startPublishing(mDCArVsPtDen);
245 publisher->startPublishing(mFractionITSTPCmatchDCArVsPt);
247 publisher->startPublishing(mK0MassVsPtVsOccpp);
248 publisher->startPublishing(mK0MassVsPtVsOccPbPb);
307 std::shared_ptr<o2::globaltracking::DataRequest> mDataRequest;
309 std::string mRequestedSources =
"ITS,TPC,ITS-TPC";
313 gsl::span<const o2::tpc::TrackTPC> mTPCTracks;
315 gsl::span<const o2::its::TrackITS> mITSTracks;
317 gsl::span<const o2::dataformats::TrackTPCITS> mITSTPCTracks;
319 bool mUseTrkPID =
false;
321 std::array<std::unordered_map<o2::MCCompLabel, LblInfo>,
matchType::SIZE> mMapLabels;
324 std::array<std::unordered_map<o2::MCCompLabel, LblInfo>,
matchType::SIZE> mMapRefLabels;
342 TEfficiency* mFractionITSTPCmatchPtVsTrkPID[
matchType::SIZE][track::PID::NIDs] = {};
356 TEfficiency* mFractionITSTPCmatchPhiVsTrkPID[
matchType::SIZE][track::PID::NIDs] = {};
378 TEfficiency* mFractionITSTPCmatchEtaVsTrkPID[
matchType::SIZE][track::PID::NIDs] = {};
380 TH2F* mResidualPt =
nullptr;
381 TH2F* mResidualPhi =
nullptr;
382 TH2F* mResidualEta =
nullptr;
384 TH1F* mChi2Matching =
nullptr;
385 TH1F* mChi2Refit =
nullptr;
386 TH2F* mTimeResVsPt =
nullptr;
387 TH1F* mDCAr =
nullptr;
388 TH2F* mDCArVsPtNum =
nullptr;
389 TH2F* mDCArVsPtDen =
nullptr;
390 TEfficiency* mFractionITSTPCmatchDCArVsPt =
nullptr;
397 TEfficiency* mFractionITSTPCmatchPhysPrim1OverPt[
matchType::SIZE] = {};
402 template <
int DIM = 1,
bool DEBUG = false>
403 void setEfficiency(TEfficiency* eff, TH1* hnum, TH1* hden);
405 int mNTPCSelectedTracks = 0;
406 int mNITSSelectedTracks = 0;
411 float mPtITSCut = 0.1f;
412 float mEtaITSCut = 1.4f;
413 int mMinNClustersITS = 0;
414 float mMaxChi2PerClusterITS{1e10f};
415 std::vector<std::pair<int8_t, std::set<uint8_t>>> mRequiredITSHits;
417 float mPtTPCCut = 0.1f;
418 float mEtaTPCCut = 1.4f;
420 float mDCATPCCut = 100.f;
421 float mDCATPCCutY = 10.f;
425 float mPtMaxCut = 20;
426 float mEtaCut = 1.4f;
427 float mEtaNo0Cut = 0.05f;
432 TH3F* mK0MassVsPtVsOccpp =
nullptr;
433 TH3F* mK0MassVsPtVsOccPbPb =
nullptr;
434 bool mDoK0QC =
false;
435 float mCutK0Mass = 0.05;
437 float mMaxEtaK0 = 0.8;
438 long int mTimestamp = -1;
439 std::unique_ptr<o2::gpu::GPUO2InterfaceConfiguration> mConfig;
440 std::unique_ptr<o2::gpu::GPUSettingsO2> mConfParam;
442 std::shared_ptr<o2::gpu::GPUParam> mParam =
nullptr;
444 int mNTPCOccBinLength = 0;
445 float mNTPCOccBinLengthInv{};
446 std::vector<float> mTBinClOcc;
447 gsl::span<const unsigned int> mTPCRefitterOccMap;
449 float mK0Scaling = 1.f;
451 float mMinTPCOccpp = 0.f;
452 float mMaxTPCOccpp = 1.e6;
453 int mNBinsTPCOccpp = 6;
454 float mMinTPCOccPbPb = 0.f;
455 float mMaxTPCOccPbPb = 8.e6;
456 int mNBinsTPCOccPbPb = 8;
457 float mK0MaxDCA = 0.01;
458 float mK0MinCosPA = 0.995;
Defintions for N-prongs secondary vertex fit.
Timeframe settings Average distance in cm of events merged into Randomize distance around average distance of merged events Simulate correct bunch interactions instead of placing only the average number of events A value[n] sets TFlen for[n] collisions in Number of bunches per trainsort Number of bunch trains Instantaneous interaction rate Do not simulate border Total number of collisions to be placed in the interior of all time Do not select random but walk over array of events in stride steps h Event generator settings h configStandalone Use CPU for GPU Force usage of the specified GPU device no CPU fallback Continue processing after an error First event to Number of events to Number of iterations to Number of iterations to Number of initial iterations excluded from const char Directory with events to Events directory is and not inside events Show standalone event Run event generator maximum time bin of continuous for triggered for automatic continuous for automatic continuous triggered uint64_t
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 Compile RTC in deterministic with NO_FAST_MATH flags and GPUCA_DETERMINISTIC_MODE define Use RTC to optimize GPU code h configStandalone Processing proc_rtctech Use a file lock to serialize access to the cache folder int32_t
TEfficiency * getFractionITSTPCmatch1OverPt(matchType m) const
void setMaxK0Eta(float v)
TH2F * getHistoDCArVsPtNum() const
TEfficiency * getFractionITSTPCmatchPhiVsPt(matchType m) const
void setMinDCAtoBeamPipeYCut(float v)
TH3F * getHistoEtaPhiPtNum(matchType m) const
TEfficiency * getFractionITSTPCmatchEtaPhysPrim(matchType m) const
TH2F * getHistoClsVsPtDen(matchType m) const
void setK0MinCosPA(float v)
void setMinTPCOccPbPb(float v)
TEfficiency * getFractionITSTPCmatchNoEta0(matchType m) const
TH1D * getHistoPtNumNoEta0(matchType m) const
TH1D * getHisto1OverPtPhysPrimNum(matchType m) const
void setMaxTPCOccPbPb(float v)
void setMaxTPCOccpp(float v)
TH3F * getHistoEtaPhiPtDen(matchType m) const
void setK0MaxDCA(float v)
void setDataRequest(const std::shared_ptr< o2::globaltracking::DataRequest > &dr)
void setTrkSources(GID::mask_t src)
TH3F * getHistoK0MassVsPtVsOccPbPb() const
float getK0Scaling() const
TH1F * getHistoDCAr() const
TH2F * getHistoChi2VsPtNum(matchType m) const
void setK0Scaling(float v)
TH1D * getHisto1OverPtPhysPrimDen(matchType m) const
TH2F * getHistoTimeResVsPt() const
TEfficiency * getFractionITSTPCmatchPhi(matchType m) const
TEfficiency * getFractionITSTPCmatchClsVsPt(matchType m) const
void setUseTrkPID(bool b)
TH1F * getHistoPtPhysPrimDen(matchType m) const
void setMinNTPCClustersCut(int v)
void setNBinsTPCOccpp(int v)
TH1D * getHistoPtDen(matchType m) const
bool processV0(int iv, o2::globaltracking::RecoContainer &recoData, std::vector< float > &mTBinClOcc, float pvTime)
TH1F * getHistoPhiNum(matchType m) const
TH1F * getHistoEtaNum(matchType m) const
void setEtaNo0Cut(float v)
TH2F * getHistoPhiVsPtNum(matchType m) const
void setMaxChi2PerClusterITS(float v)
TH1F * getHistoChi2Matching() const
TH1D * getHisto1OverPtDen(matchType m) const
float getK0MaxDCA() const
TH2F * getHistoResidualEta() const
TH1F * getHistoEtaPhysPrimNum(matchType m) const
TH2F * getHistoResidualPhi() const
void setMinDCAtoBeamPipeCut(std::array< float, 2 > v)
TH1D * getHistoPtNum(matchType m) const
void setMinDCAtoBeamPipeDistanceCut(float v)
MatchITSTPCQC & operator=(const MatchITSTPCQC &)=delete
TH3F * getHistoK0MassVsPtVsOccpp() const
TH2F * getHistoClsVsPtNum(matchType m) const
TEfficiency * getFractionITSTPCmatchEtaVsPt(matchType m) const
TEfficiency * getFractionITSTPCmatchPhysPrim(matchType m) const
TEfficiency * getFractionITSTPCmatchDCArVsPt() const
TEfficiency * getFractionITSTPCmatch(matchType m) const
void setMinNClustersITS(int v)
float getK0MinCosPA() const
bool refitV0(const o2::dataformats::V0Index &id, o2::dataformats::V0 &v0, o2::globaltracking::RecoContainer &recoData)
void setCutK0Mass(float v)
void setMinTPCOccpp(float v)
TH1D * getHistoPtDenNoEta0(matchType m) const
TH1F * getHistoPhiDen(matchType m) const
void getHistos(TObjArray &objar)
TH1F * getHistoEtaPhysPrimDen(matchType m) const
TH1F * getHistoPhiPhysPrimNum(matchType m) const
void setNBinsTPCOccPbPb(int v)
TH2F * getHistoEtaVsPtNum(matchType m) const
void setEtaTPCCut(float v)
TH2F * getHistoEtaVsPtDen(matchType m) const
TH1F * getHistoChi2Refit() const
TH2F * getHistoPhiVsPtDen(matchType m) const
TH1F * getHistoPtPhysPrimNum(matchType m) const
void setEtaITSCut(float v)
void publishHistograms(const std::shared_ptr< T > &publisher)
Publishes the histograms to the publisher e.g. the one provided by the QC task.
TEfficiency * getFractionITSTPCmatchEta(matchType m) const
MatchITSTPCQC & operator=(MatchITSTPCQC &&)=delete
TH2F * getHistoDCArVsPtDen() const
TEfficiency * getFractionITSTPCmatchPhiPhysPrim(matchType m) const
TEfficiency * getFractionITSTPCmatchPhysPrim1OverPt(matchType m) const
TH1D * getHisto1OverPtNum(matchType m) const
TEfficiency * getFractionITSTPCmatchChi2VsPt(matchType m) const
TH1F * getHistoEtaDen(matchType m) const
TH1F * getHistoPhiPhysPrimDen(matchType m) const
void setMaxPtCut(float v)
TH2F * getHistoChi2VsPtDen(matchType m) const
bool getUseTrkPID() const
void run(o2::framework::ProcessingContext &ctx)
void setMinPtITSCut(float v)
TH2F * getHistoResidualPt() const
void setMinPtTPCCut(float v)
MatchITSTPCQC(MatchITSTPCQC &&)=delete
MatchITSTPCQC(const MatchITSTPCQC &)=delete
GLboolean GLboolean GLboolean b
a couple of static helper functions to create timestamp values for CCDB queries or override obsolete ...