I apologize, that was a stupid mistake (I called x = Variable(x)) twice. However, I am still getting this error: RuntimeError: Expected object of type torch.DoubleTensor but found type torch.FloatTensor for argument #2 'weight' (Sorry I am just getting started with NN and pytorch)