You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Configurable<bool> cfVertexZSwitch{"cfVertexZSwitch", false, "switch to apply vertex z position cut"};
161
-
Configurable<std::vector<float>> cfVertexZ{"cfVertexZ", {-10, 10.}, "vertex z position range: {min, max}[cm], with convention: min <= Vz < max"};
162
-
Configurable<bool> cfPtSwitch{"cfPtSwitch", false, "switch to apply pt cut"};
163
-
Configurable<std::vector<float>> cfPt{"cfPt", {0.2, 5.}, "pt cut range: {min, max}, with convention: min <= Vz < max"};
160
+
// event level cuts
161
+
Configurable<bool> cfEventCutSwitch{"cfEventCutSwitch", false, "switch to apply vertex z position cut"};
162
+
Configurable<std::vector<float>> cfVertexZCutRange{"cfVertexZCutRange", {-10, 10.}, "vertex z position range: {min, max}[cm], with convention: min <= Vz < max"};
163
+
164
+
// particle level cuts
165
+
Configurable<bool> cfPtCutSwitch{"cfPtCutSwitch", false, "switch to apply pt cut"};
166
+
Configurable<std::vector<float>> cfPtCutRange{"cfPtCutRange", {0.2, 5.}, "pt cut range: {min, max}, with convention: min <= Vz < max"};
164
167
165
168
// misc
166
169
Configurable<double> sigmaInel{"sigmaInel", 7.71, "inelastic cross section in mb"};
@@ -377,20 +380,20 @@ struct MultiparticleCorrelationsMei // this name is used in lower-case format to
377
380
booleventCuts(T1const& collision)
378
381
{
379
382
ifconstexpr (rs == ERec || rs == ERecAndSim) {
380
-
if (cfVertexZSwitch) //Vertex Z cuts for Rec
383
+
if (cfEventCutSwitch) //event level cuts for Rec
381
384
{
382
-
if (collision.posZ() > cfVertexZ.value[1] || collision.posZ() < cfVertexZ.value[0]) {
385
+
if (collision.posZ() > cfVertexZCutRange.value[1] || collision.posZ() < cfVertexZCutRange.value[0]) {
383
386
returnfalse;
384
-
}
385
-
ifconstexpr (rs == ERecAndSim) //Vertex Z cuts for Sim
387
+
}// vertex z cut
388
+
ifconstexpr (rs == ERecAndSim) //event level cuts for Sim
386
389
{
387
390
if (!collision.has_mcCollision()) {
388
391
returnfalse;
389
392
}
390
393
auto mcCollision = collision.mcCollision(); // corresponding MC truth simulated particle
391
-
if (mcCollision.posZ() > cfVertexZ.value[1] || mcCollision.posZ() < cfVertexZ.value[0]) {
394
+
if (mcCollision.posZ() > cfVertexZCutRange.value[1] || mcCollision.posZ() < cfVertexZCutRange.value[0]) {
392
395
returnfalse;
393
-
}
396
+
}// vertex z cut
394
397
}
395
398
}
396
399
}
@@ -493,12 +496,12 @@ struct MultiparticleCorrelationsMei // this name is used in lower-case format to
493
496
}
494
497
495
498
template <ERecSim rs, typename T>
496
-
boolparticlECuts(T const& track)
499
+
boolparticleCuts(T const& track)
497
500
{
498
501
ifconstexpr (rs == ERec || rs == ERecAndSim) {
499
-
if (cfPtSwitch) // Vertex Z cuts for Rec
502
+
if (cfPtCutSwitch) // Vertex Z cuts for Rec
500
503
{
501
-
if (track.pt() < cfPt.value[0] || track.pt() > cfPt.value[1]) {
504
+
if (track.pt() < cfPtCutRange.value[0] || track.pt() > cfPtCutRange.value[1]) {
502
505
returnfalse;
503
506
}
504
507
ifconstexpr (rs == ERecAndSim) // Vertex Z cuts for Sim
@@ -507,7 +510,7 @@ struct MultiparticleCorrelationsMei // this name is used in lower-case format to
507
510
returnfalse;
508
511
}
509
512
auto mcParticle = track.mcParticle(); // corresponding MC truth simulated particle
510
-
if (mcParticle.pt() < cfPt.value[0] || mcParticle.pt() > cfPt.value[1]) {
513
+
if (mcParticle.pt() < cfPtCutRange.value[0] || mcParticle.pt() > cfPtCutRange.value[1]) {
511
514
returnfalse;
512
515
}
513
516
}
@@ -605,7 +608,7 @@ struct MultiparticleCorrelationsMei // this name is used in lower-case format to
605
608
606
609
// Fill Event Hist
607
610
eventHistFill<rs, ENoCuts>(collision, tracks);
608
-
if (eventCuts<rs>(collision)) {
611
+
if (cfEventCutSwitch && eventCuts<rs>(collision)) {
609
612
eventHistFill<rs, EWithCuts>(collision, tracks);
610
613
}
611
614
@@ -627,7 +630,7 @@ struct MultiparticleCorrelationsMei // this name is used in lower-case format to
627
630
track = tracks.iteratorAt(i);
628
631
// Fill reconstructed ...:
629
632
particleHistFill<rs, ENoCuts>(track);
630
-
if (eventCuts<rs>(collision) && particlECuts<rs>(track)) {
633
+
if (cfPtCutSwitch && cfEventCutSwitch && eventCuts<rs>(collision) && particleCuts<rs>(track)) {
631
634
particleHistFill<rs, EWithCuts>(track);
632
635
}
633
636
} // end of for (int64_t i = 0; i < tracks.size(); i++) {
@@ -702,7 +705,7 @@ struct MultiparticleCorrelationsMei // this name is used in lower-case format to
pc.fParticleHistograms[EHistPt][ERec][EWithCuts] = newTH1F("[EHistPt][ERec][EWithCuts]", "pt distribution for reconstructed particles after cuts", nBinsPt, minPt, maxPt);
pc.fParticleHistograms[EHistPt][ESim][EWithCuts] = newTH1F("[EHistPt][ESim][EWithCuts]", "pt distribution for simulated particles after cuts", nBinsPt, minPt, maxPt);
0 commit comments