Feedback about Quickstart
Author: dearwind153Created May 21, 2026Updated May 27, 2026
There is the following issue on this page: https://docs.pytorch.org/tutorials/beginner/basics/quickstart_tutorial.html
In the Section "Optimizing the Model Parameters", the backpropagation code order should be
# Backpropagation
_**optimizer.zero_grad()**_
loss.backward()
optimizer.step()Source: pytorch/tutorials