RuntimeError: Input type (torch.FloatTensor) and weight type (torch.cuda.FloatTensor) should be the

RuntimeError: Input type (torch.FloatTensor) and weight type (torch.cuda.FloatTensor) should be the same

device = torch.device("cuda" if torch.cuda.is_available() else "cpu")
inputs = inputs.to(device)

猜你喜欢

转载自blog.csdn.net/weixin_44790486/article/details/109660889