Skip to content

Rework MC weights retrieving in AnalysisTop

This MR is a reworking of how nominal MC weight is determined in AnalysisTop, and how nominal CutBookkeeper and MC generator weight variations bookkeepers are retrieved.

  • A new configuration option (with sane defaults) is provided to give a list of weight names that should be checked if they exist in the MC sample, the PMGTruthWeightTool is used for this
  • If none of the weights match any weight found in the sample, we crash with error message, providing instructions to the user what he should do.
  • AllExecutedEvents_XYZ bookkeepers are searched based on weights retrieved by PMGTruthWeightTool to determine the proper corresponding bookkeeper for the nominal weight.
  • If PMGTruthWeightTool does not find any weights (either the sample doesn't have any, or we cannot rely on MetaData), 0th element from EventInfo MC weights vector is used.

Fixes ANALYSISTO-906

Edited by Oliver Majersky

Merge request reports