mirror of
https://github.com/wassname/pytorch-lightning.git
synced 2026-09-10 12:21:57 +08:00
moved sampler
This commit is contained in:
@@ -173,10 +173,11 @@ class LightningTemplateModel(LightningModule):
|
||||
# print('no sampler')
|
||||
# train_sampler = None
|
||||
|
||||
should_shuffle = train_sampler is None
|
||||
loader = DataLoader(
|
||||
dataset=dataset,
|
||||
batch_size=self.hparams.batch_size,
|
||||
shuffle=True,
|
||||
shuffle=should_shuffle,
|
||||
sampler=train_sampler
|
||||
)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user