avalanche.training.ReservoirSamplingBuffer

class avalanche.training.ReservoirSamplingBuffer(max_size: int)[source]

Buffer updated with reservoir sampling.

__init__(max_size: int)[source]
Parameters:

max_size

Methods

__init__(max_size)

param max_size:

post_adapt(agent, exp)

Update buffer.

resize(strategy, new_size)

Update the maximum size of the buffer.

update(strategy, **kwargs)

Update self.buffer using the strategy state.

update_from_dataset(new_data)

Update the buffer using the given dataset.

Attributes

buffer

Buffer of samples.

max_size

Maximum size of the buffer.