Skip to content

Commit 9849f64

Browse files
fix device typing issue
1 parent 7534956 commit 9849f64

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

nerfstudio/data/utils/nerfstudio_collate.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ def nerfstudio_collate(batch: Any, extra_mappings: Union[Dict[type, Callable], N
9898
# If we're in a background process, concatenate directly into a
9999
# shared memory tensor to avoid an extra copy
100100
numel = sum(x.numel() for x in batch)
101-
storage = elem.untyped_storage()._new_shared(numel, device=elem.device)
101+
storage = elem.untyped_storage()._new_shared(numel, device=str(elem.device))
102102
out = elem.new(storage).resize_(len(batch), *list(elem.size()))
103103
return torch.stack(batch, 0, out=out)
104104
elif elem_type.__module__ == "numpy" and elem_type.__name__ not in ("str_", "string_"):

0 commit comments

Comments
 (0)