def METHOD_NAME(self, split, epoch):
    loaded_datasets = []
    paths = utils.split_paths(self.args.data)
    assert len(paths) > 0
    data_path = paths[(epoch - 1) % len(paths)]
    for k in itertools.count():
        split_k = split + (str(k) if k > 0 else "")
        path = os.path.join(data_path, split_k)
        ds = data_utils.load_indexed_dataset(
            path, self.dictionary, self.args.dataset_impl
        )
        if ds is None:
            if k > 0:
                break
            else:
                raise FileNotFoundError(
                    "Dataset not found: {} ({})".format(split, data_path)
                )
        # Since we append each block with the classification_token,
        # we need to effectively create blocks of length
        # tokens_per_sample-1
        loaded_datasets.append(
            TokenBlockDataset(
                ds,
                ds.sizes,
                self.args.tokens_per_sample - 1,
                pad=self.dictionary.pad(),
                eos=self.dictionary.eos(),
            )
        )
        logger.info(
            "{} {} {} examples".format(data_path, split_k, len(loaded_datasets[-1]))
        )
    if len(loaded_datasets) == 1:
        dataset = loaded_datasets[0]
        sizes = dataset.sizes
    else:
        dataset = ConcatDataset(loaded_datasets)
        sizes = np.concatenate([ds.sizes for ds in loaded_datasets])
    return dataset, sizes