Do we need a special field name "EVENT" for event level variables?

Moving the discusion to this issue.

We have Opt1 (what is done currently) i.e. we define a new special branch "EVENT" and load it with event level functorcollection.

variables = {
    "EVENT": evt_variables,
    "D0": d0_variables,
    "Kminus": daughter_variables,
    "piplus": daughter_variables}

my_tuple = Funtuple(
        name="Tuple",
        tuple_name="DecayTree",
        fields=fields,
        variables=variables,
        inputs=d02kpi_data)

Then we have Opt2 i.e no special branch but an extra argument to FunTuple (event_variables)

variables = {
    "D0": d0_variables,
    "Kminus": daughter_variables,
    "piplus": daughter_variables}

my_tuple = Funtuple(
        name="Tuple",
        tuple_name="DecayTree",
        fields=fields,
        variables=variables,
        event_variables=evt_variables,
        inputs=d02kpi_data)

The benefit of Opt1:

  • One place that users can dump functor collections which is in variables attribute of FunTuple.
  • If its well documented @pkoppenb thinks is not a problem since we also have a special branch "ALL".

The benefit of Opt2:

  • @sstahl reckons it leads to less code fewer exceptions which also better documents itself.

Work on DPA master task https://gitlab.cern.ch/lhcb-dpa/project/-/issues/121.

FYI: @erodrigu

Edited by Eduardo Rodrigues