Skip to content

Use one-line jet&MET calculator declarations, for automatic reuse

Pieter David requested to merge piedavid/bamboo:onelinejmecalc into master

Depends on https://gitlab.cern.ch/cp3-cms/CMSJMECalculators/-/merge_requests/5

Based on the discussion in https://gitlab.cern.ch/cp3-cms/bamboo/-/merge_requests/206 : with the factory methods we declare the calculators with

const auto myCalc = JetVariationsCalculator::create(...);

such that we don't need an unique name (the declaration string embeds all information), and reuse with the parallel (or sequential) backend is safe and automatic. Another benefit is that this gets rid of one difference between the regular and compiled backend, which came with a few hacks that are gone now.

One thing that I'm wondering about is if the python helpers that I added should better be moved to CMSJMECalculators (adding a method to them that can be used to construct a calculator from PyROOT shouldn't be too hard, then they may be more generally useful).

Edited by Pieter David

Merge request reports