@@ -43,7 +43,7 @@ static constexpr int kFV0MultZeqs = 9;
4343static constexpr int kFT0MultZeqs = 10 ;
4444static constexpr int kFDDMultZeqs = 11 ;
4545static constexpr int kPVMultZeqs = 12 ;
46- static constexpr int kMultsExtraMC = 13 ;
46+ static constexpr int kMultMCExtras = 13 ;
4747static constexpr int nTables = 14 ;
4848
4949// Checking that the Zeq tables are after the normal ones
@@ -66,7 +66,7 @@ static const std::vector<std::string> tableNames{"FV0Mults", // 0
6666 " FT0MultZeqs" , // 10
6767 " FDDMultZeqs" , // 11
6868 " PVMultZeqs" , // 12
69- " MultsExtraMC " }; // 13
69+ " MultMCExtras " }; // 13
7070static const std::vector<std::string> parameterNames{" Enable" };
7171static const int defaultParameters[nTables][nParameters]{{-1 }, {-1 }, {-1 }, {-1 }, {-1 }, {-1 }, {-1 }, {-1 }, {-1 }, {-1 }, {-1 }, {-1 }, {-1 }, {-1 }};
7272
@@ -85,7 +85,8 @@ struct MultiplicityTable {
8585 Produces<aod::FT0MultZeqs> tableFT0Zeqs; // 10
8686 Produces<aod::FDDMultZeqs> tableFDDZeqs; // 11
8787 Produces<aod::PVMultZeqs> tablePVZeqs; // 12
88- Produces<aod::MultsExtraMC> tableExtraMc; // 13
88+ Produces<aod::MultMCExtras> tableExtraMc; // 13
89+ Produces<aod::MC2Mults> tableExtraMc2Mults;
8990 Produces<aod::MultsGlobal> multsGlobal; // Not accounted for, produced based on process function processGlobalTrackingCounters
9091
9192 // For vertex-Z corrections in calibration
@@ -163,10 +164,11 @@ struct MultiplicityTable {
163164 }
164165 }
165166 // Handle the custom cases.
166- if (tEnabled[kMultsExtraMC ]) {
167- if (enabledTables->get (tableNames[kMultsExtraMC ].c_str (), " Enable" ) == -1 ) {
167+ if (tEnabled[kMultMCExtras ]) {
168+ if (enabledTables->get (tableNames[kMultMCExtras ].c_str (), " Enable" ) == -1 ) {
168169 doprocessMC.value = true ;
169- LOG (info) << " Enabling MC processing due to " << tableNames[kMultsExtraMC ] << " table being enabled." ;
170+ doprocessMC2Mults.value = true ;
171+ LOG (info) << " Enabling MC processing due to " << tableNames[kMultMCExtras ] << " table being enabled." ;
170172 }
171173 }
172174
@@ -335,7 +337,7 @@ struct MultiplicityTable {
335337 case kPVMultZeqs : // Equalized multiplicity for PV
336338 tablePVZeqs.reserve (collisions.size ());
337339 break ;
338- case kMultsExtraMC : // MC extra information (nothing to do in the data)
340+ case kMultMCExtras : // MC extra information (nothing to do in the data)
339341 break ;
340342 default :
341343 LOG (fatal) << " Unknown table requested: " << i;
@@ -609,7 +611,7 @@ struct MultiplicityTable {
609611 }
610612 tablePVZeqs (multZeqNContribs);
611613 } break ;
612- case kMultsExtraMC : // MC only (nothing to do)
614+ case kMultMCExtras : // MC only (nothing to do)
613615 {
614616 } break ;
615617 default : // Default
@@ -665,6 +667,11 @@ struct MultiplicityTable {
665667 tableExtraMc (multFT0A, multFT0C, multBarrelEta05, multBarrelEta08, multBarrelEta10, mcCollision.posZ ());
666668 }
667669
670+ void processMC2Mults (soa::Join<aod::McCollisionLabels, aod::Collisions>::iterator const & collision)
671+ {
672+ tableExtraMc2Mults (collision.mcCollisionId ()); // interlink
673+ }
674+
668675 Configurable<float > min_pt_globaltrack{" min_pt_globaltrack" , 0.15 , " min. pT for global tracks" };
669676 Configurable<float > max_pt_globaltrack{" max_pt_globaltrack" , 1e+10 , " max. pT for global tracks" };
670677 Configurable<int > min_ncluster_its_globaltrack{" min_ncluster_its_globaltrack" , 5 , " min. number of ITS clusters for global tracks" };
@@ -715,6 +722,7 @@ struct MultiplicityTable {
715722 PROCESS_SWITCH (MultiplicityTable, processRun3, " Produce Run 3 multiplicity tables" , true );
716723 PROCESS_SWITCH (MultiplicityTable, processGlobalTrackingCounters, " Produce Run 3 global counters" , false );
717724 PROCESS_SWITCH (MultiplicityTable, processMC, " Produce MC multiplicity tables" , false );
725+ PROCESS_SWITCH (MultiplicityTable, processMC2Mults, " Produce MC -> Mult map" , false );
718726};
719727
720728WorkflowSpec defineDataProcessing (ConfigContext const & cfgc)
0 commit comments