Commit 6c82eb88 authored by zhe chen's avatar zhe chen
Browse files

Fix the issue of the missing val.txt (#163)

parent 1ccf7825
......@@ -12,7 +12,7 @@ import torch.distributed as dist
from timm.data import Mixup, create_transform
from torchvision import transforms
from .cached_image_folder import ImageCephDataset
from .cached_image_folder import CachedImageFolder, ImageCephDataset
from .samplers import NodeDistributedSampler, SubsetRandomSampler
try:
......@@ -214,7 +214,7 @@ def build_dataset(split, config):
on_memory=config.DATA.IMG_ON_MEMORY)
elif prefix == 'val':
root = os.path.join(config.DATA.DATA_PATH, 'val')
dataset = ImageCephDataset(root, 'val', transform=transform)
dataset = CachedImageFolder(root, transform=transform)
nb_classes = 1000
elif config.DATA.DATASET == 'imagenet22K':
if prefix == 'train':
......
......@@ -24,5 +24,5 @@ PYTHONPATH="$(dirname $0)/..":$PYTHONPATH \
--cfg ${CONFIG} \
--accumulation-steps 1 \
--local-rank 0 \
--data-path /mnt/lustre/share/images \
--data-path data/imagenet \
--output work_dirs ${@:4}
......@@ -23,5 +23,5 @@ PYTHONPATH="$(dirname $0)/..":$PYTHONPATH \
python -u main_deepspeed.py \
--cfg ${CONFIG} \
--local-rank 0 \
--data-path /mnt/lustre/share/images \
--data-path data/imagenet \
--output work_dirs_deepspeed ${@:4}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment