MRG fix duality gap calculation

Fixes computation of the duality gap in BCFW when using averaging.
Also minor fixes to logging.