Skip to content

Commit a11f8b5

Browse files
authored
Merge branch 'AliceO2Group:master' into McTunePR
2 parents 3f6fbd0 + bf13110 commit a11f8b5

20 files changed

+1246
-287
lines changed

PWGCF/FemtoUniverse/Tasks/femtoUniversePairTaskTrackD0.cxx

Lines changed: 38 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,12 @@ using namespace o2::framework;
5656
using namespace o2::framework::expressions;
5757
using namespace o2::soa;
5858

59+
namespace
60+
{
61+
static const int8_t genPromptD0 = 1;
62+
static const int8_t genNonPromptD0 = 2;
63+
} // namespace
64+
5965
/// Returns deltaPhi value within the range [-pi/2, 3/2*pi]
6066
///
6167
double getDeltaPhi(double phiD, double phiDbar)
@@ -437,12 +443,20 @@ struct FemtoUniversePairTaskTrackD0 {
437443
}
438444
// MC Reco
439445
mcRecoRegistry.add("hMcRecD0", "MC Reco all D0s;#it{p}_{T} (GeV/c); #eta", {HistType::kTH2F, {{vbins, "#it{p}_{T} (GeV/#it{c})"}, {400, -1.0, 1.0}}});
446+
mcRecoRegistry.add("hMcRecD0Pt", "MC Reco all D0s;#it{p}_{T} (GeV/c); counts", {HistType::kTH1F, {vbins}});
440447
mcRecoRegistry.add("hMcRecD0Prompt", "MC Reco prompt D0s;#it{p}_{T} (GeV/c); #eta", {HistType::kTH2F, {{vbins, "#it{p}_{T} (GeV/#it{c})"}, {400, -1.0, 1.0}}});
448+
mcRecoRegistry.add("hMcRecD0PromptPt", "MC Reco prompt D0s;#it{p}_{T} (GeV/c); counts", {HistType::kTH1F, {vbins}});
441449
mcRecoRegistry.add("hMcRecD0NonPrompt", "MC Reco non-prompt D0s;#it{p}_{T} (GeV/c); #eta", {HistType::kTH2F, {{vbins, "#it{p}_{T} (GeV/#it{c})"}, {400, -1.0, 1.0}}});
450+
mcRecoRegistry.add("hMcRecD0NonPromptPt", "MC Reco non-prompt D0s;#it{p}_{T} (GeV/c); counts", {HistType::kTH1F, {vbins}});
442451
mcRecoRegistry.add("hMcRecD0Phi", "MC Reco all D0s;#varphi (rad); counts", {HistType::kTH1F, {{80, 0., o2::constants::math::TwoPI}}});
452+
mcRecoRegistry.add("hMcRecD0PromptPhi", "MC Reco prompt D0s;#varphi (rad); counts", {HistType::kTH1F, {{80, 0., o2::constants::math::TwoPI}}});
453+
mcRecoRegistry.add("hMcRecD0NonPromptPhi", "MC Reco non-prompt D0s;#varphi (rad); counts", {HistType::kTH1F, {{80, 0., o2::constants::math::TwoPI}}});
443454
mcRecoRegistry.add("hMcRecD0bar", "MC Reco all D0bars;#it{p}_{T} (GeV/c); #eta", {HistType::kTH2F, {{vbins, "#it{p}_{T} (GeV/#it{c})"}, {400, -1.0, 1.0}}});
455+
mcRecoRegistry.add("hMcRecD0barPt", "MC Reco all D0bars;#it{p}_{T} (GeV/c); counts", {HistType::kTH1F, {vbins}});
444456
mcRecoRegistry.add("hMcRecD0barPrompt", "MC Reco prompt D0bars;#it{p}_{T} (GeV/c); #eta", {HistType::kTH2F, {{vbins, "#it{p}_{T} (GeV/#it{c})"}, {400, -1.0, 1.0}}});
457+
mcRecoRegistry.add("hMcRecD0barPromptPt", "MC Reco prompt D0bars;#it{p}_{T} (GeV/c); counts", {HistType::kTH1F, {vbins}});
445458
mcRecoRegistry.add("hMcRecD0barNonPrompt", "MC Reco non-prompt D0bars;#it{p}_{T} (GeV/c); #eta", {HistType::kTH2F, {{vbins, "#it{p}_{T} (GeV/#it{c})"}, {400, -1.0, 1.0}}});
459+
mcRecoRegistry.add("hMcRecD0barNonPromptPt", "MC Reco non-prompt D0bars;#it{p}_{T} (GeV/c); counts", {HistType::kTH1F, {vbins}});
446460
mcRecoRegistry.add("hMcRecD0barPhi", "MC Reco all D0bars;#varphi (rad); counts", {HistType::kTH1F, {{80, 0., o2::constants::math::TwoPI}}});
447461
// Inv. mass histograms
448462
mcRecoRegistry.add("hMassVsPtD0Sig", "2-prong candidates;inv. mass (#pi K) (GeV/#it{c}^{2});entries", {HistType::kTH2F, {confInvMassBins, {vbins, "#it{p}_{T} (GeV/#it{c})"}}});
@@ -471,11 +485,17 @@ struct FemtoUniversePairTaskTrackD0 {
471485

472486
// MC truth
473487
mcTruthRegistry.add("hMcGenD0", "MC Truth all D0s;#it{p}_{T} (GeV/c); #eta", {HistType::kTH2F, {{vbins, "#it{p}_{T} (GeV/#it{c})"}, {400, -1.0, 1.0}}});
488+
mcTruthRegistry.add("hMcGenD0Pt", "MC Truth all D0s;#it{p}_{T} (GeV/c); counts", {HistType::kTH1F, {vbins}});
474489
mcTruthRegistry.add("hMcGenD0Prompt", "MC Truth prompt D0s;#it{p}_{T} (GeV/c); #eta", {HistType::kTH2F, {{vbins, "#it{p}_{T} (GeV/#it{c})"}, {400, -1.0, 1.0}}});
490+
mcTruthRegistry.add("hMcGenD0PromptPt", "MC Truth prompt D0s;#it{p}_{T} (GeV/c); counts", {HistType::kTH1F, {vbins}});
475491
mcTruthRegistry.add("hMcGenD0NonPrompt", "MC Truth non-prompt D0s;#it{p}_{T} (GeV/c); #eta", {HistType::kTH2F, {{vbins, "#it{p}_{T} (GeV/#it{c})"}, {400, -1.0, 1.0}}});
492+
mcTruthRegistry.add("hMcGenD0NonPromptPt", "MC Truth non-prompt D0s;#it{p}_{T} (GeV/c); counts", {HistType::kTH1F, {vbins}});
476493
mcTruthRegistry.add("hMcGenD0bar", "MC Truth all D0bars;#it{p}_{T} (GeV/c); #eta", {HistType::kTH2F, {{vbins, "#it{p}_{T} (GeV/#it{c})"}, {400, -1.0, 1.0}}});
494+
mcTruthRegistry.add("hMcGenD0barPt", "MC Truth all D0bars;#it{p}_{T} (GeV/c); counts", {HistType::kTH1F, {vbins}});
477495
mcTruthRegistry.add("hMcGenD0barPrompt", "MC Truth prompt D0bars;#it{p}_{T} (GeV/c); #eta", {HistType::kTH2F, {{vbins, "#it{p}_{T} (GeV/#it{c})"}, {400, -1.0, 1.0}}});
496+
mcTruthRegistry.add("hMcGenD0barPromptPt", "MC Truth prompt D0s;#it{p}_{T} (GeV/c); counts", {HistType::kTH1F, {vbins}});
478497
mcTruthRegistry.add("hMcGenD0barNonPrompt", "MC Truth non-prompt D0bars;#it{p}_{T} (GeV/c); #eta", {HistType::kTH2F, {{vbins, "#it{p}_{T} (GeV/#it{c})"}, {400, -1.0, 1.0}}});
498+
mcTruthRegistry.add("hMcGenD0barNonPromptPt", "MC Truth non-prompt D0s;#it{p}_{T} (GeV/c); counts", {HistType::kTH1F, {vbins}});
479499
mcTruthRegistry.add("hMcGenAllPositivePt", "MC Truth all positive;#it{p}_{T} (GeV/c); counts", {HistType::kTH1F, {{360, 0, 36}}});
480500
mcTruthRegistry.add("hMcGenAllNegativePt", "MC Truth all negative;#it{p}_{T} (GeV/c); counts", {HistType::kTH1F, {{360, 0, 36}}});
481501
mcTruthRegistry.add("hMcGenKpPtVsEta", "MC Truth K+;#it{p}_{T} (GeV/c); #eta", {HistType::kTH2F, {{500, 0, 5}, {400, -1.0, 1.0}}});
@@ -1318,19 +1338,27 @@ struct FemtoUniversePairTaskTrackD0 {
13181338
} else if ((part.partType() == aod::femtouniverseparticle::ParticleType::kD0) && (part.pt() > ConfDmesons.confMinPtD0D0barReco) && (part.pt() < ConfDmesons.confMaxPtD0D0barReco)) {
13191339
if (mcpart.pdgMCTruth() == ConfDmesons.confPDGCodeD0) {
13201340
mcRecoRegistry.fill(HIST("hMcRecD0"), part.pt(), part.eta());
1341+
mcRecoRegistry.fill(HIST("hMcRecD0Pt"), part.pt());
13211342
mcRecoRegistry.fill(HIST("hMcRecD0Phi"), part.phi());
13221343
if (part.tpcNClsFound() == 0) { // prompt candidates
13231344
mcRecoRegistry.fill(HIST("hMcRecD0Prompt"), part.pt(), part.eta());
1345+
mcRecoRegistry.fill(HIST("hMcRecD0PromptPt"), part.pt());
1346+
mcRecoRegistry.fill(HIST("hMcRecD0PromptPhi"), part.phi());
13241347
} else if (part.tpcNClsFound() == 1) { // non-prompt candidates
13251348
mcRecoRegistry.fill(HIST("hMcRecD0NonPrompt"), part.pt(), part.eta());
1349+
mcRecoRegistry.fill(HIST("hMcRecD0PromptPt"), part.pt());
1350+
mcRecoRegistry.fill(HIST("hMcRecD0PromptPhi"), part.phi());
13261351
}
13271352
} else if (mcpart.pdgMCTruth() == ConfDmesons.confPDGCodeD0bar) {
13281353
mcRecoRegistry.fill(HIST("hMcRecD0bar"), part.pt(), part.eta());
1354+
mcRecoRegistry.fill(HIST("hMcRecD0barPt"), part.pt());
13291355
mcRecoRegistry.fill(HIST("hMcRecD0barPhi"), part.phi());
13301356
if (part.tpcNClsFound() == 0) { // prompt candidates
13311357
mcRecoRegistry.fill(HIST("hMcRecD0barPrompt"), part.pt(), part.eta());
1358+
mcRecoRegistry.fill(HIST("hMcRecD0barPromptPt"), part.pt());
13321359
} else if (part.tpcNClsFound() == 1) { // non-prompt candidates
13331360
mcRecoRegistry.fill(HIST("hMcRecD0barNonPrompt"), part.pt(), part.eta());
1361+
mcRecoRegistry.fill(HIST("hMcRecD0barNonPromptPt"), part.pt());
13341362
}
13351363
}
13361364
}
@@ -1413,10 +1441,13 @@ struct FemtoUniversePairTaskTrackD0 {
14131441
if (pdgCode == o2::constants::physics::Pdg::kD0) {
14141442
if (std::abs(hfFlagMcGen) == o2::hf_decay::hf_cand_2prong::DecayChannelMain::D0ToPiK) {
14151443
mcTruthRegistry.fill(HIST("hMcGenD0"), part.pt(), part.eta());
1416-
if (part.mAntiLambda() == 1) {
1444+
mcTruthRegistry.fill(HIST("hMcGenD0Pt"), part.pt());
1445+
if (static_cast<int8_t>(part.mAntiLambda()) == genPromptD0) {
14171446
mcTruthRegistry.fill(HIST("hMcGenD0Prompt"), part.pt(), part.eta());
1418-
} else if (part.mAntiLambda() == 2) {
1447+
mcTruthRegistry.fill(HIST("hMcGenD0PromptPt"), part.pt());
1448+
} else if (static_cast<int8_t>(part.mAntiLambda()) == genNonPromptD0) {
14191449
mcTruthRegistry.fill(HIST("hMcGenD0NonPrompt"), part.pt(), part.eta());
1450+
mcTruthRegistry.fill(HIST("hMcGenD0NonPromptPt"), part.pt());
14201451
}
14211452
}
14221453
}
@@ -1439,10 +1470,13 @@ struct FemtoUniversePairTaskTrackD0 {
14391470
if (pdgCode == o2::constants::physics::Pdg::kD0Bar) {
14401471
if (std::abs(hfFlagMcGen) == o2::hf_decay::hf_cand_2prong::DecayChannelMain::D0ToPiK) {
14411472
mcTruthRegistry.fill(HIST("hMcGenD0bar"), part.pt(), part.eta());
1442-
if (part.mAntiLambda() == 1) {
1473+
mcTruthRegistry.fill(HIST("hMcGenD0barPt"), part.pt());
1474+
if (static_cast<int8_t>(part.mAntiLambda()) == genPromptD0) {
14431475
mcTruthRegistry.fill(HIST("hMcGenD0barPrompt"), part.pt(), part.eta());
1444-
} else if (part.mAntiLambda() == 2) {
1476+
mcTruthRegistry.fill(HIST("hMcGenD0barPromptPt"), part.pt());
1477+
} else if (static_cast<int8_t>(part.mAntiLambda()) == genNonPromptD0) {
14451478
mcTruthRegistry.fill(HIST("hMcGenD0barNonPrompt"), part.pt(), part.eta());
1479+
mcTruthRegistry.fill(HIST("hMcGenD0barNonPromptPt"), part.pt());
14461480
}
14471481
}
14481482
}

PWGDQ/Tasks/dqEfficiency_withAssoc.cxx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1721,10 +1721,10 @@ struct AnalysisSameEventPairing {
17211721
template <bool TTwoProngFitter, int TPairType, uint32_t TEventFillMap, uint32_t TTrackFillMap, typename TEvents, typename TTrackAssocs, typename TTracks>
17221722
void runSameEventPairing(TEvents const& events, Preslice<TTrackAssocs>& preslice, TTrackAssocs const& assocs, TTracks const& /*tracks*/, ReducedMCEvents const& /*mcEvents*/, ReducedMCTracks const& /*mcTracks*/)
17231723
{
1724-
if (events.size() == 0) {
1725-
LOG(warning) << "No events in this TF, going to the next one ...";
1726-
return;
1727-
}
1724+
// if (events.size() == 0) {
1725+
// LOG(warning) << "No events in this TF, going to the next one ...";
1726+
// return;
1727+
// }
17281728
if (fCurrentRun != events.begin().runNumber()) {
17291729
initParamsFromCCDB(events.begin().timestamp(), TTwoProngFitter);
17301730
fCurrentRun = events.begin().runNumber();

PWGEM/Dilepton/Core/Dilepton.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -131,8 +131,8 @@ struct Dilepton {
131131
// ConfigurableAxis ConfMmumuBins{"ConfMmumuBins", {VARIABLE_WIDTH, 0.20, 0.21, 0.22, 0.23, 0.24, 0.25, 0.26, 0.27, 0.28, 0.29, 0.30, 0.31, 0.32, 0.33, 0.34, 0.35, 0.36, 0.37, 0.38, 0.39, 0.40, 0.41, 0.42, 0.43, 0.44, 0.45, 0.46, 0.47, 0.48, 0.49, 0.50, 0.51, 0.52, 0.53, 0.54, 0.55, 0.56, 0.57, 0.58, 0.59, 0.60, 0.61, 0.62, 0.63, 0.64, 0.65, 0.66, 0.67, 0.68, 0.69, 0.70, 0.71, 0.72, 0.73, 0.74, 0.75, 0.76, 0.77, 0.78, 0.79, 0.80, 0.81, 0.82, 0.83, 0.84, 0.85, 0.86, 0.87, 0.88, 0.89, 0.90, 0.91, 0.92, 0.93, 0.94, 0.95, 0.96, 0.97, 0.98, 0.99, 1.00, 1.01, 1.02, 1.03, 1.04, 1.05, 1.06, 1.07, 1.08, 1.09, 1.10, 1.11,1.12,1.13,1.14,1.15,1.16,1.17,1.18,1.19, 1.20, 1.30, 1.40, 1.50, 1.60, 1.70, 1.80, 1.90, 2.00, 2.10, 2.20, 2.30, 2.40, 2.50, 2.60, 2.70, 2.75, 2.80, 2.85, 2.90, 2.95, 3.00, 3.05, 3.10, 3.15, 3.20, 3.25, 3.30, 3.35, 3.40, 3.45, 3.50, 3.55, 3.60, 3.65, 3.70, 3.75, 3.80, 3.85, 3.90, 3.95, 4.00, 4.10, 4.20, 4.30, 4.40, 4.50, 4.60, 4.70, 4.80, 4.90, 5.00, 5.10, 5.20, 5.30, 5.40, 5.50, 5.60, 5.70, 5.80, 5.90, 6.00, 6.10, 6.20, 6.30, 6.40, 6.50, 6.60, 6.70, 6.80, 6.90, 7.00, 7.10, 7.20, 7.30, 7.40, 7.50, 7.60, 7.70, 7.80, 7.90, 8.00, 8.10, 8.20, 8.30, 8.40, 8.50, 8.60, 8.70, 8.80, 8.90, 9.00, 9.10, 9.20, 9.30, 9.40, 9.50, 9.60, 9.70, 9.80, 9.90, 10.00, 10.10, 10.20, 10.30, 10.40, 10.50, 10.60, 10.70, 10.80, 10.90, 11.00, 11.50, 12.00}, "mmumu bins for output histograms"}; // for dimuon. one can copy bins here to hyperloop page.
132132

133133
ConfigurableAxis ConfSPBins{"ConfSPBins", {200, -5, 5}, "SP bins for flow analysis"};
134-
ConfigurableAxis ConfPolarizationPhiBins{"ConfPolarizationPhiBins", {1, 0.f, 2 * M_PI}, "phi bins for polarization analysis"};
135134
ConfigurableAxis ConfPolarizationCosThetaBins{"ConfPolarizationCosThetaBins", {20, -1.f, 1.f}, "cos(theta) bins for polarization analysis"};
135+
ConfigurableAxis ConfPolarizationPhiBins{"ConfPolarizationPhiBins", {1, -M_PI, M_PI}, "phi bins for polarization analysis"};
136136
ConfigurableAxis ConfPolarizationQuadMomBins{"ConfPolarizationQuadMomBins", {15, -0.5, 1}, "quadrupole moment bins for polarization analysis"}; // quardrupole moment <(3 x cos^2(theta) -1)/2>
137137

138138
EMEventCut fEMEventCut;
@@ -973,7 +973,7 @@ struct Dilepton {
973973
} else if (cfgPolarizationFrame == 1) {
974974
o2::aod::pwgem::dilepton::utils::pairutil::getAngleHX(std::array<float, 4>{t1.px(), t1.py(), t1.pz(), leptonM1}, std::array<float, 4>{t2.px(), t2.py(), t2.pz(), leptonM2}, beamE1, beamE2, beamP1, beamP2, t1.sign(), cos_thetaPol, phiPol);
975975
}
976-
o2::math_utils::bringTo02Pi(phiPol);
976+
o2::math_utils::bringToPMPi(phiPol);
977977

978978
if (t1.sign() * t2.sign() < 0) { // ULS
979979
fRegistry.fill(HIST("Pair/") + HIST(event_pair_types[ev_id]) + HIST("uls/hs"), v12.M(), v12.Pt(), pair_dca, v12.Rapidity(), aco, asym, std::fabs(dphi_e_ee), cos_thetaPol, weight);
@@ -1030,7 +1030,7 @@ struct Dilepton {
10301030
} else if (cfgPolarizationFrame == 1) {
10311031
o2::aod::pwgem::dilepton::utils::pairutil::getAngleHX(std::array<float, 4>{t1.px(), t1.py(), t1.pz(), leptonM1}, std::array<float, 4>{t2.px(), t2.py(), t2.pz(), leptonM2}, beamE1, beamE2, beamP1, beamP2, t1.sign(), cos_thetaPol, phiPol);
10321032
}
1033-
o2::math_utils::bringTo02Pi(phiPol);
1033+
o2::math_utils::bringToPMPi(phiPol);
10341034
float quadmom = (3.f * std::pow(cos_thetaPol, 2) - 1.f) / 2.f;
10351035

10361036
if (t1.sign() * t2.sign() < 0) { // ULS

0 commit comments

Comments
 (0)