PyTorch 速查

img = torch.from_numpy(img).float().to(device)