@@ -139,7 +139,7 @@ struct ResonanceInitializer {
139139
140140 // Pre-selection cuts
141141 Configurable<float > cfgCutEta{" cfgCutEta" , 0 .8f , " Eta range for tracks" };
142- Configurable<float > pidnSigmaPreSelectionCut{" pidnSigmaPreSelectionCut" , 5 .0f , " TPC and TOF PID cut (loose, improve performance)" };
142+ Configurable<float > pidnSigmaPreSelectionCut{" pidnSigmaPreSelectionCut" , 5 .0f , " TPC PID cut (loose, improve performance)" };
143143 Configurable<int > mincrossedrows{" mincrossedrows" , 70 , " min crossed rows" };
144144
145145 // / DCA Selections for V0
@@ -181,6 +181,8 @@ struct ResonanceInitializer {
181181 Configurable<bool > cfgFillLambda0{" cfgFillLambda0" , false , " Fill Lambda0" };
182182 Configurable<bool > cfgFillXi0{" cfgFillXi0" , false , " Fill Xi0" };
183183 Configurable<bool > cfgFillOmega0{" cfgFillOmega0" , false , " Fill Omega0" };
184+ Configurable<bool > cfgBypassNoPairCascades{" cfgBypassNoPairCascades" , true , " Bypass track fill if no pair cascade with track" };
185+ Configurable<bool > cfgBypassNoPairV0s{" cfgBypassNoPairV0s" , false , " Bypass if no pair V0 with track" };
184186 } FilterForDerivedTables;
185187
186188 // Secondary cuts
@@ -221,7 +223,8 @@ struct ResonanceInitializer {
221223 ConfigurableAxis impactParameterAxis{" impactParameterAxis" , {500 , 0 , 50 }, " IP (fm)" };
222224
223225 Configurable<bool > isDaughterCheck{" isDaughterCheck" , 1 , " Check if the mother has the correct daughters when it is considered" };
224- Configurable<float > cfgRapidityCutGen{" cfgRapidityCutGen" , 0.5 , " Rapidity cut for the truth particle" };
226+ Configurable<float > cfgRapidityCutMinGen{" cfgRapidityCutMinGen" , -0.5 , " Rapidity cut for the truth particle" };
227+ Configurable<float > cfgRapidityCutMaxGen{" cfgRapidityCutMaxGen" , 0.5 , " Rapidity cut for the truth particle" };
225228 Configurable<int > pdgTruthMother{" pdgTruthMother" , 3324 , " pdgcode for the truth mother e.g. Xi(1530) (3324)" };
226229 Configurable<int > pdgTruthDaughter1{" pdgTruthDaughter1" , 3312 , " pdgcode for the daughter 1, e.g. Xi- 3312" };
227230 Configurable<int > pdgTruthDaughter2{" pdgTruthDaughter2" , 211 , " pdgcode for the daughter 2, e.g. pi+ 211" };
@@ -267,8 +270,8 @@ struct ResonanceInitializer {
267270 || (nabs(aod::mcparticle::pdgCode) == 123314 ) // Xi(1820)0
268271 || (nabs(aod::mcparticle::pdgCode) == 123324 ); // Xi(1820)-0
269272
270- using ResoEvents = soa::Join<aod::Collisions, aod::EvSels, aod::CentFT0Ms, aod::CentFT0Cs, aod::CentFT0As, aod::Mults>;
271- using ResoEvents001 = soa::Join<aod::Collisions, aod::EvSels, aod::CentFT0Ms, aod::CentFT0Cs, aod::CentFT0As, aod::Mults, aod::MultsExtra, aod::PVMults>;
273+ using ResoEvents = soa::Join<aod::Collisions, aod::EvSels, aod::CentFT0Ms, aod::CentFT0Cs, aod::CentFT0As, aod::CentFV0As, aod:: Mults>;
274+ using ResoEvents001 = soa::Join<aod::Collisions, aod::EvSels, aod::CentFT0Ms, aod::CentFT0Cs, aod::CentFT0As, aod::CentFV0As, aod:: Mults, aod::MultsExtra, aod::PVMults>;
272275 using ResoRun2Events = soa::Join<aod::Collisions, aod::EvSels, aod::CentRun2V0Ms>;
273276 using ResoEventsMC = soa::Join<ResoEvents, aod::McCollisionLabels>;
274277 using ResoRun2EventsMC = soa::Join<ResoEvents, aod::McCollisionLabels>;
@@ -381,7 +384,7 @@ struct ResonanceInitializer {
381384 return false ;
382385 if (v0.qtarm () < SecondaryCuts.cfgSecondaryparamArmenterosCut * std::abs (v0.alpha ()))
383386 return false ;
384- if (std::fabs (v0.mLambda () - MassLambda0) < SecondaryCuts.cfgSecondaryMassWindow )
387+ if (std::fabs (v0.mLambda () - MassLambda0) > SecondaryCuts.cfgSecondaryMassWindow )
385388 return false ;
386389 if (SecondaryCuts.cfgSecondaryCrossMassHypothesisCut && (std::fabs (v0.mK0Short () - MassK0Short) < SecondaryCuts.cfgSecondaryCrossMassCutWindow ))
387390 return false ;
@@ -592,6 +595,9 @@ struct ResonanceInitializer {
592595 case 2 :
593596 returnValue = ResoEvents.centFT0A ();
594597 break ;
598+ case 3 :
599+ returnValue = ResoEvents.centFV0A ();
600+ break ;
595601 default :
596602 returnValue = ResoEvents.centFT0M ();
597603 break ;
@@ -1192,7 +1198,9 @@ struct ResonanceInitializer {
11921198 {
11931199 for (auto const & mcPart : mcParticles) {
11941200
1195- if (std::abs (mcPart.pdgCode ()) != GenCuts.pdgTruthMother || std::abs (mcPart.y ()) >= GenCuts.cfgRapidityCutGen )
1201+ if (std::abs (mcPart.pdgCode ()) != GenCuts.pdgTruthMother )
1202+ continue ;
1203+ if ((mcPart.y () >= GenCuts.cfgRapidityCutMaxGen ) || (mcPart.y () <= GenCuts.cfgRapidityCutMinGen ))
11961204 continue ;
11971205 std::vector<int > daughterPDGs;
11981206 if (mcPart.has_daughters ()) {
@@ -1279,15 +1287,15 @@ struct ResonanceInitializer {
12791287 {
12801288 mRunNumber = 0 ;
12811289 dBz = 0 ;
1282- // Multiplicity estimator selection (0: FT0M, 1: FT0C, 2: FT0A, 99 : FV0A)
1290+ // Multiplicity estimator selection (0: FT0M, 1: FT0C, 2: FT0A, 3 : FV0A)
12831291 if (cfgMultName.value == " FT0M" ) {
12841292 multEstimator = 0 ;
12851293 } else if (cfgMultName.value == " FT0C" ) {
12861294 multEstimator = 1 ;
12871295 } else if (cfgMultName.value == " FT0A" ) {
12881296 multEstimator = 2 ;
12891297 } else if (cfgMultName.value == " FV0A" ) {
1290- multEstimator = 99 ;
1298+ multEstimator = 3 ;
12911299 } else {
12921300 multEstimator = 0 ;
12931301 }
@@ -1337,6 +1345,7 @@ struct ResonanceInitializer {
13371345 AxisSpec idxMCAxis = {26 , -0.5 , 25.5 , " Index" };
13381346 qaRegistry.add (" Event/hMCEventIndices" , " hMCEventIndices" , kTH2D , {centAxis, idxMCAxis});
13391347 }
1348+ qaRegistry.add (" Event/CentFV0A" , " ; FV0A Percentile; Entries" , o2::framework::kTH1F , {{110 , 0 , 110 }});
13401349 AxisSpec idxAxis = {8 , 0 , 8 , " Index" };
13411350 if (cfgFillQA) {
13421351 qaRegistry.add (" hGoodTrackIndices" , " hGoodTrackIndices" , kTH1F , {idxAxis});
@@ -1513,6 +1522,9 @@ struct ResonanceInitializer {
15131522 }
15141523 resoSpheroCollisions (computeSpherocity (tracks, trackSphMin, trackSphDef));
15151524 resoEvtPlCollisions (0 , 0 , 0 , 0 );
1525+ if (FilterForDerivedTables.cfgBypassNoPairV0s && (V0s.size () < 1 )) {
1526+ return ;
1527+ }
15161528
15171529 fillTracks<false >(collision, tracks);
15181530 if (cfgFillMicroTracks) {
@@ -1572,6 +1584,14 @@ struct ResonanceInitializer {
15721584 }
15731585 resoSpheroCollisions (computeSpherocity (tracks, trackSphMin, trackSphDef));
15741586 resoEvtPlCollisions (0 , 0 , 0 , 0 );
1587+ if (cfgMultName.value == " FV0A" )
1588+ qaRegistry.fill (HIST (" Event/CentFV0A" ), centEst (collision));
1589+ if (FilterForDerivedTables.cfgBypassNoPairV0s && (V0s.size () < 1 )) {
1590+ return ;
1591+ }
1592+ if (FilterForDerivedTables.cfgBypassNoPairCascades && (Cascades.size () < 1 )) {
1593+ return ;
1594+ }
15751595 fillTracks<false >(collision, tracks);
15761596 if (cfgFillMicroTracks) {
15771597 fillMicroTracks<false >(collision, tracks);
@@ -1718,6 +1738,9 @@ struct ResonanceInitializer {
17181738 fillMCCollision<false >(collision, mcParticles);
17191739
17201740 // Loop over tracks
1741+ if (FilterForDerivedTables.cfgBypassNoPairV0s && (V0s.size () < 1 )) {
1742+ return ;
1743+ }
17211744 fillTracks<true >(collision, tracks);
17221745 if (cfgFillMicroTracks) {
17231746 fillMicroTracks<true >(collision, tracks);
@@ -1782,6 +1805,8 @@ struct ResonanceInitializer {
17821805 Cent = mcCollision.centFT0M ();
17831806 else
17841807 Cent = centEst (collision);
1808+ if (cfgMultName.value == " FV0A" )
1809+ qaRegistry.fill (HIST (" Event/CentFV0A" ), centEst (collision));
17851810
17861811 bool isRecINELgt0 = 0 ;
17871812 if (checkIsRecINELgt0)
@@ -1802,6 +1827,12 @@ struct ResonanceInitializer {
18021827 fillMCCollision<false >(collision, mcParticles, impactpar, mult);
18031828
18041829 // Loop over tracks
1830+ if (FilterForDerivedTables.cfgBypassNoPairV0s && (V0s.size () < 1 )) {
1831+ return ;
1832+ }
1833+ if (FilterForDerivedTables.cfgBypassNoPairCascades && (Cascades.size () < 1 )) {
1834+ return ;
1835+ }
18051836 fillTracks<true >(collision, tracks);
18061837 if (cfgFillMicroTracks) {
18071838 fillMicroTracks<true >(collision, tracks);
@@ -1839,6 +1870,8 @@ struct ResonanceInitializer {
18391870 return col.centFT0C ();
18401871 } else if (cfgMultName.value == " FT0A" ) {
18411872 return col.centFT0A ();
1873+ } else if (cfgMultName.value == " FV0A" ) {
1874+ return col.centFV0A ();
18421875 }
18431876 return 100 .5f ;
18441877 };
@@ -1875,7 +1908,7 @@ struct ResonanceInitializer {
18751908 for (const auto & collision : collisions) {
18761909 if (EventCuts.cfgEvtUseRCTFlagChecker && !rctChecker (collision))
18771910 continue ;
1878- if (!colCuts.isSelected (collision)) // Bug is appeared in colCuts-> double counting in event QA histo, will be fixed later
1911+ if (!colCuts.isSelected (collision, false )) // Bug is appeared in colCuts-> double counting in event QA histo, will be fixed later
18791912 continue ;
18801913 if (biggestNContribs < collision.multPVTotalContributors ()) {
18811914 biggestNContribs = collision.multPVTotalContributors ();
0 commit comments