mirror of
https://github.com/modelscope/modelscope.git
synced 2026-02-24 04:01:10 +01:00
add shuffle option for single gpu finetunning (#122)
This commit is contained in:
@@ -975,6 +975,8 @@ class EpochBasedTrainer(BaseTrainer):
|
||||
dataset, num_replicas=world_size, rank=rank, shuffle=shuffle)
|
||||
else:
|
||||
sampler = None
|
||||
if not isinstance(dataset, torch.utils.data.IterableDataset):
|
||||
kwargs['shuffle'] = shuffle
|
||||
|
||||
batch_sampler = None
|
||||
|
||||
|
||||
Reference in New Issue
Block a user