Trig_reco_tf.py: Added intermediate BS output merging step
The current Trig_reco_tf.py implementation fails to produce a single BS output file (with the name indicated b --outputBSFile) if more than 1000 events are processed at once, since athenaHLT.py then produced multiple BS files, and no merging step is currently implemented. This also results in a failure when trying to output DRAW_TRIGCOST, NTUP_TRIGCOST (dependent on DRAW_TRIGCOST), or HIST_DEBUGSTREAMMON, since the tools that produce those outputs require only one BS file to be provided as an input.
This commit addresses this issue by introducing a merging step (using file_merging, the same script that is called in bsMergeExecutor, used in Merge_tf.py and RAWMerge_tf.py, see https://gitlab.cern.ch/atlas/athena/-/blob/master/Tools/PyJobTransforms/python/trfExe.py#L2018), to be executed if more than one BS file is produced and at least one of the output arguments that require a unique BS file is used (--outputBSFile, --outputHIST_DEBUGSTREAMMONFile, --outputDRAW_TRIGCOSTFile, or --outputNTUP_TRIGCOSTFile). The merge is very fast (~1:30min to merge 2 BS files with 1200 events each), so it doesn’t impact the transform execution times.