Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
36 changes: 14 additions & 22 deletions PWGLF/DataModel/LFSigmaTables.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
#ifndef PWGLF_DATAMODEL_LFSIGMATABLES_H_
#define PWGLF_DATAMODEL_LFSIGMATABLES_H_

using std::array;

Check failure on line 32 in PWGLF/DataModel/LFSigmaTables.h

View workflow job for this annotation

GitHub Actions / O2 linter

[import-std-name]

Do not import names from the std namespace in headers.

// Creating output TTree for sigma analysis
namespace o2::aod
Expand Down Expand Up @@ -73,7 +73,7 @@

DECLARE_SOA_DYNAMIC_COLUMN(Pt, pt,
[](float photonPx, float photonPy, float lambdaPx, float lambdaPy) -> float {
return RecoDecay::pt(array{photonPx + lambdaPx, photonPy + lambdaPy});

Check failure on line 76 in PWGLF/DataModel/LFSigmaTables.h

View workflow job for this annotation

GitHub Actions / O2 linter

[std-prefix]

Use std:: prefix for names from the std namespace.
});

DECLARE_SOA_DYNAMIC_COLUMN(P, p, //! Total momentum in GeV/c
Expand Down Expand Up @@ -213,7 +213,7 @@

// Dynamic Columns

//KStar
// KStar
DECLARE_SOA_DYNAMIC_COLUMN(Px, px, //! KStar px
[](float photonPx, float kshortPx) -> float { return photonPx + kshortPx; });
DECLARE_SOA_DYNAMIC_COLUMN(Py, py, //! KStar py
Expand All @@ -223,7 +223,7 @@

DECLARE_SOA_DYNAMIC_COLUMN(Pt, pt,
[](float photonPx, float photonPy, float kshortPx, float kshortPy) -> float {
return RecoDecay::pt(array{photonPx + kshortPx, photonPy + kshortPy});

Check failure on line 226 in PWGLF/DataModel/LFSigmaTables.h

View workflow job for this annotation

GitHub Actions / O2 linter

[std-prefix]

Use std:: prefix for names from the std namespace.
});

DECLARE_SOA_DYNAMIC_COLUMN(P, p, //! Total momentum in GeV/c
Expand Down Expand Up @@ -286,8 +286,7 @@
DECLARE_SOA_DYNAMIC_COLUMN(PhotonPhi, photonPhi, //! Phi in the range [0, 2pi)
[](float photonPx, float photonPy) -> float { return RecoDecay::phi(photonPx, photonPy); });


// KShort
// KShort
DECLARE_SOA_DYNAMIC_COLUMN(KShortPt, kshortPt, //! Transverse momentum in GeV/c
[](float kshortPx, float kshortPy) -> float {
return RecoDecay::sqrtSumOfSquares(kshortPx, kshortPy);
Expand All @@ -311,14 +310,14 @@
DECLARE_SOA_DYNAMIC_COLUMN(KShortPhi, kshortPhi, //! Phi in the range [0, 2pi)
[](float kshortPx, float kshortPy) -> float { return RecoDecay::phi(kshortPx, kshortPy); });

}
} // namespace kstarCore

DECLARE_SOA_TABLE(KStarCores, "AOD", "KSTARCORES",
kstarCore::X, kstarCore::Y, kstarCore::Z, kstarCore::DCADaughters,
kstarCore::PhotonPx, kstarCore::PhotonPy, kstarCore::PhotonPz, kstarCore::PhotonMass,
kstarCore::KShortPx, kstarCore::KShortPy, kstarCore::KShortPz, kstarCore::KShortMass,

//Dynamic columns
// Dynamic columns
kstarCore::Px<kstarCore::PhotonPx, kstarCore::KShortPx>,
kstarCore::Py<kstarCore::PhotonPy, kstarCore::KShortPy>,
kstarCore::Pz<kstarCore::PhotonPz, kstarCore::KShortPz>,
Expand All @@ -343,7 +342,6 @@
kstarCore::KShortY<kstarCore::KShortPx, kstarCore::KShortPy, kstarCore::KShortPz>,
kstarCore::KShortPhi<kstarCore::KShortPx, kstarCore::KShortPy>);


// For KStar extra info
namespace kshortExtra
{
Expand Down Expand Up @@ -371,7 +369,7 @@
DECLARE_SOA_COLUMN(KShortPosTrackCode, kshortPosTrackCode, uint8_t);
DECLARE_SOA_COLUMN(KShortNegTrackCode, kshortNegTrackCode, uint8_t);
DECLARE_SOA_COLUMN(KShortV0Type, kshortV0Type, uint8_t);
}
} // namespace kshortExtra

DECLARE_SOA_TABLE(KShortExtras, "AOD", "KSHORT",
kshortExtra::KShortQt,
Expand All @@ -397,8 +395,7 @@
kshortExtra::KShortNegITSChi2PerNcl,
kshortExtra::KShortPosTrackCode,
kshortExtra::KShortNegTrackCode,
kshortExtra::KShortV0Type
);
kshortExtra::KShortV0Type);

// For KStar extra info
namespace kstarPhotonExtra
Expand All @@ -425,7 +422,7 @@
DECLARE_SOA_COLUMN(PhotonPosTrackCode, photonPosTrackCode, uint8_t);
DECLARE_SOA_COLUMN(PhotonNegTrackCode, photonNegTrackCode, uint8_t);
DECLARE_SOA_COLUMN(PhotonV0Type, photonV0Type, uint8_t);
}
} // namespace kstarPhotonExtra

DECLARE_SOA_TABLE(KStarPhotonExtras, "AOD", "KSTARPHOTON",
kstarPhotonExtra::PhotonQt,
Expand All @@ -451,7 +448,6 @@
kstarPhotonExtra::PhotonNegTrackCode,
kstarPhotonExtra::PhotonV0Type);


// For Photon extra info
namespace sigma0PhotonExtra
{
Expand Down Expand Up @@ -594,10 +590,10 @@
DECLARE_SOA_COLUMN(LambdaIsCorrectlyAssoc, lambdaIsCorrectlyAssoc, bool);

DECLARE_SOA_DYNAMIC_COLUMN(IsSigma0, isSigma0, //! IsSigma0
[](int pdgCode) -> bool { return pdgCode == 3212; });

Check failure on line 593 in PWGLF/DataModel/LFSigmaTables.h

View workflow job for this annotation

GitHub Actions / O2 linter

[pdg/explicit-code]

Avoid hard-coded PDG codes. Use named values from PDG_t or o2::constants::physics::Pdg instead.

DECLARE_SOA_DYNAMIC_COLUMN(IsAntiSigma0, isAntiSigma0, //! IsASigma0
[](int pdgCode) -> bool { return pdgCode == -3212; });

Check failure on line 596 in PWGLF/DataModel/LFSigmaTables.h

View workflow job for this annotation

GitHub Actions / O2 linter

[pdg/explicit-code]

Avoid hard-coded PDG codes. Use named values from PDG_t or o2::constants::physics::Pdg instead.

DECLARE_SOA_DYNAMIC_COLUMN(MCPx, mcpx, //! Sigma0 px
[](float photonMCPx, float lambdaMCPx) -> float { return photonMCPx + lambdaMCPx; });
Expand All @@ -608,7 +604,7 @@

DECLARE_SOA_DYNAMIC_COLUMN(MCPt, mcpt,
[](float photonMCPx, float photonMCPy, float lambdaMCPx, float lambdaMCPy) -> float {
return RecoDecay::pt(array{photonMCPx + lambdaMCPx, photonMCPy + lambdaMCPy});

Check failure on line 607 in PWGLF/DataModel/LFSigmaTables.h

View workflow job for this annotation

GitHub Actions / O2 linter

[std-prefix]

Use std:: prefix for names from the std namespace.
});

DECLARE_SOA_DYNAMIC_COLUMN(MCP, mcp, //! Total momentum in GeV/c
Expand Down Expand Up @@ -763,7 +759,7 @@
DECLARE_SOA_COLUMN(KShortIsCorrectlyAssoc, kshortIsCorrectlyAssoc, bool);

DECLARE_SOA_DYNAMIC_COLUMN(IsKStar, isKStar, //! IsSigma0
[](int pdgCode) -> bool { return pdgCode == 313; });

Check failure on line 762 in PWGLF/DataModel/LFSigmaTables.h

View workflow job for this annotation

GitHub Actions / O2 linter

[pdg/explicit-code]

Avoid hard-coded PDG codes. Use named values from PDG_t or o2::constants::physics::Pdg instead.

DECLARE_SOA_DYNAMIC_COLUMN(MCPx, mcpx, //! Sigma0 px
[](float photonMCPx, float kshortMCPx) -> float { return photonMCPx + kshortMCPx; });
Expand All @@ -774,7 +770,7 @@

DECLARE_SOA_DYNAMIC_COLUMN(MCPt, mcpt,
[](float photonMCPx, float photonMCPy, float kshortMCPx, float kshortMCPy) -> float {
return RecoDecay::pt(array{photonMCPx + kshortMCPx, photonMCPy + kshortMCPy});

Check failure on line 773 in PWGLF/DataModel/LFSigmaTables.h

View workflow job for this annotation

GitHub Actions / O2 linter

[std-prefix]

Use std:: prefix for names from the std namespace.
});

DECLARE_SOA_DYNAMIC_COLUMN(MCP, mcp, //! Total momentum in GeV/c
Expand Down Expand Up @@ -858,7 +854,7 @@
DECLARE_SOA_DYNAMIC_COLUMN(KShortMCPhi, kshortMCPhi, //! Phi in the range [0, 2pi)
[](float kshortMCPx, float kshortMCPy) -> float { return RecoDecay::phi(kshortMCPx, kshortMCPy); });

} // namespace sigma0MCCore
} // namespace kstarMCCore

DECLARE_SOA_TABLE(KStarMCCores, "AOD", "KSTARMCCORES",
// Basic properties
Expand Down Expand Up @@ -891,13 +887,11 @@
kstarMCCore::PhotonMCPhi<kstarMCCore::PhotonMCPx, kstarMCCore::PhotonMCPy>,

kstarMCCore::KShortMCPt<kstarMCCore::KShortMCPx, kstarMCCore::KShortMCPy>,
kstarMCCore::KShortMCP<kstarMCCore::KShortMCPx, kstarMCCore::KShortMCPy, kstarMCCore::KShortMCPz>,
kstarMCCore::KShortMCP<kstarMCCore::KShortMCPx, kstarMCCore::KShortMCPy, kstarMCCore::KShortMCPz>,
kstarMCCore::KShortMCEta<kstarMCCore::KShortMCPx, kstarMCCore::KShortMCPy, kstarMCCore::KShortMCPz>,
kstarMCCore::KShortMCY<kstarMCCore::KShortMCPx, kstarMCCore::KShortMCPy, kstarMCCore::KShortMCPz>,
kstarMCCore::KShortMCPhi<kstarMCCore::KShortMCPx, kstarMCCore::KShortMCPy>);



namespace sigma0Gen
{
DECLARE_SOA_COLUMN(IsSigma0, isSigma0, bool); // true: sigma0, false: antisigma0
Expand All @@ -919,7 +913,7 @@
DECLARE_SOA_COLUMN(ProducedByGenerator, producedByGenerator, bool);
DECLARE_SOA_COLUMN(KStarMCPt, kstarMCPt, float); // MC pT

} // namespace sigma0Gen
} // namespace kstarGen

DECLARE_SOA_TABLE(KStarGens, "AOD", "KSTARGENS",
kstarGen::IsKStar,
Expand All @@ -929,7 +923,6 @@
DECLARE_SOA_TABLE(SigmaCollRef, "AOD", "SIGMACOLLREF", //! optional table to refer back to a collision
o2::soa::Index<>, v0data::StraCollisionId);


DECLARE_SOA_TABLE(SigmaIndices, "AOD", "SIGMAINDEX", //! index table when using AO2Ds
o2::soa::Index<>, sigma0Core::PhotonV0Id, sigma0Core::LambdaV0Id, o2::soa::Marker<1>);

Expand All @@ -939,12 +932,11 @@
DECLARE_SOA_TABLE(SigmaGenCollRef, "AOD", "SIGMAGENCOLLREF", //! optional table to refer back to a collision
o2::soa::Index<>, v0data::StraMCCollisionId);

DECLARE_SOA_TABLE(KStarCollRef, "AOD", "KSTARCOLLREF",
o2::soa::Index<>, v0data::StraCollisionId);

DECLARE_SOA_TABLE(KStarCollRef, "AOD", "KSTARCOLLREF",
o2::soa::Index<>, v0data::StraCollisionId);

DECLARE_SOA_TABLE(KStarGenCollRef, "AOD", "KSTARGENCOLLREF",
o2::soa::Index<>, v0data::StraMCCollisionId);
DECLARE_SOA_TABLE(KStarGenCollRef, "AOD", "KSTARGENCOLLREF",
o2::soa::Index<>, v0data::StraMCCollisionId);

// ___________________________________________________________________________
// pi0 QA
Expand Down Expand Up @@ -1008,7 +1000,7 @@

DECLARE_SOA_DYNAMIC_COLUMN(Pt, pt,
[](float photon1Px, float photon1Py, float photon2Px, float photon2Py) -> float {
return RecoDecay::pt(array{photon1Px + photon2Px, photon1Py + photon2Py});

Check failure on line 1003 in PWGLF/DataModel/LFSigmaTables.h

View workflow job for this annotation

GitHub Actions / O2 linter

[std-prefix]

Use std:: prefix for names from the std namespace.
});

DECLARE_SOA_DYNAMIC_COLUMN(P, p, //! Total momentum in GeV/c
Expand Down Expand Up @@ -1176,7 +1168,7 @@

DECLARE_SOA_DYNAMIC_COLUMN(MCPt, mcpt,
[](float photon1MCPx, float photon1MCPy, float photon2MCPx, float photon2MCPy) -> float {
return RecoDecay::pt(array{photon1MCPx + photon2MCPx, photon1MCPy + photon2MCPy});

Check failure on line 1171 in PWGLF/DataModel/LFSigmaTables.h

View workflow job for this annotation

GitHub Actions / O2 linter

[std-prefix]

Use std:: prefix for names from the std namespace.
});

DECLARE_SOA_DYNAMIC_COLUMN(MCP, mcp, //! Total momentum in GeV/c
Expand Down
Loading
Loading