From 4849757eba6fb02b8ff6387b3263c5a21d5fe7ae Mon Sep 17 00:00:00 2001 From: Gabriel Studer <gabriel.studer@unibas.ch> Date: Mon, 15 Apr 2024 15:33:29 +0200 Subject: [PATCH] lDDT: bugfix --- modules/mol/alg/pymod/lddt.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/modules/mol/alg/pymod/lddt.py b/modules/mol/alg/pymod/lddt.py index 59d9e0b4e..48e40c264 100644 --- a/modules/mol/alg/pymod/lddt.py +++ b/modules/mol/alg/pymod/lddt.py @@ -1041,6 +1041,11 @@ class lDDTScorer: mask_start.extend([r_start_idx] * n_valid_atoms) mask_end.extend([r_start_idx + n_valid_atoms] * n_valid_atoms) r_start_idx += n_valid_atoms + + if len(pos_list) == 0: + # nothing to do... + continue + pos = np.vstack(pos_list) atom_indices = np.asarray(atom_indices) dists = cdist(pos, pos) -- GitLab