1717// / \author Carolina Reetz <c.reetz@cern.ch>, Heidelberg University
1818// / \author Jaeyoon Cho <jaeyoon.cho@cern.ch>, Inha University
1919
20- #include < vector>
20+ #include " PWGHF/Core/SelectorCuts.h"
21+ #include " PWGHF/DataModel/CandidateReconstructionTables.h"
22+ #include " PWGHF/DataModel/CandidateSelectionTables.h"
2123
2224#include " CommonConstants/PhysicsConstants.h"
2325#include " Framework/AnalysisTask.h"
2426#include " Framework/HistogramRegistry.h"
2527#include " Framework/O2DatabasePDGPlugin.h"
2628#include " Framework/runDataProcessing.h"
2729
28- #include " PWGHF/Core/SelectorCuts.h"
29- #include " PWGHF/DataModel/CandidateReconstructionTables.h"
30- #include " PWGHF/DataModel/CandidateSelectionTables.h"
30+ #include < vector>
3131
3232using namespace o2 ;
3333using namespace o2 ::aod;
@@ -48,6 +48,8 @@ struct HfTaskXicToXiPiPi {
4848 // THnSparese for ML selection check
4949 Configurable<bool > enableTHn{" enableTHn" , false , " Fill THnSparse for Xic" };
5050
51+ const int nVarsMultiClass = 3 ;
52+
5153 Service<o2::framework::O2DatabasePDG> pdg;
5254
5355 Filter filterSelectCandidates = (aod::hf_sel_candidate_xic::isSelXicToXiPiPi >= selectionFlagXic);
@@ -130,10 +132,9 @@ struct HfTaskXicToXiPiPi {
130132 registry.add (" hMassXiPi2" , " #Xi^{#plus}_{c} candidates;inv. mass #Xi^{#mp} #pi^{#pm} (prong 2) (GeV/#it{c}^{2});#it{p}_{T} (GeV/#it{c})" , {HistType::kTH2F , {axisMassXiRes, axisPt}});
131133 // KFParticle
132134 if (doprocessWithKFParticle || doprocessWithKFParticleAndML) {
133- registry.add (" hChi2geoXi" , " #Xi^{#plus}_{c} candidates;#Xi^{#mp} #chi^{2}_{geo};entries" , {HistType::kTH2F , {axisChi2, axisPt}});
134- registry.add (" hChi2geoLam" , " #Xi^{#plus}_{c} candidates;#Lambda #chi^{2}_{geo};entries" , {HistType::kTH2F , {axisChi2, axisPt}});
135- registry.add (" hChi2topoToPV" , " #Xi^{#plus}_{c} candidates;#Xi^{#plus}_{c} candidate #chi^{2}_{topo} to PV;entries" , {HistType::kTH2F , {axisChi2, axisPt}});
136- registry.add (" hChi2topoXiToXicPlus" , " #Xi^{#plus}_{c} candidates;#Xi^{#mp} candidate #chi^{2}_{topo} to #Xi^{#plus}_{c};entries" , {HistType::kTH2F , {axisChi2, axisPt}});
135+ registry.add (" hChi2GeoXi" , " #Xi^{#plus}_{c} candidates;#chi^{2}_{geo} (#Xi^{#mp});entries" , {HistType::kTH2F , {axisChi2, axisPt}});
136+ registry.add (" hChi2GeoLam" , " #Xi^{#plus}_{c} candidates;#chi^{2}_{geo} (#Lambda);entries" , {HistType::kTH2F , {axisChi2, axisPt}});
137+ registry.add (" hChi2TopoXicPlusToPV" , " #Xi^{#plus}_{c} candidates;#chi^{2}_{topo} (#Xi^{#plus}_{c} #rightarrow PV);entries" , {HistType::kTH2F , {axisChi2, axisPt}});
137138 }
138139 }
139140
@@ -202,14 +203,12 @@ struct HfTaskXicToXiPiPi {
202203 registry.add (" hMassXiPi2RecBg" , " #Xi^{#plus}_{c} candidates (unmatched);inv. mass #Xi^{#mp} #pi^{#pm} (prong 2) (GeV/#it{c}^{2});entries" , {HistType::kTH2F , {{300 , 1.0 , 2.0 }, axisPt}});
203204 // MC reconstructed with KFParticle
204205 if (doprocessMcWithKFParticle || doprocessMcWithKFParticleAndML) {
205- registry.add (" hChi2topoToPVRecSig" , " #Xi^{#plus}_{c} candidates (matched);#Xi^{#plus}_{c} candidate #chi^{2}_{topo} to PV;entries" , {HistType::kTH2F , {axisChi2, axisPt}});
206- registry.add (" hChi2topoToPVRecBg" , " #Xi^{#plus}_{c} candidates (unmatched);#Xi^{#plus}_{c} candidate #chi^{2}_{topo} to PV;entries" , {HistType::kTH2F , {axisChi2, axisPt}});
207- registry.add (" hChi2geoXiRecSig" , " #Xi^{#plus}_{c} candidates (matched);#Xi^{#mp} #chi^{2}_{geo};entries" , {HistType::kTH2F , {axisChi2, axisPt}});
208- registry.add (" hChi2geoXiRecBg" , " #Xi^{#plus}_{c} candidates (unmatched);#Xi^{#mp} #chi^{2}_{geo};entries" , {HistType::kTH2F , {axisChi2, axisPt}});
209- registry.add (" hChi2geoLamRecSig" , " #Xi^{#plus}_{c} candidates (matched);#Lambda #chi^{2}_{geo};entries" , {HistType::kTH2F , {axisChi2, axisPt}});
210- registry.add (" hChi2geoLamRecBg" , " #Xi^{#plus}_{c} candidates (unmatched);#Lambda #chi^{2}_{geo};entries" , {HistType::kTH2F , {axisChi2, axisPt}});
211- registry.add (" hChi2topoXiToXicPlusRecSig" , " #Xi^{#plus}_{c} candidates (matched);#Xi^{#mp} candidate #chi^{2}_{topo} to #Xi^{#plus}_{c};entries" , {HistType::kTH2F , {axisChi2, axisPt}});
212- registry.add (" hChi2topoXiToXicPlusRecBg" , " #Xi^{#plus}_{c} candidates (unmatched);#Xi^{#mp} candidate #chi^{2}_{topo} to #Xi^{#plus}_{c};entries" , {HistType::kTH2F , {axisChi2, axisPt}});
206+ registry.add (" hChi2GeoXiRecSig" , " #Xi^{#plus}_{c} candidates (matched);#chi^{2}_{geo} (#Xi^{#mp});entries" , {HistType::kTH2F , {axisChi2, axisPt}});
207+ registry.add (" hChi2GeoXiRecBg" , " #Xi^{#plus}_{c} candidates (unmatched);#chi^{2}_{geo} (#Xi^{#mp});entries" , {HistType::kTH2F , {axisChi2, axisPt}});
208+ registry.add (" hChi2GeoLamRecSig" , " #Xi^{#plus}_{c} candidates (matched);#chi^{2}_{geo} (#Lambda);entries" , {HistType::kTH2F , {axisChi2, axisPt}});
209+ registry.add (" hChi2GeoLamRecBg" , " #Xi^{#plus}_{c} candidates (unmatched);#chi^{2}_{geo} (#Lambda);entries" , {HistType::kTH2F , {axisChi2, axisPt}});
210+ registry.add (" hChi2TopoXicPlusToPVRecSig" , " #Xi^{#plus}_{c} candidates (matched);#chi^{2}_{topo} (#Xi^{#plus}_{c} #rightarrow PV);entries" , {HistType::kTH2F , {axisChi2, axisPt}});
211+ registry.add (" hChi2TopoXicPlusToPVRecBg" , " #Xi^{#plus}_{c} candidates (unmatched);#chi^{2}_{topo} (#Xi^{#plus}_{c} #rightarrow PV);entries" , {HistType::kTH2F , {axisChi2, axisPt}});
213212 }
214213 // MC generated
215214 registry.add (" hPtProng0Gen" , " MC particles (generated);prong 0 (#Xi^{#mp}) #it{p}_{T}^{gen} (GeV/#it{c});entries" , {HistType::kTH2F , {{300 , 0 ., 30 .}, axisPt}});
@@ -284,7 +283,7 @@ struct HfTaskXicToXiPiPi {
284283 if (scoreSize > 0 ) {
285284 outputBkg = candidate.mlProbXicToXiPiPi ()[0 ];
286285 outputPrompt = candidate.mlProbXicToXiPiPi ()[1 ];
287- if (scoreSize == 3 ) {
286+ if (scoreSize == nVarsMultiClass ) {
288287 outputFD = candidate.mlProbXicToXiPiPi ()[2 ];
289288 }
290289 }
@@ -343,19 +342,18 @@ struct HfTaskXicToXiPiPi {
343342 registry.fill (HIST (" hImpParErr" ), candidate.errorImpactParameter1 (), ptCandXic);
344343 registry.fill (HIST (" hImpParErr" ), candidate.errorImpactParameter2 (), ptCandXic);
345344 registry.fill (HIST (" hChi2PCA" ), candidate.chi2PCA (), ptCandXic);
346- registry.fill (HIST (" hCPAXi" ), candidate.cosPaXi (), ptCandXic);
347- registry.fill (HIST (" hCPAxyXi" ), candidate.cosPaXYXi (), ptCandXic);
348- registry.fill (HIST (" hCPALambda" ), candidate.cosPaLambda (), ptCandXic);
349- registry.fill (HIST (" hCPAxyLambda" ), candidate.cosPaLambda (), ptCandXic);
345+ registry.fill (HIST (" hCPAXi" ), candidate.cpaXi (), ptCandXic);
346+ registry.fill (HIST (" hCPAxyXi" ), candidate.cpaXYXi (), ptCandXic);
347+ registry.fill (HIST (" hCPALambda" ), candidate.cpaLambda (), ptCandXic);
348+ registry.fill (HIST (" hCPAxyLambda" ), candidate.cpaLambda (), ptCandXic);
350349 registry.fill (HIST (" hMassXiPi1" ), candidate.invMassXiPi0 (), ptCandXic);
351350 registry.fill (HIST (" hMassXiPi2" ), candidate.invMassXiPi1 (), ptCandXic);
352351
353352 // fill KFParticle specific histograms
354353 if constexpr (useKfParticle) {
355- registry.fill (HIST (" hChi2topoToPV" ), candidate.chi2TopoXicPlusToPV (), ptCandXic);
356- registry.fill (HIST (" hChi2topoXiToXicPlus" ), candidate.chi2TopoXiToXicPlus (), ptCandXic);
357- registry.fill (HIST (" hChi2geoXi" ), candidate.kfCascadeChi2 (), ptCandXic);
358- registry.fill (HIST (" hChi2geoLam" ), candidate.kfV0Chi2 (), ptCandXic);
354+ registry.fill (HIST (" hChi2GeoXi" ), candidate.kfCascadeChi2 (), ptCandXic);
355+ registry.fill (HIST (" hChi2GeoLam" ), candidate.kfV0Chi2 (), ptCandXic);
356+ registry.fill (HIST (" hChi2TopoXicPlusToPV" ), candidate.chi2TopoXicPlusToPV (), ptCandXic);
359357 }
360358
361359 // fill THnSparse
@@ -418,17 +416,16 @@ struct HfTaskXicToXiPiPi {
418416 registry.fill (HIST (" hImpParErrRecSig" ), candidate.errorImpactParameter1 (), ptCandXic);
419417 registry.fill (HIST (" hImpParErrRecSig" ), candidate.errorImpactParameter2 (), ptCandXic);
420418 registry.fill (HIST (" hChi2PCARecSig" ), candidate.chi2PCA (), ptCandXic);
421- registry.fill (HIST (" hCPAXiRecSig" ), candidate.cosPaXi (), ptCandXic);
422- registry.fill (HIST (" hCPAxyXiRecSig" ), candidate.cosPaXYXi (), ptCandXic);
423- registry.fill (HIST (" hCPALambdaRecSig" ), candidate.cosPaLambda (), ptCandXic);
424- registry.fill (HIST (" hCPAxyLambdaRecSig" ), candidate.cosPaLambda (), ptCandXic);
419+ registry.fill (HIST (" hCPAXiRecSig" ), candidate.cpaXi (), ptCandXic);
420+ registry.fill (HIST (" hCPAxyXiRecSig" ), candidate.cpaXYXi (), ptCandXic);
421+ registry.fill (HIST (" hCPALambdaRecSig" ), candidate.cpaLambda (), ptCandXic);
422+ registry.fill (HIST (" hCPAxyLambdaRecSig" ), candidate.cpaLambda (), ptCandXic);
425423
426424 // fill KFParticle specific histograms
427425 if constexpr (useKfParticle) {
428- registry.fill (HIST (" hChi2topoToPVRecSig" ), candidate.chi2TopoXicPlusToPV (), ptCandXic);
429- registry.fill (HIST (" hChi2topoXiToXicPlusRecSig" ), candidate.chi2TopoXiToXicPlus (), ptCandXic);
430426 registry.fill (HIST (" hChi2geoXiRecSig" ), candidate.kfCascadeChi2 (), ptCandXic);
431427 registry.fill (HIST (" hChi2geoLamRecSig" ), candidate.kfV0Chi2 (), ptCandXic);
428+ registry.fill (HIST (" hChi2TopoXicPlusToPVRecSig" ), candidate.chi2TopoXicPlusToPV (), ptCandXic);
432429 }
433430 } else {
434431 registry.fill (HIST (" hPtRecBg" ), ptCandXic);
@@ -457,17 +454,16 @@ struct HfTaskXicToXiPiPi {
457454 registry.fill (HIST (" hImpParErrRecBg" ), candidate.errorImpactParameter1 (), ptCandXic);
458455 registry.fill (HIST (" hImpParErrRecBg" ), candidate.errorImpactParameter2 (), ptCandXic);
459456 registry.fill (HIST (" hChi2PCARecBg" ), candidate.chi2PCA (), ptCandXic);
460- registry.fill (HIST (" hCPAXiRecBg" ), candidate.cosPaXi (), ptCandXic);
461- registry.fill (HIST (" hCPAxyXiRecBg" ), candidate.cosPaXYXi (), ptCandXic);
462- registry.fill (HIST (" hCPALambdaRecBg" ), candidate.cosPaLambda (), ptCandXic);
463- registry.fill (HIST (" hCPAxyLambdaRecBg" ), candidate.cosPaLambda (), ptCandXic);
457+ registry.fill (HIST (" hCPAXiRecBg" ), candidate.cpaXi (), ptCandXic);
458+ registry.fill (HIST (" hCPAxyXiRecBg" ), candidate.cpaXYXi (), ptCandXic);
459+ registry.fill (HIST (" hCPALambdaRecBg" ), candidate.cpaLambda (), ptCandXic);
460+ registry.fill (HIST (" hCPAxyLambdaRecBg" ), candidate.cpaLambda (), ptCandXic);
464461
465462 // fill KFParticle specific histograms
466463 if constexpr (useKfParticle) {
467- registry.fill (HIST (" hChi2topoToPVRecBg" ), candidate.chi2TopoXicPlusToPV (), ptCandXic);
468- registry.fill (HIST (" hChi2topoXiToXicPlusRecBg" ), candidate.chi2TopoXiToXicPlus (), ptCandXic);
469464 registry.fill (HIST (" hChi2geoXiRecBg" ), candidate.kfCascadeChi2 (), ptCandXic);
470465 registry.fill (HIST (" hChi2geoLamRecBg" ), candidate.kfV0Chi2 (), ptCandXic);
466+ registry.fill (HIST (" hChi2TopoXicPlusToPVRecBg" ), candidate.chi2TopoXicPlusToPV (), ptCandXic);
471467 }
472468 }
473469
0 commit comments