Skip to content

Commit f5b8a69

Browse files
committed
PWGEM/Dilepton: update electron and event table
1 parent af983df commit f5b8a69

23 files changed

+531
-2493
lines changed

PWGEM/Dilepton/Core/DielectronCut.h

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -258,14 +258,15 @@ class DielectronCut : public TNamed
258258
}
259259

260260
template <typename TTrack, typename TCollision>
261-
bool PassPIDML(TTrack const& track, TCollision const& collision) const
261+
bool PassPIDML(TTrack const&, TCollision const&) const
262262
{
263+
return false;
263264
/*if (!PassTOFif(track)) { // Allows for pre-selection. But potentially dangerous if analyzers are not aware of it
264265
return false;
265266
}*/
266-
std::vector<float> inputFeatures = mPIDMlResponse->getInputFeatures(track, collision);
267-
float binningFeature = mPIDMlResponse->getBinningFeature(track, collision);
268-
return mPIDMlResponse->isSelectedMl(inputFeatures, binningFeature);
267+
// std::vector<float> inputFeatures = mPIDMlResponse->getInputFeatures(track, collision);
268+
// float binningFeature = mPIDMlResponse->getBinningFeature(track, collision);
269+
// return mPIDMlResponse->isSelectedMl(inputFeatures, binningFeature);
269270
}
270271

271272
template <typename T>

PWGEM/Dilepton/Core/Dilepton.h

Lines changed: 10 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ using MyCollision = MyCollisions::iterator;
7575
using MyCollisionsWithSWT = soa::Join<aod::EMEvents, aod::EMEventsMult, aod::EMEventsCent, aod::EMEventsQvec, aod::EMSWTriggerInfos>;
7676
using MyCollisionWithSWT = MyCollisionsWithSWT::iterator;
7777

78-
using MyElectrons = soa::Join<aod::EMPrimaryElectrons, aod::EMPrimaryElectronsCov, aod::EMPrimaryElectronEMEventIds, aod::EMAmbiguousElectronSelfIds, aod::EMPrimaryElectronsPrefilterBit, aod::EMPrimaryElectronsPrefilterBitDerived>;
78+
using MyElectrons = soa::Join<aod::EMPrimaryElectrons, aod::EMPrimaryElectronEMEventIds, aod::EMAmbiguousElectronSelfIds, aod::EMPrimaryElectronsPrefilterBit, aod::EMPrimaryElectronsPrefilterBitDerived>;
7979
using MyElectron = MyElectrons::iterator;
8080
using FilteredMyElectrons = soa::Filtered<MyElectrons>;
8181
using FilteredMyElectron = FilteredMyElectrons::iterator;
@@ -85,7 +85,7 @@ using MyMuon = MyMuons::iterator;
8585
using FilteredMyMuons = soa::Filtered<MyMuons>;
8686
using FilteredMyMuon = FilteredMyMuons::iterator;
8787

88-
using MyEMH_electron = o2::aod::pwgem::dilepton::utils::EventMixingHandler<std::tuple<int, int, int, int>, std::pair<int, int>, EMTrackWithCov>;
88+
using MyEMH_electron = o2::aod::pwgem::dilepton::utils::EventMixingHandler<std::tuple<int, int, int, int>, std::pair<int, int>, EMTrack>;
8989
using MyEMH_muon = o2::aod::pwgem::dilepton::utils::EventMixingHandler<std::tuple<int, int, int, int>, std::pair<int, int>, EMFwdTrack>;
9090

9191
template <o2::aod::pwgem::dilepton::utils::pairutil::DileptonPairType pairtype, typename TEMH, typename... Types>
@@ -1081,27 +1081,19 @@ struct Dilepton {
10811081
used_trackIds.emplace_back(pair_tmp_id1);
10821082
if (cfgDoMix) {
10831083
if (t1.sign() > 0) {
1084-
emh_pos->AddTrackToEventPool(key_df_collision, EMTrackWithCov(ndf, t1.globalIndex(), collision.globalIndex(), t1.trackId(), t1.pt(), t1.eta(), t1.phi(), leptonM1, t1.sign(), t1.dcaXY(), t1.dcaZ(), possibleIds1,
1085-
t1.x(), t1.y(), t1.z(), t1.alpha(), t1.snp(), t1.tgl(), t1.cYY(), t1.cZY(), t1.cZZ(),
1086-
t1.cSnpY(), t1.cSnpZ(), t1.cSnpSnp(), t1.cTglY(), t1.cTglZ(), t1.cTglSnp(), t1.cTglTgl(), t1.c1PtY(), t1.c1PtZ(), t1.c1PtSnp(), t1.c1PtTgl(), t1.c1Pt21Pt2()));
1084+
emh_pos->AddTrackToEventPool(key_df_collision, EMTrack(ndf, t1.globalIndex(), collision.globalIndex(), t1.trackId(), t1.pt(), t1.eta(), t1.phi(), leptonM1, t1.sign(), t1.dcaXY(), t1.dcaZ(), possibleIds1, t1.cYY(), t1.cZY(), t1.cZZ()));
10871085
} else {
1088-
emh_neg->AddTrackToEventPool(key_df_collision, EMTrackWithCov(ndf, t1.globalIndex(), collision.globalIndex(), t1.trackId(), t1.pt(), t1.eta(), t1.phi(), leptonM1, t1.sign(), t1.dcaXY(), t1.dcaZ(), possibleIds1,
1089-
t1.x(), t1.y(), t1.z(), t1.alpha(), t1.snp(), t1.tgl(), t1.cYY(), t1.cZY(), t1.cZZ(),
1090-
t1.cSnpY(), t1.cSnpZ(), t1.cSnpSnp(), t1.cTglY(), t1.cTglZ(), t1.cTglSnp(), t1.cTglTgl(), t1.c1PtY(), t1.c1PtZ(), t1.c1PtSnp(), t1.c1PtTgl(), t1.c1Pt21Pt2()));
1086+
emh_neg->AddTrackToEventPool(key_df_collision, EMTrack(ndf, t1.globalIndex(), collision.globalIndex(), t1.trackId(), t1.pt(), t1.eta(), t1.phi(), leptonM1, t1.sign(), t1.dcaXY(), t1.dcaZ(), possibleIds1, t1.cYY(), t1.cZY(), t1.cZZ()));
10911087
}
10921088
}
10931089
}
10941090
if (std::find(used_trackIds.begin(), used_trackIds.end(), pair_tmp_id2) == used_trackIds.end()) {
10951091
used_trackIds.emplace_back(pair_tmp_id2);
10961092
if (cfgDoMix) {
10971093
if (t2.sign() > 0) {
1098-
emh_pos->AddTrackToEventPool(key_df_collision, EMTrackWithCov(ndf, t2.globalIndex(), collision.globalIndex(), t2.trackId(), t2.pt(), t2.eta(), t2.phi(), leptonM2, t2.sign(), t2.dcaXY(), t2.dcaZ(), possibleIds2,
1099-
t2.x(), t2.y(), t2.z(), t2.alpha(), t2.snp(), t2.tgl(), t2.cYY(), t2.cZY(), t2.cZZ(),
1100-
t2.cSnpY(), t2.cSnpZ(), t2.cSnpSnp(), t2.cTglY(), t2.cTglZ(), t2.cTglSnp(), t2.cTglTgl(), t2.c1PtY(), t2.c1PtZ(), t2.c1PtSnp(), t2.c1PtTgl(), t2.c1Pt21Pt2()));
1094+
emh_pos->AddTrackToEventPool(key_df_collision, EMTrack(ndf, t2.globalIndex(), collision.globalIndex(), t2.trackId(), t2.pt(), t2.eta(), t2.phi(), leptonM2, t2.sign(), t2.dcaXY(), t2.dcaZ(), possibleIds2, t2.cYY(), t2.cZY(), t2.cZZ()));
11011095
} else {
1102-
emh_neg->AddTrackToEventPool(key_df_collision, EMTrackWithCov(ndf, t2.globalIndex(), collision.globalIndex(), t2.trackId(), t2.pt(), t2.eta(), t2.phi(), leptonM2, t2.sign(), t2.dcaXY(), t2.dcaZ(), possibleIds2,
1103-
t2.x(), t2.y(), t2.z(), t2.alpha(), t2.snp(), t2.tgl(), t2.cYY(), t2.cZY(), t2.cZZ(),
1104-
t2.cSnpY(), t2.cSnpZ(), t2.cSnpSnp(), t2.cTglY(), t2.cTglZ(), t2.cTglSnp(), t2.cTglTgl(), t2.c1PtY(), t2.c1PtZ(), t2.c1PtSnp(), t2.c1PtTgl(), t2.c1Pt21Pt2()));
1096+
emh_neg->AddTrackToEventPool(key_df_collision, EMTrack(ndf, t2.globalIndex(), collision.globalIndex(), t2.trackId(), t2.pt(), t2.eta(), t2.phi(), leptonM2, t2.sign(), t2.dcaXY(), t2.dcaZ(), possibleIds2, t2.cYY(), t2.cZY(), t2.cZZ()));
11051097
}
11061098
}
11071099
}
@@ -1113,10 +1105,10 @@ struct Dilepton {
11131105
used_trackIds.emplace_back(pair_tmp_id1);
11141106
if (cfgDoMix) {
11151107
if (t1.sign() > 0) {
1116-
emh_pos->AddTrackToEventPool(key_df_collision, EMFwdTrack(ndf, t1.globalIndex(), collision.globalIndex(), t1.fwdtrackId(), t1.pt(), t1.eta(), t1.phi(), o2::constants::physics::MassMuon, t1.sign(), t1.fwdDcaX(), t1.fwdDcaY(), possibleIds1,
1108+
emh_pos->AddTrackToEventPool(key_df_collision, EMFwdTrack(ndf, t1.globalIndex(), collision.globalIndex(), t1.fwdtrackId(), t1.pt(), t1.eta(), t1.phi(), leptonM1, t1.sign(), t1.fwdDcaX(), t1.fwdDcaY(), possibleIds1,
11171109
t1.cXXatDCA(), t1.cXYatDCA(), t1.cYYatDCA()));
11181110
} else {
1119-
emh_neg->AddTrackToEventPool(key_df_collision, EMFwdTrack(ndf, t1.globalIndex(), collision.globalIndex(), t1.fwdtrackId(), t1.pt(), t1.eta(), t1.phi(), o2::constants::physics::MassMuon, t1.sign(), t1.fwdDcaX(), t1.fwdDcaY(), possibleIds1,
1111+
emh_neg->AddTrackToEventPool(key_df_collision, EMFwdTrack(ndf, t1.globalIndex(), collision.globalIndex(), t1.fwdtrackId(), t1.pt(), t1.eta(), t1.phi(), leptonM1, t1.sign(), t1.fwdDcaX(), t1.fwdDcaY(), possibleIds1,
11201112
t1.cXXatDCA(), t1.cXYatDCA(), t1.cYYatDCA()));
11211113
}
11221114
}
@@ -1125,10 +1117,10 @@ struct Dilepton {
11251117
used_trackIds.emplace_back(pair_tmp_id2);
11261118
if (cfgDoMix) {
11271119
if (t2.sign() > 0) {
1128-
emh_pos->AddTrackToEventPool(key_df_collision, EMFwdTrack(ndf, t2.globalIndex(), collision.globalIndex(), t2.fwdtrackId(), t2.pt(), t2.eta(), t2.phi(), o2::constants::physics::MassMuon, t2.sign(), t2.fwdDcaX(), t2.fwdDcaY(), possibleIds2,
1120+
emh_pos->AddTrackToEventPool(key_df_collision, EMFwdTrack(ndf, t2.globalIndex(), collision.globalIndex(), t2.fwdtrackId(), t2.pt(), t2.eta(), t2.phi(), leptonM2, t2.sign(), t2.fwdDcaX(), t2.fwdDcaY(), possibleIds2,
11291121
t2.cXXatDCA(), t2.cXYatDCA(), t2.cYYatDCA()));
11301122
} else {
1131-
emh_neg->AddTrackToEventPool(key_df_collision, EMFwdTrack(ndf, t2.globalIndex(), collision.globalIndex(), t2.fwdtrackId(), t2.pt(), t2.eta(), t2.phi(), o2::constants::physics::MassMuon, t2.sign(), t2.fwdDcaX(), t2.fwdDcaY(), possibleIds2,
1123+
emh_neg->AddTrackToEventPool(key_df_collision, EMFwdTrack(ndf, t2.globalIndex(), collision.globalIndex(), t2.fwdtrackId(), t2.pt(), t2.eta(), t2.phi(), leptonM2, t2.sign(), t2.fwdDcaX(), t2.fwdDcaY(), possibleIds2,
11321124
t2.cXXatDCA(), t2.cXYatDCA(), t2.cYYatDCA()));
11331125
}
11341126
}

PWGEM/Dilepton/Core/DileptonHadronMPC.h

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ using MyCollision = MyCollisions::iterator;
7777
using MyCollisionsWithSWT = soa::Join<aod::EMEvents, aod::EMEventsMult, aod::EMEventsCent, aod::EMSWTriggerInfos>;
7878
using MyCollisionWithSWT = MyCollisionsWithSWT::iterator;
7979

80-
using MyElectrons = soa::Join<aod::EMPrimaryElectrons, aod::EMPrimaryElectronsCov, aod::EMPrimaryElectronEMEventIds, aod::EMAmbiguousElectronSelfIds, aod::EMPrimaryElectronsPrefilterBit, aod::EMPrimaryElectronsPrefilterBitDerived>;
80+
using MyElectrons = soa::Join<aod::EMPrimaryElectrons, aod::EMPrimaryElectronEMEventIds, aod::EMAmbiguousElectronSelfIds, aod::EMPrimaryElectronsPrefilterBit, aod::EMPrimaryElectronsPrefilterBitDerived>;
8181
using MyElectron = MyElectrons::iterator;
8282
using FilteredMyElectrons = soa::Filtered<MyElectrons>;
8383
using FilteredMyElectron = FilteredMyElectrons::iterator;
@@ -111,7 +111,7 @@ struct DileptonHadronMPC {
111111
Configurable<float> cfgCentMax{"cfgCentMax", 999.f, "max. centrality"};
112112
Configurable<bool> cfgDoMix{"cfgDoMix", true, "flag for event mixing"};
113113
Configurable<int> ndepth_lepton{"ndepth_lepton", 100, "depth for event mixing between lepton-lepton"};
114-
Configurable<int> ndepth_hadron{"ndepth_hadron", 2, "depth for event mixing between hadron-hadron"};
114+
Configurable<int> ndepth_hadron{"ndepth_hadron", 1, "depth for event mixing between hadron-hadron"};
115115
Configurable<uint64_t> ndiff_bc_mix{"ndiff_bc_mix", 594, "difference in global BC required in mixed events"};
116116
ConfigurableAxis ConfVtxBins{"ConfVtxBins", {VARIABLE_WIDTH, -10.0f, -8.f, -6.f, -4.f, -2.f, 0.f, 2.f, 4.f, 6.f, 8.f, 10.f}, "Mixing bins - z-vertex"};
117117
ConfigurableAxis ConfCentBins{"ConfCentBins", {VARIABLE_WIDTH, 0.0f, 0.1, 1, 5.0f, 10.0f, 20.0f, 30.0f, 40.0f, 50.0f, 60.0f, 70.0f, 80.0f, 90.0f, 100.f, 999.f}, "Mixing bins - centrality"};
@@ -513,7 +513,7 @@ struct DileptonHadronMPC {
513513
const AxisSpec axis_deta{ConfDEtaBins, deta_axis_title};
514514

515515
// hadron-hadron info
516-
const AxisSpec axis_deta_hh{ConfDEtaBins, "#Delta#eta = #eta_{h}^{trg} - #eta_{h}^{ref}"};
516+
const AxisSpec axis_deta_hh{60, -3, +3, "#Delta#eta = #eta_{h}^{trg} - #eta_{h}^{ref}"};
517517

518518
const AxisSpec axis_pt_trg{ConfPtHadronBins, "p_{T,h} (GeV/c)"};
519519
const AxisSpec axis_eta_trg{40, -2, +2, "#eta_{h}"};
@@ -1114,11 +1114,6 @@ struct DileptonHadronMPC {
11141114
fRegistry.fill(HIST("Event/after/hCollisionCounter"), o2::aod::pwgem::dilepton::utils::eventhistogram::nbin_ev); // accepted
11151115

11161116
auto refTracks_per_coll = refTracks.sliceBy(perCollision_track, collision.globalIndex());
1117-
for (const auto& track : refTracks_per_coll) {
1118-
if (fEMTrackCut.IsSelected(track)) {
1119-
fRegistry.fill(HIST("Hadron/hs"), track.pt(), track.eta(), track.phi());
1120-
}
1121-
}
11221117

11231118
auto posTracks_per_coll = posTracks.sliceByCached(perCollision, collision.globalIndex(), cache);
11241119
auto negTracks_per_coll = negTracks.sliceByCached(perCollision, collision.globalIndex(), cache);
@@ -1154,6 +1149,11 @@ struct DileptonHadronMPC {
11541149
}
11551150

11561151
if (nuls > 0 || nlspp > 0 || nlsmm > 0) { // at least 1 pair exists.
1152+
for (const auto& track : refTracks_per_coll) {
1153+
if (fEMTrackCut.IsSelected(track)) {
1154+
fRegistry.fill(HIST("Hadron/hs"), track.pt(), track.eta(), track.phi());
1155+
}
1156+
}
11571157
for (const auto& [trg, ref] : combinations(CombinationsStrictlyUpperIndexPolicy(refTracks_per_coll, refTracks_per_coll))) {
11581158
fillHadronHadron<0>(collision, trg, ref, posTracks_per_coll, negTracks_per_coll);
11591159
}
@@ -1251,6 +1251,7 @@ struct DileptonHadronMPC {
12511251
if (cfgAnalysisType == static_cast<int>(o2::aod::pwgem::dilepton::utils::pairutil::DileptonHadronAnalysisType::kAzimuthalCorrelation)) {
12521252
auto selected_refTracks_in_this_event = emh_ref->GetTracksPerCollision(key_df_collision);
12531253
auto collisionIds_in_mixing_pool_hadron = emh_ref->GetCollisionIdsFromEventPool(key_bin);
1254+
12541255
for (const auto& mix_dfId_collisionId : collisionIds_in_mixing_pool_hadron) {
12551256
int mix_dfId = mix_dfId_collisionId.first;
12561257
int mix_collisionId = mix_dfId_collisionId.second;

PWGEM/Dilepton/Core/DileptonMC.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ using MyCollision = MyCollisions::iterator;
6767
using MyMCCollisions = soa::Join<aod::EMMCEvents, aod::MostProbableEMEventIdsInMC>;
6868
using MyMCCollision = MyMCCollisions::iterator;
6969

70-
using MyMCElectrons = soa::Join<aod::EMPrimaryElectrons, aod::EMPrimaryElectronsCov, aod::EMPrimaryElectronEMEventIds, aod::EMAmbiguousElectronSelfIds, aod::EMPrimaryElectronsPrefilterBit, aod::EMPrimaryElectronsPrefilterBitDerived, aod::EMPrimaryElectronMCLabels>;
70+
using MyMCElectrons = soa::Join<aod::EMPrimaryElectrons, aod::EMPrimaryElectronEMEventIds, aod::EMAmbiguousElectronSelfIds, aod::EMPrimaryElectronsPrefilterBit, aod::EMPrimaryElectronsPrefilterBitDerived, aod::EMPrimaryElectronMCLabels>;
7171
using MyMCElectron = MyMCElectrons::iterator;
7272
using FilteredMyMCElectrons = soa::Filtered<MyMCElectrons>;
7373
using FilteredMyMCElectron = FilteredMyMCElectrons::iterator;

PWGEM/Dilepton/Core/EMEventCut.cxx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ void EMEventCut::SetRequireVertexITSTPC(bool flag)
6565
void EMEventCut::SetRequireVertexTOFmatched(bool flag)
6666
{
6767
mRequireVertexTOFmatched = flag;
68-
LOG(info) << "EM Event Cut, require vertex reconstructed by ITS-TPC matched track: " << mRequireVertexTOFmatched;
68+
LOG(info) << "EM Event Cut, require vertex reconstructed by ITS-TPC-TOF matched track: " << mRequireVertexTOFmatched;
6969
}
7070

7171
void EMEventCut::SetRequireGoodZvtxFT0vsPV(bool flag)

PWGEM/Dilepton/Core/PhotonHBT.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ using MyCollisionWithSWT = MyCollisionsWithSWT::iterator;
8080
using MyV0Photons = soa::Join<aod::V0PhotonsKF, aod::V0KFEMEventIds>;
8181
using MyV0Photon = MyV0Photons::iterator;
8282

83-
using MyTracks = soa::Join<aod::EMPrimaryElectrons, aod::EMPrimaryElectronsCov, aod::EMPrimaryElectronEMEventIds, aod::EMAmbiguousElectronSelfIds, aod::EMPrimaryElectronsPrefilterBit>;
83+
using MyTracks = soa::Join<aod::EMPrimaryElectrons, aod::EMPrimaryElectronEMEventIds, aod::EMAmbiguousElectronSelfIds, aod::EMPrimaryElectronsPrefilterBit>;
8484
using MyTrack = MyTracks::iterator;
8585
using FilteredMyTracks = soa::Filtered<MyTracks>;
8686
using FilteredMyTrack = FilteredMyTracks::iterator;

PWGEM/Dilepton/Core/SingleTrackQC.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ using MyCollision = MyCollisions::iterator;
5858
using MyCollisionsWithSWT = soa::Join<aod::EMEvents, aod::EMEventsMult, aod::EMEventsCent, aod::EMEventsQvec, aod::EMSWTriggerInfos>;
5959
using MyCollisionWithSWT = MyCollisionsWithSWT::iterator;
6060

61-
using MyElectrons = soa::Join<aod::EMPrimaryElectrons, aod::EMPrimaryElectronsCov, aod::EMPrimaryElectronEMEventIds, aod::EMAmbiguousElectronSelfIds, aod::EMPrimaryElectronsPrefilterBit>;
61+
using MyElectrons = soa::Join<aod::EMPrimaryElectrons, aod::EMPrimaryElectronEMEventIds, aod::EMAmbiguousElectronSelfIds, aod::EMPrimaryElectronsPrefilterBit>;
6262
using MyElectron = MyElectrons::iterator;
6363
using FilteredMyElectrons = soa::Filtered<MyElectrons>;
6464
using FilteredMyElectron = FilteredMyElectrons::iterator;

PWGEM/Dilepton/Core/SingleTrackQCMC.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ using MyCollision = MyCollisions::iterator;
6060
using MyMCCollisions = soa::Join<aod::EMMCEvents, aod::MostProbableEMEventIdsInMC>;
6161
using MyMCCollision = MyMCCollisions::iterator;
6262

63-
using MyMCElectrons = soa::Join<aod::EMPrimaryElectrons, aod::EMPrimaryElectronsCov, aod::EMPrimaryElectronEMEventIds, aod::EMAmbiguousElectronSelfIds, aod::EMPrimaryElectronsPrefilterBit, aod::EMPrimaryElectronMCLabels>;
63+
using MyMCElectrons = soa::Join<aod::EMPrimaryElectrons, aod::EMPrimaryElectronEMEventIds, aod::EMAmbiguousElectronSelfIds, aod::EMPrimaryElectronsPrefilterBit, aod::EMPrimaryElectronMCLabels>;
6464
using MyMCElectron = MyMCElectrons::iterator;
6565
using FilteredMyMCElectrons = soa::Filtered<MyMCElectrons>;
6666

0 commit comments

Comments
 (0)