@vfdev-5 I got the same output. But I still can’t explain that the evaluation happening on EPOCH_COMPLETED
@trainer.on(Events.EPOCH_COMPLETED)
takes place NOT on iteration 512 but on 688. I’ve also tried this for epoch_length=3, and engine.state.iteration is 172 when logging.

@trainer.on(Events.EPOCH_COMPLETED)
    def evaluate(trainer):
        with evaluator.add_event_handler(Events.COMPLETED, log_metrics, "train"):
            evaluator.run(train_loader)

It would make more sense to me if the both Events.ITERATION_COMPLETED(every=512) and Events.EPOCH_COMPLETED(every=1) fired the “same time”.