Skip to content

Commit

Permalink
matmul inplace backwards compatibility #178
Browse files Browse the repository at this point in the history
  • Loading branch information
jacanchaplais committed Jun 1, 2024
1 parent 7976a69 commit bf1e658
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions tests/test_transform.py
Original file line number Diff line number Diff line change
Expand Up @@ -67,10 +67,14 @@ def test_momentum_split():
# invert the split of the first child:
first_child_inv = children[0].copy()
first_child_inv /= energy_fraction
first_child_inv._data[0, :3] @= gcl.transform.rotation_matrix(
-rotation_angle,
rotation_axis,
).T
np.matmul(
first_child_inv._data[0, :3],
gcl.transform.rotation_matrix(
-rotation_angle,
rotation_axis,
).T,
out=first_child_inv._data[0, :3],
)
assert np.allclose(parent, first_child_inv)


Expand Down

0 comments on commit bf1e658

Please sign in to comment.