mapping_networks.trainers.BatchAdapter¶
- class mapping_networks.trainers.BatchAdapter¶
Unpack dataloader batches into (model_inputs, targets).
Different datasets and dataloaders produce batches in different formats. A batch adapter normalizes them into the
(inputs, targets)tuple that the trainer loop expects.- __init__()¶
Methods
__init__()unpack(batch)Return
((input_arg1, ...), targets)from a dataloader batch.