Skip to content

Commit bee05ee

Browse files
committed
try fix orb issues
1 parent 0d1b82f commit bee05ee

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

torch_sim/models/orb.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -84,9 +84,10 @@ def cell_to_cellpar(
8484
else:
8585
angle = torch.tensor(90.0, device=cell.device, dtype=cell.dtype)
8686
angles.append(angle)
87+
angles_tensor = torch.stack(angles)
8788
if radians:
88-
angles = [angle * torch.pi / 180 for angle in angles]
89-
return torch.concat((lengths, torch.stack(angles)))
89+
angles_tensor = angles_tensor * torch.pi / 180.0
90+
return torch.concat((lengths, angles_tensor))
9091

9192

9293
def state_to_atom_graphs( # noqa: PLR0915

0 commit comments

Comments
 (0)