Skip to content

Commit 8646f4e

Browse files
committed
Reset and fill the event properties in the runMCGen
1 parent fff9af3 commit 8646f4e

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

‎PWGDQ/Tasks/dqEfficiency_withAssoc.cxx‎

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2638,6 +2638,11 @@ struct AnalysisSameEventPairing {
26382638
if (!event.has_reducedMCevent()) {
26392639
continue;
26402640
}
2641+
// Fill the event-wise variables (e.g. centrality) of this reconstructed event, otherwise the generated particles and pairs
2642+
// get the values left over from the last event processed in runSameEventPairing
2643+
VarManager::ResetValues(0, VarManager::kNVars);
2644+
VarManager::FillEvent<gkEventFillMap>(event, dqefficiency_helpers::varValues());
2645+
VarManager::FillEvent<VarManager::ObjTypes::ReducedEventMC>(event.reducedMCevent(), dqefficiency_helpers::varValues());
26412646

26422647
FinalStateMcParticleIndices.clear();
26432648

0 commit comments

Comments
 (0)