Create DeviceDataLoader from `dataset` with `bs` and `shuffle`: process using `num_workers`.
(cls, dataset:Dataset, bs:int=64, shuffle:bool=False, device:torch.device=defaults.device,
tfms:Collection[Callable]=tfms, num_workers:int=defaults.cpus, collate_fn:Callable=data_collate, **kwargs:Any)
| 76 | |
| 77 | @classmethod |
| 78 | def create(cls, dataset:Dataset, bs:int=64, shuffle:bool=False, device:torch.device=defaults.device, |
| 79 | tfms:Collection[Callable]=tfms, num_workers:int=defaults.cpus, collate_fn:Callable=data_collate, **kwargs:Any): |
| 80 | "Create DeviceDataLoader from `dataset` with `bs` and `shuffle`: process using `num_workers`." |
| 81 | return cls(DataLoader(dataset, batch_size=bs, shuffle=shuffle, num_workers=num_workers, **kwargs), |
| 82 | device=device, tfms=tfms, collate_fn=collate_fn) |
| 83 | |
| 84 | class DataBunch(): |
| 85 | "Bind `train_dl`,`valid_dl` and `test_dl` in a data object." |
nothing calls this directly
no outgoing calls
no test coverage detected