Skip to content

Rework interface for GRL and PRW block configuration in CP algos

Oliver Majersky requested to merge omajersk/athena:per-year-config-grl-prw into main

Currently, it is not possible to simultaneously provide configuration for event GRL cleaning and PRW block configuration for all years at once.

The use-case for this scenario is if users cannot use the default auto-configured GRL and PRW and lumicalc config files for their analysis but need to specify them (for example because they use non-standard GRL where one also needs corresponding lumicalc and actualMu files for PRW).

When using YAML configuration, this limitation would imply writing separate YAML file for each sub-campaign (e.g. mc20a/d/e, mc23a/d)...we don't want to repeat this bookkeeping nightmare again.

The proposed solution here introduces extra options userLumicalcFilesPerCampaign, userPileupConfigsPerCampaign for PileupAnalysisConfig and userGRLFilesPerYear for EventCleaningConfig. These options require passing a dictionary which maps MC campaign or data year onto a list of files.

For backwards compatibility reasons, also the old userLumicalcFiles, userPileupConfigs and userGRLFiles, which simply require a list of files each, are kept. A check is done to ensure that people don't accidentally use both the legacy and the per-year/campaign options.

The PRW auto-configuration was also slightly cleaned up to make the control logic a bit clearer.

Edited by Oliver Majersky

Merge request reports