ksuit.utils.training.counter¶
Classes¶
UpdateCounter is used to track the current update, epoch, and sample |
Module Contents¶
- class ksuit.utils.training.counter.UpdateCounter(start_iteration, end_iteration, updates_per_epoch, effective_batch_size)¶
UpdateCounter is used to track the current update, epoch, and sample number during training.
Initializes UpdateCounter.
- Parameters:
start_iteration (ksuit.utils.training.training_iteration.TrainingIteration) – The iteration (measured in either epochs, updates, or samples) at which the training will start. If the training is resumed the values will be updated accordingly.
end_iteration (ksuit.utils.training.training_iteration.TrainingIteration) – The iteration (measured in either epochs, updates, or samples) at which the training will end.
updates_per_epoch (int) – Number of updates per epoch.
effective_batch_size (int) – Effective batch size.
- updates_per_epoch¶
- start_iteration¶
- end_iteration¶
- cur_iteration¶
- effective_batch_size¶
- next_epoch()¶
Increments the current epoch by 1.
- Return type:
None
- next_update()¶
Increments the current update by 1.
- Return type:
None