Created using Colaboratory
This commit is contained in:
@@ -4,7 +4,7 @@
|
|||||||
"metadata": {
|
"metadata": {
|
||||||
"colab": {
|
"colab": {
|
||||||
"provenance": [],
|
"provenance": [],
|
||||||
"authorship_tag": "ABX9TyObut1y9atNUuowPT6dMY+I",
|
"authorship_tag": "ABX9TyMXS3SPB4cS/4qxix0lH/Hq",
|
||||||
"include_colab_link": true
|
"include_colab_link": true
|
||||||
},
|
},
|
||||||
"kernelspec": {
|
"kernelspec": {
|
||||||
@@ -144,10 +144,10 @@
|
|||||||
" def count_params(self):\n",
|
" def count_params(self):\n",
|
||||||
" return sum([p.view(-1).shape[0] for p in self.parameters()])\n",
|
" return sum([p.view(-1).shape[0] for p in self.parameters()])\n",
|
||||||
"\n",
|
"\n",
|
||||||
"# # TODO -- Add residual connections to this model\n",
|
"# TODO -- Add residual connections to this model\n",
|
||||||
"# # The order of operations should similar to figure 11.5b\n",
|
"# The order of operations within each block should similar to figure 11.5b\n",
|
||||||
"# # linear1 first, ReLU+linear2 in first residual block, ReLU+linear3 in second residual block), linear4 at end\n",
|
"# ie., linear1 first, ReLU+linear2 in first residual block, ReLU+linear3 in second residual block), linear4 at end\n",
|
||||||
"# # Replace this function\n",
|
"# Replace this function\n",
|
||||||
" def forward(self, x):\n",
|
" def forward(self, x):\n",
|
||||||
" h1 = self.linear1(x).relu()\n",
|
" h1 = self.linear1(x).relu()\n",
|
||||||
" h2 = self.linear2(h1).relu()\n",
|
" h2 = self.linear2(h1).relu()\n",
|
||||||
|
|||||||
Reference in New Issue
Block a user