Small fix for trainer
Small fix for trainer

Summary: Pull Request resolved: https://github.com/fairinternal/fairseq-py/pull/711

Differential Revision: D16192752

Pulled By: myleott

fbshipit-source-id: 102ed337a3d31e2047be7c033e9007c04223a684

pytorch/fairseq,pytorch/fairseq,pytorch/fairseq