Solved by jpeg729 in post #7 
              
              
                When you do 
print(out[-1])

you are taking the last element of the batch dimension. 
You probably wanted to do 
print(out[:, -1])