Skip to content

Commit 4393619

Browse files
author
Neelima Agrawal
committed
Added Event Cut to remove time ranges with dead ITS staves (dips)
1 parent e7a258c commit 4393619

4 files changed

Lines changed: 27 additions & 6 deletions

File tree

PWGCF/Femto3D/DataModel/singletrackselector.h

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,7 @@ DECLARE_SOA_DYNAMIC_COLUMN(dIsGoodZvtxFT0vsPV, isGoodZvtxFT0vsPV, [](uint64_t se
135135
DECLARE_SOA_DYNAMIC_COLUMN(dIsVertexITSTPC, isVertexITSTPC, [](uint64_t selBit) -> bool { return TESTBIT(selBit, evsel::kIsVertexITSTPC); });
136136
DECLARE_SOA_DYNAMIC_COLUMN(dIsVertexTOForTRDmatched, isVertexTOForTRDmatched, [](uint64_t selBit) -> int { return static_cast<int>(TESTBIT(selBit, evsel::kIsVertexTOFmatched)) + static_cast<int>(TESTBIT(selBit, evsel::kIsVertexTRDmatched)); });
137137
DECLARE_SOA_DYNAMIC_COLUMN(dNoCollInTimeRangeStandard, noCollInTimeRangeStandard, [](uint64_t selBit) -> bool { return TESTBIT(selBit, evsel::kNoCollInTimeRangeStandard); });
138-
138+
DECLARE_SOA_DYNAMIC_COLUMN(dIsGoodITSLayersAll, isGoodITSLayersAll, [](uint64_t selBit) -> bool { return TESTBIT(selBit, evsel::kIsGoodITSLayersAll); });
139139
} // namespace singletrackselector
140140

141141
DECLARE_SOA_TABLE(SingleCollSels, "AOD", "SINGLECOLLSEL", // Table of the variables for single track selection.
@@ -154,7 +154,8 @@ DECLARE_SOA_TABLE(SingleCollExtras_v1, "AOD", "SINGLECOLLEXTR1", // Joinable col
154154
singletrackselector::dIsGoodZvtxFT0vsPV<evsel::Selection>,
155155
singletrackselector::dIsVertexITSTPC<evsel::Selection>,
156156
singletrackselector::dIsVertexTOForTRDmatched<evsel::Selection>,
157-
singletrackselector::dNoCollInTimeRangeStandard<evsel::Selection>);
157+
singletrackselector::dNoCollInTimeRangeStandard<evsel::Selection>,
158+
singletrackselector::dIsGoodITSLayersAll<evsel::Selection>);
158159

159160
using SingleCollExtras = SingleCollExtras_v1;
160161

PWGCF/Femto3D/Tasks/femto3dPairTask.cxx

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,7 @@ struct FemtoCorrelations {
5555
Configurable<bool> _requestVertexITSTPC{"requestVertexITSTPC", false, ""};
5656
Configurable<int> _requestVertexTOForTRDmatched{"requestVertexTOFmatched", 0, "0 -> no selectio; 1 -> vertex is matched to TOF or TRD; 2 -> matched to both;"};
5757
Configurable<bool> _requestNoCollInTimeRangeStandard{"requestNoCollInTimeRangeStandard", false, ""};
58+
Configurable<bool>_requestIsGoodITSLayersAll{"requestIsGoodITSLayersAll", false, "cut time intervals with dead ITS staves"};
5859
Configurable<std::pair<float, float>> _IRcut{"IRcut", std::pair<float, float>{0.f, 100.f}, "[min., max.] IR range to keep events within"};
5960
Configurable<std::pair<int, int>> _OccupancyCut{"OccupancyCut", std::pair<int, int>{0, 10000}, "[min., max.] occupancy range to keep events within"};
6061

@@ -423,6 +424,8 @@ struct FemtoCorrelations {
423424
continue;
424425
if (_requestNoCollInTimeRangeStandard && !track.template singleCollSel_as<soa::Filtered<FilteredCollisions>>().noCollInTimeRangeStandard())
425426
continue;
427+
if (_requestIsGoodITSLayersAll && !track.template singleCollSel_as<soa::Filtered<FilteredCollisions>>().isGoodITSLayersAll())
428+
continue;
426429
if (track.tpcFractionSharedCls() > _tpcFractionSharedCls || track.itsNCls() < _itsNCls)
427430
continue;
428431
if (track.template singleCollSel_as<soa::Filtered<FilteredCollisions>>().multPerc() < *_centBins.value.begin() || track.template singleCollSel_as<soa::Filtered<FilteredCollisions>>().multPerc() >= *(_centBins.value.end() - 1))
@@ -474,6 +477,9 @@ struct FemtoCorrelations {
474477
if (_requestNoCollInTimeRangeStandard && !collision.noCollInTimeRangeStandard())
475478
continue;
476479

480+
if (_requestIsGoodITSLayersAll && !collision.isGoodITSLayersAll())
481+
continue;
482+
477483
if (selectedtracks_1.find(collision.globalIndex()) == selectedtracks_1.end()) {
478484
if (IsIdentical)
479485
continue;

PWGCF/Femto3D/Tasks/femto3dPairTaskMC.cxx

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,7 @@ struct FemtoCorrelationsMC {
5151
Configurable<bool> _requestVertexITSTPC{"requestVertexITSTPC", false, ""};
5252
Configurable<int> _requestVertexTOForTRDmatched{"requestVertexTOFmatched", 0, "0 -> no selectio; 1 -> vertex is matched to TOF or TRD; 2 -> matched to both;"};
5353
Configurable<bool> _requestNoCollInTimeRangeStandard{"requestNoCollInTimeRangeStandard", false, ""};
54+
Configurable<bool>_requestIsGoodITSLayersAll{"requestIsGoodITSLayersAll", false, "cut time intervals with dead ITS staves"};
5455
Configurable<std::pair<float, float>> _IRcut{"IRcut", std::pair<float, float>{0.f, 100.f}, "[min., max.] IR range to keep events within"};
5556
Configurable<std::pair<int, int>> _OccupancyCut{"OccupancyCut", std::pair<int, int>{0, 10000}, "[min., max.] occupancy range to keep events within"};
5657

@@ -350,6 +351,8 @@ struct FemtoCorrelationsMC {
350351
continue;
351352
if (_requestNoCollInTimeRangeStandard && !track.template singleCollSel_as<soa::Filtered<FilteredCollisions>>().noCollInTimeRangeStandard())
352353
continue;
354+
if (_requestIsGoodITSLayersAll && !track.template singleCollSel_as<soa::Filtered<FilteredCollisions>>().isGoodITSLayersAll())
355+
continue;
353356

354357
unsigned int centBin = o2::aod::singletrackselector::getBinIndex<unsigned int>(track.template singleCollSel_as<soa::Filtered<FilteredCollisions>>().multPerc(), _centBins);
355358

@@ -412,7 +415,9 @@ struct FemtoCorrelationsMC {
412415
continue;
413416
if (_requestNoCollInTimeRangeStandard && !collision.noCollInTimeRangeStandard())
414417
continue;
415-
418+
if (_requestIsGoodITSLayersAll && !collision.isGoodITSLayersAll())
419+
continue;
420+
416421
if (selectedtracks_1.find(collision.globalIndex()) == selectedtracks_1.end()) {
417422
if (IsIdentical)
418423
continue;

PWGCF/Femto3D/Tasks/femto3dQA.cxx

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@ struct QAHistograms {
5252
Configurable<bool> _requestVertexITSTPC{"requestVertexITSTPC", false, ""};
5353
Configurable<int> _requestVertexTOForTRDmatched{"requestVertexTOFmatched", 0, "0 -> no selectio; 1 -> vertex is matched to TOF or TRD; 2 -> matched to both;"};
5454
Configurable<bool> _requestNoCollInTimeRangeStandard{"requestNoCollInTimeRangeStandard", false, ""};
55+
Configurable<bool>_requestIsGoodITSLayersAll{"requestIsGoodITSLayersAll", false, "cut time intervals with dead ITS staves"};
5556
Configurable<std::pair<float, float>> _IRcut{"IRcut", std::pair<float, float>{0.f, 100.f}, "[min., max.] IR range to keep events within"};
5657
Configurable<std::pair<int, int>> _OccupancyCut{"OccupancyCut", std::pair<int, int>{0, 10000}, "[min., max.] occupancy range to keep events within"};
5758

@@ -181,6 +182,8 @@ struct QAHistograms {
181182
continue;
182183
if (_requestNoCollInTimeRangeStandard && !collision.noCollInTimeRangeStandard())
183184
continue;
185+
if (_requestIsGoodITSLayersAll && !collision.isGoodITSLayersAll())
186+
continue;
184187
if (collision.multPerc() < _centCut.value.first || collision.multPerc() >= _centCut.value.second)
185188
continue;
186189
if (collision.hadronicRate() < _IRcut.value.first || collision.hadronicRate() >= _IRcut.value.second)
@@ -206,6 +209,8 @@ struct QAHistograms {
206209
continue;
207210
if (_requestNoCollInTimeRangeStandard && !track.template singleCollSel_as<ColsType>().noCollInTimeRangeStandard())
208211
continue;
212+
if (_requestIsGoodITSLayersAll && !track.template singleCollSel_as<ColsType>().isGoodITSLayersAll())
213+
continue;
209214

210215
if (std::fabs(track.template singleCollSel_as<ColsType>().posZ()) > _vertexZ)
211216
continue;
@@ -245,9 +250,13 @@ struct QAHistograms {
245250
registry.fill(HIST("ITSchi2"), track.itsChi2NCl());
246251
registry.fill(HIST("TPCchi2"), track.tpcChi2NCl());
247252

248-
ITShisto->Fill(track.p(), o2::aod::singletrackselector::getITSNsigma(track, _particlePDG));
249-
TPChisto->Fill(track.p(), o2::aod::singletrackselector::getTPCNsigma(track, _particlePDG));
250-
TOFhisto->Fill(track.p(), o2::aod::singletrackselector::getTOFNsigma(track, _particlePDG));
253+
if (ITShisto) ITShisto->Fill(track.p(), o2::aod::singletrackselector::getITSNsigma(track, _particlePDG));
254+
if (TPChisto) TPChisto->Fill(track.p(), o2::aod::singletrackselector::getTPCNsigma(track, _particlePDG));
255+
if (TOFhisto) TOFhisto->Fill(track.p(), o2::aod::singletrackselector::getTOFNsigma(track, _particlePDG));
256+
257+
if (!ITShisto || !TPChisto || !TOFhisto) {
258+
LOGF(error, "One or more dynamic histograms were not created. Check PDG: %d", _particlePDG.value);}
259+
251260

252261
if constexpr (FillExtra) {
253262
registry.fill(HIST("TPCSignal"), track.tpcInnerParam(), track.tpcSignal());

0 commit comments

Comments
 (0)