Skip to content

Commit 3b24bb5

Browse files
author
Tim Joseph
committed
Formatting
1 parent 88be148 commit 3b24bb5

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/tensorcontainer/tensor_container.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -609,9 +609,9 @@ def reshape(self: Self, *shape: int) -> Self:
609609
def to(self: Self, *args, **kwargs) -> Self:
610610
with TensorContainer.unsafe_construction():
611611
leaves, context = self._pytree_flatten()
612-
leaves = [l.to(*args, **kwargs) for l in leaves]
612+
leaves = [leaf.to(*args, **kwargs) for leaf in leaves]
613613
tc = self._pytree_unflatten(leaves, context)
614-
614+
615615
device = self.device
616616

617617
is_device_in_args = len(args) > 0 and isinstance(args[0], (str, torch.device))

0 commit comments

Comments
 (0)