@@ -110,35 +110,43 @@ struct UccZdc {
110110 ConfigurableAxis binsCent{" binsCent" , {VARIABLE_WIDTH, 0 ., 10 ., 20 ., 30 ., 40 ., 50 ., 60 ., 70 ., 80 ., 90 ., 100 .}, " T0C binning" };
111111
112112 // Configurable event selectiond and flags ZDC
113+ Configurable<bool > isOccupancyCut{" isOccupancyCut" , true , " Occupancy cut?" };
114+ Configurable<bool > isApplyFT0CbasedOccupancy{" isApplyFT0CbasedOccupancy" ,
115+ false , " T0C Occu cut?" };
113116 Configurable<bool > isApplySameBunchPileup{" isApplySameBunchPileup" , true ,
114- " Enable SameBunchPileup cut" };
117+ " SameBunchPileup cut? " };
115118 Configurable<bool > isApplyGoodZvtxFT0vsPV{" isApplyGoodZvtxFT0vsPV" , true ,
116- " Enable GoodZvtxFT0vsPV cut" };
119+ " GoodZvtxFT0vsPV cut? " };
117120 Configurable<bool > isApplyVertexITSTPC{" isApplyVertexITSTPC" , true ,
118- " Enable VertexITSTPC cut" };
121+ " VertexITSTPC cut? " };
119122 Configurable<bool > isApplyVertexTOFmatched{" isApplyVertexTOFmatched" , true ,
120- " Enable VertexTOFmatched cut" };
123+ " VertexTOFmatched cut? " };
121124 Configurable<bool > isAmpZDC{" isAmpZDC" , false , " Use amplitude ZDC?" };
122125 Configurable<bool > isCommPMT{" isCommPMT" , false , " Use common PMT ZDC?" };
123126 Configurable<bool > isSumTowers{" isSumTowers" , false , " Use sum of Tow ZDC?" };
124127 Configurable<bool > isTDCcut{" isTDCcut" , false , " Use TDC cut?" };
125128 Configurable<bool > isZEMcut{" isZEMcut" , true , " Use ZEM cut?" };
126129 Configurable<float > zemCut{" zemCut" , 1000.0 , " ZEM cut" };
127130 Configurable<float > tdcCut{" tdcCut" , 1.0 , " TDC cut" };
128-
129- enum EvCutLabel { All = 1 ,
130- SelEigth,
131- NoSameBunchPileup,
132- IsGoodZvtxFT0vsPV,
133- IsVertexITSTPC,
134- IsVertexTOFmatched,
135- Centrality,
136- VtxZ,
137- CentralityCut,
138- Zdc,
139- TZero,
140- Tdc,
141- Zem };
131+ Configurable<float > minOccCut{" minOccCut" , 0 , " min Occu cut" };
132+ Configurable<float > maxOccCut{" maxOccCut" , 500 , " max Occu cut" };
133+
134+ enum EvCutLabel {
135+ All = 1 ,
136+ SelEigth,
137+ NoSameBunchPileup,
138+ IsGoodZvtxFT0vsPV,
139+ IsVertexITSTPC,
140+ IsVertexTOFmatched,
141+ OccuCut,
142+ Centrality,
143+ VtxZ,
144+ CentralityCut,
145+ Zdc,
146+ TZero,
147+ Tdc,
148+ Zem
149+ };
142150
143151 // Filters
144152 Filter collFilter = (nabs(aod::collision::posZ) < posZcut);
@@ -177,19 +185,20 @@ struct UccZdc {
177185 registry.add (" hEventCounter" , " ;;Events" , kTH1F , {axisEvent});
178186 auto hstat = registry.get <TH1>(HIST (" hEventCounter" ));
179187 auto * x = hstat->GetXaxis ();
180- x->SetBinLabel (1 , " All events" );
181- x->SetBinLabel (2 , " sel8" );
182- x->SetBinLabel (3 , " kNoSameBunchPileup" );
183- x->SetBinLabel (4 , " kIsGoodZvtxFT0vsPV" );
184- x->SetBinLabel (5 , " kIsVertexITSTPC" );
185- x->SetBinLabel (6 , " kIsVertexTOFmatched" );
186- x->SetBinLabel (7 , " Centrality" );
187- x->SetBinLabel (8 , " VtxZ" );
188- x->SetBinLabel (9 , " Centrality cut" );
189- x->SetBinLabel (10 , " has ZDC?" );
190- x->SetBinLabel (11 , " has T0?" );
191- x->SetBinLabel (12 , " inside TDC cut?" );
192- x->SetBinLabel (13 , " within ZEM cut?" );
188+ x->SetBinLabel (1 , " All" );
189+ x->SetBinLabel (2 , " SelEigth" );
190+ x->SetBinLabel (3 , " NoSameBunchPileup" );
191+ x->SetBinLabel (4 , " IsGoodZvtxFT0vsPV" );
192+ x->SetBinLabel (5 , " IsVertexITSTPC" );
193+ x->SetBinLabel (6 , " IsVertexTOFmatched" );
194+ x->SetBinLabel (7 , " Occupancy Cut" );
195+ x->SetBinLabel (8 , " Centrality" );
196+ x->SetBinLabel (9 , " VtxZ cut" );
197+ x->SetBinLabel (10 , " Centrality cut" );
198+ x->SetBinLabel (11 , " has ZDC?" );
199+ x->SetBinLabel (12 , " has T0?" );
200+ x->SetBinLabel (13 , " Within TDC cut?" );
201+ x->SetBinLabel (14 , " Within ZEM cut?" );
193202
194203 // Histograms: paritcle-level info
195204 if (doprocessZdcCollAss) {
@@ -323,6 +332,16 @@ struct UccZdc {
323332 }
324333 registry.fill (HIST (" hEventCounter" ), EvCutLabel::IsVertexTOFmatched);
325334
335+ if (isOccupancyCut) {
336+ auto occuValue{isApplyFT0CbasedOccupancy
337+ ? col.ft0cOccupancyInTimeRange ()
338+ : col.trackOccupancyInTimeRange ()};
339+
340+ if (occuValue < minOccCut || occuValue > maxOccCut)
341+ return false ;
342+ }
343+ registry.fill (HIST (" hEventCounter" ), EvCutLabel::OccuCut);
344+
326345 // if (isApplyVertexTRDmatched &&
327346 // !col.selection_bit(o2::aod::evsel::kIsVertexTRDmatched)) {
328347 // return false;
@@ -346,29 +365,6 @@ struct UccZdc {
346365 }
347366 registry.fill (HIST (" hEventCounter" ), EvCutLabel::CentralityCut);
348367
349- // if (isApplyExtraCorrCut && col.multNTracksPV() > npvTracksCut &&
350- // col.multFT0C() < (10 * col.multNTracksPV() - ft0cCut)) {
351- // return false;
352- // }
353- // histos.fill(HIST("EventHist"), 9);
354- //
355- // if (isApplyNoCollInTimeRangeStandard &&
356- // !col.selection_bit(o2::aod::evsel::kNoCollInTimeRangeStandard)) {
357- // return false;
358- // }
359- // histos.fill(HIST("EventHist"), 10);
360- //
361- // if (isApplyNoCollInRofStandard &&
362- // !col.selection_bit(o2::aod::evsel::kNoCollInRofStandard)) {
363- // return false;
364- // }
365- // histos.fill(HIST("EventHist"), 11);
366- //
367- // if (isApplyNoHighMultCollInPrevRof &&
368- // !col.selection_bit(o2::aod::evsel::kNoHighMultCollInPrevRof)) {
369- // return false;
370- // }
371- // histos.fill(HIST("EventHist"), 12);
372368 return true ;
373369 }
374370
0 commit comments