提交 00a4e188 编写于 作者: M mindspore-ci-bot 提交者: Gitee

!1590 dataset: fix some format problem in take and split

Merge pull request !1590 from ms_yan/r0.3_format
......@@ -590,7 +590,7 @@ class Dataset:
# here again
dataset_size = self.get_dataset_size()
if(dataset_size is None or dataset_size <= 0):
if dataset_size is None or dataset_size <= 0:
raise RuntimeError("dataset size unknown, unable to split.")
all_int = all(isinstance(item, int) for item in sizes)
......@@ -1173,6 +1173,7 @@ class SourceDataset(Dataset):
def is_sharded(self):
raise NotImplementedError("SourceDataset must implement is_sharded.")
class MappableDataset(SourceDataset):
"""
Abstract class to represent a source dataset which supports use of samplers.
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册