Default data type of parameters is Float.
I want to convert it to Double.
How can i do this?
You can convert your model to double by doing model.double().
Note that after this, you will need your input to be DoubleTensor.
Thanks very much! It’s very simple.
Convert Your Data to float instead … as it’s very dangerous to convert model type to Double … as GPUs are not good at double precision computation
Try:
X_train = torch.FloatTensor(X_train)
instead