Skip to content

Commit 4c450ba

Browse files
georgiosgmantzar
authored andcommitted
Merge the ProducerWithCascades with the Producer
- also adding the CascadeCascade pair task - including before and after selection plots for all species
1 parent 8030bff commit 4c450ba

File tree

9 files changed

+1805
-106
lines changed

9 files changed

+1805
-106
lines changed

PWGCF/FemtoDream/Core/femtoDreamCascadeSelection.h

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@
3737
#include "ReconstructionDataFormats/PID.h"
3838

3939
using namespace o2::framework;
40+
using namespace o2::analysis::femtoDream::femtoDreamSelection;
4041

4142
namespace o2::analysis::femtoDream
4243
{
@@ -346,8 +347,8 @@ class FemtoDreamCascadeSelection
346347
}; ///< Helper information for the
347348
///< different selections
348349

349-
static constexpr int kNcutStages = 2;
350-
static constexpr std::string_view mCutStage[kNcutStages] = {"BeforeSel", "AfterSel"};
350+
//static constexpr int kNcutStages = 2;
351+
//static constexpr std::string_view mCutStage[kNcutStages] = {"BeforeSel", "AfterSel"};
351352
}; // namespace femtoDream
352353

353354
template <o2::aod::femtodreamparticle::ParticleType part, o2::aod::femtodreamparticle::ParticleType daugh, o2::aod::femtodreamparticle::ParticleType bach, typename cutContainerType>

PWGCF/FemtoDream/Core/femtoDreamSelection.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,9 @@ enum SelectionType { kUpperLimit, ///< simple upper limit for the value, e.g.
3535
kAbsLowerLimit, ///< lower limit of the absolute value, e.g. |DCA_xyz| > 0.05 cm
3636
kEqual ///< values need to be equal, e.g. sign = 1
3737
};
38+
39+
static constexpr int kNcutStages = 2;
40+
static constexpr std::string_view mCutStage[kNcutStages] = {"BeforeSel", "AfterSel"};
3841

3942
} // namespace femtoDreamSelection
4043

PWGCF/FemtoDream/Core/femtoDreamTrackSelection.h

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@
3333
#include "Framework/HistogramRegistry.h"
3434

3535
using namespace o2::framework;
36+
using namespace o2::analysis::femtoDream::femtoDreamSelection;
3637

3738
namespace o2::analysis::femtoDream
3839
{
@@ -301,8 +302,6 @@ class FemtoDreamTrackSelection : public FemtoDreamObjectSelection<float, femtoDr
301302
"Maximal DCA_z (cm)",
302303
"Minimal DCA (cm)",
303304
"Maximal PID (nSigma)"}; ///< Helper information for the different selections
304-
static constexpr int kNcutStages = 2;
305-
static constexpr std::string_view mCutStage[kNcutStages] = {"BeforeSel", "AfterSel"};
306305
}; // namespace femtoDream
307306

308307
template <o2::aod::femtodreamparticle::ParticleType part, o2::aod::femtodreamparticle::TrackType tracktype, typename cutContainerType>

PWGCF/FemtoDream/Core/femtoDreamV0Selection.h

Lines changed: 60 additions & 54 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@
3131
#include "ReconstructionDataFormats/PID.h"
3232

3333
using namespace o2::framework;
34+
using namespace o2::analysis::femtoDream::femtoDreamSelection;
3435

3536
namespace o2::analysis::femtoDream
3637
{
@@ -91,7 +92,8 @@ class FemtoDreamV0Selection
9192
T const& posTrack,
9293
T const& negTrack);
9394

94-
template <o2::aod::femtodreamparticle::ParticleType part,
95+
template <int cutstage,
96+
o2::aod::femtodreamparticle::ParticleType part,
9597
o2::aod::femtodreamparticle::ParticleType daugh, typename C,
9698
typename V, typename T>
9799
void fillQA(C const& col, V const& v0, T const& posTrack, T const& negTrack);
@@ -296,43 +298,46 @@ void FemtoDreamV0Selection::init(HistogramRegistry* QAregistry, HistogramRegistr
296298
LOG(fatal) << "FemtoDreamV0Cuts: Number of selections to large for your "
297299
"container - quitting!";
298300
}
299-
std::string folderName = static_cast<std::string>(
300-
o2::aod::femtodreamparticle::ParticleTypeName[part]);
301-
/// \todo initialize histograms for children tracks of v0s
302-
mQAHistogramRegistry->add((folderName + "/hPt").c_str(),
303-
"; #it{p}_{T} (GeV/#it{c}); Entries", kTH1F,
304-
{{1000, 0, 10}});
305-
mQAHistogramRegistry->add((folderName + "/hEta").c_str(), "; #eta; Entries",
306-
kTH1F, {{1000, -1, 1}});
307-
mQAHistogramRegistry->add((folderName + "/hPhi").c_str(), "; #phi; Entries",
308-
kTH1F, {{1000, 0, 2. * M_PI}});
309-
mQAHistogramRegistry->add((folderName + "/hDaughDCA").c_str(),
310-
"; DCA^{daugh} (cm); Entries", kTH1F,
311-
{{1000, 0, 10}});
312-
mQAHistogramRegistry->add((folderName + "/hTransRadius").c_str(),
313-
"; #it{r}_{xy} (cm); Entries", kTH1F,
314-
{{1500, 0, 150}});
315-
mQAHistogramRegistry->add((folderName + "/hDecayVtxX").c_str(),
316-
"; #it{Vtx}_{x} (cm); Entries", kTH1F,
317-
{{2000, 0, 200}});
318-
mQAHistogramRegistry->add((folderName + "/hDecayVtxY").c_str(),
319-
"; #it{Vtx}_{y} (cm)); Entries", kTH1F,
320-
{{2000, 0, 200}});
321-
mQAHistogramRegistry->add((folderName + "/hDecayVtxZ").c_str(),
322-
"; #it{Vtx}_{z} (cm); Entries", kTH1F,
323-
{{2000, 0, 200}});
324-
mQAHistogramRegistry->add((folderName + "/hCPA").c_str(),
325-
"; #it{cos #theta_{p}}; Entries", kTH1F,
326-
{{1000, 0.9, 1.}});
327-
mQAHistogramRegistry->add((folderName + "/hCPAvsPt").c_str(),
328-
"; #it{p}_{T} (GeV/#it{c}); #it{cos #theta_{p}}",
329-
kTH2F, {{8, 0.3, 4.3}, {1000, 0.9, 1.}});
330-
mQAHistogramRegistry->add((folderName + "/hInvMassLambda").c_str(), "", kTH1F,
331-
{massAxisLambda});
332-
mQAHistogramRegistry->add((folderName + "/hInvMassAntiLambda").c_str(), "",
333-
kTH1F, {massAxisAntiLambda});
334-
mQAHistogramRegistry->add((folderName + "/hInvMassLambdaAntiLambda").c_str(),
335-
"", kTH2F, {massAxisLambda, massAxisAntiLambda});
301+
for (int istage = 0; istage < kNcutStages; istage++){
302+
std::string folderName =
303+
static_cast<std::string>(o2::aod::femtodreamparticle::ParticleTypeName[part]) + "/" +
304+
static_cast<std::string>(mCutStage[istage]);
305+
/// \todo initialize histograms for children tracks of v0s
306+
mQAHistogramRegistry->add((folderName + "/hPt").c_str(),
307+
"; #it{p}_{T} (GeV/#it{c}); Entries", kTH1F,
308+
{{1000, 0, 10}});
309+
mQAHistogramRegistry->add((folderName + "/hEta").c_str(), "; #eta; Entries",
310+
kTH1F, {{1000, -1, 1}});
311+
mQAHistogramRegistry->add((folderName + "/hPhi").c_str(), "; #phi; Entries",
312+
kTH1F, {{1000, 0, 2. * M_PI}});
313+
mQAHistogramRegistry->add((folderName + "/hDaughDCA").c_str(),
314+
"; DCA^{daugh} (cm); Entries", kTH1F,
315+
{{1000, 0, 10}});
316+
mQAHistogramRegistry->add((folderName + "/hTransRadius").c_str(),
317+
"; #it{r}_{xy} (cm); Entries", kTH1F,
318+
{{1500, 0, 150}});
319+
mQAHistogramRegistry->add((folderName + "/hDecayVtxX").c_str(),
320+
"; #it{Vtx}_{x} (cm); Entries", kTH1F,
321+
{{2000, 0, 200}});
322+
mQAHistogramRegistry->add((folderName + "/hDecayVtxY").c_str(),
323+
"; #it{Vtx}_{y} (cm)); Entries", kTH1F,
324+
{{2000, 0, 200}});
325+
mQAHistogramRegistry->add((folderName + "/hDecayVtxZ").c_str(),
326+
"; #it{Vtx}_{z} (cm); Entries", kTH1F,
327+
{{2000, 0, 200}});
328+
mQAHistogramRegistry->add((folderName + "/hCPA").c_str(),
329+
"; #it{cos #theta_{p}}; Entries", kTH1F,
330+
{{1000, 0.9, 1.}});
331+
mQAHistogramRegistry->add((folderName + "/hCPAvsPt").c_str(),
332+
"; #it{p}_{T} (GeV/#it{c}); #it{cos #theta_{p}}",
333+
kTH2F, {{8, 0.3, 4.3}, {1000, 0.9, 1.}});
334+
mQAHistogramRegistry->add((folderName + "/hInvMassLambda").c_str(), "", kTH1F,
335+
{massAxisLambda});
336+
mQAHistogramRegistry->add((folderName + "/hInvMassAntiLambda").c_str(), "",
337+
kTH1F, {massAxisAntiLambda});
338+
mQAHistogramRegistry->add((folderName + "/hInvMassLambdaAntiLambda").c_str(),
339+
"", kTH2F, {massAxisLambda, massAxisAntiLambda});
340+
}
336341

337342
PosDaughTrack.init<aod::femtodreamparticle::ParticleType::kV0Child,
338343
aod::femtodreamparticle::TrackType::kPosChild,
@@ -636,7 +641,8 @@ std::array<cutContainerType, 5>
636641
outputNegTrack.at(femtoDreamTrackSelection::TrackContainerPosition::kPID)};
637642
}
638643

639-
template <o2::aod::femtodreamparticle::ParticleType part,
644+
template <int cutstage,
645+
o2::aod::femtodreamparticle::ParticleType part,
640646
o2::aod::femtodreamparticle::ParticleType daugh, typename C,
641647
typename V, typename T>
642648
void FemtoDreamV0Selection::fillQA(C const& /*col*/, V const& v0, T const& posTrack,
@@ -645,62 +651,62 @@ void FemtoDreamV0Selection::fillQA(C const& /*col*/, V const& v0, T const& posTr
645651
if (mQAHistogramRegistry) {
646652
mQAHistogramRegistry->fill(
647653
HIST(o2::aod::femtodreamparticle::ParticleTypeName[part]) +
648-
HIST("/hPt"),
654+
HIST("/") + HIST(mCutStage[cutstage]) + HIST("/hPt"),
649655
v0.pt());
650656
mQAHistogramRegistry->fill(
651657
HIST(o2::aod::femtodreamparticle::ParticleTypeName[part]) +
652-
HIST("/hEta"),
658+
HIST("/") + HIST(mCutStage[cutstage]) + HIST("/hEta"),
653659
v0.eta());
654660
mQAHistogramRegistry->fill(
655661
HIST(o2::aod::femtodreamparticle::ParticleTypeName[part]) +
656-
HIST("/hPhi"),
662+
HIST("/") + HIST(mCutStage[cutstage]) + HIST("/hPhi"),
657663
v0.phi());
658664
mQAHistogramRegistry->fill(
659665
HIST(o2::aod::femtodreamparticle::ParticleTypeName[part]) +
660-
HIST("/hDaughDCA"),
666+
HIST("/") + HIST(mCutStage[cutstage]) + HIST("/hDaughDCA"),
661667
v0.dcaV0daughters());
662668
mQAHistogramRegistry->fill(
663669
HIST(o2::aod::femtodreamparticle::ParticleTypeName[part]) +
664-
HIST("/hTransRadius"),
670+
HIST("/") + HIST(mCutStage[cutstage]) + HIST("/hTransRadius"),
665671
v0.v0radius());
666672
mQAHistogramRegistry->fill(
667673
HIST(o2::aod::femtodreamparticle::ParticleTypeName[part]) +
668-
HIST("/hDecayVtxX"),
674+
HIST("/") + HIST(mCutStage[cutstage]) + HIST("/hDecayVtxX"),
669675
v0.x());
670676
mQAHistogramRegistry->fill(
671677
HIST(o2::aod::femtodreamparticle::ParticleTypeName[part]) +
672-
HIST("/hDecayVtxY"),
678+
HIST("/") + HIST(mCutStage[cutstage]) + HIST("/hDecayVtxY"),
673679
v0.y());
674680
mQAHistogramRegistry->fill(
675681
HIST(o2::aod::femtodreamparticle::ParticleTypeName[part]) +
676-
HIST("/hDecayVtxZ"),
682+
HIST("/") + HIST(mCutStage[cutstage]) + HIST("/hDecayVtxZ"),
677683
v0.z());
678684
mQAHistogramRegistry->fill(
679685
HIST(o2::aod::femtodreamparticle::ParticleTypeName[part]) +
680-
HIST("/hCPA"),
686+
HIST("/") + HIST(mCutStage[cutstage]) + HIST("/hCPA"),
681687
v0.v0cosPA());
682688
mQAHistogramRegistry->fill(
683689
HIST(o2::aod::femtodreamparticle::ParticleTypeName[part]) +
684-
HIST("/hCPAvsPt"),
690+
HIST("/") + HIST(mCutStage[cutstage]) + HIST("/hCPAvsPt"),
685691
v0.pt(), v0.v0cosPA());
686692
mQAHistogramRegistry->fill(
687693
HIST(o2::aod::femtodreamparticle::ParticleTypeName[part]) +
688-
HIST("/hInvMassLambda"),
694+
HIST("/") + HIST(mCutStage[cutstage]) + HIST("/hInvMassLambda"),
689695
v0.mLambda());
690696
mQAHistogramRegistry->fill(
691697
HIST(o2::aod::femtodreamparticle::ParticleTypeName[part]) +
692-
HIST("/hInvMassAntiLambda"),
698+
HIST("/") + HIST(mCutStage[cutstage]) + HIST("/hInvMassAntiLambda"),
693699
v0.mAntiLambda());
694700
mQAHistogramRegistry->fill(
695701
HIST(o2::aod::femtodreamparticle::ParticleTypeName[part]) +
696-
HIST("/hInvMassLambdaAntiLambda"),
702+
HIST("/") + HIST(mCutStage[cutstage]) + HIST("/hInvMassLambdaAntiLambda"),
697703
v0.mLambda(), v0.mAntiLambda());
698704
}
699705

700706
PosDaughTrack.fillQA<aod::femtodreamparticle::ParticleType::kV0Child,
701-
aod::femtodreamparticle::TrackType::kPosChild>(posTrack);
707+
aod::femtodreamparticle::TrackType::kPosChild, cutstage>(posTrack);
702708
NegDaughTrack.fillQA<aod::femtodreamparticle::ParticleType::kV0Child,
703-
aod::femtodreamparticle::TrackType::kNegChild>(negTrack);
709+
aod::femtodreamparticle::TrackType::kNegChild, cutstage>(negTrack);
704710
}
705711

706712
} // namespace o2::analysis::femtoDream

PWGCF/FemtoDream/TableProducer/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,4 +22,4 @@ o2physics_add_dpl_workflow(femtodream-producer-reduced
2222
o2physics_add_dpl_workflow(femtodream-producer-for-specific-analysis
2323
SOURCES femtoDreamProducerTaskForSpecificAnalysis.cxx
2424
PUBLIC_LINK_LIBRARIES O2::Framework O2Physics::AnalysisCore
25-
COMPONENT_NAME Analysis)
25+
COMPONENT_NAME Analysis)

0 commit comments

Comments
 (0)