Solved by albanD in post #2 
              
              
                Hi, 
Did you properly convert the input to double as well by doing input = input.double()? (this is not an inplace operation on Tensors, you have to use the result).