From 65f0badf141fb356a937230a3baccf863bafaef1 Mon Sep 17 00:00:00 2001 From: weishengyu Date: Thu, 3 Jun 2021 15:14:05 +0800 Subject: [PATCH] merge dataset and sampler -> dataloader --- ppcls/data/__init__.py | 10 +++++----- .../DistributedRandomIdentitySampler.py | 0 ppcls/data/{dataset => dataloader}/__init__.py | 0 ppcls/data/{dataset => dataloader}/common_dataset.py | 0 .../{dataset => dataloader}/flowers102/__init__.py | 0 .../flowers102/generate_flowers102_list.py | 0 ppcls/data/{dataset => dataloader}/imagenet_dataset.py | 0 .../data/{dataset => dataloader}/multilabel_dataset.py | 0 ppcls/data/{dataset => dataloader}/vehicle_dataset.py | 0 ppcls/data/samplers/__init__.py | 1 - 10 files changed, 5 insertions(+), 6 deletions(-) rename ppcls/data/{samplers => dataloader}/DistributedRandomIdentitySampler.py (100%) rename ppcls/data/{dataset => dataloader}/__init__.py (100%) rename ppcls/data/{dataset => dataloader}/common_dataset.py (100%) rename ppcls/data/{dataset => dataloader}/flowers102/__init__.py (100%) rename ppcls/data/{dataset => dataloader}/flowers102/generate_flowers102_list.py (100%) rename ppcls/data/{dataset => dataloader}/imagenet_dataset.py (100%) rename ppcls/data/{dataset => dataloader}/multilabel_dataset.py (100%) rename ppcls/data/{dataset => dataloader}/vehicle_dataset.py (100%) delete mode 100644 ppcls/data/samplers/__init__.py diff --git a/ppcls/data/__init__.py b/ppcls/data/__init__.py index c7efa217..de62cc5d 100644 --- a/ppcls/data/__init__.py +++ b/ppcls/data/__init__.py @@ -18,14 +18,14 @@ from paddle.io import DistributedBatchSampler, BatchSampler, DataLoader from ppcls.utils import logger -from . import dataset +from . import dataloader from . import imaug from . import samplers # dataset -from .dataset.imagenet_dataset import ImageNetDataset -from .dataset.multilabel_dataset import MultiLabelDataset -from .dataset.common_dataset import create_operators -from .dataset.vehicle_dataset import CompCars, VeriWild +from .dataloader.imagenet_dataset import ImageNetDataset +from .dataloader.multilabel_dataset import MultiLabelDataset +from .dataloader.common_dataset import create_operators +from .dataloader.vehicle_dataset import CompCars, VeriWild # sampler from .samplers import DistributedRandomIdentitySampler diff --git a/ppcls/data/samplers/DistributedRandomIdentitySampler.py b/ppcls/data/dataloader/DistributedRandomIdentitySampler.py similarity index 100% rename from ppcls/data/samplers/DistributedRandomIdentitySampler.py rename to ppcls/data/dataloader/DistributedRandomIdentitySampler.py diff --git a/ppcls/data/dataset/__init__.py b/ppcls/data/dataloader/__init__.py similarity index 100% rename from ppcls/data/dataset/__init__.py rename to ppcls/data/dataloader/__init__.py diff --git a/ppcls/data/dataset/common_dataset.py b/ppcls/data/dataloader/common_dataset.py similarity index 100% rename from ppcls/data/dataset/common_dataset.py rename to ppcls/data/dataloader/common_dataset.py diff --git a/ppcls/data/dataset/flowers102/__init__.py b/ppcls/data/dataloader/flowers102/__init__.py similarity index 100% rename from ppcls/data/dataset/flowers102/__init__.py rename to ppcls/data/dataloader/flowers102/__init__.py diff --git a/ppcls/data/dataset/flowers102/generate_flowers102_list.py b/ppcls/data/dataloader/flowers102/generate_flowers102_list.py similarity index 100% rename from ppcls/data/dataset/flowers102/generate_flowers102_list.py rename to ppcls/data/dataloader/flowers102/generate_flowers102_list.py diff --git a/ppcls/data/dataset/imagenet_dataset.py b/ppcls/data/dataloader/imagenet_dataset.py similarity index 100% rename from ppcls/data/dataset/imagenet_dataset.py rename to ppcls/data/dataloader/imagenet_dataset.py diff --git a/ppcls/data/dataset/multilabel_dataset.py b/ppcls/data/dataloader/multilabel_dataset.py similarity index 100% rename from ppcls/data/dataset/multilabel_dataset.py rename to ppcls/data/dataloader/multilabel_dataset.py diff --git a/ppcls/data/dataset/vehicle_dataset.py b/ppcls/data/dataloader/vehicle_dataset.py similarity index 100% rename from ppcls/data/dataset/vehicle_dataset.py rename to ppcls/data/dataloader/vehicle_dataset.py diff --git a/ppcls/data/samplers/__init__.py b/ppcls/data/samplers/__init__.py deleted file mode 100644 index a6fb850d..00000000 --- a/ppcls/data/samplers/__init__.py +++ /dev/null @@ -1 +0,0 @@ -from .DistributedRandomIdentitySampler import DistributedRandomIdentitySampler -- GitLab