experanto.utils.ShortCycler

class ShortCycler(loaders)[source]

Bases: object

Cycle through multiple dataloaders until the shortest is exhausted.

Similar to LongCycler, but stops when the smallest loader completes one epoch. No recycling occurs.

Parameters:

loaders (dict) – Dictionary mapping session keys to DataLoader instances.

min_batches

Number of batches in the shortest loader.

Type:

int

Methods

__init__(loaders)

__init__(loaders)[source]