Skip to content

Commit f158ee1

Browse files
PWGLF: NucleiTask - Add cluster cut (#1619)
* PWGLF: NucleiTask - Add cluster cut * Minor format fix * Fix MegaLinter issue
1 parent 8f2e718 commit f158ee1

3 files changed

Lines changed: 17 additions & 14 deletions

File tree

PWGLF/DataModel/LFNucleiTables.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,7 @@ DECLARE_SOA_COLUMN(Beta, beta, float);
8484
// TPC and ITS QA
8585
DECLARE_SOA_COLUMN(TPCNClsCrossedRows, tpcNClsCrossedRows, int16_t);
8686
DECLARE_SOA_COLUMN(TPCCrossedRowsOverFindableCls, tpcCrossedRowsOverFindableCls, float);
87+
DECLARE_SOA_COLUMN(TPCNClsFound, tpcNClsFound, int16_t);
8788
DECLARE_SOA_COLUMN(TPCChi2Ncl, tpcChi2NCl, float);
8889
DECLARE_SOA_COLUMN(ITSChi2NCl, itsChi2NCl, float);
8990
// For MC
@@ -126,6 +127,7 @@ DECLARE_SOA_TABLE(LfCandNucleusFull, "AOD", "LFNUCL",
126127
full::Sign,
127128
full::TPCNClsCrossedRows,
128129
full::TPCCrossedRowsOverFindableCls,
130+
full::TPCNClsFound,
129131
full::TPCChi2Ncl,
130132
full::ITSChi2NCl);
131133
DECLARE_SOA_TABLE(LfCandNucleusMC, "AOD", "LFNUCLMC",

PWGLF/TableProducer/LFTreeCreatorNuclei.cxx

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,12 @@
2020

2121
#include "PWGLF/DataModel/LFNucleiTables.h"
2222

23+
#include <cmath>
24+
25+
#include <TLorentzVector.h>
26+
#include <TMath.h>
27+
#include <TObjArray.h>
28+
2329
#include "ReconstructionDataFormats/Track.h"
2430
#include "Framework/runDataProcessing.h"
2531
#include "Framework/AnalysisTask.h"
@@ -35,11 +41,6 @@
3541
#include "Common/DataModel/TrackSelectionTables.h"
3642
#include "Common/Core/trackUtilities.h"
3743

38-
#include <TLorentzVector.h>
39-
#include <TMath.h>
40-
#include <TObjArray.h>
41-
#include <cmath>
42-
4344
using namespace o2;
4445
using namespace o2::framework;
4546
using namespace o2::framework::expressions;
@@ -133,6 +134,7 @@ struct LfTreeCreatorNuclei {
133134
track.sign(),
134135
track.tpcNClsCrossedRows(),
135136
track.tpcCrossedRowsOverFindableCls(),
137+
track.tpcNClsFound(),
136138
track.tpcChi2NCl(),
137139
track.itsChi2NCl());
138140

PWGLF/Tasks/LFNucleiBATask.cxx

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,8 @@ struct LFNucleiBATask {
4646
Configurable<float> etaCut{"etaCut", 0.8f, "Value of the eta selection for spectra (default 0.8)"};
4747
Configurable<float> yCut{"yCut", 0.5f, "Value of the rapidity selection for spectra (default 0.5)"};
4848
Configurable<float> cfgCutVertex{"cfgCutVSertex", 10.0f, "Accepted z-vertex range"};
49+
Configurable<float> cfgCutTPCXRows{"cfgCutTPCXRows", -1.f, "Minimum number of crossed TPC rows"};
50+
Configurable<float> cfgCutTPCClusters{"cfgCutTPCClusters", -1.f, "Minimum number of found TPC clusters"};
4951
ConfigurableAxis binsPt{"binsPt", {VARIABLE_WIDTH, 0.0, 0.1, 0.12, 0.14, 0.16, 0.18, 0.2, 0.25, 0.3, 0.35, 0.4, 0.45, 0.5, 0.55, 0.6, 0.65, 0.7, 0.75, 0.8, 0.85, 0.9, 0.95, 1.0, 1.1, 1.2, 1.3, 1.4, 1.5, 1.6, 1.7, 1.8, 2.0, 2.2, 2.4, 2.6, 2.8, 3.0, 3.2, 3.4, 3.6, 3.8, 4.0, 4.2, 4.4, 4.6, 4.8, 5.0}, ""};
5052
ConfigurableAxis binsdEdx{"binsdEdx", {1000, 0.f, 1000.f}, ""};
5153
Configurable<bool> enableEvTimeSplitting{"enableEvTimeSplitting", true, "Flag to enable histograms splitting depending on the Event Time used"};
@@ -654,7 +656,11 @@ struct LFNucleiBATask {
654656
continue;
655657
}
656658
}
657-
// QUI DCA
659+
660+
if (track.tpcNClsCrossedRows() < cfgCutTPCXRows)
661+
continue;
662+
if (track.tpcNClsFound() < cfgCutTPCClusters)
663+
continue;
658664

659665
// Tracks DCA histos fill
660666
histos.fill(HIST("tracks/hDCAxy"), track.dcaXY());
@@ -714,7 +720,7 @@ struct LFNucleiBATask {
714720
continue;
715721
}
716722
}
717-
// QUI TUTTO IL RESTO
723+
718724
// LOG(info)<<"\n collisionId ============>"<<track.collisionId();
719725

720726
// QA histos fill
@@ -753,13 +759,6 @@ struct LFNucleiBATask {
753759
}
754760
}
755761

756-
// Calculate on fly NSigmaTPC* calibrated from BB parameters for light antinuclei
757-
/*
758-
To be included
759-
760-
return NSigmaTPC[De,Tr,He,Al]Cal
761-
*/
762-
763762
// Tracks histos fill
764763
histos.fill(HIST("tracks/h1Eta"), track.eta());
765764
histos.fill(HIST("tracks/h1VarPhi"), track.phi());

0 commit comments

Comments
 (0)