Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion test/cluster/check_alphafold2_predictions.py
Original file line number Diff line number Diff line change
Expand Up @@ -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

Expand Down Expand Up @@ -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())
Expand Down
12 changes: 10 additions & 2 deletions test/cluster/check_alphalink_predictions.py
Original file line number Diff line number Diff line change
Expand Up @@ -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

Expand Down Expand Up @@ -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:
Expand Down Expand Up @@ -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:
Expand Down
Loading