diff --git a/python/BioSimSpace/Sandpit/Exscientia/Trajectory/_trajectory.py b/python/BioSimSpace/Sandpit/Exscientia/Trajectory/_trajectory.py index e3d747ca0..b49a05d7d 100644 --- a/python/BioSimSpace/Sandpit/Exscientia/Trajectory/_trajectory.py +++ b/python/BioSimSpace/Sandpit/Exscientia/Trajectory/_trajectory.py @@ -1120,11 +1120,10 @@ def _split_molecules(frame, pdb, reference, work_dir, property_map={}): # Create a triclinic space from the information in the frame file. if isinstance(frame, _SireIO.AmberRst7): - # Get the box dimensions and angles. Take the values, since the - # units are wrong. + # Get the box dimensions and angles. degree = _SireUnits.degree dimensions = [x.value() for x in frame.box_dimensions()] - angles = [x.value() * degree for x in frame.box_angles()] + angles = [x.to(degree) * degree for x in frame.box_angles()] box = _SireVol.TriclinicBox(*dimensions, *angles) else: box = _SireVol.TriclinicBox(frame.box_v1(), frame.box_v2(), frame.box_v3()) diff --git a/python/BioSimSpace/Sandpit/Exscientia/_SireWrappers/_system.py b/python/BioSimSpace/Sandpit/Exscientia/_SireWrappers/_system.py index c1fed655f..3b9a22aa3 100644 --- a/python/BioSimSpace/Sandpit/Exscientia/_SireWrappers/_system.py +++ b/python/BioSimSpace/Sandpit/Exscientia/_SireWrappers/_system.py @@ -1228,7 +1228,10 @@ def rotateBoxVectors( try: prop_name = property_map.get("velocity", "velocity") cursor = cursor.rotate( - center=center, matrix=rotation_matrix, map={"coordinates": prop_name} + center=center, + matrix=rotation_matrix, + rotate_velocities=False, + map={"coordinates": prop_name}, ) except: pass @@ -1241,12 +1244,14 @@ def rotateBoxVectors( cursor = cursor.rotate( center=center, matrix=rotation_matrix, + rotate_velocities=False, map={"coordinates": prop_name}, ) prop_name = property_map.get("coordinates", "coordinates") + "1" cursor = cursor.rotate( center=center, matrix=rotation_matrix, + rotate_velocities=False, map={"coordinates": prop_name}, ) except: @@ -1258,12 +1263,14 @@ def rotateBoxVectors( cursor = cursor.rotate( center=center, matrix=rotation_matrix, + rotate_velocities=False, map={"coordinates": prop_name}, ) prop_name = property_map.get("velocity", "velocity") + "1" cursor = cursor.rotate( center=center, matrix=rotation_matrix, + rotate_velocities=False, map={"coordinates": prop_name}, ) except: diff --git a/python/BioSimSpace/Trajectory/_trajectory.py b/python/BioSimSpace/Trajectory/_trajectory.py index e3d747ca0..b49a05d7d 100644 --- a/python/BioSimSpace/Trajectory/_trajectory.py +++ b/python/BioSimSpace/Trajectory/_trajectory.py @@ -1120,11 +1120,10 @@ def _split_molecules(frame, pdb, reference, work_dir, property_map={}): # Create a triclinic space from the information in the frame file. if isinstance(frame, _SireIO.AmberRst7): - # Get the box dimensions and angles. Take the values, since the - # units are wrong. + # Get the box dimensions and angles. degree = _SireUnits.degree dimensions = [x.value() for x in frame.box_dimensions()] - angles = [x.value() * degree for x in frame.box_angles()] + angles = [x.to(degree) * degree for x in frame.box_angles()] box = _SireVol.TriclinicBox(*dimensions, *angles) else: box = _SireVol.TriclinicBox(frame.box_v1(), frame.box_v2(), frame.box_v3()) diff --git a/python/BioSimSpace/_SireWrappers/_system.py b/python/BioSimSpace/_SireWrappers/_system.py index 8208eb0da..3ab8258f9 100644 --- a/python/BioSimSpace/_SireWrappers/_system.py +++ b/python/BioSimSpace/_SireWrappers/_system.py @@ -1167,7 +1167,10 @@ def rotateBoxVectors( try: prop_name = property_map.get("coordinates", "coordinates") cursor = cursor.rotate( - center=center, matrix=rotation_matrix, map={"coordinates": prop_name} + center=center, + matrix=rotation_matrix, + rotate_velocities=False, + map={"coordinates": prop_name}, ) except: pass @@ -1176,7 +1179,10 @@ def rotateBoxVectors( try: prop_name = property_map.get("velocity", "velocity") cursor = cursor.rotate( - center=center, matrix=rotation_matrix, map={"coordinates": prop_name} + center=center, + matrix=rotation_matrix, + rotate_velocities=False, + map={"coordinates": prop_name}, ) except: pass @@ -1189,12 +1195,14 @@ def rotateBoxVectors( cursor = cursor.rotate( center=center, matrix=rotation_matrix, + rotate_velocities=False, map={"coordinates": prop_name}, ) prop_name = property_map.get("coordinates", "coordinates") + "1" cursor = cursor.rotate( center=center, matrix=rotation_matrix, + rotate_velocities=False, map={"coordinates": prop_name}, ) except: @@ -1206,12 +1214,14 @@ def rotateBoxVectors( cursor = cursor.rotate( center=center, matrix=rotation_matrix, + rotate_velocities=False, map={"coordinates": prop_name}, ) prop_name = property_map.get("velocity", "velocity") + "1" cursor = cursor.rotate( center=center, matrix=rotation_matrix, + rotate_velocities=False, map={"coordinates": prop_name}, ) except: