Skip to content

Commit f861753

Browse files
authored
Merge branch 'AliceO2Group:master' into pjpsi_femto
2 parents 5b6a828 + 2ff3835 commit f861753

File tree

6 files changed

+87
-52
lines changed

6 files changed

+87
-52
lines changed

PWGCF/FemtoUniverse/Core/FemtoUniverseParticleHisto.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,7 @@ class FemtoUniverseParticleHisto
7979
mHistogramRegistry->add((folderName + folderSuffix + "/hTPCcrossedRows").c_str(), "; TPC crossed rows; Entries", kTH1F, {{163, -0.5, 162.5}});
8080
mHistogramRegistry->add((folderName + folderSuffix + "/hTPCfindableVsCrossed").c_str(), ";TPC findable clusters ; TPC crossed rows;", kTH2F, {{163, -0.5, 162.5}, {163, -0.5, 162.5}});
8181
mHistogramRegistry->add((folderName + folderSuffix + "/hTPCshared").c_str(), "; TPC shared clusters; Entries", kTH1F, {{163, -0.5, 162.5}});
82+
mHistogramRegistry->add((folderName + folderSuffix + "/hTPCsharedFrac").c_str(), "; TPC fraction of shared clusters; Entries", kTH1F, {{100, 0.0, 100.0}});
8283
mHistogramRegistry->add((folderName + folderSuffix + "/hITSclusters").c_str(), "; ITS clusters; Entries", kTH1F, {{10, -0.5, 9.5}});
8384
mHistogramRegistry->add((folderName + folderSuffix + "/hITSclustersIB").c_str(), "; ITS clusters in IB; Entries", kTH1F, {{10, -0.5, 9.5}});
8485
mHistogramRegistry->add((folderName + folderSuffix + "/hDCAz").c_str(), "; #it{p}_{T} (GeV/#it{c}); DCA_{z} (cm)", kTH2F, {{100, 0, 10}, {500, -5, 5}});
@@ -251,6 +252,7 @@ class FemtoUniverseParticleHisto
251252
mHistogramRegistry->fill(histFolder + HIST(o2::aod::femtouniverse_mc_particle::MCTypeName[mc]) + HIST("/hTPCcrossedRows"), part.tpcNClsCrossedRows());
252253
mHistogramRegistry->fill(histFolder + HIST(o2::aod::femtouniverse_mc_particle::MCTypeName[mc]) + HIST("/hTPCfindableVsCrossed"), part.tpcNClsFindable(), part.tpcNClsCrossedRows());
253254
mHistogramRegistry->fill(histFolder + HIST(o2::aod::femtouniverse_mc_particle::MCTypeName[mc]) + HIST("/hTPCshared"), part.tpcNClsShared());
255+
mHistogramRegistry->fill(histFolder + HIST(o2::aod::femtouniverse_mc_particle::MCTypeName[mc]) + HIST("/hTPCsharedFrac"), part.tpcFractionSharedCls());
254256
mHistogramRegistry->fill(histFolder + HIST(o2::aod::femtouniverse_mc_particle::MCTypeName[mc]) + HIST("/hITSclusters"), part.itsNCls());
255257
mHistogramRegistry->fill(histFolder + HIST(o2::aod::femtouniverse_mc_particle::MCTypeName[mc]) + HIST("/hITSclustersIB"), part.itsNClsInnerBarrel());
256258
mHistogramRegistry->fill(histFolder + HIST(o2::aod::femtouniverse_mc_particle::MCTypeName[mc]) + HIST("/hDCAz"), part.pt(), part.dcaZ());

PWGCF/FemtoUniverse/Core/FemtoUniverseTrackSelection.h

Lines changed: 34 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -37,20 +37,21 @@ namespace o2::analysis::femto_universe
3737
namespace femto_universe_track_selection
3838
{
3939
/// The different selections this task is capable of doing
40-
enum TrackSel { kSign, ///< Sign of the track
41-
kpTMin, ///< Min. p_T (GeV/c)
42-
kpTMax, ///< Max. p_T (GeV/c)
43-
kEtaMax, ///< Max. |eta|
44-
kTPCnClsMin, ///< Min. number of TPC clusters
45-
kTPCfClsMin, ///< Min. fraction of crossed rows/findable TPC clusters
46-
kTPCcRowsMin, ///< Min. number of crossed TPC rows
47-
kTPCsClsMax, ///< Max. number of shared TPC clusters
48-
kITSnClsMin, ///< Min. number of ITS clusters
49-
kITSnClsIbMin, ///< Min. number of ITS clusters in the inner barrel
50-
kDCAxyMax, ///< Max. DCA_xy (cm)
51-
kDCAzMax, ///< Max. DCA_z (cm)
52-
kDCAMin, ///< Min. DCA_xyz (cm)
53-
kPIDnSigmaMax ///< Max. |n_sigma| for PID
40+
enum TrackSel { kSign, ///< Sign of the track
41+
kpTMin, ///< Min. p_T (GeV/c)
42+
kpTMax, ///< Max. p_T (GeV/c)
43+
kEtaMax, ///< Max. |eta|
44+
kTPCnClsMin, ///< Min. number of TPC clusters
45+
kTPCfClsMin, ///< Min. fraction of crossed rows/findable TPC clusters
46+
kTPCcRowsMin, ///< Min. number of crossed TPC rows
47+
kTPCsClsMax, ///< Max. number of shared TPC clusters
48+
kTPCfracsClsMax, ///< Max. number of fraction of shared TPC clusters
49+
kITSnClsMin, ///< Min. number of ITS clusters
50+
kITSnClsIbMin, ///< Min. number of ITS clusters in the inner barrel
51+
kDCAxyMax, ///< Max. DCA_xy (cm)
52+
kDCAzMax, ///< Max. DCA_z (cm)
53+
kDCAMin, ///< Min. DCA_xyz (cm)
54+
kPIDnSigmaMax ///< Max. |n_sigma| for PID
5455
};
5556

5657
enum TrackContainerPosition {
@@ -86,6 +87,7 @@ class FemtoUniverseTrackSelection : public FemtoUniverseObjectSelection<float, f
8687
fClsMin(9999999.),
8788
cTPCMin(9999999.),
8889
sTPCMax(-9999999.),
90+
fracsTPCMax(-9999999.),
8991
dcaXYMax(-9999999.),
9092
dcaZMax(-9999999.),
9193
dcaMin(9999999.),
@@ -220,6 +222,7 @@ class FemtoUniverseTrackSelection : public FemtoUniverseObjectSelection<float, f
220222
int nTPCfMinSel;
221223
int nTPCcMinSel;
222224
int nTPCsMaxSel;
225+
int nTPCsFracMaxSel;
223226
int nITScMinSel;
224227
int nITScIbMinSel;
225228
int nDCAxyMaxSel;
@@ -233,6 +236,7 @@ class FemtoUniverseTrackSelection : public FemtoUniverseObjectSelection<float, f
233236
float fClsMin;
234237
float cTPCMin;
235238
float sTPCMax;
239+
float fracsTPCMax;
236240
float nITSclsMin;
237241
float nITSclsIbMin;
238242
float dcaXYMax;
@@ -242,7 +246,7 @@ class FemtoUniverseTrackSelection : public FemtoUniverseObjectSelection<float, f
242246
float nSigmaPIDOffsetTPC;
243247
float nSigmaPIDOffsetTOF;
244248
std::vector<o2::track::PID> kPIDspecies; ///< All the particle species for which the n_sigma values need to be stored
245-
static constexpr int kNtrackSelection = 14;
249+
static constexpr int kNtrackSelection = 15;
246250
static constexpr std::string_view kSelectionNames[kNtrackSelection] = {"Sign",
247251
"PtMin",
248252
"PtMax",
@@ -251,6 +255,7 @@ class FemtoUniverseTrackSelection : public FemtoUniverseObjectSelection<float, f
251255
"TPCfClsMin",
252256
"TPCcRowsMin",
253257
"TPCsClsMax",
258+
"TPCfracsClsMax",
254259
"ITSnClsMin",
255260
"ITSnClsIbMin",
256261
"DCAxyMax",
@@ -266,6 +271,7 @@ class FemtoUniverseTrackSelection : public FemtoUniverseObjectSelection<float, f
266271
femto_universe_selection::kLowerLimit,
267272
femto_universe_selection::kLowerLimit,
268273
femto_universe_selection::kUpperLimit,
274+
femto_universe_selection::kUpperLimit,
269275
femto_universe_selection::kLowerLimit,
270276
femto_universe_selection::kLowerLimit,
271277
femto_universe_selection::kAbsUpperLimit,
@@ -281,6 +287,7 @@ class FemtoUniverseTrackSelection : public FemtoUniverseObjectSelection<float, f
281287
"Minimum fraction of crossed rows/findable clusters",
282288
"Minimum number of crossed TPC rows",
283289
"Maximal number of shared TPC cluster",
290+
"Maximal number of fraction of shared TPC cluster",
284291
"Minimum number of ITS clusters",
285292
"Minimum number of ITS clusters in the inner barrel",
286293
"Maximal DCA_xy (cm)",
@@ -311,6 +318,7 @@ void FemtoUniverseTrackSelection::init(HistogramRegistry* registry)
311318
mHistogramRegistry->add((folderName + "/hTPCcrossedRows").c_str(), "; TPC crossed rows; Entries", kTH1F, {{163, 0, 163}});
312319
mHistogramRegistry->add((folderName + "/hTPCfindableVsCrossed").c_str(), ";TPC findable clusters ; TPC crossed rows;", kTH2F, {{163, 0, 163}, {163, 0, 163}});
313320
mHistogramRegistry->add((folderName + "/hTPCshared").c_str(), "; TPC shared clusters; Entries", kTH1F, {{163, -0.5, 162.5}});
321+
mHistogramRegistry->add((folderName + "/hTPCfracshared").c_str(), "; TPC fraction of shared clusters; Entries", kTH1F, {{100, 0.0, 100.0}});
314322
mHistogramRegistry->add((folderName + "/hITSclusters").c_str(), "; ITS clusters; Entries", kTH1F, {{10, -0.5, 9.5}});
315323
mHistogramRegistry->add((folderName + "/hITSclustersIB").c_str(), "; ITS clusters in IB; Entries", kTH1F, {{10, -0.5, 9.5}});
316324
mHistogramRegistry->add((folderName + "/hDCAxy").c_str(), "; #it{p}_{T} (GeV/#it{c}); DCA_{xy} (cm)", kTH2F, {{100, 0, 10}, {500, -5, 5}});
@@ -341,6 +349,7 @@ void FemtoUniverseTrackSelection::init(HistogramRegistry* registry)
341349
nTPCfMinSel = getNSelections(femto_universe_track_selection::kTPCfClsMin);
342350
nTPCcMinSel = getNSelections(femto_universe_track_selection::kTPCcRowsMin);
343351
nTPCsMaxSel = getNSelections(femto_universe_track_selection::kTPCsClsMax);
352+
nTPCsFracMaxSel = getNSelections(femto_universe_track_selection::kTPCfracsClsMax);
344353
nITScMinSel = getNSelections(femto_universe_track_selection::kITSnClsMin);
345354
nITScIbMinSel = getNSelections(femto_universe_track_selection::kITSnClsIbMin);
346355
nDCAxyMaxSel = getNSelections(femto_universe_track_selection::kDCAxyMax);
@@ -355,6 +364,7 @@ void FemtoUniverseTrackSelection::init(HistogramRegistry* registry)
355364
fClsMin = getMinimalSelection(femto_universe_track_selection::kTPCfClsMin, femto_universe_selection::kLowerLimit);
356365
cTPCMin = getMinimalSelection(femto_universe_track_selection::kTPCcRowsMin, femto_universe_selection::kLowerLimit);
357366
sTPCMax = getMinimalSelection(femto_universe_track_selection::kTPCsClsMax, femto_universe_selection::kUpperLimit);
367+
fracsTPCMax = getMinimalSelection(femto_universe_track_selection::kTPCfracsClsMax, femto_universe_selection::kUpperLimit);
358368
nITSclsMin = getMinimalSelection(femto_universe_track_selection::kITSnClsMin, femto_universe_selection::kLowerLimit);
359369
nITSclsIbMin = getMinimalSelection(femto_universe_track_selection::kITSnClsIbMin, femto_universe_selection::kLowerLimit);
360370
dcaXYMax = getMinimalSelection(femto_universe_track_selection::kDCAxyMax, femto_universe_selection::kAbsUpperLimit);
@@ -389,6 +399,7 @@ bool FemtoUniverseTrackSelection::isSelectedMinimal(T const& track)
389399
const auto tpcRClsC = track.tpcCrossedRowsOverFindableCls();
390400
const auto tpcNClsC = track.tpcNClsCrossedRows();
391401
const auto tpcNClsS = track.tpcNClsShared();
402+
const auto tpcNClsFracS = track.tpcFractionSharedCls();
392403
const auto itsNCls = track.itsNCls();
393404
const auto itsNClsIB = track.itsNClsInnerBarrel();
394405
const auto dcaXY = track.dcaXY();
@@ -422,6 +433,9 @@ bool FemtoUniverseTrackSelection::isSelectedMinimal(T const& track)
422433
if (nTPCsMaxSel > 0 && tpcNClsS > sTPCMax) {
423434
return false;
424435
}
436+
if (nTPCsFracMaxSel > 0 && tpcNClsFracS > fracsTPCMax) {
437+
return false;
438+
}
425439
if (nITScMinSel > 0 && itsNCls < nITSclsMin) {
426440
return false;
427441
}
@@ -469,6 +483,7 @@ std::array<CutContainerType, 2> FemtoUniverseTrackSelection::getCutContainer(T c
469483
const auto tpcRClsC = track.tpcCrossedRowsOverFindableCls();
470484
const auto tpcNClsC = track.tpcNClsCrossedRows();
471485
const auto tpcNClsS = track.tpcNClsShared();
486+
const auto tpcNClsFracS = track.tpcFractionSharedCls();
472487
const auto itsNCls = track.itsNCls();
473488
const auto itsNClsIB = track.itsNClsInnerBarrel();
474489
const auto dcaXY = track.dcaXY();
@@ -519,6 +534,9 @@ std::array<CutContainerType, 2> FemtoUniverseTrackSelection::getCutContainer(T c
519534
case (femto_universe_track_selection::kTPCsClsMax):
520535
observable = tpcNClsS;
521536
break;
537+
case (femto_universe_track_selection::kTPCfracsClsMax):
538+
observable = tpcNClsFracS;
539+
break;
522540
case (femto_universe_track_selection::kITSnClsMin):
523541
observable = itsNCls;
524542
break;
@@ -556,6 +574,7 @@ void FemtoUniverseTrackSelection::fillQA(T const& track)
556574
mHistogramRegistry->fill(HIST(o2::aod::femtouniverseparticle::ParticleTypeName[part]) + HIST("/") + HIST(o2::aod::femtouniverseparticle::TrackTypeName[tracktype]) + HIST("/hTPCcrossedRows"), track.tpcNClsCrossedRows());
557575
mHistogramRegistry->fill(HIST(o2::aod::femtouniverseparticle::ParticleTypeName[part]) + HIST("/") + HIST(o2::aod::femtouniverseparticle::TrackTypeName[tracktype]) + HIST("/hTPCfindableVsCrossed"), track.tpcNClsFindable(), track.tpcNClsCrossedRows());
558576
mHistogramRegistry->fill(HIST(o2::aod::femtouniverseparticle::ParticleTypeName[part]) + HIST("/") + HIST(o2::aod::femtouniverseparticle::TrackTypeName[tracktype]) + HIST("/hTPCshared"), track.tpcNClsShared());
577+
mHistogramRegistry->fill(HIST(o2::aod::femtouniverseparticle::ParticleTypeName[part]) + HIST("/") + HIST(o2::aod::femtouniverseparticle::TrackTypeName[tracktype]) + HIST("/hTPCfractionSharedCls"), track.tpcFractionSharedCls());
559578
mHistogramRegistry->fill(HIST(o2::aod::femtouniverseparticle::ParticleTypeName[part]) + HIST("/") + HIST(o2::aod::femtouniverseparticle::TrackTypeName[tracktype]) + HIST("/hITSclusters"), track.itsNCls());
560579
mHistogramRegistry->fill(HIST(o2::aod::femtouniverseparticle::ParticleTypeName[part]) + HIST("/") + HIST(o2::aod::femtouniverseparticle::TrackTypeName[tracktype]) + HIST("/hITSclustersIB"), track.itsNClsInnerBarrel());
561580
mHistogramRegistry->fill(HIST(o2::aod::femtouniverseparticle::ParticleTypeName[part]) + HIST("/") + HIST(o2::aod::femtouniverseparticle::TrackTypeName[tracktype]) + HIST("/hDCAxy"), track.pt(), track.dcaXY());

PWGCF/FemtoUniverse/DataModel/FemtoDerived.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -123,6 +123,7 @@ DECLARE_SOA_DYNAMIC_COLUMN(P, p, //! Compute the overall momentum in GeV/c
123123
DECLARE_SOA_COLUMN(Sign, sign, int8_t); //! Sign of the track charge
124124
DECLARE_SOA_COLUMN(TpcNClsFound, tpcNClsFound, uint8_t); //! Number of TPC clusters
125125
DECLARE_SOA_COLUMN(TpcNClsCrossedRows, tpcNClsCrossedRows, uint8_t); //! Number of TPC crossed rows
126+
DECLARE_SOA_COLUMN(TPCFractionSharedCls, tpcFractionSharedCls, float); //! Number of TPC crossed rows
126127
DECLARE_SOA_COLUMN(ItsNCls, itsNCls, uint8_t); //! Number of ITS clusters
127128
DECLARE_SOA_COLUMN(ItsNClsInnerBarrel, itsNClsInnerBarrel, uint8_t); //! Number of ITS clusters in the inner barrel //! TPC signal
128129
DECLARE_SOA_DYNAMIC_COLUMN(TpcCrossedRowsOverFindableCls, tpcCrossedRowsOverFindableCls, //! Compute the number of crossed rows over findable TPC clusters
@@ -181,6 +182,7 @@ DECLARE_SOA_TABLE(FDExtParticles, "AOD", "FDEXTPARTICLE",
181182
track::TPCNClsFindable,
182183
femtouniverseparticle::TpcNClsCrossedRows,
183184
track::TPCNClsShared,
185+
femtouniverseparticle::TPCFractionSharedCls,
184186
track::TPCInnerParam,
185187
femtouniverseparticle::ItsNCls,
186188
femtouniverseparticle::ItsNClsInnerBarrel,

PWGCF/FemtoUniverse/TableProducer/femtoUniverseProducerReducedTask.cxx

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,10 @@
1616
/// \author Anton Riedel, TU München, anton.riedel@tum.de
1717
/// \author Zuzanna Chochulska, WUT Warsaw & CTU Prague, zchochul@cern.ch
1818

19-
#include "TMath.h"
2019
#include <CCDB/BasicCCDBManager.h>
20+
#include <vector>
21+
22+
#include "TMath.h"
2123
#include "PWGCF/FemtoUniverse/Core/FemtoUniverseCollisionSelection.h"
2224
#include "PWGCF/FemtoUniverse/Core/FemtoUniverseTrackSelection.h"
2325
#include "PWGCF/FemtoUniverse/DataModel/FemtoDerived.h"
@@ -100,6 +102,7 @@ struct femtoUniverseProducerReducedTask {
100102
Configurable<std::vector<float>> ConfTrkTPCfCls{FemtoUniverseTrackSelection::getSelectionName(femto_universe_track_selection::kTPCfClsMin, "ConfTrk"), std::vector<float>{0.7f, 0.83f, 0.9f}, FemtoUniverseTrackSelection::getSelectionHelper(femto_universe_track_selection::kTPCfClsMin, "Track selection: ")};
101103
Configurable<std::vector<float>> ConfTrkTPCcRowsMin{FemtoUniverseTrackSelection::getSelectionName(femto_universe_track_selection::kTPCcRowsMin, "ConfTrk"), std::vector<float>{70.f, 60.f, 80.f}, FemtoUniverseTrackSelection::getSelectionHelper(femto_universe_track_selection::kTPCcRowsMin, "Track selection: ")};
102104
Configurable<std::vector<float>> ConfTrkTPCsCls{FemtoUniverseTrackSelection::getSelectionName(femto_universe_track_selection::kTPCsClsMax, "ConfTrk"), std::vector<float>{0.1f, 160.f}, FemtoUniverseTrackSelection::getSelectionHelper(femto_universe_track_selection::kTPCsClsMax, "Track selection: ")};
105+
Configurable<std::vector<float>> ConfTrkTPCfracsCls{FemtoUniverseTrackSelection::getSelectionName(femto_universe_track_selection::kTPCfracsClsMax, "ConfTrk"), std::vector<float>{0.1f, 160.f}, FemtoUniverseTrackSelection::getSelectionHelper(femto_universe_track_selection::kTPCfracsClsMax, "Track selection: ")};
103106
Configurable<std::vector<float>> ConfTrkITSnclsMin{FemtoUniverseTrackSelection::getSelectionName(femto_universe_track_selection::kITSnClsMin, "ConfTrk"), std::vector<float>{-1.f, 2.f, 4.f}, FemtoUniverseTrackSelection::getSelectionHelper(femto_universe_track_selection::kITSnClsMin, "Track selection: ")};
104107
Configurable<std::vector<float>> ConfTrkITSnclsIbMin{FemtoUniverseTrackSelection::getSelectionName(femto_universe_track_selection::kITSnClsIbMin, "ConfTrk"), std::vector<float>{-1.f, 1.f}, FemtoUniverseTrackSelection::getSelectionHelper(femto_universe_track_selection::kITSnClsIbMin, "Track selection: ")};
105108
Configurable<std::vector<float>> ConfTrkDCAxyMax{FemtoUniverseTrackSelection::getSelectionName(femto_universe_track_selection::kDCAxyMax, "ConfTrk"), std::vector<float>{0.1f, 0.5f}, FemtoUniverseTrackSelection::getSelectionHelper(femto_universe_track_selection::kDCAxyMax, "Track selection: ")}; /// here we need an open cut to do the DCA fits later on!
@@ -129,6 +132,7 @@ struct femtoUniverseProducerReducedTask {
129132
trackCuts.setSelection(ConfTrkTPCfCls, femto_universe_track_selection::kTPCfClsMin, femto_universe_selection::kLowerLimit);
130133
trackCuts.setSelection(ConfTrkTPCcRowsMin, femto_universe_track_selection::kTPCcRowsMin, femto_universe_selection::kLowerLimit);
131134
trackCuts.setSelection(ConfTrkTPCsCls, femto_universe_track_selection::kTPCsClsMax, femto_universe_selection::kUpperLimit);
135+
trackCuts.setSelection(ConfTrkTPCfracsCls, femto_universe_track_selection::kTPCfracsClsMax, femto_universe_selection::kUpperLimit);
132136
trackCuts.setSelection(ConfTrkITSnclsMin, femto_universe_track_selection::kITSnClsMin, femto_universe_selection::kLowerLimit);
133137
trackCuts.setSelection(ConfTrkITSnclsIbMin, femto_universe_track_selection::kITSnClsIbMin, femto_universe_selection::kLowerLimit);
134138
trackCuts.setSelection(ConfTrkDCAxyMax, femto_universe_track_selection::kDCAxyMax, femto_universe_selection::kAbsUpperLimit);
@@ -289,6 +293,7 @@ struct femtoUniverseProducerReducedTask {
289293
track.tpcNClsFindable(),
290294
(uint8_t)track.tpcNClsCrossedRows(),
291295
track.tpcNClsShared(),
296+
track.tpcFractionSharedCls(),
292297
track.tpcInnerParam(),
293298
track.itsNCls(),
294299
track.itsNClsInnerBarrel(),

0 commit comments

Comments
 (0)