Skip to content

Commit 8c84725

Browse files
committed
Please consider the following formatting changes
1 parent 1bdaf36 commit 8c84725

File tree

2 files changed

+43
-55
lines changed

2 files changed

+43
-55
lines changed

PWGHF/HFC/TableProducer/correlatorHfeHadrons.cxx

Lines changed: 41 additions & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,6 @@ struct HfCorrelatorHfeHadrons {
9494

9595
{"hptElectron", "hptElectron", {HistType::kTH1F, {{100, 0, 100}}}},
9696

97-
9897
{"hMixEventInclusiveEHCorrl", "Sparse for mix event Delta phi and Delta eta Inclusive Electron with Hadron;p_{T}^{e} (GeV#it{/c});p_{T}^{h} (GeV#it{/c});#Delta#varphi;#Delta#eta;", hCorrelSpec},
9998
{"hMixEventLSEHCorrel", "Sparse for mix event Delta phi and Delta eta Like sign Electron pair with Hadron;p_{T}^{e} (GeV#it{/c});p_{T}^{h} (GeV#it{/c});#Delta#varphi;#Delta#eta;", hCorrelSpec},
10099
{"hMixEventULSEHCorrel", "Sparse for mix event Delta phi and Delta eta Unlike sign Electron pair with Hadron;p_{T}^{e} (GeV#it{/c});p_{T}^{h} (GeV#it{/c});#Delta#varphi;#Delta#eta;", hCorrelSpec},
@@ -383,7 +382,6 @@ struct HfCorrelatorHfeHadrons {
383382
auto tracksTuple = std::make_tuple(electrons, mcParticles);
384383
Pair<McGenTableCollisions, aod::HfMcGenSelEl, aod::McParticles, BinningTypeMcGen> pairMcGen{corrBinningMcGen, 5, -1, mcCollision, tracksTuple, &cache};
385384

386-
387385
// loop over the rows of the new table
388386
double ptElectronMix = -999;
389387
double phiElectronMix = -999;
@@ -423,50 +421,48 @@ struct HfCorrelatorHfeHadrons {
423421
registry.fill(HIST("hMixEventMcGenInclusiveEHCorrl"), ptElectronMix, ptHadronMix, deltaPhiMix, deltaEtaMix);
424422
}
425423

426-
427-
// loop over the rows of the new table
428-
double ptElectronMix = -999;
429-
double phiElectronMix = -999;
430-
double etaElectronMix = -999;
431-
double deltaPhiMix = -999;
432-
double deltaEtaMix = -999;
433-
double ptHadronMix = -999;
434-
double etaHadronMix = -999;
435-
double phiHadronMix = -999;
436-
for (const auto& [c1, tracks1, c2, tracks2] : pairMcGen) {
437-
int poolBin = corrBinningMcGen.getBin(std::make_tuple(c1.posZ(), c1.multMCFT0A()));
438-
for (const auto& [t1, t2] : combinations(CombinationsFullIndexPolicy(tracks1, tracks2))) {
439-
ptHadronMix = t2.pt();
440-
ptElectronMix = t1.ptTrackMc();
441-
phiElectronMix = t1.phiTrackMc();
442-
phiHadronMix = t2.phi();
443-
etaElectronMix = t1.etaTrackMc();
444-
etaHadronMix = t2.eta();
445-
if (t2.eta() < etaTrackMin || t2.eta() > etaTrackMax) {
446-
continue;
447-
}
448-
if (t2.pt() < ptTrackMin) {
449-
continue;
450-
}
451-
if (ptCondition && (ptElectronMix < ptHadronMix)) {
452-
continue;
453-
}
454-
455-
deltaPhiMix = RecoDecay::constrainAngle(phiElectronMix - phiHadronMix, -o2::constants::math::PIHalf);
456-
deltaEtaMix = etaElectronMix - etaHadronMix;
457-
bool isNonHfeCorr = false;
458-
if (t1.isNonHfeMc()) {
459-
isNonHfeCorr = true;
460-
registry.fill(HIST("hMixEventMcGenNonHfEHCorrl"), ptElectronMix, ptHadronMix, deltaPhiMix, deltaEtaMix);
461-
} else {
462-
463-
registry.fill(HIST("hMixEventMcGenInclusiveEHCorrl"), ptElectronMix, ptHadronMix, deltaPhiMix, deltaEtaMix);
424+
// loop over the rows of the new table
425+
double ptElectronMix = -999;
426+
double phiElectronMix = -999;
427+
double etaElectronMix = -999;
428+
double deltaPhiMix = -999;
429+
double deltaEtaMix = -999;
430+
double ptHadronMix = -999;
431+
double etaHadronMix = -999;
432+
double phiHadronMix = -999;
433+
for (const auto& [c1, tracks1, c2, tracks2] : pairMcGen) {
434+
int poolBin = corrBinningMcGen.getBin(std::make_tuple(c1.posZ(), c1.multMCFT0A()));
435+
for (const auto& [t1, t2] : combinations(CombinationsFullIndexPolicy(tracks1, tracks2))) {
436+
ptHadronMix = t2.pt();
437+
ptElectronMix = t1.ptTrackMc();
438+
phiElectronMix = t1.phiTrackMc();
439+
phiHadronMix = t2.phi();
440+
etaElectronMix = t1.etaTrackMc();
441+
etaHadronMix = t2.eta();
442+
if (t2.eta() < etaTrackMin || t2.eta() > etaTrackMax) {
443+
continue;
444+
}
445+
if (t2.pt() < ptTrackMin) {
446+
continue;
447+
}
448+
if (ptCondition && (ptElectronMix < ptHadronMix)) {
449+
continue;
450+
}
451+
452+
deltaPhiMix = RecoDecay::constrainAngle(phiElectronMix - phiHadronMix, -o2::constants::math::PIHalf);
453+
deltaEtaMix = etaElectronMix - etaHadronMix;
454+
bool isNonHfeCorr = false;
455+
if (t1.isNonHfeMc()) {
456+
isNonHfeCorr = true;
457+
registry.fill(HIST("hMixEventMcGenNonHfEHCorrl"), ptElectronMix, ptHadronMix, deltaPhiMix, deltaEtaMix);
458+
} else {
459+
460+
registry.fill(HIST("hMixEventMcGenInclusiveEHCorrl"), ptElectronMix, ptHadronMix, deltaPhiMix, deltaEtaMix);
461+
}
462+
463+
entryElectronHadronPairmcGen(deltaPhiMix, deltaEtaMix, ptElectronMix, ptHadronMix, poolBin, isNonHfeCorr);
464+
}
464465
}
465-
466-
467-
entryElectronHadronPairmcGen(deltaPhiMix, deltaEtaMix, ptElectronMix, ptHadronMix, poolBin, isNonHfeCorr);
468-
}
469-
}
470466
}
471467
PROCESS_SWITCH(HfCorrelatorHfeHadrons, processMcGenMixedEvent, "Process Mixed Event MC Gen mode", false);
472468
};

PWGHF/HFL/TableProducer/electronSelectionWithTpcEmcal.cxx

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,6 @@ const int passEMCalBins = 3;
4747
const int passEMCalAxisMin = 0.;
4848
const int passEMCalAxisMax = 3;
4949

50-
5150
const int eopAxisBins = 60;
5251
const float eopAxisMin = 0.;
5352
const float eopAxisMax = 3.0;
@@ -100,7 +99,6 @@ struct HfElectronSelectionWithTpcEmcal {
10099
Configurable<float> invariantMass{"invariantMass", 0.14f, "max Invariant Mass for Photonic electron"};
101100
Configurable<float> chiSquareMax{"chiSquareMax", 3.0f, "chiSquare on the reconstructed parent particle"};
102101

103-
104102
// EtMcal and Dcal selection cut
105103

106104
// EMcal and Dcal selection cut
@@ -180,8 +178,8 @@ struct HfElectronSelectionWithTpcEmcal {
180178
HistogramRegistry registry{
181179
"registry",
182180
{{"hNevents", "No of events", {HistType::kTH1F, {{3, 1, 4}}}},
183-
<
184-
{"hZvertex", "z vertex", {HistType::kTH1F, {{binsPosZ}}}},
181+
<
182+
{"hZvertex", "z vertex", {HistType::kTH1F, {{binsPosZ}}}},
185183
{"hLikeMass", "Like mass", {HistType::kTH1F, {{binsMass}}}},
186184
{"hUnLikeMass", "unLike mass", {HistType::kTH1F, {{binsMass}}}},
187185
{"hLikeSignPt", "Like sign Momentum ", {HistType::kTH1F, {{binsP}}}},
@@ -350,7 +348,6 @@ struct HfElectronSelectionWithTpcEmcal {
350348
continue;
351349
}
352350

353-
354351
if (std::sqrt(std::abs(chi2recg)) > chiSquareMax) {
355352
continue;
356353
}
@@ -374,8 +371,6 @@ struct HfElectronSelectionWithTpcEmcal {
374371
}
375372
}
376373

377-
378-
379374
if (std::sqrt(std::abs(chi2recg)) > chiSquareMax) {
380375
continue;
381376
}
@@ -399,7 +394,6 @@ struct HfElectronSelectionWithTpcEmcal {
399394
}
400395
}
401396

402-
403397
// for like charge
404398
if (isLSElectron && (invMassElectron <= invariantMass)) {
405399
massLike = invMassElectron;
@@ -679,11 +673,9 @@ struct HfElectronSelectionWithTpcEmcal {
679673
}
680674
}
681675

682-
683676
PROCESS_SWITCH(HfElectronSelectionWithTpcEmcal, processMcGen, "Process MC Gen mode", false);
684677
=======
685678
PROCESS_SWITCH(HfElectronSelectionWithTpcEmcal, processMcGen, "Process MC Gen mode", true);
686-
687679
};
688680

689681
WorkflowSpec defineDataProcessing(ConfigContext const& cfgc)

0 commit comments

Comments
 (0)