From 3ea2e27add90a00d0a3790316d5ae26a5b241a12 Mon Sep 17 00:00:00 2001 From: Ameya Daigavane Date: Sun, 19 May 2024 11:30:16 -0700 Subject: [PATCH] Remove defaults. --- moleculib/protein/dataset.py | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/moleculib/protein/dataset.py b/moleculib/protein/dataset.py index 1825f9c..92a694c 100644 --- a/moleculib/protein/dataset.py +++ b/moleculib/protein/dataset.py @@ -486,9 +486,9 @@ class TimewarpDataset(torch.utils.data.Dataset): def __init__( self, - dataset: str = "2AA-1-big", - split: str = "train", - tau: int = 1, + dataset: str, + split: str, + tau: int, ): base = "/mas/projects/molecularmachines/db/timewarp2/" self.base_path = os.path.join(base, dataset, split) @@ -496,6 +496,9 @@ def __init__( self.tau = tau self.files = self._list_files() + if len(self.files) == 0: + raise ValueError(f"No files found in {self.base_path}") + print(f"Found {len(self.files)} files in {self.base_path}") self._load_coords(self.files[0])