recpack.algorithms.samplers.SequenceMiniBatchSampler
- class recpack.algorithms.samplers.SequenceMiniBatchSampler(pad_token: int, batch_size: int = 100)
Samples batches of user, input sequences.
Handles sequences of unequal length by padding them with pad_token.
- Parameters
pad_token (int) – Token used to indicate that this location in the sequence contains a padding element.
batch_size (int, optional) – The number of sequences returned per batch, defaults to 100
Methods
sample
(X)