ER#
Arguments#
Rehearsal arguments
Arguments shared by all rehearsal-based methods.
- --buffer_sizeint
Help: The size of the memory buffer.
Default:
None
- --minibatch_sizeint
Help: The batch size of the memory buffer.
Default:
None
This module implements the simplest form of rehearsal training: Experience Replay. It maintains a buffer of previously seen examples and uses them to augment the current batch during training.
- Example usage:
model = Er(backbone, loss, args, transform, dataset) loss = model.observe(inputs, labels, not_aug_inputs, epoch)
Classes#
- class models.er.Er(backbone, loss, args, transform, dataset=None)[source]#
Bases:
ContinualModel
Continual learning via Experience Replay.