You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The Variable API has been deprecated in Pytorch 1.10.
From Pytorch 1.10 documentation:
"Autograd automatically supports Tensors with requires_grad set to True
Variables are no longer necessary to use autograd with tensors."
The code can be further simplified if lines with Variable calls are removed. For example lines 56-57 of train.pyfile:
# convert to torch Variables
train_batch, labels_batch = Variable(train_batch), Variable(labels_batch)
The text was updated successfully, but these errors were encountered:
The Variable API has been deprecated in Pytorch 1.10.
From Pytorch 1.10 documentation:
"Autograd automatically supports Tensors with requires_grad set to True
Variables are no longer necessary to use autograd with tensors."
The code can be further simplified if lines with Variable calls are removed. For example lines 56-57 of
train.py
file:The text was updated successfully, but these errors were encountered: