Skip to content
Merged
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
17 changes: 11 additions & 6 deletions PWGLF/Tasks/Nuspex/spectraTOF.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 PWGLF/Tasks/Nuspex/spectraTOF.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[name/workflow-file]

Name of a workflow file must match the name of the main struct in it (without the PWG prefix). (Class implementation files should be in "Core" directories.)
// See https://alice-o2.web.cern.ch/copyright for details of the copyright holders.
// All rights not expressly granted are reserved.
//
Expand Down Expand Up @@ -127,8 +127,10 @@

struct : ConfigurableGroup {
Configurable<float> cfgCutEtaMax{"cfgCutEtaMax", 0.8f, "Max eta range for tracks"};
Configurable<float> cfgCutdcaZMax{"cfgCutdcaZMax", 0.02f, "Max dcaZ range for tracks"};
Configurable<float> cfgCutNsigma{"cfgCutNsigma", 100.0f, "nsigma cut range for tracks"};
Configurable<float> cfgCutEtaMin{"cfgCutEtaMin", -0.8f, "Min eta range for tracks"};
Configurable<float> cfgCutdcaZMin{"cfgCutdcaZMin", -0.02f, "Min dcaZ range for tracks"};
Configurable<float> cfgCutY{"cfgCutY", 0.5f, "Y range for tracks"};
Configurable<int> lastRequiredTrdCluster{"lastRequiredTrdCluster", 5, "Last cluster to require in TRD for track selection. -1 does not require any TRD cluster"};
Configurable<bool> requireTrdOnly{"requireTrdOnly", false, "Require only tracks from TRD"};
Expand Down Expand Up @@ -175,7 +177,7 @@
Configurable<float> minChi2PerClusterTPC{"minChi2PerClusterTPC", 0.5f, "Additional cut on the minimum value of the chi2 per cluster in the TPC"};
Configurable<float> maxChi2PerClusterITS{"maxChi2PerClusterITS", 36.f, "Additional cut on the maximum value of the chi2 per cluster in the ITS"};
Configurable<float> maxDcaXYFactor{"maxDcaXYFactor", 1.f, "Additional cut on the maximum value of the DCA xy (multiplicative factor)"};
Configurable<float> maxDcaZ{"maxDcaZ", 2.f, "Additional cut on the maximum value of the DCA z"};
Configurable<float> maxDcaZ{"maxDcaZ", 0.02f, "Additional cut on the maximum value of the DCA z"};
Configurable<float> minTPCNClsFound{"minTPCNClsFound", 100.f, "Additional cut on the minimum value of the number of found clusters in the TPC"};
Configurable<bool> makeTHnSparseChoice{"makeTHnSparseChoice", false, "choose if produce thnsparse"}; // RD
Configurable<bool> enableTPCTOFvsEtaHistograms{"enableTPCTOFvsEtaHistograms", false, "choose if produce TPC tof vs Eta"};
Expand Down Expand Up @@ -263,7 +265,7 @@
LOG(info) << "\tminITSnClusters=" << minITSnClusters.value;
LOG(info) << "\tminTPCNClsFound=" << minTPCNClsFound.value;
LOG(info) << "\tmaxChi2PerClusterITS=" << maxChi2PerClusterITS.value;
LOG(info) << "\tmaxDcaZ=" << maxDcaZ.value;
LOG(info) << "\tmaxDcaZ=" << maxDcaZ;
LOG(info) << "\tmakeTHnSparseChoice=" << makeTHnSparseChoice.value;

customTrackCuts = getGlobalTrackSelectionRun3ITSMatch(itsPattern.value);
Expand All @@ -278,7 +280,7 @@
customTrackCuts.SetMinNClustersTPC(minTPCNClsFound.value);
customTrackCuts.SetMinNCrossedRowsOverFindableClustersTPC(minNCrossedRowsOverFindableClustersTPC.value);
customTrackCuts.SetMaxDcaXYPtDep([](float /*pt*/) { return 10000.f; }); // No DCAxy cut will be used, this is done via the member function of the task
customTrackCuts.SetMaxDcaZ(maxDcaZ.value);
customTrackCuts.SetMaxDcaZ(maxDcaZ);
customTrackCuts.print();
}
// Histograms
Expand Down Expand Up @@ -757,7 +759,7 @@
if (enableDCAxyzHistograms) {
hDcaXYZ[i] = histos.add<TH3>(Form("dca/%s/%s", (i < Np) ? "pos" : "neg", pN[i % Np]), pTCharge[i], kTH3D, {ptAxis, dcaXyAxis, dcaZAxis});
} else {
histos.add(hdcaxy[i].data(), pTCharge[i], kTH2D, {ptAxis, dcaXyAxis});
histos.add(hdcaxy[i].data(), pTCharge[i], kTH3D, {ptAxis, dcaXyAxis, multAxis});
histos.add(hdcaz[i].data(), pTCharge[i], kTH2D, {ptAxis, dcaZAxis});
}

Expand Down Expand Up @@ -1127,15 +1129,15 @@
}
} else {
if (track.sign() > 0) {
histos.fill(HIST(hdcaxy[id]), track.pt(), track.dcaXY());
histos.fill(HIST(hdcaxy[id]), track.pt(), track.dcaXY(), multiplicity);
histos.fill(HIST(hdcaz[id]), track.pt(), track.dcaZ());
if (isInPtRangeForPhi) {
if (enableDCAxyphiHistograms) {
histos.fill(HIST(hdcaxyphi[id]), track.phi(), track.dcaXY());
}
}
} else {
histos.fill(HIST(hdcaxy[id + Np]), track.pt(), track.dcaXY());
histos.fill(HIST(hdcaxy[id + Np]), track.pt(), track.dcaXY(), multiplicity);
histos.fill(HIST(hdcaz[id + Np]), track.pt(), track.dcaZ());
if (isInPtRangeForPhi) {
if (enableDCAxyphiHistograms) {
Expand Down Expand Up @@ -1305,6 +1307,9 @@
if (track.eta() < trkselOptions.cfgCutEtaMin || track.eta() > trkselOptions.cfgCutEtaMax) {
return false;
}
if (track.dcaZ() < trkselOptions.cfgCutdcaZMin || track.dcaZ() > trkselOptions.cfgCutdcaZMax) {
return false;
}
if constexpr (fillHistograms) {
histos.fill(HIST("tracksel"), 2);
if (enableTrackCutHistograms) {
Expand Down Expand Up @@ -1527,7 +1532,7 @@
continue;
}
// trackwoCut++;
if (std::abs(track.dcaXY()) > 0.05) { // Skipping tracks that don't pass the standard cuts

Check failure on line 1535 in PWGLF/Tasks/Nuspex/spectraTOF.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[magic-number]

Avoid magic numbers in expressions. Assign the value to a clearly named variable or constant.
return;
}

Expand Down Expand Up @@ -2657,7 +2662,7 @@
continue;
}
}
if (evselOptions.cfgINELCut.value == 2) {

Check failure on line 2665 in PWGLF/Tasks/Nuspex/spectraTOF.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[magic-number]

Avoid magic numbers in expressions. Assign the value to a clearly named variable or constant.
if (!o2::pwglf::isINELgt1mc(particlesInCollision, pdgDB)) {
continue;
}
Expand Down
Loading