Skip to content

Commit 4c87d0e

Browse files
[PWGLF] Add derivedXi0analysis task (#18081)
Co-authored-by: ALICE Action Bot <alibuild@cern.ch>
1 parent 7ec2f86 commit 4c87d0e

4 files changed

Lines changed: 1298 additions & 11 deletions

File tree

‎PWGLF/DataModel/LFSigmaTables.h‎

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1452,7 +1452,7 @@ DECLARE_SOA_DYNAMIC_COLUMN(Xi0Mass, xi0Mass,
14521452
std::array<float, 3> pVecPi0{photon1Px + photon2Px, photon1Py + photon2Py, photon1Pz + photon2Pz};
14531453
std::array<float, 3> pVecLambda{lambdaPx, lambdaPy, lambdaPz};
14541454
auto arrMom = std::array{pVecPi0, pVecLambda};
1455-
return RecoDecay::m(arrMom, std::array{o2::constants::physics::MassPi0, o2::constants::physics::MassXi0});
1455+
return RecoDecay::m(arrMom, std::array{o2::constants::physics::MassPi0, o2::constants::physics::MassLambda0});
14561456
});
14571457

14581458
DECLARE_SOA_DYNAMIC_COLUMN(PxPi0, pxPi0, //! Pi0 px
@@ -1607,11 +1607,12 @@ DECLARE_SOA_TABLE(Xi0Cores, "AOD", "XI0CORES",
16071607
Xi0Core::Pz<Xi0Core::Photon1Pz, Xi0Core::Photon2Pz, Xi0Core::LambdaPz>,
16081608
Xi0Core::Pt<Xi0Core::Photon1Px, Xi0Core::Photon1Py, Xi0Core::Photon2Px, Xi0Core::Photon2Py, Xi0Core::LambdaPx, Xi0Core::LambdaPy>,
16091609
Xi0Core::P<Xi0Core::Photon1Px, Xi0Core::Photon1Py, Xi0Core::Photon1Pz, Xi0Core::Photon2Px, Xi0Core::Photon2Py, Xi0Core::Photon2Pz, Xi0Core::LambdaPx, Xi0Core::LambdaPy, Xi0Core::LambdaPz>,
1610+
Xi0Core::Xi0Mass<Xi0Core::Photon1Px, Xi0Core::Photon1Py, Xi0Core::Photon1Pz, Xi0Core::Photon2Px, Xi0Core::Photon2Py, Xi0Core::Photon2Pz, Xi0Core::LambdaPx, Xi0Core::LambdaPy, Xi0Core::LambdaPz>,
16101611
Xi0Core::Rapidity<Xi0Core::Photon1Px, Xi0Core::Photon1Py, Xi0Core::Photon1Pz, Xi0Core::Photon2Px, Xi0Core::Photon2Py, Xi0Core::Photon2Pz, Xi0Core::LambdaPx, Xi0Core::LambdaPy, Xi0Core::LambdaPz>,
16111612
Xi0Core::Phi<Xi0Core::Photon1Px, Xi0Core::Photon1Py, Xi0Core::Photon2Px, Xi0Core::Photon2Py, Xi0Core::LambdaPx, Xi0Core::LambdaPy>,
16121613
Xi0Core::Eta<Xi0Core::Photon1Px, Xi0Core::Photon1Py, Xi0Core::Photon1Pz, Xi0Core::Photon2Px, Xi0Core::Photon2Py, Xi0Core::Photon2Pz, Xi0Core::LambdaPx, Xi0Core::LambdaPy, Xi0Core::LambdaPz>,
16131614
Xi0Core::Radius<Xi0Core::X, Xi0Core::Y>,
1614-
Xi0Core::CascCosPA<Xi0Core::X, Xi0Core::Y, Xi0Core::Z, Xi0Core::Photon1Px, Xi0Core::Photon1Py, Xi0Core::Photon1Pz, Xi0Core::Photon2Px, Xi0Core::Photon2Py, Xi0Core::Photon2Pz, Xi0Core::LambdaPx, Xi0Core::LambdaPy, Xi0Core::LambdaPz>,
1615+
Xi0Core::CascCosPA<Xi0Core::X, Xi0Core::Y, Xi0Core::Z, Xi0Core::Photon1Px, Xi0Core::Photon2Px, Xi0Core::LambdaPx, Xi0Core::Photon1Py, Xi0Core::Photon2Py, Xi0Core::LambdaPy, Xi0Core::Photon1Pz, Xi0Core::Photon2Pz, Xi0Core::LambdaPz>,
16151616

16161617
// Dynamic columns for pi0
16171618
Xi0Core::PxPi0<Xi0Core::Photon1Px, Xi0Core::Photon2Px>,
@@ -1620,7 +1621,7 @@ DECLARE_SOA_TABLE(Xi0Cores, "AOD", "XI0CORES",
16201621
Xi0Core::Pi0Mass<Xi0Core::Photon1Px, Xi0Core::Photon1Py, Xi0Core::Photon1Pz, Xi0Core::Photon2Px, Xi0Core::Photon2Py, Xi0Core::Photon2Pz>,
16211622
Xi0Core::RadiusPi0<Xi0Core::XPi0, Xi0Core::YPi0>,
16221623
Xi0Core::Pi0CosPA<Xi0Core::XPi0, Xi0Core::YPi0, Xi0Core::ZPi0, Xi0Core::Photon1Px, Xi0Core::Photon1Py, Xi0Core::Photon1Pz, Xi0Core::Photon2Px, Xi0Core::Photon2Py, Xi0Core::Photon2Pz>,
1623-
Xi0Core::DCAPi0ToPV<Xi0Core::XLambda, Xi0Core::YLambda, Xi0Core::ZLambda, Xi0Core::Photon1Px, Xi0Core::Photon1Py, Xi0Core::Photon1Pz, Xi0Core::Photon2Px, Xi0Core::Photon2Py, Xi0Core::Photon2Pz>,
1624+
Xi0Core::DCAPi0ToPV<Xi0Core::XPi0, Xi0Core::YPi0, Xi0Core::ZPi0, Xi0Core::Photon1Px, Xi0Core::Photon1Py, Xi0Core::Photon1Pz, Xi0Core::Photon2Px, Xi0Core::Photon2Py, Xi0Core::Photon2Pz>,
16241625

16251626
// Dynamic columns for Lambda
16261627
Xi0Core::RadiusLambda<Xi0Core::XLambda, Xi0Core::YLambda>,
@@ -1884,11 +1885,11 @@ DECLARE_SOA_TABLE(Xi0MCCores, "AOD", "XI0MCCORES",
18841885
Xi0MCCore::MCRadius<Xi0MCCore::MCx, Xi0MCCore::MCy>,
18851886
Xi0MCCore::MCRadiusPi0<Xi0MCCore::Pi0MCx, Xi0MCCore::Pi0MCy>,
18861887

1887-
Xi0MCCore::MCPx<Xi0MCCore::Photon1MCPx, Xi0MCCore::Photon2MCPx>,
1888-
Xi0MCCore::MCPy<Xi0MCCore::Photon1MCPy, Xi0MCCore::Photon2MCPy>,
1889-
Xi0MCCore::MCPz<Xi0MCCore::Photon1MCPz, Xi0MCCore::Photon2MCPz>,
1890-
Xi0MCCore::MCPt<Xi0MCCore::Photon1MCPx, Xi0MCCore::Photon1MCPy, Xi0MCCore::Photon2MCPx, Xi0MCCore::Photon2MCPy>,
1891-
Xi0MCCore::MCP<Xi0MCCore::Photon1MCPx, Xi0MCCore::Photon1MCPy, Xi0MCCore::Photon1MCPz, Xi0MCCore::Photon2MCPx, Xi0MCCore::Photon2MCPy, Xi0MCCore::Photon2MCPz>,
1888+
Xi0MCCore::Pi0MCPx<Xi0MCCore::Photon1MCPx, Xi0MCCore::Photon2MCPx>,
1889+
Xi0MCCore::Pi0MCPy<Xi0MCCore::Photon1MCPy, Xi0MCCore::Photon2MCPy>,
1890+
Xi0MCCore::Pi0MCPz<Xi0MCCore::Photon1MCPz, Xi0MCCore::Photon2MCPz>,
1891+
Xi0MCCore::Pi0MCPt<Xi0MCCore::Photon1MCPx, Xi0MCCore::Photon1MCPy, Xi0MCCore::Photon2MCPx, Xi0MCCore::Photon2MCPy>,
1892+
Xi0MCCore::Pi0MCP<Xi0MCCore::Photon1MCPx, Xi0MCCore::Photon1MCPy, Xi0MCCore::Photon1MCPz, Xi0MCCore::Photon2MCPx, Xi0MCCore::Photon2MCPy, Xi0MCCore::Photon2MCPz>,
18921893
Xi0MCCore::Pi0MCMass<Xi0MCCore::Photon1MCPx, Xi0MCCore::Photon1MCPy, Xi0MCCore::Photon1MCPz, Xi0MCCore::Photon2MCPx, Xi0MCCore::Photon2MCPy, Xi0MCCore::Photon2MCPz>,
18931894
Xi0MCCore::Pi0RapidityMC<Xi0MCCore::Photon1MCPx, Xi0MCCore::Photon1MCPy, Xi0MCCore::Photon1MCPz, Xi0MCCore::Photon2MCPx, Xi0MCCore::Photon2MCPy, Xi0MCCore::Photon2MCPz>,
18941895
Xi0MCCore::Pi0MCPhi<Xi0MCCore::Photon1MCPx, Xi0MCCore::Photon1MCPy, Xi0MCCore::Photon2MCPx, Xi0MCCore::Photon2MCPy>,

‎PWGLF/TableProducer/Strangeness/sigma0builder.cxx‎

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@
4343
#include <Framework/InitContext.h>
4444
#include <Framework/OutputObjHeader.h>
4545
#include <Framework/runDataProcessing.h>
46+
#include <ReconstructionDataFormats/Track.h>
4647
#include <ReconstructionDataFormats/TrackParametrizationWithError.h>
4748

4849
#include <Math/Vector3D.h> // IWYU pragma: keep (do not replace with Math/Vector3Dfwd.h)
@@ -1511,7 +1512,7 @@ struct sigma0builder {
15111512
if (MCMother_pi0.globalIndex() == MCMother_lambda.globalIndex()) { // check that lambda and pi0 have the same mother.
15121513
MCinfo.xi0PDGCode = MCMother_pi0.pdgCode();
15131514
MCinfo.xi0MCProcess = MCMother_pi0.getProcess();
1514-
MCinfo.pi0IsPhysicalPrimary = MCMother_pi0.isPhysicalPrimary();
1515+
MCinfo.xi0IsPhysicalPrimary = MCMother_pi0.isPhysicalPrimary();
15151516
MCinfo.xi0X = MCMother_pi0.vx();
15161517
MCinfo.xi0Y = MCMother_pi0.vy();
15171518
MCinfo.xi0Z = MCMother_pi0.vz();
@@ -2703,7 +2704,7 @@ struct sigma0builder {
27032704
//_______________________________________________
27042705
// Build Xi0 candidate for analysis
27052706
template <typename TV0Object, typename TCollision, typename TMCParticles>
2706-
bool buildXi0(TV0Object const& gamma1, TV0Object const& gamma2, TV0Object const& lambda, TCollision const& collision, TMCParticles const& mcparticles)
2707+
bool buildXi0(TV0Object const& gamma1, TV0Object const& gamma2, TV0Object const& lambda, V0PairTopoInfo& pi0Info, TCollision const& collision, TMCParticles const& mcparticles)
27072708
{
27082709
Xi0Info cascade;
27092710
//_______________________________________________
@@ -2764,6 +2765,8 @@ struct sigma0builder {
27642765
return false;
27652766
}
27662767

2768+
cascade.pi0DaughterDCA = pi0Info.daughterDCA;
2769+
27672770
lGamma1Track.getPxPyPzGlo(cascade.gamma1Momentum);
27682771
lGamma2Track.getPxPyPzGlo(cascade.gamma2Momentum);
27692772
lLambdaTrack.getPxPyPzGlo(cascade.lambdaMomentum);
@@ -2776,6 +2779,10 @@ struct sigma0builder {
27762779
return false;
27772780
}
27782781

2782+
cascade.pi0Position[0] = pi0Info.position[0];
2783+
cascade.pi0Position[1] = pi0Info.position[1];
2784+
cascade.pi0Position[2] = pi0Info.position[2];
2785+
27792786
double cosPA = RecoDecay::cpa(
27802787
std::array{collision.posX(), collision.posY(), collision.posZ()},
27812788
std::array{cascade.cascadePosition[0], cascade.cascadePosition[1], cascade.cascadePosition[2]},
@@ -3418,7 +3425,7 @@ struct sigma0builder {
34183425
auto gamma1 = fullV0s.rawIteratorAt(pi0Candidates[j].v01Index);
34193426
auto gamma2 = fullV0s.rawIteratorAt(pi0Candidates[j].v02Index);
34203427
// Building pi0 candidate & filling tables
3421-
if (!buildXi0(gamma1, gamma2, lambda, coll, mcparticles))
3428+
if (!buildXi0(gamma1, gamma2, lambda, pi0Candidates[j], coll, mcparticles))
34223429
continue;
34233430
}
34243431
}

‎PWGLF/Tasks/Strangeness/CMakeLists.txt‎

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,11 @@ o2physics_add_dpl_workflow(derivedcascadeanalysis
6969
PUBLIC_LINK_LIBRARIES O2Physics::AnalysisCore O2Physics::MLCore O2Physics::AnalysisCCDB
7070
COMPONENT_NAME Analysis)
7171

72+
o2physics_add_dpl_workflow(derivedxi0analysis
73+
SOURCES derivedXi0analysis.cxx
74+
PUBLIC_LINK_LIBRARIES O2Physics::AnalysisCore O2Physics::AnalysisCCDB
75+
COMPONENT_NAME Analysis)
76+
7277
o2physics_add_dpl_workflow(cascpostprocessing
7378
SOURCES cascpostprocessing.cxx
7479
PUBLIC_LINK_LIBRARIES O2Physics::AnalysisCore

0 commit comments

Comments
 (0)