@@ -54,7 +54,12 @@ struct LFNucleiBATask {
5454 Configurable<bool > enableAl{" enableAl" , true , " Flag to enable alpha analysis." };
5555
5656 Configurable<bool > enableTrackingEff{" enableTrackingEff" , 0 , " Flag to enable tracking efficiency hitos." };
57- // Configurable<bool> enableTrackingEffWithTPCPID{"enableTrackingEffWithTPCPID", 0, "Flag to enable tracking efficiency hitos with TPC PID selection."};
57+
58+ // Set the event selection cuts
59+ Configurable<bool > useSel8{" useSel8" , true , " Use Sel8 for run3 Event Selection" };
60+ Configurable<bool > TVXtrigger{" TVXtrigger" , false , " Use TVX for Event Selection (default w/ Sel8)" };
61+ Configurable<bool > removeTFBorder{" removeTFBorder" , false , " Remove TimeFrame border (default w/ Sel8)" };
62+ Configurable<bool > removeITSROFBorder{" removeITSROFBorder" , false , " Remove ITS Read-Out Frame border (default w/ Sel8)" };
5863
5964 // Set the multiplity event limits
6065 Configurable<float > cfgLowMultCut{" cfgLowMultCut" , 0 .0f , " Accepted multiplicity percentage lower limit" };
@@ -88,7 +93,6 @@ struct LFNucleiBATask {
8893 Configurable<float > nsigmaTPCAl{" nsigmaTPCAl" , 3 .f , " Value of the Nsigma TPC cut for alpha" };
8994
9095 // Set additional cuts (used for debug)
91- Configurable<float > ProtonNsigmaTPCcutInTOFbeta{" ProtonNsigmaTPCcutInTOFbeta" , 3 .5f , " Value of the Nsigma TPC cut (proton) for TOF beta distribution" };
9296 Configurable<float > betaCut{" betaCut" , 0 .4f , " Value of the beta selection for TOF cut (default 0.4)" };
9397
9498 // Set the axis used in this task
@@ -115,7 +119,6 @@ struct LFNucleiBATask {
115119 // Enable output histograms
116120 Configurable<bool > makeDCABeforeCutPlots{" makeDCABeforeCutPlots" , false , " Flag to enable plots of DCA before cuts" };
117121 Configurable<bool > makeDCAAfterCutPlots{" makeDCAAfterCutPlots" , false , " Flag to enable plots of DCA after cuts" };
118- Configurable<bool > doTPCcalib{" doTPCcalib" , false , " Flag to stop task after dEdX. Please set to 'processData'." };
119122 Configurable<bool > doTOFplots{" doTOFplots" , true , " Flag to export plots of tracks with 1 hit on TOF." };
120123 Configurable<bool > enableExpSignalTPC{" enableExpSignalTPC" , true , " Flag to export dEdX - dEdX(exp) plots." };
121124 Configurable<bool > enableExpSignalTOF{" enableExpSignalTOF" , false , " Flag to export T - T(exp) plots." };
@@ -157,7 +160,6 @@ struct LFNucleiBATask {
157160 Configurable<std::vector<float >> parShiftPtAntiD{" parShiftPtAntiD" , {-0.0955412 , 0.798164 , -0.536111 , 0.0887876 , -1.11022e-13 }, " Parameters for Pt shift (if enabled)." };
158161 Configurable<std::vector<float >> parShiftPtD{" parShiftPtD" , {-0.0955412 , 0.798164 , -0.536111 , 0.0887876 , -1.11022e-13 }, " Parameters for Pt shift (if enabled)." };
159162 Configurable<bool > enableCentrality{" enableCentrality" , true , " Flag to enable centrality 3D histos)" };
160- Configurable<bool > removeTFBorder{" removeTFBorder" , false , " Remove TimeFrame border" };
161163
162164 // PDG codes and masses used in this analysis
163165 static constexpr int PDGPion = 211 ;
@@ -196,8 +198,10 @@ struct LFNucleiBATask {
196198
197199 if (enableDebug) {
198200 debugHistos.add <TH1>(" qa/h1VtxZ_nocut" , " V_{z};V_{z} (in cm); counts" , HistType::kTH1F , {{1500 , -15 , 15 }});
199- debugHistos.add <TH1>(" qa/h1VtxZ_sel8 " , " V_{z};V_{z} (in cm); counts" , HistType::kTH1F , {{1500 , -15 , 15 }});
201+ debugHistos.add <TH1>(" qa/h1VtxZ_TVXtrigger " , " V_{z};V_{z} (in cm); counts" , HistType::kTH1F , {{1500 , -15 , 15 }});
200202 debugHistos.add <TH1>(" qa/h1VtxZ_TFrameBorder" , " V_{z};V_{z} (in cm); counts" , HistType::kTH1F , {{1500 , -15 , 15 }});
203+ debugHistos.add <TH1>(" qa/h1VtxZ_ITSROFBorder" , " V_{z};V_{z} (in cm); counts" , HistType::kTH1F , {{1500 , -15 , 15 }});
204+ debugHistos.add <TH1>(" qa/h1VtxZ_sel8" , " V_{z};V_{z} (in cm); counts" , HistType::kTH1F , {{1500 , -15 , 15 }});
201205 debugHistos.add <TH1>(" qa/h1VtxZ_Centrality" , " V_{z};V_{z} (in cm); counts" , HistType::kTH1F , {{1500 , -15 , 15 }});
202206
203207 if (enableCentrality) {
@@ -206,6 +210,15 @@ struct LFNucleiBATask {
206210 }
207211 }
208212
213+ histos.add <TH1>(" event/eventSelection" , " eventSelection" , HistType::kTH1D , {{7 , -0.5 , 6.5 }});
214+ auto h = histos.get <TH1>(HIST (" event/eventSelection" ));
215+ h->GetXaxis ()->SetBinLabel (1 , " Total" );
216+ h->GetXaxis ()->SetBinLabel (2 , " TVX trigger cut" );
217+ h->GetXaxis ()->SetBinLabel (3 , " TF border cut" );
218+ h->GetXaxis ()->SetBinLabel (4 , " ITS ROF cut" );
219+ h->GetXaxis ()->SetBinLabel (5 , " TVX + TF + ITS ROF" );
220+ h->GetXaxis ()->SetBinLabel (6 , " Sel8 cut" );
221+ h->GetXaxis ()->SetBinLabel (7 , " Z-vert Cut" );
209222 histos.add <TH1>(" event/h1VtxZ" , " V_{z};V_{z} (in cm); counts" , HistType::kTH1F , {{1500 , -15 , 15 }});
210223
211224 histos.add <TH1>(" tracks/h1pT" , " Track #it{p}_{T}; #it{p}_{T} (GeV/#it{c}); counts" , HistType::kTH1F , {{500 , 0 ., 10 .}});
@@ -1078,7 +1091,6 @@ struct LFNucleiBATask {
10781091 if (doTOFplots) {
10791092 histos.add <TH2>(" tracks/h2TPCsignVsBetaGamma" , " TPC <-dE/dX> vs #beta#gamma/Z; Signed #beta#gamma; TPC <-dE/dx> (a.u.)" , HistType::kTH2F , {{600 , -6 .f , 6 .f }, {dedxAxis}});
10801093 histos.add <TH2>(" tracks/h2TOFbetaVsP" , " TOF #beta vs #it{p}/Z; Signed #it{p} (GeV/#it{c}); TOF #beta" , HistType::kTH2F , {{500 , -5 .f , 5 .f }, {betaAxis}});
1081- histos.add <TH2>(" tracks/h2withTPCProtonCutTOFbetaVsP" , " TOF #beta (with N#sigma_{TPC}(p)) cut) vs #it{p}/Z; Signed #it{p} (GeV/#it{c}); TOF #beta (with N#sigma_{TPC}(p)) cut)" , HistType::kTH2F , {{500 , -5 .f , 5 .f }, {betaAxis}});
10821094 if (enableBetaCut)
10831095 histos.add <TH2>(" tracks/h2TOFbetaVsP_BetaCut" , " TOF #beta vs #it{p}/Z; Signed #it{p} (GeV/#it{c}); TOF #beta" , HistType::kTH2F , {{500 , -5 .f , 5 .f }, {betaAxis}});
10841096 }
@@ -1600,33 +1612,63 @@ struct LFNucleiBATask {
16001612 const ParticleType& particles)
16011613 {
16021614 // Event histos fill
1615+ histos.fill (HIST (" event/eventSelection" ), 0 );
16031616 if (enableDebug)
16041617 debugHistos.fill (HIST (" qa/h1VtxZ_nocut" ), event.posZ ());
16051618
16061619 if constexpr (!IsFilteredData) {
1607- if (!event.sel8 ()) {
1608- return ;
1620+ if (!event.selection_bit (aod::evsel::kIsTriggerTVX )) {
1621+ if (TVXtrigger)
1622+ return ;
1623+ } else {
1624+ histos.fill (HIST (" event/eventSelection" ), 1 );
1625+ if (enableDebug)
1626+ debugHistos.fill (HIST (" qa/h1VtxZ_TVXtrigger" ), event.posZ ());
16091627 }
1610- if (enableDebug)
1611- debugHistos.fill (HIST (" qa/h1VtxZ_sel8" ), event.posZ ());
16121628
1613- if (removeTFBorder && !event.selection_bit (aod::evsel::kNoTimeFrameBorder ))
1629+ if (!event.selection_bit (aod::evsel::kNoTimeFrameBorder )) {
1630+ if (removeTFBorder)
1631+ return ;
1632+ } else {
1633+ histos.fill (HIST (" event/eventSelection" ), 2 );
1634+ if (enableDebug)
1635+ debugHistos.fill (HIST (" qa/h1VtxZ_TFrameBorder" ), event.posZ ());
1636+ }
1637+
1638+ if (!event.selection_bit (aod::evsel::kNoITSROFrameBorder )) {
1639+ if (removeITSROFBorder)
1640+ return ;
1641+ } else {
1642+ histos.fill (HIST (" event/eventSelection" ), 3 );
1643+ if (enableDebug)
1644+ debugHistos.fill (HIST (" qa/h1VtxZ_ITSROFBorder" ), event.posZ ());
1645+ }
1646+
1647+ if ((event.selection_bit (aod::evsel::kNoITSROFrameBorder )) &&
1648+ (event.selection_bit (aod::evsel::kNoTimeFrameBorder )) &&
1649+ (event.selection_bit (aod::evsel::kIsTriggerTVX ))) {
1650+ histos.fill (HIST (" event/eventSelection" ), 4 );
1651+ }
1652+
1653+ if (useSel8 && !event.sel8 ())
16141654 return ;
1655+ histos.fill (HIST (" event/eventSelection" ), 5 );
16151656 if (enableDebug)
1616- debugHistos.fill (HIST (" qa/h1VtxZ_TFrameBorder " ), event.posZ ());
1657+ debugHistos.fill (HIST (" qa/h1VtxZ_sel8 " ), event.posZ ());
16171658
16181659 if (enableCentrality) {
16191660 if (event.centFT0M () < cfgLowMultCut || event.centFT0M () > cfgHighMultCut) {
16201661 return ;
16211662 }
1663+ if (enableDebug)
1664+ debugHistos.fill (HIST (" event/h1VtxZ_Centrality" ), event.posZ ());
16221665 }
1623- if (enableDebug)
1624- debugHistos.fill (HIST (" event/h1VtxZ_Centrality" ), event.posZ ());
16251666
16261667 if (event.posZ () < cfgLowCutVertex || event.posZ () > cfgHighCutVertex)
16271668 return ;
1628- } else {
1669+ histos. fill ( HIST ( " event/eventSelection " ), 6 );
16291670
1671+ } else {
16301672 if (event.posZ () < cfgLowCutVertex || event.posZ () > cfgHighCutVertex)
16311673 return ;
16321674 if (removeTFBorder && !event.selection_bit (aod::evsel::kNoTimeFrameBorder ))
@@ -2424,9 +2466,6 @@ struct LFNucleiBATask {
24242466 // p,d,t,He
24252467 histos.fill (HIST (" tracks/h2TPCsignVsTPCmomentum" ), track.tpcInnerParam () / (1 .f * track.sign ()), track.tpcSignal ());
24262468
2427- if (doTPCcalib)
2428- return ;
2429-
24302469 if (track.sign () > 0 ) {
24312470 if (enablePr && prRapCut) {
24322471 if (enableExpSignalTPC)
@@ -3062,9 +3101,6 @@ struct LFNucleiBATask {
30623101 }
30633102 break ;
30643103 }
3065- if (track.tpcNSigmaPr () + 3 > ProtonNsigmaTPCcutInTOFbeta) {
3066- histos.fill (HIST (" tracks/h2withTPCProtonCutTOFbetaVsP" ), track.p () / (1 .f * track.sign ()), track.beta ());
3067- }
30683104
30693105 if (enablePtSpectra)
30703106 histos.fill (HIST (" tracks/eff/h2TPCmomentumVsTOFExpMomentum" ), track.tofExpMom (), track.tpcInnerParam ());
0 commit comments