Now I realize what the problem is. One of my objects is a variable, the other is a tensor.
<class 'torch.autograd.variable.Variable'>
<class 'torch.FloatTensor'>

How can I convert from the former to the later (autograd variable to floatTesnor) ?
EDIT:
Oh , now I understand, to go from variable to tensor, you just use
 variable.data