diff --git a/test/cluster/check_alphafold2_predictions.py b/test/cluster/check_alphafold2_predictions.py index 57d19d62..14750f54 100755 --- a/test/cluster/check_alphafold2_predictions.py +++ b/test/cluster/check_alphafold2_predictions.py @@ -187,6 +187,10 @@ def _af2_subprocess_env() -> dict[str, str]: # --------------------------------------------------------------------------- # # common helper mix-in / assertions # # --------------------------------------------------------------------------- # +# AlphaPulldown's own subfolders of a fold directory (records, feature metadata, debug +# output); the folds are the other subfolders. +_ALPHAPULLDOWN_SUBDIRS = {"alphapulldown", "debug"} + class _TestBase(parameterized.TestCase): use_temp_dir = True @@ -262,7 +266,10 @@ def _runCommonTests(self, res: subprocess.CompletedProcess, multimer: bool, dirn if dirname is not None: folders = [self.output_dir / dirname] else: - folders = [d for d in self.output_dir.iterdir() if d.is_dir()] + folders = [ + d for d in self.output_dir.iterdir() + if d.is_dir() and d.name not in _ALPHAPULLDOWN_SUBDIRS + ] for folder in folders: files = list(folder.iterdir()) diff --git a/test/cluster/check_alphalink_predictions.py b/test/cluster/check_alphalink_predictions.py index d83cbab1..1ff70643 100644 --- a/test/cluster/check_alphalink_predictions.py +++ b/test/cluster/check_alphalink_predictions.py @@ -54,6 +54,10 @@ # --------------------------------------------------------------------------- # # common helper mix-in / assertions # # --------------------------------------------------------------------------- # +# AlphaPulldown's own subfolders of a fold directory (records, feature metadata, debug +# output); the folds are the other subfolders. +_ALPHAPULLDOWN_SUBDIRS = {"alphapulldown", "debug"} + class _TestBase(parameterized.TestCase): use_temp_dir = True # Class variable to control directory behavior - default to True @@ -308,7 +312,10 @@ def _check_chain_counts_and_sequences(self, protein_list: str): print(f"\nExpected sequences: {expected_sequences}") # Find the predicted PDB files (should be in the output directory) - subdirs = [d for d in self.output_dir.iterdir() if d.is_dir()] + subdirs = [ + d for d in self.output_dir.iterdir() + if d.is_dir() and d.name not in _ALPHAPULLDOWN_SUBDIRS + ] for d in subdirs: pdb_files = list(d.glob("ranked_*.pdb")) if not pdb_files: @@ -469,7 +476,8 @@ def _runCommonTests(self, res: subprocess.CompletedProcess, multimer: bool, dirn ) dirs = [dirname] if dirname else [ - d for d in self.output_dir.iterdir() if d.is_dir() + d for d in self.output_dir.iterdir() + if d.is_dir() and d.name not in _ALPHAPULLDOWN_SUBDIRS ] for d in dirs: