Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 0 additions & 5 deletions PWGEM/Dilepton/Core/DielectronCut.cxx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright 2019-2020 CERN and copyright holders of ALICE O2.

Check failure on line 1 in PWGEM/Dilepton/Core/DielectronCut.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[doc/file]

Provide mandatory file documentation.
// See https://alice-o2.web.cern.ch/copyright for details of the copyright holders.
// All rights not expressly granted are reserved.
//
Expand All @@ -8,7 +8,7 @@
// In applying this license CERN does not waive the privileges and immunities
// granted to it by virtue of its status as an Intergovernmental Organization
// or submit itself to any jurisdiction.

Check failure on line 11 in PWGEM/Dilepton/Core/DielectronCut.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[doc/file]

Documentation for \author is missing, incorrect or misplaced.

Check failure on line 11 in PWGEM/Dilepton/Core/DielectronCut.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[doc/file]

Documentation for \brief is missing, incorrect or misplaced.

Check failure on line 11 in PWGEM/Dilepton/Core/DielectronCut.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[doc/file]

Documentation for \file is missing, incorrect or misplaced.
//
// Class for dielectron Cut
//
Expand All @@ -22,28 +22,28 @@

ClassImp(DielectronCut);

const std::pair<int8_t, std::set<uint8_t>> DielectronCut::its_ib_any_Requirement = {1, {0, 1, 2}}; // hits on any ITS ib layers.

Check failure on line 25 in PWGEM/Dilepton/Core/DielectronCut.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[name/function-variable]

Use lowerCamelCase for names of functions and variables.
const std::pair<int8_t, std::set<uint8_t>> DielectronCut::its_ib_1st_Requirement = {1, {0}}; // hit on 1st ITS ib layers.

Check failure on line 26 in PWGEM/Dilepton/Core/DielectronCut.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[name/function-variable]

Use lowerCamelCase for names of functions and variables.

void DielectronCut::SetPairPtRange(float minPt, float maxPt)

Check failure on line 28 in PWGEM/Dilepton/Core/DielectronCut.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[name/function-variable]

Use lowerCamelCase for names of functions and variables.
{
mMinPairPt = minPt;
mMaxPairPt = maxPt;
LOG(info) << "Dielectron Cut, set pair pt range: " << mMinPairPt << " - " << mMaxPairPt;
}
void DielectronCut::SetPairYRange(float minY, float maxY)

Check failure on line 34 in PWGEM/Dilepton/Core/DielectronCut.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[name/function-variable]

Use lowerCamelCase for names of functions and variables.
{
mMinPairY = minY;
mMaxPairY = maxY;
LOG(info) << "Dielectron Cut, set pair y range: " << mMinPairY << " - " << mMaxPairY;
}
void DielectronCut::SetPairDCARange(float min, float max)

Check failure on line 40 in PWGEM/Dilepton/Core/DielectronCut.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[name/function-variable]

Use lowerCamelCase for names of functions and variables.
{
mMinPairDCA3D = min;
mMaxPairDCA3D = max;
LOG(info) << "Dielectron Cut, set pair 3d dca range: " << mMinPairDCA3D << " - " << mMaxPairDCA3D;
}
void DielectronCut::SetMeeRange(float min, float max)

Check failure on line 46 in PWGEM/Dilepton/Core/DielectronCut.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[name/function-variable]

Use lowerCamelCase for names of functions and variables.
{
mMinMee = min;
mMaxMee = max;
Expand Down Expand Up @@ -324,11 +324,6 @@
// LOG(info) << "Dielectron Cut, set p range for ITS n sigma Pr: " << mMinP_ITSNsigmaPr << " - " << mMaxP_ITSNsigmaPr;
// }

void DielectronCut::SetMaxPinMuonTPConly(float max)
{
mMaxPinMuonTPConly = max;
LOG(info) << "Dielectron Cut, set max pin for Muon ID with TPC only: " << mMaxPinMuonTPConly;
}
void DielectronCut::SetPinRangeForPionRejectionTPC(float min, float max)
{
mMinPinForPionRejectionTPC = min;
Expand Down
28 changes: 11 additions & 17 deletions PWGEM/Dilepton/Core/DielectronCut.h
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ class DielectronCut : public TNamed
kDCAz,
kITSNCls,
kITSChi2NDF,
// kITSClusterSize,
kITSClusterSize,
kPrefilter,
kNCuts
};
Expand Down Expand Up @@ -199,9 +199,9 @@ class DielectronCut : public TNamed
return false;
}

// if (!IsSelectedTrack(track, DielectronCuts::kITSClusterSize)) {
// return false;
// }
if (!IsSelectedTrack(track, DielectronCuts::kITSClusterSize)) {
return false;
}

if (mRequireITSibAny) {
auto hits_ib = std::count_if(its_ib_any_Requirement.second.begin(), its_ib_any_Requirement.second.end(), [&](auto&& requiredLayer) { return track.itsClusterMap() & (1 << requiredLayer); });
Expand Down Expand Up @@ -252,15 +252,8 @@ class DielectronCut : public TNamed
}

// PID cuts
if (track.hasITS() && !track.hasTPC() && !track.hasTRD() && !track.hasTOF()) { // ITSsa
float meanClusterSizeITS = track.meanClusterSizeITS() * std::cos(std::atan(track.tgl()));
if (meanClusterSizeITS < mMinMeanClusterSizeITS || mMaxMeanClusterSizeITS < meanClusterSizeITS) {
return false;
}
} else { // not ITSsa
if (!PassPID(track)) {
return false;
}
if (!PassPID(track)) {
return false;
}

return true;
Expand Down Expand Up @@ -399,8 +392,8 @@ class DielectronCut : public TNamed
bool is_in_phi_range = track.phi() > mMinTrackPhi && track.phi() < mMaxTrackPhi;
return mRejectTrackPhi ? !is_in_phi_range : is_in_phi_range;
} else {
double minTrackPhiMirror = mMinTrackPhi + TMath::Pi();
double maxTrackPhiMirror = mMaxTrackPhi + TMath::Pi();
float minTrackPhiMirror = mMinTrackPhi + M_PI;
float maxTrackPhiMirror = mMaxTrackPhi + M_PI;
bool is_in_phi_range = (track.phi() > mMinTrackPhi && track.phi() < mMaxTrackPhi) || (track.phi() > minTrackPhiMirror && track.phi() < maxTrackPhiMirror);
return mRejectTrackPhi ? !is_in_phi_range : is_in_phi_range;
}
Expand Down Expand Up @@ -438,6 +431,9 @@ class DielectronCut : public TNamed
case DielectronCuts::kITSChi2NDF:
return mMinChi2PerClusterITS < track.itsChi2NCl() && track.itsChi2NCl() < mMaxChi2PerClusterITS;

case DielectronCuts::kITSClusterSize:
return mMinMeanClusterSizeITS < track.meanClusterSizeITS() * std::cos(std::atan(track.tgl())) && track.meanClusterSizeITS() * std::cos(std::atan(track.tgl())) < mMaxMeanClusterSizeITS;

case DielectronCuts::kPrefilter:
return track.pfb() <= 0;

Expand Down Expand Up @@ -494,7 +490,6 @@ class DielectronCut : public TNamed
// void SetPRangeForITSNsigmaKa(float min, float max);
// void SetPRangeForITSNsigmaPr(float min, float max);

void SetMaxPinMuonTPConly(float max);
void SetPinRangeForPionRejectionTPC(float min, float max);
void RequireITSibAny(bool flag);
void RequireITSib1st(bool flag);
Expand Down Expand Up @@ -560,7 +555,6 @@ class DielectronCut : public TNamed
float mMinRelDiffPin{-1e10f}, mMaxRelDiffPin{1e10f}; // max relative difference between p at TPC inner wall and p at PV
int mMinNClustersITS{0}, mMaxNClustersITS{7}; // range in number of ITS clusters
float mMinChi2PerClusterITS{-1e10f}, mMaxChi2PerClusterITS{1e10f}; // max its fit chi2 per ITS cluster
float mMaxPinMuonTPConly{0.2f}; // max pin cut for muon ID with TPConly
float mMinPinForPionRejectionTPC{0.f}, mMaxPinForPionRejectionTPC{1e10f}; // pin range for pion rejection in TPC
bool mRequireITSibAny{true};
bool mRequireITSib1st{false};
Expand Down
Loading