|
3 | 3 | { |
4 | 4 | "cell_type": "markdown", |
5 | 5 | "id": "e00f1a44", |
6 | | - "metadata": { |
7 | | - "editable": true |
8 | | - }, |
| 6 | + "metadata": {}, |
9 | 7 | "source": [ |
10 | 8 | "<!-- HTML file automatically generated from DocOnce source (https://github.com/doconce/doconce/)\n", |
11 | 9 | "doconce format html week7.do.txt --no_mako -->\n", |
|
15 | 13 | { |
16 | 14 | "cell_type": "markdown", |
17 | 15 | "id": "0521f5b9", |
18 | | - "metadata": { |
19 | | - "editable": true |
20 | | - }, |
| 16 | + "metadata": {}, |
21 | 17 | "source": [ |
22 | 18 | "# Advanced machine learning and data analysis for the physical sciences\n", |
23 | 19 | "**Morten Hjorth-Jensen**, Department of Physics and Center for Computing in Science Education, University of Oslo, Norway\n", |
|
28 | 24 | { |
29 | 25 | "cell_type": "markdown", |
30 | 26 | "id": "794145b7", |
31 | | - "metadata": { |
32 | | - "editable": true |
33 | | - }, |
| 27 | + "metadata": {}, |
34 | 28 | "source": [ |
35 | 29 | "## Plans for the week of March 3-7\n", |
36 | 30 | "\n", |
|
56 | 50 | { |
57 | 51 | "cell_type": "markdown", |
58 | 52 | "id": "e5e42fd9", |
59 | | - "metadata": { |
60 | | - "editable": true |
61 | | - }, |
| 53 | + "metadata": {}, |
62 | 54 | "source": [ |
63 | 55 | "## What is a recurrent NN?\n", |
64 | 56 | "\n", |
|
77 | 69 | { |
78 | 70 | "cell_type": "markdown", |
79 | 71 | "id": "8ea5b91a", |
80 | | - "metadata": { |
81 | | - "editable": true |
82 | | - }, |
| 72 | + "metadata": {}, |
83 | 73 | "source": [ |
84 | 74 | "## Why RNNs?\n", |
85 | 75 | "\n", |
|
99 | 89 | { |
100 | 90 | "cell_type": "markdown", |
101 | 91 | "id": "6dadec9c", |
102 | | - "metadata": { |
103 | | - "editable": true |
104 | | - }, |
| 92 | + "metadata": {}, |
105 | 93 | "source": [ |
106 | 94 | "## Basic layout, [Figures from Sebastian Rashcka et al, Machine learning with Sickit-Learn and PyTorch](https://sebastianraschka.com/blog/2022/ml-pytorch-book.html)\n", |
107 | 95 | "\n", |
|
115 | 103 | { |
116 | 104 | "cell_type": "markdown", |
117 | 105 | "id": "f69c94e7", |
118 | | - "metadata": { |
119 | | - "editable": true |
120 | | - }, |
| 106 | + "metadata": {}, |
121 | 107 | "source": [ |
122 | 108 | "## RNNs in more detail\n", |
123 | 109 | "\n", |
|
131 | 117 | { |
132 | 118 | "cell_type": "markdown", |
133 | 119 | "id": "3e66ff38", |
134 | | - "metadata": { |
135 | | - "editable": true |
136 | | - }, |
| 120 | + "metadata": {}, |
137 | 121 | "source": [ |
138 | 122 | "## RNNs in more detail, part 2\n", |
139 | 123 | "\n", |
|
147 | 131 | { |
148 | 132 | "cell_type": "markdown", |
149 | 133 | "id": "a485dcbf", |
150 | | - "metadata": { |
151 | | - "editable": true |
152 | | - }, |
| 134 | + "metadata": {}, |
153 | 135 | "source": [ |
154 | 136 | "## RNNs in more detail, part 3\n", |
155 | 137 | "\n", |
|
163 | 145 | { |
164 | 146 | "cell_type": "markdown", |
165 | 147 | "id": "ea3e2dd7", |
166 | | - "metadata": { |
167 | | - "editable": true |
168 | | - }, |
| 148 | + "metadata": {}, |
169 | 149 | "source": [ |
170 | 150 | "## RNNs in more detail, part 4\n", |
171 | 151 | "\n", |
|
179 | 159 | { |
180 | 160 | "cell_type": "markdown", |
181 | 161 | "id": "5eed88f5", |
182 | | - "metadata": { |
183 | | - "editable": true |
184 | | - }, |
| 162 | + "metadata": {}, |
185 | 163 | "source": [ |
186 | 164 | "## RNNs in more detail, part 5\n", |
187 | 165 | "\n", |
|
195 | 173 | { |
196 | 174 | "cell_type": "markdown", |
197 | 175 | "id": "f4dd3d82", |
198 | | - "metadata": { |
199 | | - "editable": true |
200 | | - }, |
| 176 | + "metadata": {}, |
201 | 177 | "source": [ |
202 | 178 | "## RNNs in more detail, part 6\n", |
203 | 179 | "\n", |
|
211 | 187 | { |
212 | 188 | "cell_type": "markdown", |
213 | 189 | "id": "f2f57990", |
214 | | - "metadata": { |
215 | | - "editable": true |
216 | | - }, |
| 190 | + "metadata": {}, |
217 | 191 | "source": [ |
218 | 192 | "## RNNs in more detail, part 7\n", |
219 | 193 | "\n", |
|
227 | 201 | { |
228 | 202 | "cell_type": "markdown", |
229 | 203 | "id": "f86b6161", |
230 | | - "metadata": { |
231 | | - "editable": true |
232 | | - }, |
| 204 | + "metadata": {}, |
233 | 205 | "source": [ |
234 | 206 | "## Backpropagation through time\n", |
235 | 207 | "\n", |
|
248 | 220 | { |
249 | 221 | "cell_type": "markdown", |
250 | 222 | "id": "40adbc7d", |
251 | | - "metadata": { |
252 | | - "editable": true |
253 | | - }, |
| 223 | + "metadata": {}, |
254 | 224 | "source": [ |
255 | 225 | "## The backward pass is linear\n", |
256 | 226 | "\n", |
|
267 | 237 | { |
268 | 238 | "cell_type": "markdown", |
269 | 239 | "id": "bc9082ba", |
270 | | - "metadata": { |
271 | | - "editable": true |
272 | | - }, |
| 240 | + "metadata": {}, |
273 | 241 | "source": [ |
274 | 242 | "## The problem of exploding or vanishing gradients\n", |
275 | 243 | "* What happens to the magnitude of the gradients as we backpropagate through many layers?\n", |
|
292 | 260 | { |
293 | 261 | "cell_type": "markdown", |
294 | 262 | "id": "9f380618", |
295 | | - "metadata": { |
296 | | - "editable": true |
297 | | - }, |
| 263 | + "metadata": {}, |
298 | 264 | "source": [ |
299 | 265 | "## The mathematics of RNNs, the basic architecture\n", |
300 | 266 | "\n", |
|
304 | 270 | { |
305 | 271 | "cell_type": "markdown", |
306 | 272 | "id": "2b6f4cbd", |
307 | | - "metadata": { |
308 | | - "editable": true |
309 | | - }, |
| 273 | + "metadata": {}, |
310 | 274 | "source": [ |
311 | 275 | "## Four effective ways to learn an RNN and preparing for next week\n", |
312 | | - "1. Long Short Term Memory Make the RNN out of little modules that are designed to remember values for a long time.\n", |
| 276 | + "1. Long Short Term Memory Make the RNN out of little modules that are designed to remember values for a long time. We discuss this next week.\n", |
313 | 277 | "\n", |
314 | 278 | "2. Hessian Free Optimization: Deal with the vanishing gradients problem by using a fancy optimizer that can detect directions with a tiny gradient but even smaller curvature.\n", |
315 | 279 | "\n", |
|
321 | 285 | { |
322 | 286 | "cell_type": "markdown", |
323 | 287 | "id": "ba57c26d", |
324 | | - "metadata": { |
325 | | - "editable": true |
326 | | - }, |
| 288 | + "metadata": {}, |
327 | 289 | "source": [ |
328 | 290 | "## Long Short Term Memory (LSTM)\n", |
329 | 291 | "\n", |
|
343 | 305 | ] |
344 | 306 | } |
345 | 307 | ], |
346 | | - "metadata": {}, |
| 308 | + "metadata": { |
| 309 | + "kernelspec": { |
| 310 | + "display_name": "Python 3 (ipykernel)", |
| 311 | + "language": "python", |
| 312 | + "name": "python3" |
| 313 | + }, |
| 314 | + "language_info": { |
| 315 | + "codemirror_mode": { |
| 316 | + "name": "ipython", |
| 317 | + "version": 3 |
| 318 | + }, |
| 319 | + "file_extension": ".py", |
| 320 | + "mimetype": "text/x-python", |
| 321 | + "name": "python", |
| 322 | + "nbconvert_exporter": "python", |
| 323 | + "pygments_lexer": "ipython3", |
| 324 | + "version": "3.9.15" |
| 325 | + } |
| 326 | + }, |
347 | 327 | "nbformat": 4, |
348 | 328 | "nbformat_minor": 5 |
349 | 329 | } |
0 commit comments