diff --git a/tutorials/source_en/use/data_preparation/converting_datasets.md b/tutorials/source_en/use/data_preparation/converting_datasets.md index 50fbc8687ef6a22486af9847c3a66f1505be3afa..11ea33c866010d2275ede0a1831a1da03e1b1320 100644 --- a/tutorials/source_en/use/data_preparation/converting_datasets.md +++ b/tutorials/source_en/use/data_preparation/converting_datasets.md @@ -178,12 +178,14 @@ You can use the `ImageNetToMR` class to convert the raw ImageNet data (images an Store the downloaded ImageNet dataset in a folder. The folder contains all images and a mapping file that records labels of the images. - In the mapping file, there are three columns, which are separated by spaces. They indicate image classes, label IDs, and label names. The following is an example of the mapping file: - ``` - n02119789 1 pen - n02100735 2 notbook - n02110185 3 mouse - n02096294 4 orange + In the mapping file, there are two columns, which are separated by spaces. They indicate image classes and label IDs. The following is an example of the mapping file: + ``` + n01440760 0 + n01443537 1 + n01484850 2 + n01491361 3 + n01494475 4 + n01496331 5 ``` 2. Import the `ImageNetToMR` class for dataset converting. diff --git a/tutorials/source_en/use/data_preparation/loading_the_datasets.md b/tutorials/source_en/use/data_preparation/loading_the_datasets.md index 6a47a1a22b3b896b632aaf386421184f93306909..db0ab7d1907427964acc894ae0649ef34dec4ddb 100644 --- a/tutorials/source_en/use/data_preparation/loading_the_datasets.md +++ b/tutorials/source_en/use/data_preparation/loading_the_datasets.md @@ -65,7 +65,7 @@ To read a dataset using the `MindDataset` object, perform the following steps: data_set = ds.MindDataset(dataset_file=CV_FILE_NAME) ``` In the preceding information: - `dataset_file`: specifies the MindRecord file, including the path and file name. + `dataset_file`: specifies the MindRecord file or list of MindRecord files. 2. Create a dictionary iterator and read data records through the iterator. ```python diff --git a/tutorials/source_zh_cn/use/data_preparation/converting_datasets.md b/tutorials/source_zh_cn/use/data_preparation/converting_datasets.md index 7bd585166ad30dc26656b09a6686fd7cacc8b398..ba744652da3054a25d64a8d55e95dfbf84da3071 100644 --- a/tutorials/source_zh_cn/use/data_preparation/converting_datasets.md +++ b/tutorials/source_zh_cn/use/data_preparation/converting_datasets.md @@ -178,12 +178,14 @@ MindSpore提供转换常见数据集的工具类,将常见数据集转换为Mi 对下载后的ImageNet数据集,整理数据集组织形式为一个包含所有图片的文件夹,以及一个记录图片对应标签的映射文件。 - 标签映射文件包含3列,分别为各类别图片目录、标签ID、标签名,用空格隔开,映射文件示例如下: - ``` - n02119789 1 pen - n02100735 2 notbook - n02110185 3 mouse - n02096294 4 orange + 标签映射文件包含2列,分别为各类别图片目录、标签ID,用空格隔开,映射文件示例如下: + ``` + n01440760 0 + n01443537 1 + n01484850 2 + n01491361 3 + n01494475 4 + n01496331 5 ``` 2. 导入转换数据集的工具类`ImageNetToMR`。 diff --git a/tutorials/source_zh_cn/use/data_preparation/loading_the_datasets.md b/tutorials/source_zh_cn/use/data_preparation/loading_the_datasets.md index 3186acaa2bd0c2779064fc2ae411bd324d8898f2..52a061a28df6d9838f8a7aa9b48db3901c5404e0 100644 --- a/tutorials/source_zh_cn/use/data_preparation/loading_the_datasets.md +++ b/tutorials/source_zh_cn/use/data_preparation/loading_the_datasets.md @@ -65,7 +65,7 @@ MindSpore天然支持读取MindSpore数据格式——`MindRecord`存储的数 data_set = ds.MindDataset(dataset_file=CV_FILE_NAME) ``` 其中, - `dataset_file`:指定MindRecord的文件,含路径及文件名。 + `dataset_file`:指定MindRecord的文件或文件列表。 2. 创建字典迭代器,通过迭代器读取数据记录。 ```python