Skip to content

Commit a5ff4db

Browse files
authored
[PWGEM/PhotonMeson] update several photon tasks (#10520)
1 parent 46b20f6 commit a5ff4db

17 files changed

+111
-1263
lines changed

PWGEM/Dilepton/TableProducer/eventSelection.cxx

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -36,14 +36,14 @@ struct EMEventSelection {
3636

3737
// Configurables
3838
Configurable<int> cfgCentEstimator{"cfgCentEstimator", 2, "FT0M:0, FT0A:1, FT0C:2"};
39-
Configurable<float> cfgCentMin{"cfgCentMin", 0.f, "min. centrality"};
39+
Configurable<float> cfgCentMin{"cfgCentMin", -1.f, "min. centrality"};
4040
Configurable<float> cfgCentMax{"cfgCentMax", 999.f, "max. centrality"};
4141

42-
Configurable<float> cfgZvtxMax{"cfgZvtxMax", 10.f, "max. Zvtx"};
43-
Configurable<bool> cfgRequireSel8{"cfgRequireSel8", true, "require sel8 in event cut"};
44-
Configurable<bool> cfgRequireFT0AND{"cfgRequireFT0AND", true, "require FT0AND in event cut"};
45-
Configurable<bool> cfgRequireNoTFB{"cfgRequireNoTFB", true, "require No time frame border in event cut"};
46-
Configurable<bool> cfgRequireNoITSROFB{"cfgRequireNoITSROFB", true, "require no ITS readout frame border in event cut"};
42+
Configurable<float> cfgZvtxMax{"cfgZvtxMax", 1e+10, "max. Zvtx"};
43+
Configurable<bool> cfgRequireSel8{"cfgRequireSel8", false, "require sel8 in event cut"};
44+
Configurable<bool> cfgRequireFT0AND{"cfgRequireFT0AND", false, "require FT0AND in event cut"};
45+
Configurable<bool> cfgRequireNoTFB{"cfgRequireNoTFB", false, "require No time frame border in event cut"};
46+
Configurable<bool> cfgRequireNoITSROFB{"cfgRequireNoITSROFB", false, "require no ITS readout frame border in event cut"};
4747
Configurable<bool> cfgRequireNoSameBunchPileup{"cfgRequireNoSameBunchPileup", false, "require no same bunch pileup in event cut"};
4848
Configurable<bool> cfgRequireGoodZvtxFT0vsPV{"cfgRequireGoodZvtxFT0vsPV", false, "require good Zvtx between FT0 vs. PV in event cut"};
4949
Configurable<int> cfgTrackOccupancyMin{"cfgTrackOccupancyMin", -2, "min. track occupancy"};
@@ -63,7 +63,7 @@ struct EMEventSelection {
6363
}
6464
}
6565

66-
if (fabs(collision.posZ()) > cfgZvtxMax) {
66+
if (std::fabs(collision.posZ()) > cfgZvtxMax) {
6767
return false;
6868
}
6969

@@ -112,7 +112,7 @@ struct EMEventSelection {
112112
template <typename TCollisions>
113113
void processEventSelection(TCollisions const& collisions)
114114
{
115-
for (auto& collision : collisions) {
115+
for (const auto& collision : collisions) {
116116
emevsel(isSelectedEvent(collision));
117117
} // end of collision loop
118118
} // end of process

PWGEM/PhotonMeson/Core/Pi0EtaToGammaGamma.h

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@
2727
#include <tuple>
2828
#include <utility>
2929
#include <array>
30+
#include <algorithm>
3031

3132
#include "TString.h"
3233
#include "Math/Vector4D.h"
@@ -91,6 +92,7 @@ struct Pi0EtaToGammaGamma {
9192
Configurable<std::string> grpmagPath{"grpmagPath", "GLO/Config/GRPMagField", "CCDB path of the GRPMagField object"};
9293
Configurable<bool> skipGRPOquery{"skipGRPOquery", true, "skip grpo query"};
9394
Configurable<float> d_bz_input{"d_bz_input", -999, "bz field in kG, -999 is automatic"};
95+
Configurable<uint64_t> ndiff_bc_mix{"ndiff_bc_mix", 198, "difference in global BC required in mixed events"};
9496

9597
Configurable<int> cfgQvecEstimator{"cfgQvecEstimator", 0, "FT0M:0, FT0A:1, FT0C:2"};
9698
Configurable<int> cfgCentEstimator{"cfgCentEstimator", 2, "FT0M:0, FT0A:1, FT0C:2"};
@@ -263,6 +265,7 @@ struct Pi0EtaToGammaGamma {
263265
fRegistry.addClone("Pair/same/", "Pair/rotation/");
264266
emcalGeom = o2::emcal::Geometry::GetInstanceFromRunNumber(300000);
265267
}
268+
fRegistry.add("Pair/mix/hDiffBC", "diff. global BC in mixed event;|BC_{current} - BC_{mixed}|", kTH1D, {{10001, -0.5, 10000.5}}, true);
266269

267270
mRunNumber = 0;
268271
d_bz = 0;
@@ -323,6 +326,7 @@ struct Pi0EtaToGammaGamma {
323326
used_photonIds.shrink_to_fit();
324327
used_dileptonIds.clear();
325328
used_dileptonIds.shrink_to_fit();
329+
map_mixed_eventId_to_globalBC.clear();
326330
}
327331

328332
void DefineEMEventCut()
@@ -550,6 +554,7 @@ struct Pi0EtaToGammaGamma {
550554
MyEMH* emh2 = nullptr;
551555
std::vector<std::pair<int, int>> used_photonIds; // <ndf, trackId>
552556
std::vector<std::tuple<int, int, int, int>> used_dileptonIds; // <ndf, trackId>
557+
std::map<std::pair<int, int>, uint64_t> map_mixed_eventId_to_globalBC;
553558

554559
template <typename TCollisions, typename TPhotons1, typename TPhotons2, typename TSubInfos1, typename TSubInfos2, typename TPreslice1, typename TPreslice2, typename TCut1, typename TCut2>
555560
void runPairing(TCollisions const& collisions,
@@ -773,6 +778,13 @@ struct Pi0EtaToGammaGamma {
773778
continue;
774779
}
775780

781+
auto globalBC_mix = map_mixed_eventId_to_globalBC[mix_dfId_collisionId];
782+
uint64_t diffBC = std::max(collision.globalBC(), globalBC_mix) - std::min(collision.globalBC(), globalBC_mix);
783+
fRegistry.fill(HIST("Pair/mix/hDiffBC"), diffBC);
784+
if (diffBC < ndiff_bc_mix) {
785+
continue;
786+
}
787+
776788
auto photons1_from_event_pool = emh1->GetTracksPerCollision(mix_dfId_collisionId);
777789
// LOGF(info, "Do event mixing: current event (%d, %d), ngamma = %d | event pool (%d, %d), ngamma = %d", ndf, collision.globalIndex(), selected_photons1_in_this_event.size(), mix_dfId, mix_collisionId, photons1_from_event_pool.size());
778790

@@ -799,6 +811,13 @@ struct Pi0EtaToGammaGamma {
799811
continue;
800812
}
801813

814+
auto globalBC_mix = map_mixed_eventId_to_globalBC[mix_dfId_collisionId];
815+
uint64_t diffBC = std::max(collision.globalBC(), globalBC_mix) - std::min(collision.globalBC(), globalBC_mix);
816+
fRegistry.fill(HIST("Pair/mix/hDiffBC"), diffBC);
817+
if (diffBC < ndiff_bc_mix) {
818+
continue;
819+
}
820+
802821
auto photons2_from_event_pool = emh2->GetTracksPerCollision(mix_dfId_collisionId);
803822
// LOGF(info, "Do event mixing: current event (%d, %d), ngamma = %d | event pool (%d, %d), nll = %d", ndf, collision.globalIndex(), selected_photons1_in_this_event.size(), mix_dfId, mix_collisionId, photons2_from_event_pool.size());
804823

@@ -825,6 +844,13 @@ struct Pi0EtaToGammaGamma {
825844
continue;
826845
}
827846

847+
auto globalBC_mix = map_mixed_eventId_to_globalBC[mix_dfId_collisionId];
848+
uint64_t diffBC = std::max(collision.globalBC(), globalBC_mix) - std::min(collision.globalBC(), globalBC_mix);
849+
fRegistry.fill(HIST("Pair/mix/hDiffBC"), diffBC);
850+
if (diffBC < ndiff_bc_mix) {
851+
continue;
852+
}
853+
828854
auto photons1_from_event_pool = emh1->GetTracksPerCollision(mix_dfId_collisionId);
829855
// LOGF(info, "Do event mixing: current event (%d, %d), nll = %d | event pool (%d, %d), ngamma = %d", ndf, collision.globalIndex(), selected_photons2_in_this_event.size(), mix_dfId, mix_collisionId, photons1_from_event_pool.size());
830856

@@ -848,6 +874,7 @@ struct Pi0EtaToGammaGamma {
848874
if (ndiphoton > 0) {
849875
emh1->AddCollisionIdAtLast(key_bin, key_df_collision);
850876
emh2->AddCollisionIdAtLast(key_bin, key_df_collision);
877+
map_mixed_eventId_to_globalBC[key_df_collision] = collision.globalBC();
851878
}
852879

853880
} // end of collision loop

PWGEM/PhotonMeson/Core/TaggingPi0.h

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@
2727
#include <tuple>
2828
#include <utility>
2929
#include <array>
30+
#include <algorithm>
3031

3132
#include "TString.h"
3233
#include "Math/Vector4D.h"
@@ -85,6 +86,7 @@ struct TaggingPi0 {
8586
Configurable<std::string> grpmagPath{"grpmagPath", "GLO/Config/GRPMagField", "CCDB path of the GRPMagField object"};
8687
Configurable<bool> skipGRPOquery{"skipGRPOquery", true, "skip grpo query"};
8788
Configurable<float> d_bz_input{"d_bz_input", -999, "bz field in kG, -999 is automatic"};
89+
Configurable<uint64_t> ndiff_bc_mix{"ndiff_bc_mix", 198, "difference in global BC required in mixed events"};
8890

8991
Configurable<int> cfgQvecEstimator{"cfgQvecEstimator", 0, "FT0M:0, FT0A:1, FT0C:2"};
9092
Configurable<int> cfgCentEstimator{"cfgCentEstimator", 2, "FT0M:0, FT0A:1, FT0C:2"};
@@ -306,6 +308,7 @@ struct TaggingPi0 {
306308
used_photonIds.shrink_to_fit();
307309
used_dileptonIds.clear();
308310
used_dileptonIds.shrink_to_fit();
311+
map_mixed_eventId_to_globalBC.clear();
309312
}
310313

311314
void addHistogrms()
@@ -324,6 +327,7 @@ struct TaggingPi0 {
324327
fRegistry.add("Photon/hEtaPhi", "#varphi vs. #eta;#varphi_{#gamma} (rad.);#eta_{#gamma}", kTH2D, {{90, 0, 2 * M_PI}, {40, -1, +1}}, true);
325328
fRegistry.add("Pair/same/hMvsPt", "mass vs. p_{T,#gamma}", kTH2D, {axis_m, axis_pt}, true);
326329
fRegistry.addClone("Pair/same/", "Pair/mix/");
330+
fRegistry.add("Pair/mix/hDiffBC", "diff. global BC in mixed event;|BC_{current} - BC_{mixed}|", kTH1D, {{10001, -0.5, 10000.5}}, true);
327331
}
328332

329333
void DefineEMEventCut()
@@ -450,6 +454,7 @@ struct TaggingPi0 {
450454
MyEMH* emh2 = nullptr;
451455
std::vector<std::pair<int, int>> used_photonIds; // <ndf, trackId>
452456
std::vector<std::tuple<int, int, int, int>> used_dileptonIds; // <ndf, trackId>
457+
std::map<std::pair<int, int>, uint64_t> map_mixed_eventId_to_globalBC;
453458

454459
template <typename TCollisions, typename TPhotons1, typename TPhotons2, typename TSubInfos1, typename TSubInfos2, typename TPreslice1, typename TPreslice2, typename TCut1, typename TCut2>
455460
void runPairing(TCollisions const& collisions,
@@ -622,6 +627,13 @@ struct TaggingPi0 {
622627
continue;
623628
}
624629

630+
auto globalBC_mix = map_mixed_eventId_to_globalBC[mix_dfId_collisionId];
631+
uint64_t diffBC = std::max(collision.globalBC(), globalBC_mix) - std::min(collision.globalBC(), globalBC_mix);
632+
fRegistry.fill(HIST("Pair/mix/hDiffBC"), diffBC);
633+
if (diffBC < ndiff_bc_mix) {
634+
continue;
635+
}
636+
625637
auto photons2_from_event_pool = emh2->GetTracksPerCollision(mix_dfId_collisionId);
626638
// LOGF(info, "Do event mixing: current event (%d, %d), ngamma = %d | event pool (%d, %d), nll = %d", ndf, collision.globalIndex(), selected_photons1_in_this_event.size(), mix_dfId, mix_collisionId, photons2_from_event_pool.size());
627639

@@ -641,6 +653,7 @@ struct TaggingPi0 {
641653
if (ndiphoton > 0) {
642654
emh1->AddCollisionIdAtLast(key_bin, key_df_collision);
643655
emh2->AddCollisionIdAtLast(key_bin, key_df_collision);
656+
map_mixed_eventId_to_globalBC[key_df_collision] = collision.globalBC();
644657
}
645658

646659
} // end of collision loop

PWGEM/PhotonMeson/Core/TaggingPi0MC.h

Lines changed: 23 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -89,6 +89,7 @@ struct TaggingPi0MC {
8989
Configurable<int> cfgCentEstimator{"cfgCentEstimator", 2, "FT0M:0, FT0A:1, FT0C:2"};
9090
Configurable<float> cfgCentMin{"cfgCentMin", 0, "min. centrality"};
9191
Configurable<float> cfgCentMax{"cfgCentMax", 999, "max. centrality"};
92+
Configurable<std::string> fd_k0s_to_pi0{"fd_k0s_pi0", "1.0", "feed down correction to pi0"};
9293
Configurable<bool> cfgRequireTrueAssociation{"cfgRequireTrueAssociation", false, "flag to require true mc collision association"};
9394
ConfigurableAxis ConfPtBins{"ConfPtBins", {100, 0, 10}, "pT bins for output histograms"};
9495

@@ -207,6 +208,7 @@ struct TaggingPi0MC {
207208
Service<o2::ccdb::BasicCCDBManager> ccdb;
208209
int mRunNumber;
209210
float d_bz;
211+
TF1* f1fd_k0s_to_pi0;
210212

211213
void init(InitContext&)
212214
{
@@ -220,6 +222,7 @@ struct TaggingPi0MC {
220222

221223
mRunNumber = 0;
222224
d_bz = 0;
225+
f1fd_k0s_to_pi0 = new TF1("f1fd_k0s_to_pi0", TString(fd_k0s_to_pi0), 0.f, 100.f);
223226

224227
ccdb->setURL(ccdburl);
225228
ccdb->setCaching(true);
@@ -266,7 +269,11 @@ struct TaggingPi0MC {
266269
mRunNumber = collision.runNumber();
267270
}
268271

269-
~TaggingPi0MC() {}
272+
~TaggingPi0MC()
273+
{
274+
delete f1fd_k0s_to_pi0;
275+
f1fd_k0s_to_pi0 = 0x0;
276+
}
270277

271278
void addHistogrms()
272279
{
@@ -479,8 +486,14 @@ struct TaggingPi0MC {
479486
}
480487
}
481488
} else if (IsFromWD(g1mc.template emmcevent_as<TMCCollisions>(), g1mc, mcparticles) > 0) {
482-
fRegistry.fill(HIST("Photon/fromWD/hPt"), v_gamma.Pt(), collision.weight());
483-
fRegistry.fill(HIST("Photon/fromWD/hEtaPhi"), v_gamma.Phi() > 0 ? v_gamma.Phi() : v_gamma.Phi() + 2 * M_PI, v_gamma.Eta(), collision.weight());
489+
int motherid_strhad = IsFromWD(g1mc.template emmcevent_as<TMCCollisions>(), g1mc, mcparticles);
490+
auto str_had = mcparticles.iteratorAt(motherid_strhad);
491+
float weight = 1.f;
492+
if (std::abs(str_had.pdgCode()) == 310 && f1fd_k0s_to_pi0 != nullptr) {
493+
weight = f1fd_k0s_to_pi0->Eval(str_had.pt());
494+
}
495+
fRegistry.fill(HIST("Photon/fromWD/hPt"), v_gamma.Pt(), collision.weight() * weight);
496+
fRegistry.fill(HIST("Photon/fromWD/hEtaPhi"), v_gamma.Phi() > 0 ? v_gamma.Phi() : v_gamma.Phi() + 2 * M_PI, v_gamma.Eta(), collision.weight() * weight);
484497
} else {
485498
fRegistry.fill(HIST("Photon/fromHS/hPt"), v_gamma.Pt(), collision.weight());
486499
fRegistry.fill(HIST("Photon/fromHS/hEtaPhi"), v_gamma.Phi() > 0 ? v_gamma.Phi() : v_gamma.Phi() + 2 * M_PI, v_gamma.Eta(), collision.weight());
@@ -519,7 +532,13 @@ struct TaggingPi0MC {
519532
if (pi0mc.isPhysicalPrimary() || pi0mc.producedByGenerator()) {
520533
fRegistry.fill(HIST("Pair/primary/hMvsPt"), veeg.M(), v_gamma.Pt(), collision.weight());
521534
} else if (IsFromWD(pi0mc.template emmcevent_as<TMCCollisions>(), pi0mc, mcparticles) > 0) {
522-
fRegistry.fill(HIST("Pair/fromWD/hMvsPt"), veeg.M(), v_gamma.Pt(), collision.weight());
535+
int motherid_strhad = IsFromWD(pi0mc.template emmcevent_as<TMCCollisions>(), pi0mc, mcparticles);
536+
auto str_had = mcparticles.iteratorAt(motherid_strhad);
537+
float weight = 1.f;
538+
if (std::abs(str_had.pdgCode()) == 310 && f1fd_k0s_to_pi0 != nullptr) {
539+
weight = f1fd_k0s_to_pi0->Eval(str_had.pt());
540+
}
541+
fRegistry.fill(HIST("Pair/fromWD/hMvsPt"), veeg.M(), v_gamma.Pt(), collision.weight() * weight);
523542
} else {
524543
fRegistry.fill(HIST("Pair/fromHS/hMvsPt"), veeg.M(), v_gamma.Pt(), collision.weight());
525544
}

PWGEM/PhotonMeson/Core/V0PhotonCut.cxx

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -229,12 +229,6 @@ void V0PhotonCut::SetRequireTPCTOF(bool flag)
229229
LOG(info) << "V0 Photon Cut, require TPC-TOF track: " << mRequireTPCTOF;
230230
}
231231

232-
void V0PhotonCut::SetRequireTPCTRDTOF(bool flag)
233-
{
234-
mRequireTPCTRDTOF = flag;
235-
LOG(info) << "V0 Photon Cut, require TPC-TOF track: " << mRequireTPCTRDTOF;
236-
}
237-
238232
void V0PhotonCut::SetDisableITSonly(bool flag)
239233
{
240234
mDisableITSonly = flag;

PWGEM/PhotonMeson/Core/V0PhotonCut.h

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,6 @@ class V0PhotonCut : public TNamed
7070
kRequireTPConly,
7171
kRequireTPCTRD,
7272
kRequireTPCTOF,
73-
kRequireTPCTRDTOF,
7473
kNCuts
7574
};
7675

@@ -198,9 +197,6 @@ class V0PhotonCut : public TNamed
198197
if (mRequireTPCTOF && !IsSelectedTrack(track, V0PhotonCuts::kRequireTPCTOF)) {
199198
return false;
200199
}
201-
if (mRequireTPCTRDTOF && !IsSelectedTrack(track, V0PhotonCuts::kRequireTPCTRDTOF)) {
202-
return false;
203-
}
204200
}
205201
return true;
206202
}
@@ -429,9 +425,6 @@ class V0PhotonCut : public TNamed
429425
case V0PhotonCuts::kRequireTPCTOF:
430426
return isTPCTOFTrack(track);
431427

432-
case V0PhotonCuts::kRequireTPCTRDTOF:
433-
return isTPCTRDTOFTrack(track);
434-
435428
default:
436429
return false;
437430
}
@@ -477,7 +470,6 @@ class V0PhotonCut : public TNamed
477470
void SetRequireTPConly(bool flag);
478471
void SetRequireTPCTRD(bool flag);
479472
void SetRequireTPCTOF(bool flag);
480-
void SetRequireTPCTRDTOF(bool flag);
481473
void SetDisableITSonly(bool flag);
482474
void SetDisableTPConly(bool flag);
483475

@@ -529,7 +521,6 @@ class V0PhotonCut : public TNamed
529521
bool mRequireTPConly{false};
530522
bool mRequireTPCTRD{false};
531523
bool mRequireTPCTOF{false};
532-
bool mRequireTPCTRDTOF{false};
533524
bool mDisableITSonly{false};
534525
bool mDisableTPConly{false};
535526

PWGEM/PhotonMeson/TableProducer/associateMCinfoPhoton.cxx

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ using namespace o2::framework::expressions;
3333
using namespace o2::soa;
3434
using namespace o2::aod::pwgem::photonmeson::utils::mcutil;
3535

36-
using MyCollisionsMC = soa::Join<aod::Collisions, aod::McCollisionLabels, aod::EvSels>;
36+
using MyCollisionsMC = soa::Join<aod::Collisions, aod::McCollisionLabels, aod::EvSels, aod::EMEvSels>;
3737
using TracksMC = soa::Join<aod::TracksIU, aod::McTrackLabels>;
3838
using FwdTracksMC = soa::Join<aod::FwdTracks, aod::McFwdTrackLabels>;
3939
using MyEMCClusters = soa::Join<aod::SkimEMCClusters, aod::EMCClusterMCLabels>;
@@ -55,7 +55,6 @@ struct AssociateMCInfoPhoton {
5555

5656
Produces<o2::aod::BinnedGenPts> binnedGenPt;
5757

58-
Configurable<bool> applyEveSel_at_skimming{"applyEveSel_at_skimming", false, "flag to apply minimal event selection at the skimming level"};
5958
Configurable<float> max_eta_gen_secondary{"max_eta_gen_secondary", 0.9, "max eta to store generated information"};
6059
Configurable<float> margin_z_gen{"margin_z_gen", 15.f, "margin for Z of true photon conversion point to store generated information"};
6160
Configurable<float> max_rxy_gen{"max_rxy_gen", 100, "max rxy to store generated information"};
@@ -132,7 +131,7 @@ struct AssociateMCInfoPhoton {
132131
continue;
133132
}
134133

135-
if (applyEveSel_at_skimming && (!collision.selection_bit(o2::aod::evsel::kIsTriggerTVX) || !collision.selection_bit(o2::aod::evsel::kNoTimeFrameBorder) || !collision.selection_bit(o2::aod::evsel::kNoITSROFrameBorder))) {
134+
if (!collision.isSelected()) {
136135
continue;
137136
}
138137

PWGEM/PhotonMeson/TableProducer/createEMEventPhoton.cxx

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ using namespace o2::soa;
4040
using MyBCs = soa::Join<aod::BCsWithTimestamps, aod::BcSels>;
4141
using MyQvectors = soa::Join<aod::QvectorFT0CVecs, aod::QvectorFT0AVecs, aod::QvectorFT0MVecs, aod::QvectorBPosVecs, aod::QvectorBNegVecs, aod::QvectorBTotVecs>;
4242

43-
using MyCollisions = soa::Join<aod::Collisions, aod::EvSels, aod::Mults>;
43+
using MyCollisions = soa::Join<aod::Collisions, aod::EvSels, aod::EMEvSels, aod::Mults>;
4444
using MyCollisionsCent = soa::Join<MyCollisions, aod::CentFT0Ms, aod::CentFT0As, aod::CentFT0Cs>; // centrality table has dependency on multiplicity table.
4545
using MyCollisionsCentQvec = soa::Join<MyCollisionsCent, MyQvectors>;
4646

@@ -69,7 +69,6 @@ struct CreateEMEventPhoton {
6969
Configurable<std::string> grpmagPath{"grpmagPath", "GLO/Config/GRPMagField", "CCDB path of the GRPMagField object"};
7070
Configurable<bool> skipGRPOquery{"skipGRPOquery", true, "skip grpo query"};
7171
Configurable<double> dBzInput{"d_bz", -999, "bz field, -999 is automatic"};
72-
Configurable<bool> applyEveSelAtSkimming{"applyEveSel_at_skimming", false, "flag to apply minimal event selection at the skimming level"};
7372
Configurable<bool> needEMCTrigger{"needEMCTrigger", false, "flag to only save events which have kTVXinEMC trigger bit. To reduce PbPb derived data size"};
7473
Configurable<bool> needPHSTrigger{"needPHSTrigger", false, "flag to only save events which have kTVXinPHOS trigger bit. To reduce PbPb derived data size"};
7574
Configurable<bool> enableJJHistograms{"enableJJHistograms", false, "flag to fill JJ QA histograms for outlier rejection"};
@@ -143,7 +142,7 @@ struct CreateEMEventPhoton {
143142
auto bc = collision.template foundBC_as<TBCs>();
144143
initCCDB(bc);
145144

146-
if (applyEveSelAtSkimming && (!collision.selection_bit(o2::aod::evsel::kIsTriggerTVX) || !collision.selection_bit(o2::aod::evsel::kNoTimeFrameBorder) || !collision.selection_bit(o2::aod::evsel::kNoITSROFrameBorder))) {
145+
if (!collision.isSelected()) {
147146
continue;
148147
}
149148
if (needEMCTrigger && !collision.alias_bit(kTVXinEMC)) {
@@ -210,13 +209,13 @@ struct CreateEMEventPhoton {
210209
if (!collision.has_mcCollision()) {
211210
continue;
212211
}
212+
if (!collision.isSelected()) {
213+
continue;
214+
}
213215

214216
auto bc = collision.template foundBC_as<MyBCs>();
215217
initCCDB(bc);
216218

217-
if (applyEveSelAtSkimming && (!collision.selection_bit(o2::aod::evsel::kIsTriggerTVX) || !collision.selection_bit(o2::aod::evsel::kNoTimeFrameBorder) || !collision.selection_bit(o2::aod::evsel::kNoITSROFrameBorder))) {
218-
continue;
219-
}
220219
auto mcCollision = collision.mcCollision_as<MyJJCollisions>();
221220

222221
// Outlier rejection: Set weight to 0 for events with large pTJet/pTHard

0 commit comments

Comments
 (0)