EventInfoMgt: postInclude to override bad AMITag in /TagInfo ATEAM-787
This is a patch for the bug reported in ATEAM-787. The script parses the AMITag from the input dataset name and compares to the one contained in the in-file metadata. If there are differences, it updates the TagInfoMgr to place the tag derived from the input dataset name in the AOD output.
If the AMITag from the dataset name and the in-file metadata match, we leave things as they are.
This is intended to be used as a postInclude to the Reco_tf step producing the AOD output. This is how I tested this for the overlay task reported in the ticket, for example:
export ATHENA_CORE_NUMBER=8
export ATHENA_PROC_NUMBER=8
export INDS='mc16_13TeV.410470.PhPy8EG_A14_ttbar_hdamp258p75_nonallhad.simul.HITS.e6337_s3681_tid25836826_00'
Reco_tf.py \
--postInclude a2da:EventInfoMgt/AMITagFix.py \
--inputAODFile /cvmfs/atlas-nightlies.cern.ch/repo/data/data-art/Tier0ChainTests/data18_13TeV.00357750.physics_Main.merge.AOD.r12879_p4685/AOD.26343283._000019.pool.root.1 \
--outputDAODFile art.pool.root \
--reductionConf PHYS PHYSLITE \
--maxEvents -1 \
--sharedWriter True \
--multiprocess True \
--AMITag 'r12345' \
--preExec 'from AthenaCommon.DetFlags import DetFlags; DetFlags.detdescr.all_setOff(); DetFlags.BField_setOn(); DetFlags.pileup.all_setOff(); DetFlags.overlay.all_setOff();'
Note: this would serve as a patch. I am working on fixing the AMITag propagation in the in-file metadata properly in !47767 (merged).
Edited by Frank Berghaus