Skip to content

Commit 82666cd

Browse files
authored
Merge branch 'AliceO2Group:master' into master
2 parents 472bc31 + 9185290 commit 82666cd

File tree

5 files changed

+61
-40
lines changed

5 files changed

+61
-40
lines changed

PWGCF/Flow/Tasks/flowGFWOmegaXi.cxx

Lines changed: 45 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -112,8 +112,8 @@ struct FlowGFWOmegaXi {
112112

113113
// Connect to ccdb
114114
Service<ccdb::BasicCCDBManager> ccdb;
115-
O2_DEFINE_CONFIGURABLE(nolaterthan, int64_t, std::chrono::duration_cast<std::chrono::milliseconds>(std::chrono::system_clock::now().time_since_epoch()).count(), "latest acceptable timestamp of creation for the object")
116-
O2_DEFINE_CONFIGURABLE(url, std::string, "http://ccdb-test.cern.ch", "url of the ccdb repository")
115+
O2_DEFINE_CONFIGURABLE(cfgnolaterthan, int64_t, std::chrono::duration_cast<std::chrono::milliseconds>(std::chrono::system_clock::now().time_since_epoch()).count(), "latest acceptable timestamp of creation for the object")
116+
O2_DEFINE_CONFIGURABLE(cfgurl, std::string, "http://alice-ccdb.cern.ch", "url of the ccdb repository")
117117

118118
// Define output
119119
HistogramRegistry registry{"registry"};
@@ -140,47 +140,43 @@ struct FlowGFWOmegaXi {
140140
using aodCollisions = soa::Filtered<soa::Join<aod::Collisions, aod::EvSels, aod::CentFT0Cs, aod::Mults>>; // collisions filter
141141
using DaughterTracks = soa::Join<aod::Tracks, aod::TracksExtra, aod::TracksDCA, aod::pidTPCPi, aod::pidTPCPr, aod::pidTPCKa>;
142142

143-
// Set the pt, mult and phi Axis;
144-
o2::framework::AxisSpec axisPt = cfgaxisPt;
145-
int nPtBins = axisPt.binEdges.size() - 1;
146-
TAxis* fPtAxis = new TAxis(nPtBins, &(axisPt.binEdges)[0]);
143+
// Declare the pt, mult and phi Axis;
144+
int nPtBins = 0;
145+
TAxis* fPtAxis = nullptr;
147146

148-
o2::framework::AxisSpec axisXiPt = cfgaxisPtXi;
149-
int nXiPtBins = axisXiPt.binEdges.size() - 1;
150-
TAxis* fXiPtAxis = new TAxis(nXiPtBins, &(axisXiPt.binEdges)[0]);
147+
int nXiPtBins = 0;
148+
TAxis* fXiPtAxis = nullptr;
151149

152-
o2::framework::AxisSpec axisV0Pt = cfgaxisPtV0;
153-
int nV0PtBins = axisV0Pt.binEdges.size() - 1;
154-
TAxis* fV0PtAxis = new TAxis(nV0PtBins, &(axisV0Pt.binEdges)[0]);
150+
int nV0PtBins = 0;
151+
TAxis* fV0PtAxis = nullptr;
155152

156-
o2::framework::AxisSpec axisMult = axisMultiplicity;
157-
int nMultBins = axisMult.binEdges.size() - 1;
158-
TAxis* fMultAxis = new TAxis(nMultBins, &(axisMult.binEdges)[0]);
153+
int nMultBins = 0;
154+
TAxis* fMultAxis = nullptr;
159155

160156
int nPhiBins = 60;
161157
TAxis* fPhiAxis = new TAxis(nPhiBins, 0, constants::math::TwoPI);
162158

163-
TAxis* fOmegaMass = new TAxis(cfgOmegaMassbins, 1.63, 1.71);
159+
TAxis* fOmegaMass = nullptr;
164160

165-
TAxis* fXiMass = new TAxis(cfgXiMassbins, 1.3, 1.37);
161+
TAxis* fXiMass = nullptr;
166162

167-
TAxis* fK0sMass = new TAxis(cfgK0sMassbins, 0.4, 0.6);
163+
TAxis* fK0sMass = nullptr;
168164

169-
TAxis* fLambdaMass = new TAxis(cfgLambdaMassbins, 1.08, 1.16);
165+
TAxis* fLambdaMass = nullptr;
170166

171167
void init(InitContext const&) // Initialization
172168
{
173-
ccdb->setURL(url.value);
169+
ccdb->setURL(cfgurl.value);
174170
ccdb->setCaching(true);
175-
ccdb->setCreatedNotAfter(nolaterthan.value);
171+
ccdb->setCreatedNotAfter(cfgnolaterthan.value);
176172

177173
// Add some output objects to the histogram registry
178174
registry.add("hPhi", "", {HistType::kTH1D, {cfgaxisPhi}});
179175
registry.add("hEta", "", {HistType::kTH1D, {cfgaxisEta}});
180176
registry.add("hVtxZ", "", {HistType::kTH1D, {cfgaxisVertex}});
181177
registry.add("hMult", "", {HistType::kTH1D, {{3000, 0.5, 3000.5}}});
182178
registry.add("hCent", "", {HistType::kTH1D, {{90, 0, 90}}});
183-
registry.add("hPt", "", {HistType::kTH1D, {axisPt}});
179+
registry.add("hPt", "", {HistType::kTH1D, {cfgaxisPt}});
184180
registry.add("hEtaPhiVtxzREF", "", {HistType::kTH3D, {cfgaxisEta, cfgaxisPhi, {20, -10, 10}}});
185181
registry.add("hEtaPhiVtxzPOIXi", "", {HistType::kTH3D, {cfgaxisEta, cfgaxisPhi, {20, -10, 10}}});
186182
registry.add("hEtaPhiVtxzPOIOmega", "", {HistType::kTH3D, {cfgaxisEta, cfgaxisPhi, {20, -10, 10}}});
@@ -197,8 +193,8 @@ struct FlowGFWOmegaXi {
197193
registry.get<TH2>(HIST("hEventCount"))->GetYaxis()->SetBinLabel(4, "Omega");
198194

199195
// cumulant of flow
200-
registry.add("c22", ";Centrality (%) ; C_{2}{2}", {HistType::kTProfile2D, {axisPt, axisMultiplicity}});
201-
registry.add("c24", ";Centrality (%) ; C_{2}{4}", {HistType::kTProfile2D, {axisPt, axisMultiplicity}});
196+
registry.add("c22", ";Centrality (%) ; C_{2}{2}", {HistType::kTProfile2D, {cfgaxisPt, axisMultiplicity}});
197+
registry.add("c24", ";Centrality (%) ; C_{2}{4}", {HistType::kTProfile2D, {cfgaxisPt, axisMultiplicity}});
202198
// pt-diff cumulant of flow
203199
registry.add("Xic22dpt", ";pt ; C_{2}{2} ", {HistType::kTProfile3D, {cfgaxisPtXi, cfgaxisXiminusMassforflow, axisMultiplicity}});
204200
registry.add("Omegac22dpt", ";pt ; C_{2}{2} ", {HistType::kTProfile3D, {cfgaxisPtXi, cfgaxisOmegaminusMassforflow, axisMultiplicity}});
@@ -218,6 +214,31 @@ struct FlowGFWOmegaXi {
218214
registry.add("InvMassK0s", "", {HistType::kTHnSparseF, {cfgaxisPtV0, axisK0sMass, cfgaxisEta, axisMultiplicity}});
219215
registry.add("InvMassLambda", "", {HistType::kTHnSparseF, {cfgaxisPtV0, axisLambdaMass, cfgaxisEta, axisMultiplicity}});
220216

217+
// Set the pt, mult and phi Axis;
218+
o2::framework::AxisSpec axisPt = cfgaxisPt;
219+
nPtBins = axisPt.binEdges.size() - 1;
220+
fPtAxis = new TAxis(nPtBins, &(axisPt.binEdges)[0]);
221+
222+
o2::framework::AxisSpec axisXiPt = cfgaxisPtXi;
223+
nXiPtBins = axisXiPt.binEdges.size() - 1;
224+
fXiPtAxis = new TAxis(nXiPtBins, &(axisXiPt.binEdges)[0]);
225+
226+
o2::framework::AxisSpec axisV0Pt = cfgaxisPtV0;
227+
nV0PtBins = axisV0Pt.binEdges.size() - 1;
228+
fV0PtAxis = new TAxis(nV0PtBins, &(axisV0Pt.binEdges)[0]);
229+
230+
o2::framework::AxisSpec axisMult = axisMultiplicity;
231+
nMultBins = axisMult.binEdges.size() - 1;
232+
fMultAxis = new TAxis(nMultBins, &(axisMult.binEdges)[0]);
233+
234+
fOmegaMass = new TAxis(cfgOmegaMassbins, 1.63, 1.71);
235+
236+
fXiMass = new TAxis(cfgXiMassbins, 1.3, 1.37);
237+
238+
fK0sMass = new TAxis(cfgK0sMassbins, 0.4, 0.6);
239+
240+
fLambdaMass = new TAxis(cfgLambdaMassbins, 1.08, 1.16);
241+
221242
fGFW->AddRegion("reffull", -0.8, 0.8, 1, 1); // ("name", etamin, etamax, ptbinnum, bitmask)eta region -0.8 to 0.8
222243
// with (-0.5, 0.5) eta gap
223244
fGFW->AddRegion("refN10", -0.8, -0.5, 1, 1);

PWGLF/Tasks/Resonances/k892pmanalysis.cxx

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -352,9 +352,9 @@ struct k892pmanalysis {
352352
}
353353

354354
// apply the competing V0 rejection cut (excluding Lambda0 candidates, massLambdaPDG = 1115.683 MeV/c2)
355-
if (abs(v0.mLambda() - massLambda0) < cV0MassWindow)
355+
if (std::abs(v0.mLambda() - massLambda0) < cV0MassWindow)
356356
continue;
357-
if (abs(v0.mAntiLambda() - massAntiLambda0) < cV0MassWindow)
357+
if (std::abs(v0.mAntiLambda() - massAntiLambda0) < cV0MassWindow)
358358
continue;
359359

360360
if (!IsMix && !IsV0QAFilled) {
@@ -382,7 +382,7 @@ struct k892pmanalysis {
382382
}
383383

384384
// Checking whether the mid-rapidity condition is met
385-
if (abs(lResonance.Rapidity()) > 0.5) {
385+
if (std::abs(lResonance.Rapidity()) > 0.5) {
386386
continue;
387387
}
388388

@@ -401,7 +401,7 @@ struct k892pmanalysis {
401401
histos.fill(HIST("k892pmMassPtMult3d"), lResonance.M(), lResonance.Pt(), multiplicity);
402402
if constexpr (IsMC) {
403403
// LOG(info) << "track PDG:\t" << trk.pdgCode() << "\tV0 PDG:\t" << v0.pdgCode();
404-
if (abs(trk.pdgCode()) != 211 || abs(v0.pdgCode()) != 310) // Skip to next iteration if daughters are not charged pion + K0s/AntiK0s
404+
if (std::abs(trk.pdgCode()) != 211 || std::abs(v0.pdgCode()) != 310) // Skip to next iteration if daughters are not charged pion + K0s/AntiK0s
405405
continue;
406406
if (trk.motherPDG() != v0.motherPDG())
407407
continue;
@@ -444,17 +444,17 @@ struct k892pmanalysis {
444444
void processMCTrue(aod::ResoMCParents& resoParents)
445445
{
446446
for (auto& part : resoParents) { // loop over all pre-filtered MC particles
447-
if (abs(part.pdgCode()) != 323) // K*892(pm)
447+
if (std::abs(part.pdgCode()) != 323) // K*892(pm)
448448
continue;
449-
if (abs(part.y()) > 0.5) // rapidity cut
449+
if (std::abs(part.y()) > 0.5) // rapidity cut
450450
continue;
451451
bool pass1 = false;
452452
bool pass2 = false;
453453
/*// Sanity check: looking for K*0 resonances for sanity check
454-
if (abs(part.pdgCode()) == 323) {
454+
if (std::abs(part.pdgCode()) == 323) {
455455
LOG(info) << "Found charged K*: " << part.pdgCode() << ". Daughters' PDG are " << part.daughterPDG1() << " and " << part.daughterPDG2();
456456
}
457-
if (abs(part.pdgCode()) == 313) {
457+
if (std::abs(part.pdgCode()) == 313) {
458458
LOG(info) << "Found non-charged K*: " << part.pdgCode() << ". Daughters' PDG are " << part.daughterPDG1() << " and " << part.daughterPDG2();
459459
}*/
460460

@@ -466,11 +466,11 @@ struct k892pmanalysis {
466466
pass2 = true;
467467
histos.fill(HIST("hK892pmCounter"), 1.5);
468468
}
469-
/*if (abs(part.daughterPDG1()) == 211)
469+
/*if (std::abs(part.daughterPDG1()) == 211)
470470
histos.fill(HIST("hDaughterCounter"), 0.5);
471-
if (abs(part.daughterPDG2()) == 310)
471+
if (std::abs(part.daughterPDG2()) == 310)
472472
histos.fill(HIST("hDaughterCounter"), 1.5);
473-
if (abs(part.daughterPDG1()) == 211 && abs(part.daughterPDG2()) == 310)
473+
if (std::abs(part.daughterPDG1()) == 211 && std::abs(part.daughterPDG2()) == 310)
474474
histos.fill(HIST("hDaughterCounter"), 2.5);*/
475475
// if (!pass1 || !pass2) // Go on only if we have both decay products, else skip to next iteration
476476
if (!pass1 && !pass2) // Go on only if we have both decay products, else skip to next iteration

PWGLF/Tasks/Strangeness/CMakeLists.txt

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -118,3 +118,8 @@ o2physics_add_dpl_workflow(strange-yield-pbpb
118118
SOURCES strange-yield-pbpb.cxx
119119
PUBLIC_LINK_LIBRARIES O2Physics::AnalysisCore
120120
COMPONENT_NAME Analysis)
121+
122+
o2physics_add_dpl_workflow(lambdak0sflattenicity
123+
SOURCES lambdak0sflattenicity.cxx
124+
PUBLIC_LINK_LIBRARIES O2::Framework O2Physics::AnalysisCore
125+
COMPONENT_NAME Analysis)
File renamed without changes.

PWGMM/UE/Tasks/CMakeLists.txt

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,3 @@ o2physics_add_dpl_workflow(ue-zdc-analysis
1818
SOURCES ue-zdc-analysys.cxx
1919
PUBLIC_LINK_LIBRARIES O2::Framework O2Physics::AnalysisCore
2020
COMPONENT_NAME Analysis)
21-
22-
o2physics_add_dpl_workflow(ue-lambdak0sflattenicity
23-
SOURCES lambdak0sflattenicity.cxx
24-
PUBLIC_LINK_LIBRARIES O2::Framework O2Physics::AnalysisCore
25-
COMPONENT_NAME Analysis)

0 commit comments

Comments
 (0)