Skip to content

Commit 244a23e

Browse files
committed
[fix] Address the francisco's review
1 parent d20c1b5 commit 244a23e

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

autoPyTorch/datasets/base_dataset.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ class BaseDataset(Dataset, metaclass=ABCMeta):
7474
def __init__(
7575
self,
7676
train_tensors: BaseDatasetInputType,
77-
dataset_name: Optional[str] = None,
77+
dataset_name: str = "",
7878
val_tensors: Optional[BaseDatasetInputType] = None,
7979
test_tensors: Optional[BaseDatasetInputType] = None,
8080
resampling_strategy: Union[CrossValTypes, HoldoutValTypes] = HoldoutValTypes.holdout_validation,
@@ -108,9 +108,9 @@ def __init__(
108108
val_transforms (Optional[torchvision.transforms.Compose]):
109109
Additional Transforms to be applied to the validation/test data
110110
"""
111-
self.dataset_name = ""
111+
self.dataset_name = dataset_name
112112

113-
if self.dataset_name is not None:
113+
if self.dataset_name == "":
114114
self.dataset_name = str(uuid.uuid1(clock_seq=os.getpid()))
115115

116116
if not hasattr(train_tensors[0], 'shape'):

0 commit comments

Comments
 (0)