4
0
mirror of https://github.com/nerfstudio-project/nerfstudio.git synced 2026-11-11 10:34:29 +08:00

Adding conversion to torch.float32 in get_interpolated_poses_many. (#1532)

This commit is contained in:
Georgy Ponimatkin 2023-02-28 18:22:22 +01:00 committed by GitHub
parent bfaf11cd72
commit 7366456835
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -229,7 +229,7 @@ def get_interpolated_poses_many(
traj = np.stack(traj, axis=0)
k_interp = np.stack(k_interp, axis=0)
return torch.tensor(traj), torch.tensor(k_interp)
return torch.tensor(traj, dtype=torch.float32), torch.tensor(k_interp, dtype=torch.float32)
def normalize(x: torch.Tensor) -> TensorType[...]: