@@ -67,7 +67,6 @@ static constexpr float LongArrayFloat[3][20] = {{1.1, 1.2, 1.3, -1.1, -1.2, -1.3
6767#define O2_DEFINE_CONFIGURABLE (NAME, TYPE, DEFAULT, HELP ) Configurable<TYPE> NAME{#NAME, DEFAULT, HELP};
6868
6969struct V0ptHadPiKaProt {
70-
7170 // ITS response
7271 o2::aod::ITSResponse itsResponse;
7372 // Connect to ccdb
@@ -812,20 +811,20 @@ struct V0ptHadPiKaProt {
812811 return 0 ;
813812 }
814813
815- int occupancy = coll.trackOccupancyInTimeRange ();
816- histos.fill (HIST (" hOccupancyVsCentrality_before" ), occupancy);
817-
818814 histos.fill (HIST (" hEventStatData" ), 6.5 );
819815 // events with selection bits based on occupancy time pattern
820- if (cfgEvSelUseOcuppancyTimeCut && !(coll.selection_bit (o2::aod::evsel::kNoCollInTimeRangeStandard ))) {
821- return 0 ;
822- }
823-
824- histos.fill (HIST (" hOccupancyVsCentrality_after" ), occupancy);
825-
826- histos.fill (HIST (" hEventStatData" ), 7.5 );
827- if (cfgEvSelSetOcuppancyRange && (occupancy < cfgMinOccupancy || occupancy > cfgMaxOccupancy)) {
828- return 0 ;
816+ if (cfgEvSelUseOcuppancyTimeCut) {
817+ int occupancy = coll.trackOccupancyInTimeRange ();
818+ histos.fill (HIST (" hOccupancyVsCentrality_before" ), coll.centFT0C (), occupancy);
819+ if (!(coll.selection_bit (o2::aod::evsel::kNoCollInTimeRangeStandard )))
820+ return 0 ;
821+ else
822+ histos.fill (HIST (" hOccupancyVsCentrality_after" ), coll.centFT0C (), occupancy);
823+
824+ histos.fill (HIST (" hEventStatData" ), 7.5 );
825+ if (cfgEvSelSetOcuppancyRange && (occupancy < cfgMinOccupancy || occupancy > cfgMaxOccupancy)) {
826+ return 0 ;
827+ }
829828 }
830829
831830 histos.fill (HIST (" hEventStatData" ), 8.5 );
0 commit comments