From 720290e4e6c897156ab33ee6c5942e01e9f4bedd Mon Sep 17 00:00:00 2001 From: Simon Blackburn Date: Tue, 19 Mar 2024 14:25:11 -0400 Subject: [PATCH] weird lines added --- crystal_diffusion/data/data_loader.py | 1 - crystal_diffusion/data/data_preprocess.py | 1 - crystal_diffusion/data/diffusion/data_preprocess.py | 4 ++-- 3 files changed, 2 insertions(+), 4 deletions(-) diff --git a/crystal_diffusion/data/data_loader.py b/crystal_diffusion/data/data_loader.py index ad2018ca..d837a5b0 100644 --- a/crystal_diffusion/data/data_loader.py +++ b/crystal_diffusion/data/data_loader.py @@ -119,4 +119,3 @@ def test_dataloader(self): shuffle=False, num_workers=self.num_workers, ) - diff --git a/crystal_diffusion/data/data_preprocess.py b/crystal_diffusion/data/data_preprocess.py index e0c35a45..83ee3259 100644 --- a/crystal_diffusion/data/data_preprocess.py +++ b/crystal_diffusion/data/data_preprocess.py @@ -138,4 +138,3 @@ def prepare_dataset(self): self.test_images = test_images self.test_labels = test_labels - diff --git a/crystal_diffusion/data/diffusion/data_preprocess.py b/crystal_diffusion/data/diffusion/data_preprocess.py index 7dd58ae0..87854066 100644 --- a/crystal_diffusion/data/diffusion/data_preprocess.py +++ b/crystal_diffusion/data/diffusion/data_preprocess.py @@ -42,8 +42,8 @@ def prepare_data(self, raw_data_dir: str, mode: str = 'train') -> List[str]: # we assume that raw_data_dir contains subdirectories named train_run_N for N>=1 # get the list of runs to parse assert mode in ['train', 'valid', 'test'], f"Mode should be train, valid or test. Got {mode}." - list_runs = [d for d in os.listdir(raw_data_dir) if os.path.isdir(os.path.join(raw_data_dir, d)) and - d.startswith(f"{mode}_run")] + list_runs = [d for d in os.listdir(raw_data_dir) if os.path.isdir(os.path.join(raw_data_dir, d)) + and d.startswith(f"{mode}_run")] list_files = [] for d in list_runs: if f"{d}.parquet" not in os.listdir(self.data_dir):