Closed
Description
🚀 Feature
Idea is to cover the following usage:
trainer.run(data, max_iters=1234)
# here we still have epoch length as len(data) if defined
which can be roughly done as
max_iters = 1234
trainer.run(data, epoch_length=max_iters)
# here we run 1 epoch of size max_iters
or as something like
max_iters = 1234
epoch_length = ...
max_epochs = max_iters // epoch_length + 1
@trainer.on(Events.ITERATION_COMPLETED(once=max_iters))
def stop():
trainer.terminate()
trainer.run(data, max_epochs=max_epochs)
Argument max_iters
is mutually exclusive with max_epochs
.