Skip to content

Commit d21f330

Browse files
authored
[PWGEM/Dilepton] change order of track selection (#16575)
1 parent b53c699 commit d21f330

1 file changed

Lines changed: 13 additions & 13 deletions

File tree

PWGEM/Dilepton/Utils/ElectronModule.h

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -697,6 +697,10 @@ class ElectronModule
697697
void fillMapMLPID(TCollision const& collision, TTrack const& track)
698698
{
699699
if (fElectronCut.usePIDML) {
700+
if (!isElectron_TOFif(track, collision, fElectronCut)) { // minimal n sigma cut is taken from the main electron cut.
701+
return;
702+
}
703+
700704
o2::dataformats::DCA mDcaInfoCov;
701705
mDcaInfoCov.set(999, 999, 999, 999, 999);
702706
auto trackParCov = getTrackParCov(track);
@@ -706,10 +710,6 @@ class ElectronModule
706710
return;
707711
}
708712

709-
if (!isElectron_TOFif(track, collision, fElectronCut)) { // minimal n sigma cut is taken from the main electron cut.
710-
return;
711-
}
712-
713713
o2::analysis::pwgem::dilepton::mlpid::candidate candidate;
714714
candidate.tpcInnerParam = track.tpcInnerParam();
715715
candidate.tpcNClsFound = track.tpcNClsFound();
@@ -726,7 +726,7 @@ class ElectronModule
726726
}
727727
candidate.meanClusterSizeITSobCosTgl = static_cast<float>(total_cluster_size_ob) / static_cast<float>(nl_ob) * std::cos(std::atan(trackParCov.getTgl()));
728728

729-
std::vector<float> inputFeatures = mlResponsePID.getInputFeatures(candidate);
729+
auto inputFeatures = mlResponsePID.getInputFeatures(candidate);
730730
float binningFeature = mlResponsePID.getBinningFeature(candidate);
731731

732732
int pbin = lower_bound(fElectronCut.binsMl.value.begin(), fElectronCut.binsMl.value.end(), binningFeature) - fElectronCut.binsMl.value.begin() - 1;
@@ -1671,7 +1671,7 @@ class ElectronModule
16711671
candidate.signedMassLH = electron.sign() * hadron.sign() * eTpair.mass;
16721672
candidate.tpcNSigmaKa = hadron.tpcNSigmaKa();
16731673

1674-
std::vector<float> inputFeatures = mlResponseSCTeT.getInputFeatures(candidate);
1674+
auto inputFeatures = mlResponseSCTeT.getInputFeatures(candidate);
16751675
float binningFeature = mlResponseSCTeT.getBinningFeature(candidate);
16761676

16771677
int pbin = lower_bound(fConfigDFeT.binsMl.value.begin(), fConfigDFeT.binsMl.value.end(), binningFeature) - fConfigDFeT.binsMl.value.begin() - 1;
@@ -1721,7 +1721,7 @@ class ElectronModule
17211721
candidate.ptL = trackParCov.getPt();
17221722
candidate.massH = o2::constants::physics::MassK0Short;
17231723

1724-
std::vector<float> inputFeatures = mlResponseSCTeV0.getInputFeatures(candidate);
1724+
auto inputFeatures = mlResponseSCTeV0.getInputFeatures(candidate);
17251725
float binningFeature = mlResponseSCTeV0.getBinningFeature(candidate);
17261726

17271727
int pbin = lower_bound(fConfigDFeV0.binsMl.value.begin(), fConfigDFeV0.binsMl.value.end(), binningFeature) - fConfigDFeV0.binsMl.value.begin() - 1;
@@ -1772,7 +1772,7 @@ class ElectronModule
17721772
candidate.ptL = trackParCov.getPt();
17731773
candidate.massH = o2::constants::physics::MassLambda;
17741774

1775-
std::vector<float> inputFeatures = mlResponseSCTeV0.getInputFeatures(candidate);
1775+
auto inputFeatures = mlResponseSCTeV0.getInputFeatures(candidate);
17761776
float binningFeature = mlResponseSCTeV0.getBinningFeature(candidate);
17771777

17781778
int pbin = lower_bound(fConfigDFeV0.binsMl.value.begin(), fConfigDFeV0.binsMl.value.end(), binningFeature) - fConfigDFeV0.binsMl.value.begin() - 1;
@@ -1823,7 +1823,7 @@ class ElectronModule
18231823
candidate.ptL = trackParCov.getPt();
18241824
candidate.massH = o2::constants::physics::MassXiMinus;
18251825

1826-
std::vector<float> inputFeatures = mlResponseSCTeC.getInputFeatures(candidate);
1826+
auto inputFeatures = mlResponseSCTeC.getInputFeatures(candidate);
18271827
float binningFeature = mlResponseSCTeC.getBinningFeature(candidate);
18281828

18291829
int pbin = lower_bound(fConfigDFeC.binsMl.value.begin(), fConfigDFeC.binsMl.value.end(), binningFeature) - fConfigDFeC.binsMl.value.begin() - 1;
@@ -1874,7 +1874,7 @@ class ElectronModule
18741874
candidate.ptL = trackParCov.getPt();
18751875
candidate.massH = o2::constants::physics::MassOmegaMinus;
18761876

1877-
std::vector<float> inputFeatures = mlResponseSCTeC.getInputFeatures(candidate);
1877+
auto inputFeatures = mlResponseSCTeC.getInputFeatures(candidate);
18781878
float binningFeature = mlResponseSCTeC.getBinningFeature(candidate);
18791879

18801880
int pbin = lower_bound(fConfigDFeC.binsMl.value.begin(), fConfigDFeC.binsMl.value.end(), binningFeature) - fConfigDFeC.binsMl.value.begin() - 1;
@@ -1925,7 +1925,7 @@ class ElectronModule
19251925
candidate.ptL = trackParCov.getPt();
19261926
candidate.massH = o2::constants::physics::MassLambda;
19271927

1928-
std::vector<float> inputFeatures = mlResponseSCTeV0.getInputFeatures(candidate);
1928+
auto inputFeatures = mlResponseSCTeV0.getInputFeatures(candidate);
19291929
float binningFeature = mlResponseSCTeV0.getBinningFeature(candidate);
19301930

19311931
int pbin = lower_bound(fConfigDFeV0.binsMl.value.begin(), fConfigDFeV0.binsMl.value.end(), binningFeature) - fConfigDFeV0.binsMl.value.begin() - 1;
@@ -1976,7 +1976,7 @@ class ElectronModule
19761976
candidate.ptL = trackParCov.getPt();
19771977
candidate.massH = o2::constants::physics::MassXiMinus;
19781978

1979-
std::vector<float> inputFeatures = mlResponseSCTeC.getInputFeatures(candidate);
1979+
auto inputFeatures = mlResponseSCTeC.getInputFeatures(candidate);
19801980
float binningFeature = mlResponseSCTeC.getBinningFeature(candidate);
19811981

19821982
int pbin = lower_bound(fConfigDFeC.binsMl.value.begin(), fConfigDFeC.binsMl.value.end(), binningFeature) - fConfigDFeC.binsMl.value.begin() - 1;
@@ -2027,7 +2027,7 @@ class ElectronModule
20272027
candidate.ptL = trackParCov.getPt();
20282028
candidate.massH = o2::constants::physics::MassOmegaMinus;
20292029

2030-
std::vector<float> inputFeatures = mlResponseSCTeC.getInputFeatures(candidate);
2030+
auto inputFeatures = mlResponseSCTeC.getInputFeatures(candidate);
20312031
float binningFeature = mlResponseSCTeC.getBinningFeature(candidate);
20322032

20332033
int pbin = lower_bound(fConfigDFeC.binsMl.value.begin(), fConfigDFeC.binsMl.value.end(), binningFeature) - fConfigDFeC.binsMl.value.begin() - 1;

0 commit comments

Comments
 (0)