gw.transforms.inference_transforms.ToTorch

gw.transforms.inference_transforms.ToTorch(device='cpu')

Convert all numpy arrays sample to torch tensors and push them to the specified device. All items of sample that are not numpy arrays (e.g., dicts of arrays) remain unchanged.

Attributes

Name Description
device