├── README.md
├── develop
├── index.ipynb
└── pipeline.ipynb
├── examples
├── code.ipynb
├── index.ipynb
└── markdown.ipynb
├── img
├── build.svg
├── catdog.jpg
├── koebel.jpg
└── lstm.svg
├── index.ipynb
└── refs.bib
/README.md:
--------------------------------------------------------------------------------
1 | # Colab notebooks for d2l-book
2 |
3 | Automatically generated notebooks for d2l-book. Don't edit directly.
4 |
5 |
--------------------------------------------------------------------------------
/develop/index.ipynb:
--------------------------------------------------------------------------------
1 | {
2 | "cells": [
3 | {
4 | "cell_type": "markdown",
5 | "metadata": {},
6 | "source": [
7 | "# Development\n",
8 | "\n",
9 | "Explain how it works."
10 | ]
11 | },
12 | {
13 | "cell_type": "markdown",
14 | "metadata": {},
15 | "source": [
16 | "```toc\n",
17 | "pipeline\n",
18 | "```\n"
19 | ]
20 | }
21 | ],
22 | "metadata": {
23 | "kernelspec": {
24 | "display_name": "Python 3",
25 | "name": "python3"
26 | },
27 | "language_info": {
28 | "name": "python"
29 | }
30 | },
31 | "nbformat": 4,
32 | "nbformat_minor": 2
33 | }
--------------------------------------------------------------------------------
/develop/pipeline.ipynb:
--------------------------------------------------------------------------------
1 | {
2 | "cells": [
3 | {
4 | "cell_type": "markdown",
5 | "metadata": {},
6 | "source": [
7 | "# Build pipeline\n",
8 | "\n",
9 | "\n",
10 | "\n",
11 | "\n",
12 | "The source files are markdown files. They are either purely markdown files or\n",
13 | "juypyter notebooks saved in the markdown format with output removed. For the\n",
14 | "latter, we may use Jupyter to edit them directly with the `notedown` plugin and\n",
15 | "then run \"Kernel -> Restart & Clear Output\" before committing.\n",
16 | "\n",
17 | "Then our building pipeline runs the following steps to publish the artifacts.\n",
18 | "\n",
19 | "1. Convert .md files into .ipynb files and evaluate each of them. The reason that\n",
20 | " we use .md file as source format is because it's easy to review the source\n",
21 | " changes. We evaluate every time to guarantee every notebook is\n",
22 | " executable. This evaluation step may be time consuming, we can\n",
23 | "\n",
24 | " - Assume every notebook can be executed in 10 minutes, we may use multiple\n",
25 | " GPUs to accelerate the execution\n",
26 | " - If the source .md file hasn't change since last evaluation, we can reuse\n",
27 | " the cached .ipynb file to avoid execution again.\n",
28 | " - We use multiple processes to run notebooks in parallel.\n",
29 | "\n",
30 | "1. The .ipynb files with outputs can be uploaded to Github directly so users can\n",
31 | " clone it to run them locally or on the cloud. Also we zip all files so users\n",
32 | " can download it easily\n",
33 | "\n",
34 | "1. These .ipynb files are then converted to .rst files with format compatible to\n",
35 | " Sphinx. Additional preprocessing steps are used for image/table/citation\n",
36 | " references.\n",
37 | "\n",
38 | "1. Use Sphinx to build .html and .pdf files\n",
39 | "\n",
40 | "1. Publish all .html/.pdf/.zip files online, such as into an AWS S3 bucket."
41 | ]
42 | }
43 | ],
44 | "metadata": {
45 | "kernelspec": {
46 | "display_name": "Python 3",
47 | "name": "python3"
48 | },
49 | "language_info": {
50 | "name": "python"
51 | }
52 | },
53 | "nbformat": 4,
54 | "nbformat_minor": 2
55 | }
--------------------------------------------------------------------------------
/examples/code.ipynb:
--------------------------------------------------------------------------------
1 | {
2 | "cells": [
3 | {
4 | "cell_type": "markdown",
5 | "metadata": {},
6 | "source": [
7 | "# Code Cells\n",
8 | "\n",
9 | ":label:`sec_code`"
10 | ]
11 | },
12 | {
13 | "cell_type": "code",
14 | "execution_count": 1,
15 | "metadata": {},
16 | "outputs": [
17 | {
18 | "data": {
19 | "text/plain": [
20 | "3"
21 | ]
22 | },
23 | "execution_count": 1,
24 | "metadata": {},
25 | "output_type": "execute_result"
26 | }
27 | ],
28 | "source": [
29 | "\n",
30 | "1+2"
31 | ]
32 | },
33 | {
34 | "cell_type": "code",
35 | "execution_count": 2,
36 | "metadata": {},
37 | "outputs": [],
38 | "source": [
39 | "!ls ."
40 | ]
41 | },
42 | {
43 | "cell_type": "code",
44 | "execution_count": 3,
45 | "metadata": {},
46 | "outputs": [
47 | {
48 | "data": {
49 | "text/plain": [
50 | "'A code line with 78 chars should not be wrappered =========================='"
51 | ]
52 | },
53 | "execution_count": 3,
54 | "metadata": {},
55 | "output_type": "execute_result"
56 | }
57 | ],
58 | "source": [
59 | "'A code line with 78 chars should not be wrappered =========================='"
60 | ]
61 | },
62 | {
63 | "cell_type": "markdown",
64 | "metadata": {},
65 | "source": [
66 | "## Hide Source and Outputs\n",
67 | "\n",
68 | "We can hide the source of a code cell by adding a comment line `# Hide\n",
69 | "code` in the cell. We can also hide the code cell outputs using `# Hide outputs`\n",
70 | "\n",
71 | "For example, here is the normal code cell:"
72 | ]
73 | },
74 | {
75 | "cell_type": "code",
76 | "execution_count": 4,
77 | "metadata": {},
78 | "outputs": [
79 | {
80 | "data": {
81 | "text/plain": [
82 | "6"
83 | ]
84 | },
85 | "execution_count": 4,
86 | "metadata": {},
87 | "output_type": "execute_result"
88 | }
89 | ],
90 | "source": [
91 | "1+2+3"
92 | ]
93 | },
94 | {
95 | "cell_type": "markdown",
96 | "metadata": {},
97 | "source": [
98 | "Let's hide the source codes"
99 | ]
100 | },
101 | {
102 | "cell_type": "code",
103 | "execution_count": 5,
104 | "metadata": {},
105 | "outputs": [
106 | {
107 | "data": {
108 | "text/plain": [
109 | "6"
110 | ]
111 | },
112 | "execution_count": 5,
113 | "metadata": {},
114 | "output_type": "execute_result"
115 | }
116 | ],
117 | "source": [
118 | "# Hide code\n",
119 | "1+2+3"
120 | ]
121 | },
122 | {
123 | "cell_type": "markdown",
124 | "metadata": {},
125 | "source": [
126 | "Also try hiding the outputs"
127 | ]
128 | },
129 | {
130 | "cell_type": "code",
131 | "execution_count": 6,
132 | "metadata": {},
133 | "outputs": [
134 | {
135 | "data": {
136 | "text/plain": [
137 | "6"
138 | ]
139 | },
140 | "execution_count": 6,
141 | "metadata": {},
142 | "output_type": "execute_result"
143 | }
144 | ],
145 | "source": [
146 | "# Hide outputs\n",
147 | "1+2+3"
148 | ]
149 | },
150 | {
151 | "cell_type": "markdown",
152 | "metadata": {},
153 | "source": [
154 | "## Plot"
155 | ]
156 | },
157 | {
158 | "cell_type": "code",
159 | "execution_count": 7,
160 | "metadata": {
161 | "attributes": {
162 | "classes": [],
163 | "id": "",
164 | "n": "3"
165 | }
166 | },
167 | "outputs": [
168 | {
169 | "data": {
170 | "image/svg+xml": [
171 | "\n",
172 | "\n",
174 | "\n",
175 | "\n"
776 | ],
777 | "text/plain": [
778 | ""
779 | ]
780 | },
781 | "metadata": {
782 | "needs_background": "light"
783 | },
784 | "output_type": "display_data"
785 | }
786 | ],
787 | "source": [
788 | "%matplotlib inline\n",
789 | "from IPython import display\n",
790 | "from matplotlib import pyplot as plt\n",
791 | "import numpy as np\n",
792 | "\n",
793 | "display.set_matplotlib_formats('svg')\n",
794 | "\n",
795 | "x = np.arange(0, 10, 0.1)\n",
796 | "plt.plot(x, np.sin(x));"
797 | ]
798 | }
799 | ],
800 | "metadata": {
801 | "kernelspec": {
802 | "display_name": "Python 3",
803 | "name": "python3"
804 | },
805 | "language_info": {
806 | "name": "python"
807 | }
808 | },
809 | "nbformat": 4,
810 | "nbformat_minor": 2
811 | }
--------------------------------------------------------------------------------
/examples/index.ipynb:
--------------------------------------------------------------------------------
1 | {
2 | "cells": [
3 | {
4 | "cell_type": "markdown",
5 | "metadata": {},
6 | "source": [
7 | "# Examples\n",
8 | "\n",
9 | "Various examples"
10 | ]
11 | },
12 | {
13 | "cell_type": "markdown",
14 | "metadata": {},
15 | "source": [
16 | "```toc\n",
17 | ":maxdepth: 2\n",
18 | "\n",
19 | "markdown\n",
20 | "code\n",
21 | "```\n"
22 | ]
23 | }
24 | ],
25 | "metadata": {
26 | "kernelspec": {
27 | "display_name": "Python 3",
28 | "name": "python3"
29 | },
30 | "language_info": {
31 | "name": "python"
32 | }
33 | },
34 | "nbformat": 4,
35 | "nbformat_minor": 2
36 | }
--------------------------------------------------------------------------------
/examples/markdown.ipynb:
--------------------------------------------------------------------------------
1 | {
2 | "cells": [
3 | {
4 | "cell_type": "markdown",
5 | "metadata": {},
6 | "source": [
7 | "# Markdown Cells\n",
8 | "\n",
9 | "The `d2lbook` provide additional features beyond the normal markdown supports in\n",
10 | "Jupyter.\n",
11 | "\n",
12 | "## Table of Contents\n",
13 | "\n",
14 | "You can use a `toc` code block to specify the table of contents.\n",
15 | "Here `:maxdepth: 2` means display two levels of files, and `:numbered:` means\n",
16 | "adding number to each section (default is not enabled). Also note that you don't\n",
17 | "need to specify the file extension."
18 | ]
19 | },
20 | {
21 | "cell_type": "markdown",
22 | "metadata": {},
23 | "source": [
24 | "`````\n",
25 | "```toc\n",
26 | ":maxdepth: 2\n",
27 | ":numbered:\n",
28 | "\n",
29 | "guide/index\n",
30 | "```\n",
31 | "`````\n"
32 | ]
33 | },
34 | {
35 | "cell_type": "markdown",
36 | "metadata": {},
37 | "source": [
38 | "## Images\n",
39 | "\n",
40 | "\n",
41 | "We can put the image caption in `[]`. In addition, we can use\n",
42 | "`:width:` followed by its value in an inline block to specify the image width,\n",
43 | "similarly use `:height:`for height."
44 | ]
45 | },
46 | {
47 | "cell_type": "markdown",
48 | "metadata": {},
49 | "source": [
50 | "```\n",
51 | "\n",
52 | ":width:`400px`\n",
53 | "```\n"
54 | ]
55 | },
56 | {
57 | "cell_type": "markdown",
58 | "metadata": {},
59 | "source": [
60 | "\n",
61 | "\n",
62 | ":width:`400px`\n",
63 | "\n",
64 | "\n",
65 | "\n",
66 | "### SVG Images\n",
67 | "\n",
68 | "We recommend you to use SVG images as much as you can. It is sharp and its size\n",
69 | "is small. But since Latex doesn't support SVG images, if you want to build a PDF\n",
70 | "output, you need to install `rsvg-convert`. On Macos, you can simply\n",
71 | "`brew install librsvg` or `sudo apt-get install librsvg2-bin` for Ubuntu.\n",
72 | "\n",
73 | "\n",
74 | "\n",
75 | "## Tables\n",
76 | "\n",
77 | "You can insert table caption before the table by starting it with a `:`. Note\n",
78 | "that you need to leave an empty line between the caption and the table itself."
79 | ]
80 | },
81 | {
82 | "cell_type": "markdown",
83 | "metadata": {},
84 | "source": [
85 | "```\n",
86 | ": The number is computed by $z_{ij} = \\sum_{k}x_{ik}y_{kj}$.\n",
87 | "\n",
88 | "| Year | Number | Comment |\n",
89 | "| --- | --- | --- |\n",
90 | "| 2018 | 100 | Good year |\n",
91 | "| 2019 | 200 | Even better, add something to make this column wider |\n",
92 | "```\n"
93 | ]
94 | },
95 | {
96 | "cell_type": "markdown",
97 | "metadata": {},
98 | "source": [
99 | ": The number is computed by $z_{ij} = \\sum_{k}x_{ik}y_{kj}$.\n",
100 | "\n",
101 | "| Year | Number | Comment |\n",
102 | "| --- | --- | --- |\n",
103 | "| 2018 | 100 | Good year |\n",
104 | "| 2019 | 200 | Even better, add something to make this column wider |\n",
105 | "\n",
106 | "If the Table caption number doesn't show properly, you may need to update\n",
107 | "`pandoc` to the latest version.\n",
108 | "\n",
109 | "## Cross References\n",
110 | "\n",
111 | "We often want to reference sections, figures, tables and equations in a book.\n",
112 | "\n",
113 | "### Referencing Sections\n",
114 | "\n",
115 | ":label:`my_sec3`\n",
116 | "\n",
117 | "\n",
118 | "We can put a label immediately after the section title to allow this section to\n",
119 | "be referenced by its label. The label format is\n",
120 | "`:label:` followed by its label name in an inline code block."
121 | ]
122 | },
123 | {
124 | "cell_type": "markdown",
125 | "metadata": {},
126 | "source": [
127 | "```\n",
128 | "### Referencing Sections\n",
129 | ":label:`my_sec3`\n",
130 | "```\n"
131 | ]
132 | },
133 | {
134 | "cell_type": "markdown",
135 | "metadata": {},
136 | "source": [
137 | "Then we can reference this section through `:ref:` followed by label name in an\n",
138 | "inline code block"
139 | ]
140 | },
141 | {
142 | "cell_type": "markdown",
143 | "metadata": {},
144 | "source": [
145 | "```\n",
146 | ":ref:`my_sec3` demonstrates how to reference a section.\n",
147 | "```\n"
148 | ]
149 | },
150 | {
151 | "cell_type": "markdown",
152 | "metadata": {},
153 | "source": [
154 | ":ref:`my_sec3` demonstrates how to reference a section.\n",
155 | "\n",
156 | "\n",
157 | "Note that it displays the referenced section title with a clickable link. We can\n",
158 | "also use a numbered version by changing `:num:` to `:numref:`, e.g. :numref:`my_sec3`.\n",
159 | "\n",
160 | "If the label is incorrect, say we put `my_sec2` here, the build log will\n",
161 | "contains a warning such as"
162 | ]
163 | },
164 | {
165 | "cell_type": "markdown",
166 | "metadata": {},
167 | "source": [
168 | "```\n",
169 | "WARNING: undefined label: my_sec2\n",
170 | "```\n"
171 | ]
172 | },
173 | {
174 | "cell_type": "markdown",
175 | "metadata": {},
176 | "source": [
177 | "You can turn it into error by setting `warning_is_error = True` in\n",
178 | "`config.ini`.\n",
179 | "\n",
180 | "Besides, we can cross\n",
181 | "reference label from other files as well, e.g. :numref:`sec_code`. This applies\n",
182 | "to figures, tables and equations as well.\n",
183 | "\n",
184 | "\n",
185 | "### Referencing Images\n",
186 | "\n",
187 | "Similarly we can label an image and reference it later."
188 | ]
189 | },
190 | {
191 | "cell_type": "markdown",
192 | "metadata": {},
193 | "source": [
194 | "```\n",
195 | "\n",
196 | ":width:`300px`\n",
197 | ":label:`img_catdog`\n",
198 | "\n",
199 | "As can be seen from :numref:`img_catdog`,\n",
200 | "```\n"
201 | ]
202 | },
203 | {
204 | "cell_type": "markdown",
205 | "metadata": {},
206 | "source": [
207 | "\n",
208 | "\n",
209 | ":width:`300px`\n",
210 | "\n",
211 | "\n",
212 | ":label:`img_catdog`\n",
213 | "\n",
214 | "\n",
215 | "As can be seen from :numref:`img_catdog`, there is a cat and a dog.\n",
216 | "\n",
217 | "### Referencing Tables"
218 | ]
219 | },
220 | {
221 | "cell_type": "markdown",
222 | "metadata": {},
223 | "source": [
224 | "```\n",
225 | ":This a is very long table caption. It will breaks into several lines. And\n",
226 | "contains a math equation as well. $z_{ij} = \\sum_{k}x_{ik}y_{kj}$.\n",
227 | "\n",
228 | "| Year | Number | Comment |\n",
229 | "| --- | --- | --- |\n",
230 | "| 2018 | 100 | Good year |\n",
231 | ":label:`table`\n",
232 | "\n",
233 | "Refer to :numref:`table`\n",
234 | "\n",
235 | "```\n"
236 | ]
237 | },
238 | {
239 | "cell_type": "markdown",
240 | "metadata": {},
241 | "source": [
242 | ":This a is very long table caption. It will breaks into several lines. And\n",
243 | "contains a math equation as well. $z_{ij} = \\sum_{k}x_{ik}y_{kj}$.\n",
244 | "\n",
245 | "| Year | Number | Comment |\n",
246 | "| --- | --- | --- |\n",
247 | "| 2018 | 100 | Good year |\n",
248 | "\n",
249 | ":label:`table`\n",
250 | "\n",
251 | "\n",
252 | "Refer to :numref:`table`\n",
253 | "\n",
254 | "### Referencing Equations\n",
255 | "\n",
256 | "The difference here is that we need to use `eqlabel` instead of `label`. For\n",
257 | "example"
258 | ]
259 | },
260 | {
261 | "cell_type": "markdown",
262 | "metadata": {},
263 | "source": [
264 | "```\n",
265 | "$$\\hat{\\mathbf{y}}=\\mathbf X \\mathbf{w}+b$$\n",
266 | ":eqlabel:`linear`\n",
267 | "\n",
268 | "\n",
269 | "In :eqref:`linear`, we define the linear model.\n",
270 | "```\n"
271 | ]
272 | },
273 | {
274 | "cell_type": "markdown",
275 | "metadata": {},
276 | "source": [
277 | "$$\\hat{\\mathbf{y}}=\\mathbf X \\mathbf{w}+b$$\n",
278 | "\n",
279 | ":eqlabel:`linear`\n",
280 | "\n",
281 | "\n",
282 | "In :eqref:`linear`, we define the linear model.\n",
283 | "\n",
284 | "\n",
285 | "## Citations\n",
286 | "\n",
287 | "First put your bib file at somewhere. All references will be displayed on the\n",
288 | "place where it inserted in HTML. But in PDF, all references will be moved to end of\n",
289 | "the document. Then we can cite a paper through `:cite:`. Multipel papers can be\n",
290 | "separated by commans (note there should be no space)"
291 | ]
292 | },
293 | {
294 | "cell_type": "markdown",
295 | "metadata": {},
296 | "source": [
297 | "```\n",
298 | "\n",
299 | "The breakthrough of deep learning origins from :cite:`krizhevsky2012imagenet` for...\n",
300 | "\n",
301 | "Two keys together :cite:`he2016deep,devlin2018bert`...\n",
302 | "\n",
303 | ":bibliography:`../refs.bib`\n",
304 | "```\n"
305 | ]
306 | },
307 | {
308 | "cell_type": "markdown",
309 | "metadata": {},
310 | "source": [
311 | "The breakthrough of deep learning origins from :cite:`krizhevsky2012imagenet` for\n",
312 | "computer vision, there is a rich of following up works, such as\n",
313 | ":cite:`he2016deep`. NLP is catching up as well, the recent work\n",
314 | ":cite:`devlin2018bert` shows significant improvements.\n",
315 | "\n",
316 | "Two keys together :cite:`he2016deep,devlin2018bert`. Single author\n",
317 | ":cite:`mitchell80`, two authors :cite:`Newell81`\n",
318 | "\n",
319 | "## References\n",
320 | "\n",
321 | "\n",
322 | ":bibliography:`../refs.bib`"
323 | ]
324 | }
325 | ],
326 | "metadata": {
327 | "kernelspec": {
328 | "display_name": "Python 3",
329 | "name": "python3"
330 | },
331 | "language_info": {
332 | "name": "python"
333 | }
334 | },
335 | "nbformat": 4,
336 | "nbformat_minor": 2
337 | }
--------------------------------------------------------------------------------
/img/build.svg:
--------------------------------------------------------------------------------
1 |
2 |
422 |
--------------------------------------------------------------------------------
/img/catdog.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/d2l-ai/d2l-book-colab/ee5251a48aeb3190648d9bb27f9eeff4415276bc/img/catdog.jpg
--------------------------------------------------------------------------------
/img/koebel.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/d2l-ai/d2l-book-colab/ee5251a48aeb3190648d9bb27f9eeff4415276bc/img/koebel.jpg
--------------------------------------------------------------------------------
/img/lstm.svg:
--------------------------------------------------------------------------------
1 |
2 |
652 |
--------------------------------------------------------------------------------
/index.ipynb:
--------------------------------------------------------------------------------
1 | {
2 | "cells": [
3 | {
4 | "cell_type": "markdown",
5 | "metadata": {},
6 | "source": [
7 | "# Books with Jupyter Notebooks\n",
8 | "\n",
9 | "The `d2lbook` package helps you build and publish a book consists with\n",
10 | "multiple Jupyter notebooks. It assumes all notebooks are saved in the Markdown\n",
11 | "format with outputs striped in favor of editing and reviewing. It then evaluates\n",
12 | "notebooks to obtain code cell outputs and build them to various formats,\n",
13 | "including Jupyter notebook, HTML and PDF.\n",
14 | "\n",
15 | "In addition, it provides extra functionalities such as:\n",
16 | "\n",
17 | "1. Reference sections, figures, and tables with labels.\n",
18 | "1. Cite references with bibtex.\n",
19 | "1. Evaluate notebooks in parallel with GPU supports (under developing).\n",
20 | "\n",
21 | "Check [Dive into Deep Learning](https://d2l.ai/) for an example built with\n",
22 | "`d2lbook`.\n",
23 | "\n",
24 | "\n",
25 | "## Getting Started\n",
26 | "\n",
27 | "### Installation\n",
28 | "\n",
29 | "Use `pip` to install the command-line interface."
30 | ]
31 | },
32 | {
33 | "cell_type": "markdown",
34 | "metadata": {},
35 | "source": [
36 | "```sh\n",
37 | "pip install git+https://github.com/d2l-ai/d2l-book\n",
38 | "```\n"
39 | ]
40 | },
41 | {
42 | "cell_type": "markdown",
43 | "metadata": {},
44 | "source": [
45 | "In addition, you also need to install `pandoc`, e.g. `conda install pandoc`.\n",
46 | "\n",
47 | "\n",
48 | "### Create a new book (under developing)\n",
49 | "\n",
50 | "Create a new book into the directory `mybook` with a default configuration\n",
51 | "file."
52 | ]
53 | },
54 | {
55 | "cell_type": "markdown",
56 | "metadata": {},
57 | "source": [
58 | "```sh\n",
59 | "d2lbook create mybook\n",
60 | "```\n"
61 | ]
62 | },
63 | {
64 | "cell_type": "markdown",
65 | "metadata": {},
66 | "source": [
67 | "Or create a new book using the demo book content (the website that you’re viewing\n",
68 | "now)."
69 | ]
70 | },
71 | {
72 | "cell_type": "markdown",
73 | "metadata": {},
74 | "source": [
75 | "```sh\n",
76 | "d2lbook create mybook --demo\n",
77 | "```\n"
78 | ]
79 | },
80 | {
81 | "cell_type": "markdown",
82 | "metadata": {},
83 | "source": [
84 | "Edit the `config.ini` by updating the book title, authors, and others.\n",
85 | "\n",
86 | "### Build the contents for your book\n",
87 | "\n",
88 | "First enter your book directory"
89 | ]
90 | },
91 | {
92 | "cell_type": "markdown",
93 | "metadata": {},
94 | "source": [
95 | "```sh\n",
96 | "cd mybook\n",
97 | "```\n"
98 | ]
99 | },
100 | {
101 | "cell_type": "markdown",
102 | "metadata": {},
103 | "source": [
104 | "The following command will evaluate all notebooks and generate outputs in\n",
105 | "`ipynb`, `html` and `pdf` format."
106 | ]
107 | },
108 | {
109 | "cell_type": "markdown",
110 | "metadata": {},
111 | "source": [
112 | "```sh\n",
113 | "d2lbook build all\n",
114 | "```\n"
115 | ]
116 | },
117 | {
118 | "cell_type": "markdown",
119 | "metadata": {},
120 | "source": [
121 | "Once finished, you can check the results in the `_build` folder.\n",
122 | "\n",
123 | "Or you can only build HTML outputs"
124 | ]
125 | },
126 | {
127 | "cell_type": "markdown",
128 | "metadata": {},
129 | "source": [
130 | "```\n",
131 | "d2lbook build html\n",
132 | "```\n"
133 | ]
134 | },
135 | {
136 | "cell_type": "markdown",
137 | "metadata": {},
138 | "source": [
139 | "### Deploy the contents online\n",
140 | "\n",
141 | "Publish both HTML and PDF into a s3 bucket, which allows to setup a static\n",
142 | "website hosting easily (you need to configure the `s3_bucket` in `config.ini`)."
143 | ]
144 | },
145 | {
146 | "cell_type": "markdown",
147 | "metadata": {},
148 | "source": [
149 | "```sh\n",
150 | "d2l-book deploy html pdf\n",
151 | "```\n"
152 | ]
153 | },
154 | {
155 | "cell_type": "markdown",
156 | "metadata": {},
157 | "source": [
158 | "Or push all notebooks in the `ipynb` format into a github repo (you need\n",
159 | "configure `github_repo` in `config.ini`) (under developing)."
160 | ]
161 | },
162 | {
163 | "cell_type": "markdown",
164 | "metadata": {},
165 | "source": [
166 | "```sh\n",
167 | "d2l-book deploy ipynb\n",
168 | "```\n"
169 | ]
170 | },
171 | {
172 | "cell_type": "markdown",
173 | "metadata": {},
174 | "source": [
175 | "## Table of Contents"
176 | ]
177 | },
178 | {
179 | "cell_type": "markdown",
180 | "metadata": {},
181 | "source": [
182 | "```toc\n",
183 | ":numbered:\n",
184 | ":maxdepth: 2\n",
185 | "\n",
186 | "examples/index\n",
187 | "develop/index\n",
188 | "```\n"
189 | ]
190 | },
191 | {
192 | "cell_type": "markdown",
193 | "metadata": {},
194 | "source": [
195 | "## History\n",
196 | "\n",
197 | "This project starts with several scripts wrote to build the documents sites for\n",
198 | "several projects, including [Apache MXNet](http://mxnet.io),\n",
199 | "[GluonCV](http://gluon-cv.mxnet.io), [D2L](http://d2l.ai). Later on, heavily inspired\n",
200 | "by [Jupyter Book](https://jupyter.org/jupyter-book), we refactored these scripts\n",
201 | "into a package."
202 | ]
203 | }
204 | ],
205 | "metadata": {
206 | "kernelspec": {
207 | "display_name": "Python 3",
208 | "name": "python3"
209 | },
210 | "language_info": {
211 | "name": "python"
212 | }
213 | },
214 | "nbformat": 4,
215 | "nbformat_minor": 2
216 | }
--------------------------------------------------------------------------------
/refs.bib:
--------------------------------------------------------------------------------
1 | @inproceedings{krizhevsky2012imagenet,
2 | title={Imagenet classification with deep convolutional neural networks},
3 | author={Krizhevsky, Alex and Sutskever, Ilya and Hinton, Geoffrey E},
4 | booktitle={Advances in neural information processing systems},
5 | pages={1097--1105},
6 | year={2012}
7 | }
8 |
9 | @inproceedings{he2016deep,
10 | title={Deep residual learning for image recognition},
11 | author={He, Kaiming and Zhang, Xiangyu and Ren, Shaoqing and Sun, Jian},
12 | booktitle={Proceedings of the IEEE conference on computer vision and pattern recognition},
13 | pages={770--778},
14 | year={2016}
15 | }
16 |
17 | @article{devlin2018bert,
18 | title={Bert: Pre-training of deep bidirectional transformers for language understanding},
19 | author={Devlin, Jacob and Chang, Ming-Wei and Lee, Kenton and Toutanova, Kristina},
20 | journal={arXiv preprint arXiv:1810.04805},
21 | year={2018}
22 | }
23 |
24 | @TechReport{mitchell80,
25 | author = "T. M. Mitchell",
26 | title = "The Need for Biases in Learning Generalizations",
27 | institution = "Computer Science Department, Rutgers University",
28 | year = "1980",
29 | address = "New Brunswick, MA",
30 | }
31 |
32 | @InCollection{Newell81,
33 | author = "A. Newell and P. S. Rosenbloom",
34 | title = "Mechanisms of Skill Acquisition and the Law of
35 | Practice",
36 | booktitle = "Cognitive Skills and Their Acquisition",
37 | pages = "1--51",
38 | publisher = "Lawrence Erlbaum Associates, Inc.",
39 | year = "1981",
40 | editor = "J. R. Anderson",
41 | chapter = "1",
42 | address = "Hillsdale, NJ",
43 | eprint = {arXiv:1510.01797},
44 | }
45 |
--------------------------------------------------------------------------------