revert removal of stats generation