Skip to content

Commit

Permalink
fix get_contact_idx_ab
Browse files Browse the repository at this point in the history
  • Loading branch information
edikedik committed Aug 4, 2024
1 parent 703b636 commit 81b7f4b
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion lXtractor/core/interface.py
Original file line number Diff line number Diff line change
Expand Up @@ -559,7 +559,7 @@ def get_contact_idx_ab(
"""
idx = np.array(list(self.G.edge_list()))
if chain_ids:
idx = idx[np.isin(idx, self._chain_atom_idx(chain_ids).any(axis=1))]
idx = idx[np.isin(idx, self._chain_atom_idx(chain_ids)).any(axis=1)]
return idx

def get_contact_idx_a(self) -> npt.NDArray[int]:
Expand Down
1 change: 1 addition & 0 deletions test/test_interface.py
Original file line number Diff line number Diff line change
Expand Up @@ -188,6 +188,7 @@ def test_io(interface_2oiq, overwrite, name, tmp_path, additional_meta):

iface_ = Interface.read(dest)
assert iface_ == iface
assert iface_.num_contact_residues(['A']) == iface.num_contact_residues(['A'])


def test_sasa(interface_2oiq):
Expand Down

0 comments on commit 81b7f4b

Please sign in to comment.