diff --git a/demo/imagenet_reader.py b/demo/imagenet_reader.py index 55512e4f71a9b4ca057dbf6bfa928b1bdf4750fb..295ce218df79b1a6717abc46d5f49d2d999cd13f 100644 --- a/demo/imagenet_reader.py +++ b/demo/imagenet_reader.py @@ -156,8 +156,8 @@ def _reader_creator(file_list, for line in lines: if mode == 'train' or mode == 'val': img_path, label = line.split() - img_path = os.path.join(data_dir + "/" + mode, - img_path) + img_path = os.path.join( + os.path.join(data_dir, mode), img_path) yield img_path, int(label) elif mode == 'test': img_path = os.path.join(data_dir, line) diff --git a/demo/quant/quant_aware/README.md b/demo/quant/quant_aware/README.md index f7fa2686d52ae168f82840f6798fe4ebebb816d6..407a882607033e22562595bda26008bb09038cd5 100644 --- a/demo/quant/quant_aware/README.md +++ b/demo/quant/quant_aware/README.md @@ -10,7 +10,7 @@ ### 准备数据 -在``demo``文件夹下创建``data``文件夹,将``ImageNet``数据集解压在``data``文件夹下,解压后``data``文件夹下应包含以下文件: +在``demo``文件夹下创建``data``文件夹,将``ImageNet``数据集解压在``data``文件夹下,解压后``data/ILSVRC2012``文件夹下应包含以下文件: - ``'train'``文件夹,训练图片 - ``'train_list.txt'``文件 - ``'val'``文件夹,验证图片 diff --git a/demo/quant/quant_post/README.md b/demo/quant/quant_post/README.md index 027bcf3dba6ba6079ab1da942ee393f6751010c0..cda541037c7e9d4895513773e2fdd5a9579d18ed 100755 --- a/demo/quant/quant_post/README.md +++ b/demo/quant/quant_post/README.md @@ -10,7 +10,7 @@ ### 准备数据 -在``demo``文件夹下创建``data``文件夹,将``ImageNet``数据集解压在``data``文件夹下,解压后``data``文件夹下应包含以下文件: +在``demo``文件夹下创建``data``文件夹,将``ImageNet``数据集解压在``data``文件夹下,解压后``data/ILSVRC2012``文件夹下应包含以下文件: - ``'train'``文件夹,训练图片 - ``'train_list.txt'``文件 - ``'val'``文件夹,验证图片