File tree Expand file tree Collapse file tree 1 file changed +34
-0
lines changed
Expand file tree Collapse file tree 1 file changed +34
-0
lines changed Original file line number Diff line number Diff line change @@ -2256,6 +2256,40 @@ struct AnalysisSameEventPairing {
22562256 isig++;
22572257 }
22582258 }
2259+ // Fill Generated PAIR histograms taking into account selected collisions
2260+ for (auto & event : events) {
2261+ if (!event.isEventSelected_bit (0 )) {
2262+ continue ;
2263+ }
2264+ if (!event.has_reducedMCevent ()) {
2265+ continue ;
2266+ }
2267+
2268+ if (fHasTwoProngGenMCsignals ) {
2269+ for (auto & [t1, t2] : combinations (mcTracks, mcTracks)) {
2270+ if (t1.reducedMCeventId () != event.reducedMCeventId ()) {
2271+ continue ;
2272+ }
2273+ if (t2.reducedMCeventId () != event.reducedMCeventId ()) {
2274+ continue ;
2275+ }
2276+ auto t1_raw = mcTracks.rawIteratorAt (t1.globalIndex ());
2277+ auto t2_raw = mcTracks.rawIteratorAt (t2.globalIndex ());
2278+ if (t1_raw.reducedMCeventId () == t2_raw.reducedMCeventId ()) {
2279+ for (auto & sig : fGenMCSignals ) {
2280+ if (sig->GetNProngs () != 2 ) { // NOTE: 2-prong signals required here
2281+ continue ;
2282+ }
2283+ if (sig->CheckSignal (true , t1_raw, t2_raw)) {
2284+ // mcDecision |= (static_cast<uint32_t>(1) << isig);
2285+ VarManager::FillPairMC<VarManager::kDecayToMuMu >(t1, t2); // NOTE: This feature will only work for muons
2286+ fHistMan ->FillHistClass (Form (" MCTruthGenPairSel_%s" , sig->GetName ()), VarManager::fgValues);
2287+ }
2288+ }
2289+ }
2290+ }
2291+ }
2292+ } // end loop over reconstructed events
22592293 }
22602294
22612295 void processDummy (MyEvents&)
You can’t perform that action at this time.
0 commit comments