A guess would be that you’re using from_numpy on a float64 array, and this gives you a DoubleTensor. PyTorch uses FloatTensors as the default tensor type. Once you send the double input and float weights to the GPU, and try to multiply them it will raise an error. I’d suggest you to convert all numpy arrays to float32 type.