Hi Johannes!



 Johannes_L:

Or is there any benefit from using Variable?


With newer version of pytorch, don’t use Variables.  They are
deprecated and don’t actually do anything.  I think that
torch.autograd.Variable is just a stub that is there for backward
compatibility.
If you happen to be using an old version of pytorch, but don’t use
Variables, your code won’t silently fail – it will immediately complain
if you try to do any kind of autograd stuff on a raw tensor.  So you
don’t need to use Variables “just to be safe.”
Best.
K. Frank