@@ -92,12 +92,15 @@ enum KindOfCorrType {
9292
9393enum {
9494 kSpeciesbegin = 0 ,
95- kSpPion = 1 ,
95+ kSpPrimary = 1 ,
96+ kSpRecoAll ,
97+ kSpRecoPrimary ,
98+ kSpPion ,
9699 kSpKaon ,
97100 kSpProton ,
98- kBkg ,
101+ kSpOther ,
99102 kSpNotPrimary ,
100- kSpAll ,
103+ kSpFake ,
101104 kSpeciesend
102105};
103106
@@ -870,7 +873,7 @@ struct LongrangeCorrelation {
870873 if (!isGenTrackSelected (particle)) {
871874 continue ;
872875 }
873- histos.fill (HIST (" hmcgendndpt" ), particle.eta (), particle.pt (), static_cast <double >(kSpAll ), multiplicity, mcCollision.posZ ());
876+ histos.fill (HIST (" hmcgendndpt" ), particle.eta (), particle.pt (), static_cast <double >(kSpPrimary ), multiplicity, mcCollision.posZ ());
874877 int pid = 0 ;
875878 switch (std::abs (particle.pdgCode ())) {
876879 case PDG_t::kPiPlus :
@@ -882,6 +885,9 @@ struct LongrangeCorrelation {
882885 case PDG_t::kProton :
883886 pid = kSpProton ;
884887 break ;
888+ default :
889+ pid = kSpOther ;
890+ break ;
885891 }
886892 histos.fill (HIST (" hmcgendndpt" ), particle.eta (), particle.pt (), static_cast <double >(pid), multiplicity, mcCollision.posZ ());
887893 } // track (mcgen) loop
@@ -891,13 +897,13 @@ struct LongrangeCorrelation {
891897 continue ;
892898 }
893899 auto recTracksPart = RecTracks.sliceBy (perColMC, RecCol.globalIndex ());
894- std::vector<int > mclabels;
895900 for (const auto & Rectrack : recTracksPart) {
896901 if (Rectrack.has_mcParticle ()) {
897- int pid = kBkg ;
898- auto mcpart = Rectrack.template mcParticle_as <aod::McParticles>();
902+ int pid = 0 ;
903+ auto mcpart = Rectrack.mcParticle ();
904+ histos.fill (HIST (" hmcrecdndpt" ), mcpart.eta (), mcpart.pt (), static_cast <double >(kSpRecoAll ), multiplicity, mcCollision.posZ ());
899905 if (mcpart.isPhysicalPrimary ()) {
900- histos.fill (HIST (" hmcrecdndpt" ), mcpart.eta (), mcpart.pt (), static_cast <double >(kSpAll ), multiplicity, mcCollision.posZ ());
906+ histos.fill (HIST (" hmcrecdndpt" ), mcpart.eta (), mcpart.pt (), static_cast <double >(kSpRecoPrimary ), multiplicity, mcCollision.posZ ());
901907 switch (std::abs (mcpart.pdgCode ())) {
902908 case PDG_t::kPiPlus :
903909 pid = kSpPion ;
@@ -908,17 +914,16 @@ struct LongrangeCorrelation {
908914 case PDG_t::kProton :
909915 pid = kSpProton ;
910916 break ;
917+ default :
918+ pid = kSpOther ;
919+ break ;
911920 }
912921 } else {
913922 pid = kSpNotPrimary ;
914923 }
915- if (find (mclabels.begin (), mclabels.end (), Rectrack.mcParticleId ()) != mclabels.end ()) {
916- pid = kBkg ;
917- }
918- mclabels.push_back (Rectrack.mcParticleId ());
919- histos.fill (HIST (" hmcrecdndpt" ), mcpart.eta (), mcpart.pt (), static_cast <double >(pid), multiplicity, mcCollision.posZ ());
924+ histos.fill (HIST (" hmcrecdndpt" ), mcpart.eta (), mcpart.pt (), static_cast <double >(pid), multiplicity, mcCollision.posZ ());
920925 } else {
921- histos.fill (HIST (" hmcrecdndpt" ), Rectrack.eta (), Rectrack.pt (), static_cast <double >(kBkg ), multiplicity, mcCollision.posZ ());
926+ histos.fill (HIST (" hmcrecdndpt" ), Rectrack.eta (), Rectrack.pt (), static_cast <double >(kSpFake ), multiplicity, mcCollision.posZ ());
922927 }
923928 } // track (mcrec) loop
924929 } // rec collision
@@ -944,6 +949,7 @@ struct MultiplicityClassifier {
944949 Configurable<float > dcaZ{" dcaZ" , 0 .2f , " Custom DCA Z cut (ignored if negative)" };
945950 Configurable<float > cfgPtCutMin{" cfgPtCutMin" , 0 .2f , " minimum accepted track pT" };
946951 Configurable<float > cfgPtCutMax{" cfgPtCutMax" , 3 .0f , " maximum accepted track pT" };
952+ HistogramRegistry histos{" histos" , {}, OutputObjHandlingPolicy::AnalysisObject};
947953
948954 Filter fTrackSelectionITS = ncheckbit(aod::track::v001::detectorMap, (uint8_t )o2::aod::track::ITS ) &&
949955 ncheckbit (aod::track::trackCutFlag, TrackSelectionIts);
@@ -958,15 +964,20 @@ struct MultiplicityClassifier {
958964 {
959965 int enabledFunctions = 0 ;
960966 if (doprocessTracks) {
967+ histos.add (" htrackPt" , " htrackPt" , {HistType::kTH1F , {{10 , 0 ., 10 .}}});
968+ histos.add (" htrackMult" , " htrackMult" , {HistType::kTH1F , {{500 , 0 ., 500 .}}});
961969 enabledFunctions++;
962970 }
963971 if (doprocessFT0C) {
972+ histos.add (" hCentFt0c" , " hCentFt0c" , {HistType::kTH1F , {{100 , 0 ., 100 .}}});
964973 enabledFunctions++;
965974 }
966975 if (doprocessFV0A) {
976+ histos.add (" hCentFv0a" , " hCentFv0a" , {HistType::kTH1F , {{100 , 0 ., 100 .}}});
967977 enabledFunctions++;
968978 }
969979 if (doprocessFT0M) {
980+ histos.add (" hCentFt0m" , " hCentFt0m" , {HistType::kTH1F , {{100 , 0 ., 100 .}}});
970981 enabledFunctions++;
971982 }
972983 if (enabledFunctions != 1 ) {
@@ -977,26 +988,32 @@ struct MultiplicityClassifier {
977988 void processTracks (aod::Collision const &, soa::Filtered<soa::Join<aod::Tracks, aod::TracksExtra, aod::TracksDCA, aod::TrackSelection>> const & tracks)
978989 {
979990 multvalue (tracks.size ());
991+ histos.fill (HIST (" htrackMult" ), tracks.size ());
992+ for (auto const & iTrk : tracks)
993+ histos.fill (HIST (" htrackPt" ), iTrk.pt ());
980994 }
981995
982996 void processFT0C (aod::CentFT0Cs const & centralities)
983997 {
984998 for (auto const & c : centralities) {
985999 multvalue (c.centFT0C ());
1000+ histos.fill (HIST (" hCentFt0c" ), c.centFT0C ());
9861001 }
9871002 }
9881003
9891004 void processFV0A (aod::CentFV0As const & centralities)
9901005 {
9911006 for (auto const & c : centralities) {
9921007 multvalue (c.centFV0A ());
1008+ histos.fill (HIST (" hCentFv0a" ), c.centFV0A ());
9931009 }
9941010 }
9951011
9961012 void processFT0M (aod::CentFT0Ms const & centralities)
9971013 {
9981014 for (auto const & c : centralities) {
9991015 multvalue (c.centFT0M ());
1016+ histos.fill (HIST (" hCentFt0m" ), c.centFT0M ());
10001017 }
10011018 }
10021019
0 commit comments