Skip to content

Commit

Permalink
Merge pull request #132 from StollLab/macos_err
Browse files Browse the repository at this point in the history
Fix bug using wrong index when altering chain_operators
  • Loading branch information
mtessmer authored May 3, 2024
2 parents 8c265db + db1ba8a commit e509fb5
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 2 deletions.
9 changes: 9 additions & 0 deletions .github/workflows/PR_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,15 @@ on:
branches:
- "**"

workflow_dispatch:
inputs:
myCommit:
description: 'Commit SHA1'
required: true
default: 'undefined'
type: string


jobs:
tests:
runs-on: ${{ matrix.os }}
Expand Down
4 changes: 2 additions & 2 deletions src/chilife/MolSysIC.py
Original file line number Diff line number Diff line change
Expand Up @@ -769,7 +769,7 @@ def apply_chain_operators(self, idx=None, from_list=False):

cart_coords = self.protein.trajectory.coordinate_array
if isinstance(self._chain_operators, list):
for i, op in zip(idx, self._chain_operators):
for i, op in zip(idx, self._chain_operators[idx]):
for start, stop in self._chain_segs:
current_mx, current_ori = chilife.ic_mx(*cart_coords[i, start:start+3])
mx = self.chain_operators[start]['mx']
Expand All @@ -778,7 +778,7 @@ def apply_chain_operators(self, idx=None, from_list=False):
cart_coords[i, start:stop] = (cart_coords[i, start:stop] - current_ori) @ m2m3 + ori

elif from_list:
for i in range(len(cart_coords)):
for i in idx:
for start, stop in self._chain_segs:
current_mx, current_ori = chilife.ic_mx(*cart_coords[i, start:start+3])
mx = self.chain_operators[start]['mx']
Expand Down

0 comments on commit e509fb5

Please sign in to comment.