def fold_loaders(self, fold=(- 1)):
    '\n        Loading a specific fold as train and test data loader. If no fold number is provided it returns the next fold. It returns a randomly sampled subset of\n        the original data set.\n\n        Args:\n            fold: fold number to return\n\n        Returns:\n            (train data loader, test data loader)\n\n        '
    if (fold == (- 1)):
        fold = self.fold
    test_fold_idx = self.fold_idx[fold]
    train_fold_idx = self.fold_idx[[i for i in range(self.n_fold) if (i != fold)]].view((- 1))
    train_loader = torch.utils.data.DataLoader(self.dataset, batch_size=self.batch_size, num_workers=self.num_workers, pin_memory=self.pin_memory, sampler=torch.utils.data.SubsetRandomSampler(train_fold_idx))
    test_loader = torch.utils.data.DataLoader(self.dataset, batch_size=self.batch_size, num_workers=self.num_workers, pin_memory=self.pin_memory, sampler=torch.utils.data.SubsetRandomSampler(test_fold_idx))
    self.fold = ((self.fold + 1) % self.n_fold)
    return (train_loader, test_loader)
Loading a specific fold as train and test data loader. If no fold number is provided it returns the next fold. It returns a randomly sampled subset of
the original data set.

Args:
    fold: fold number to return

Returns:
    (train data loader, test data loader)
def fold_loaders(self, fold=(- 1)):
    '\n        Loading a specific fold as train and test data loader. If no fold number is provided it returns the next fold. It returns a randomly sampled subset of\n        the original data set.\n\n        Args:\n            fold: fold number to return\n\n        Returns:\n            (train data loader, test data loader)\n\n        '
    if (fold == (- 1)):
        fold = self.fold
    test_fold_idx = self.fold_idx[fold]
    train_fold_idx = self.fold_idx[[i for i in range(self.n_fold) if (i != fold)]].view((- 1))
    train_loader = torch.utils.data.DataLoader(self.dataset, batch_size=self.batch_size, num_workers=self.num_workers, pin_memory=self.pin_memory, sampler=torch.utils.data.SubsetRandomSampler(train_fold_idx))
    test_loader = torch.utils.data.DataLoader(self.dataset, batch_size=self.batch_size, num_workers=self.num_workers, pin_memory=self.pin_memory, sampler=torch.utils.data.SubsetRandomSampler(test_fold_idx))
    self.fold = ((self.fold + 1) % self.n_fold)
    return (train_loader, test_loader)