From bbf77c9f91ad04fc865e5ffd56270fddbdc56f43 Mon Sep 17 00:00:00 2001 From: Yin Li Date: Tue, 14 Jul 2020 18:47:26 -0400 Subject: [PATCH] Deprecate GroupedRandomSampler for use of memmap in place of cache --- map2map/data/__init__.py | 1 - map2map/data/sampler.py | 3 +++ map2map/train.py | 2 +- 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/map2map/data/__init__.py b/map2map/data/__init__.py index fe313f0..0fe6e8a 100644 --- a/map2map/data/__init__.py +++ b/map2map/data/__init__.py @@ -1,2 +1 @@ from .fields import FieldDataset -from .sampler import GroupedRandomSampler diff --git a/map2map/data/sampler.py b/map2map/data/sampler.py index 9bf3436..f0cb05b 100644 --- a/map2map/data/sampler.py +++ b/map2map/data/sampler.py @@ -1,3 +1,6 @@ +""" +Deprecated for use of memmap in place of cache +""" from itertools import chain import torch from torch.utils.data import Sampler diff --git a/map2map/train.py b/map2map/train.py index c779466..8e1e010 100644 --- a/map2map/train.py +++ b/map2map/train.py @@ -14,7 +14,7 @@ from torch.utils.data.distributed import DistributedSampler from torch.utils.data import DataLoader from torch.utils.tensorboard import SummaryWriter -from .data import FieldDataset, GroupedRandomSampler +from .data import FieldDataset from .data.figures import plt_slices from . import models from .models import (narrow_cast, resample,