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
10 changes: 8 additions & 2 deletions PWGCF/TwoParticleCorrelations/DataModel/LongRangeDerived.h
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@

namespace lrcorrmctrktable
{
DECLARE_SOA_INDEX_COLUMN(LRMcCollision, lrMcCollision);

Check failure on line 48 in PWGCF/TwoParticleCorrelations/DataModel/LongRangeDerived.h

View workflow job for this annotation

GitHub Actions / O2 linter

[name/o2-column]

Use UpperCamelCase for names of O2 columns and matching lowerCamelCase names for their getters.
DECLARE_SOA_COLUMN(Pt, pt, float);
DECLARE_SOA_COLUMN(Eta, eta, float);
DECLARE_SOA_COLUMN(Phi, phi, float);
Expand Down Expand Up @@ -88,7 +88,7 @@

namespace lrcorrcolltable
{
DECLARE_SOA_INDEX_COLUMN(LRMcCollision, lrMcCollision);

Check failure on line 91 in PWGCF/TwoParticleCorrelations/DataModel/LongRangeDerived.h

View workflow job for this annotation

GitHub Actions / O2 linter

[name/o2-column]

Use UpperCamelCase for names of O2 columns and matching lowerCamelCase names for their getters.
DECLARE_SOA_COLUMN(Multiplicity, multiplicity, float);
DECLARE_SOA_COLUMN(Centrality, centrality, float);
DECLARE_SOA_COLUMN(TotalFT0AmplitudeA, totalFT0AmplitudeA, float); //! sum of amplitudes on A side of FT0
Expand Down Expand Up @@ -142,7 +142,7 @@

namespace lrcorrtrktable
{
DECLARE_SOA_INDEX_COLUMN(LRCollision, lrCollision);

Check failure on line 145 in PWGCF/TwoParticleCorrelations/DataModel/LongRangeDerived.h

View workflow job for this annotation

GitHub Actions / O2 linter

[name/o2-column]

Use UpperCamelCase for names of O2 columns and matching lowerCamelCase names for their getters.
DECLARE_SOA_INDEX_COLUMN(UpcLRCollision, upcLRCollision);
DECLARE_SOA_COLUMN(ChannelID, channelID, uint8_t);
DECLARE_SOA_COLUMN(Amplitude, amplitude, float);
Expand All @@ -152,13 +152,15 @@
DECLARE_SOA_COLUMN(TrackType, trackType, uint8_t);
DECLARE_SOA_COLUMN(V0Type, v0Type, uint8_t);
DECLARE_SOA_COLUMN(AmbDegree, ambDegree, uint8_t);
DECLARE_SOA_COLUMN(TPCNClsFound, tpcNClsFound, uint8_t);

Check failure on line 155 in PWGCF/TwoParticleCorrelations/DataModel/LongRangeDerived.h

View workflow job for this annotation

GitHub Actions / O2 linter

[name/o2-column]

Use UpperCamelCase for names of O2 columns and matching lowerCamelCase names for their getters.
DECLARE_SOA_COLUMN(TPCNClsCrossedRows, tpcNClsCrossedRows, uint8_t);

Check failure on line 156 in PWGCF/TwoParticleCorrelations/DataModel/LongRangeDerived.h

View workflow job for this annotation

GitHub Actions / O2 linter

[name/o2-column]

Use UpperCamelCase for names of O2 columns and matching lowerCamelCase names for their getters.
DECLARE_SOA_COLUMN(TPCChi2NCl, tpcChi2NCl, float);

Check failure on line 157 in PWGCF/TwoParticleCorrelations/DataModel/LongRangeDerived.h

View workflow job for this annotation

GitHub Actions / O2 linter

[name/o2-column]

Use UpperCamelCase for names of O2 columns and matching lowerCamelCase names for their getters.
DECLARE_SOA_COLUMN(DcaZ, dcaZ, float);
DECLARE_SOA_COLUMN(Pt, pt, float);
DECLARE_SOA_COLUMN(Eta, eta, float);
DECLARE_SOA_COLUMN(Phi, phi, float);
DECLARE_SOA_COLUMN(IsCA, isCA, bool);
DECLARE_SOA_COLUMN(IsReassigned, isReassigned, bool);

enum TrackPid {
kSpCharge,
Expand Down Expand Up @@ -226,7 +228,9 @@
lrcorrtrktable::Phi,
fwdtrack::NClusters,
fwdtrack::BestDCAXY,
fwdtrack::BestDCAZ);
fwdtrack::BestDCAZ,
lrcorrtrktable::IsCA,
lrcorrtrktable::IsReassigned);
using LRMftTrack = LRMftTracks::iterator;

DECLARE_SOA_TABLE(UpcLRMidTracks, "AOD", "UPCLRMIDTRACK",
Expand Down Expand Up @@ -281,7 +285,9 @@
lrcorrtrktable::Phi,
fwdtrack::NClusters,
fwdtrack::BestDCAXY,
fwdtrack::BestDCAZ);
fwdtrack::BestDCAZ,
lrcorrtrktable::IsCA,
lrcorrtrktable::IsReassigned);
using UpcLRMftTrack = UpcLRMftTracks::iterator;
} // namespace o2::aod

Expand Down
77 changes: 39 additions & 38 deletions PWGCF/TwoParticleCorrelations/TableProducer/longrangeMaker.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ using namespace o2::constants::math;
auto static constexpr CintZero = 0;
auto static constexpr KminFt0cCell = 96;
auto static constexpr TotFt0Channels = 208;
AxisSpec axisEvent{15, 0.5, 15.5, "#Event", "EventAxis"};
AxisSpec axisEvent{20, 0.5, 20.5, "#Event", "EventAxis"};
AxisSpec axisTrackSel{10, 0.5, 10.5, "#Track", "TrackAxis"};
auto static constexpr KminCharge = 3.0f;
static constexpr std::string_view species[] = {"Pi", "Ka", "Pr"};
Expand Down Expand Up @@ -112,7 +112,9 @@ struct LongrangeMaker {
Configurable<bool> isApplyBestCollIndex{"isApplyBestCollIndex", true, "bestCollIndex"};
Configurable<bool> isrejectFlangeEvent{"isrejectFlangeEvent", false, "At least one channel with -350 TDC < time < -450 TDC"};
Configurable<bool> isApplyNoCollInTimeRangeStandard{"isApplyNoCollInTimeRangeStandard", false, "Enable NoCollInTimeRangeStandard cut"};
Configurable<bool> isApplyNoCollInTimeRangeStrict{"isApplyNoCollInTimeRangeStrict", false, "Enable NoCollInTimeRangeStrict cut"};
Configurable<bool> isApplyNoCollInRofStandard{"isApplyNoCollInRofStandard", false, "Enable NoCollInRofStandard cut"};
Configurable<bool> isApplyNoCollInRofStrict{"isApplyNoCollInRofStrict", false, "Enable NoCollInRofStrict cut"};
Configurable<bool> isApplyNoHighMultCollInPrevRof{"isApplyNoHighMultCollInPrevRof", false, "Enable NoHighMultCollInPrevRof cut"};
Configurable<bool> isApplyCentFT0C{"isApplyCentFT0C", false, "Centrality based on FT0C"};
Configurable<bool> isApplyCentFV0A{"isApplyCentFV0A", false, "Centrality based on FV0A"};
Expand Down Expand Up @@ -142,6 +144,7 @@ struct LongrangeMaker {
struct : ConfigurableGroup {
Configurable<bool> cfgUseChi2Cut{"cfgUseChi2Cut", false, "Use condition on MFT track: chi2/Nclusters"};
Configurable<bool> cfgRequireCA{"cfgRequireCA", false, "Use Cellular Automaton track-finding algorithm"};
Configurable<bool> cfgRequireLTF{"cfgRequireLTF", false, "Use LTF track-finding algorithm"};
Configurable<bool> useMftPtCut{"useMftPtCut", true, "Choose to apply MFT track pT cut"};
Configurable<int> cfgMftCluster{"cfgMftCluster", 5, "cut on MFT Cluster"};
Configurable<float> cfgMftEtaMax{"cfgMftEtaMax", -2.4f, "Maximum MFT eta cut"};
Expand Down Expand Up @@ -251,11 +254,13 @@ struct LongrangeMaker {
x->SetBinLabel(6, "ApplyGoodZvtxFT0vsPV");
x->SetBinLabel(7, "ApplyGoodITSLayersAll");
x->SetBinLabel(8, "ApplyExtraCorrCut");
x->SetBinLabel(9, "ApplyNoCollInTimeRangeStandard");
x->SetBinLabel(10, "ApplyNoCollInRofStandard");
x->SetBinLabel(11, "ApplyNoHighMultCollInPrevRof");
x->SetBinLabel(12, "ApplyOccupancySelection");
x->SetBinLabel(13, "reject flange event");
x->SetBinLabel(9, "ApplyNoCollInRofStandard");
x->SetBinLabel(10, "ApplyNoCollInRofStrict");
x->SetBinLabel(11, "ApplyNoCollInTimeRangeStandard");
x->SetBinLabel(12, "ApplyNoCollInTimeRangeStrict");
x->SetBinLabel(13, "ApplyNoHighMultCollInPrevRof");
x->SetBinLabel(14, "ApplyOccupancySelection");
x->SetBinLabel(15, "reject flange event");
histos.add("hSelectionResult", "hSelectionResult", kTH1I, {{5, -0.5, 4.5}});

histos.add("hMftTrkSel", "hMftTrkSel", kTH1D, {axisTrackSel}, false);
Expand All @@ -277,9 +282,6 @@ struct LongrangeMaker {
xMftBestTrk->SetBinLabel(4, "DCAxy selection");
xMftBestTrk->SetBinLabel(5, "DCAz selection");

histos.add("ReassignedMFTtrackAmbDegree", "ReassignedMFTtrackAmbDegree", kTH1D, {cfgAxis.axisMFTAmbDegree});
histos.add("AssignedMFTtrackAmbDegree", "AssignedMFTtrackAmbDegree", kTH1D, {cfgAxis.axisMFTAmbDegree});

histos.add("FT0A_Amp", "FT0A_Amp", kTH1D, {cfgAxis.axisAmplitude});
histos.add("FT0A_Amp_gaincorrected", "FT0A_Amp_gaincorrected", kTH1D, {cfgAxis.axisAmplitude});
histos.add("FT0A_Channel_vs_Amp", "FT0A_Channel_vs_Amp", kTH2D, {cfgAxis.axisChannel, cfgAxis.axisAmplitude});
Expand Down Expand Up @@ -427,7 +429,7 @@ struct LongrangeMaker {
return;
}
}
histos.fill(HIST("EventHist"), 13);
histos.fill(HIST("EventHist"), 15);
for (std::size_t iCh = 0; iCh < ft0.channelA().size(); iCh++) {
auto chanelid = ft0.channelA()[iCh];
float ampl = ft0.amplitudeA()[iCh];
Expand Down Expand Up @@ -483,12 +485,6 @@ struct LongrangeMaker {
continue;
}
auto phi = itrack.phi();
if (itrack.collisionId() != reassoMftTrack.bestCollisionId()) {
histos.fill(HIST("ReassignedMFTtrackAmbDegree"), reassoMftTrack.ambDegree());
}
if (itrack.collisionId() == reassoMftTrack.bestCollisionId()) {
histos.fill(HIST("AssignedMFTtrackAmbDegree"), reassoMftTrack.ambDegree());
}
o2::math_utils::bringTo02Pi(phi);
lrmfttracks(lrcollision.lastIndex(),
reassoMftTrack.ambDegree(),
Expand All @@ -497,7 +493,9 @@ struct LongrangeMaker {
phi,
itrack.nClusters(),
reassoMftTrack.bestDCAXY(),
reassoMftTrack.bestDCAZ());
reassoMftTrack.bestDCAZ(),
itrack.isCA(),
itrack.collisionId() != reassoMftTrack.bestCollisionId());
}

// v0 loop
Expand Down Expand Up @@ -664,20 +662,16 @@ struct LongrangeMaker {
}
auto phi = itrack.phi();
o2::math_utils::bringTo02Pi(phi);
if (itrack.collisionId() != reassoMftTrack.bestCollisionId()) {
histos.fill(HIST("ReassignedMFTtrackAmbDegree"), reassoMftTrack.ambDegree());
}
if (itrack.collisionId() == reassoMftTrack.bestCollisionId()) {
histos.fill(HIST("AssignedMFTtrackAmbDegree"), reassoMftTrack.ambDegree());
}
upclrmfttracks(upclrcollision.lastIndex(),
reassoMftTrack.ambDegree(),
itrack.pt(),
itrack.eta(),
phi,
itrack.nClusters(),
reassoMftTrack.bestDCAXY(),
reassoMftTrack.bestDCAZ());
reassoMftTrack.bestDCAZ(),
itrack.isCA(),
itrack.collisionId() != reassoMftTrack.bestCollisionId());
}

// v0 loop
Expand Down Expand Up @@ -869,20 +863,16 @@ struct LongrangeMaker {
}
auto phi = itrack.phi();
o2::math_utils::bringTo02Pi(phi);
if (itrack.collisionId() != reassoMftTrack.bestCollisionId()) {
histos.fill(HIST("ReassignedMFTtrackAmbDegree"), reassoMftTrack.ambDegree());
}
if (itrack.collisionId() == reassoMftTrack.bestCollisionId()) {
histos.fill(HIST("AssignedMFTtrackAmbDegree"), reassoMftTrack.ambDegree());
}
lrmfttracks(lrcollision.lastIndex(),
reassoMftTrack.ambDegree(),
itrack.pt(),
itrack.eta(),
phi,
itrack.nClusters(),
reassoMftTrack.bestDCAXY(),
reassoMftTrack.bestDCAZ());
reassoMftTrack.bestDCAZ(),
itrack.isCA(),
itrack.collisionId() != reassoMftTrack.bestCollisionId());
}

for (const auto& particle : mcparticles) {
Expand Down Expand Up @@ -1034,6 +1024,12 @@ struct LongrangeMaker {
if (!isMftTrackSelected(track)) {
continue;
}
if (cfgmfttrksel.cfgRequireCA && !track.isCA()) {
continue;
}
if (cfgmfttrksel.cfgRequireLTF && track.isCA()) {
continue;
}
if (!track.has_mcParticle())
continue;
auto particle = track.mcParticle();
Expand Down Expand Up @@ -1096,22 +1092,30 @@ struct LongrangeMaker {
return false;
}
histos.fill(HIST("EventHist"), 8);
if (cfgevtsel.isApplyNoCollInTimeRangeStandard && !col.selection_bit(o2::aod::evsel::kNoCollInTimeRangeStandard)) {
if (cfgevtsel.isApplyNoCollInRofStandard && !col.selection_bit(o2::aod::evsel::kNoCollInRofStandard)) {
return false;
}
histos.fill(HIST("EventHist"), 9);
if (cfgevtsel.isApplyNoCollInRofStandard && !col.selection_bit(o2::aod::evsel::kNoCollInRofStandard)) {
if (cfgevtsel.isApplyNoCollInRofStrict && !col.selection_bit(o2::aod::evsel::kNoCollInRofStrict)) {
return false;
}
histos.fill(HIST("EventHist"), 10);
if (cfgevtsel.isApplyNoHighMultCollInPrevRof && !col.selection_bit(o2::aod::evsel::kNoHighMultCollInPrevRof)) {
if (cfgevtsel.isApplyNoCollInTimeRangeStandard && !col.selection_bit(o2::aod::evsel::kNoCollInTimeRangeStandard)) {
return false;
}
histos.fill(HIST("EventHist"), 11);
if (cfgevtsel.isApplyOccuSelection && (col.trackOccupancyInTimeRange() > cfgevtsel.cfgOccuCut)) {
if (cfgevtsel.isApplyNoCollInTimeRangeStrict && !col.selection_bit(o2::aod::evsel::kNoCollInTimeRangeStrict)) {
return false;
}
histos.fill(HIST("EventHist"), 12);
if (cfgevtsel.isApplyNoHighMultCollInPrevRof && !col.selection_bit(o2::aod::evsel::kNoHighMultCollInPrevRof)) {
return false;
}
histos.fill(HIST("EventHist"), 13);
if (cfgevtsel.isApplyOccuSelection && (col.trackOccupancyInTimeRange() > cfgevtsel.cfgOccuCut)) {
return false;
}
histos.fill(HIST("EventHist"), 14);
return true;
}

Expand Down Expand Up @@ -1247,9 +1251,6 @@ struct LongrangeMaker {
if constexpr (fillHis) {
histos.fill(HIST("hMftTrkSel"), 5);
}
if (cfgmfttrksel.cfgRequireCA && !track.isCA()) {
return false;
}
if constexpr (fillHis) {
histos.fill(HIST("hMftTrkSel"), 6);
}
Expand Down
22 changes: 19 additions & 3 deletions PWGCF/TwoParticleCorrelations/Tasks/longrangecorrDerived.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,8 @@ struct LongrangecorrDerived {
Configurable<float> cfgMftDcaz{"cfgMftDcaz", 2.0f, "cut on DCA z for MFT tracks"};
Configurable<bool> cfgRejectAmbTrk{"cfgRejectAmbTrk", false, "Condition to reject Ambiguous tracks"};
Configurable<bool> cfgRejectNonAmbTrk{"cfgRejectNonAmbTrk", false, "Condition to reject Non-Ambiguous tracks"};
Configurable<bool> cfgRequireCA{"cfgRequireCA", false, "Use Cellular Automaton track-finding algorithm"};
Configurable<bool> cfgRequireLTF{"cfgRequireLTF", false, "Use LTF track-finding algorithm"};
} cfgSel;

struct : ConfigurableGroup {
Expand Down Expand Up @@ -203,10 +205,12 @@ struct LongrangecorrDerived {
histos.add("TPCChi2NCl", "TPCChi2NCl", kTH1D, {cfgAxis.axisTPCChi2NCl});
histos.add("TPCdcaZ", "TPCdcaZ", kTH1D, {cfgAxis.axisTPCdcaZ});

histos.add("MFTAmbDegree", "MFTAmbDegree", kTH1D, {cfgAxis.axisMFTAmbDegree});
histos.add("MFTNClusters", "MFTNClusters", kTH1D, {cfgAxis.axisMFTNClusters});
histos.add("MFTbestDCAXY", "MFTbestDCAXY", kTH1D, {cfgAxis.axisMFTbestDCAXY});
histos.add("MFTbestDCAZ", "MFTbestDCAZ", kTH1D, {cfgAxis.axisMFTbestDCAZ});

histos.add("ReassignedMFTtrackAmbDegree", "ReassignedMFTtrackAmbDegree", kTH1D, {cfgAxis.axisMFTAmbDegree});
histos.add("AssignedMFTtrackAmbDegree", "AssignedMFTtrackAmbDegree", kTH1D, {cfgAxis.axisMFTAmbDegree});
}

template <typename TTrack>
Expand All @@ -233,6 +237,10 @@ struct LongrangecorrDerived {
return false;
if (cfgSel.cfgRejectNonAmbTrk && track.ambDegree() == 1)
return false;
if (cfgSel.cfgRequireCA && !track.isCA())
return false;
if (cfgSel.cfgRequireLTF && track.isCA())
return false;
return true;
} else {
return true;
Expand Down Expand Up @@ -274,7 +282,11 @@ struct LongrangecorrDerived {
histos.fill(HIST("MFTNClusters"), track.nClusters());
histos.fill(HIST("MFTbestDCAXY"), track.bestDCAXY());
histos.fill(HIST("MFTbestDCAZ"), track.bestDCAZ());
histos.fill(HIST("MFTAmbDegree"), track.ambDegree());
if (track.isReassigned()) {
histos.fill(HIST("ReassignedMFTtrackAmbDegree"), track.ambDegree());
} else {
histos.fill(HIST("AssignedMFTtrackAmbDegree"), track.ambDegree());
}
}
}

Expand All @@ -292,7 +304,11 @@ struct LongrangecorrDerived {
histos.fill(HIST("MFTNClusters"), track.nClusters());
histos.fill(HIST("MFTbestDCAXY"), track.bestDCAXY());
histos.fill(HIST("MFTbestDCAZ"), track.bestDCAZ());
histos.fill(HIST("MFTAmbDegree"), track.ambDegree());
if (track.isReassigned()) {
histos.fill(HIST("ReassignedMFTtrackAmbDegree"), track.ambDegree());
} else {
histos.fill(HIST("AssignedMFTtrackAmbDegree"), track.ambDegree());
}
}
}

Expand Down
Loading