Skip to content

Commit ada521c

Browse files
Fix typos regarding SGD, and make links specific
1 parent 4ccc908 commit ada521c

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

Deep Learning with PyTorch.ipynb

+5-5
Original file line numberDiff line numberDiff line change
@@ -720,14 +720,14 @@
720720
"- updating the weights of the network\n",
721721
"\n",
722722
"The simplest update rule used in practice is the Stochastic Gradient Descent (SGD):\n",
723-
"> `weight = weight = learning_rate * gradient`\n",
723+
"> `weight = weight - learning_rate * gradient`\n",
724724
"\n",
725725
"We can implement this using simple python code:\n",
726726
"\n",
727727
"```python\n",
728728
"learning_rate = 0.01\n",
729729
"for f in net.parameters():\n",
730-
" f.data.add_(f.grad * learning_rate)\n",
730+
" f.data.sub_(f.grad * learning_rate)\n",
731731
"```\n",
732732
"\n",
733733
"However, as you use neural networks, you want to use various different update rules such as SGD, Nesterov-SGD, Adam, RMSProp, etc.\n",
@@ -1199,9 +1199,9 @@
11991199
"source": [
12001200
"## Where do I go next?\n",
12011201
"\n",
1202-
"- [Train neural nets to play video games](https://github.com/pytorch/tutorials)\n",
1203-
"- [Train a state-of-the-art ResNet network on imagenet](https://github.com/pytorch/examples)\n",
1204-
"- [Train an face generator using Generative Adversarial Networks](https://github.com/pytorch/examples)\n",
1202+
"- [Train neural nets to play video games](https://github.com/pytorch/tutorials/blob/master/Reinforcement%20(Q-)Learning%20with%20PyTorch.ipynb)\n",
1203+
"- [Train a state-of-the-art ResNet network on imagenet](https://github.com/pytorch/examples/tree/master/imagenet)\n",
1204+
"- [Train an face generator using Generative Adversarial Networks](https://github.com/pytorch/examples/tree/master/dcgan)\n",
12051205
"- [Train a word-level language model using Recurrent LSTM networks](https://github.com/pytorch/examples/tree/master/word_language_model)\n",
12061206
"- [More examples](https://github.com/pytorch/examples)\n",
12071207
"- [More tutorials](https://github.com/pytorch/tutorials)\n",

0 commit comments

Comments
 (0)