Skip to content

Commit 7c63641

Browse files
committed
Automated tutorials push
1 parent 5e115ef commit 7c63641

File tree

186 files changed

+495704
-481755
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

186 files changed

+495704
-481755
lines changed
Lines changed: 75 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,75 @@
1+
{
2+
"cells": [
3+
{
4+
"cell_type": "code",
5+
"execution_count": null,
6+
"metadata": {
7+
"collapsed": false
8+
},
9+
"outputs": [],
10+
"source": [
11+
"# For tips on running notebooks in Google Colab, see\n# https://pytorch.org/tutorials/beginner/colab\n%matplotlib inline"
12+
]
13+
},
14+
{
15+
"cell_type": "markdown",
16+
"metadata": {},
17+
"source": [
18+
"\n# Template Tutorial\n\n**Author:** [FirstName LastName](https://github.com/username)\n\n.. grid:: 2\n\n .. grid-item-card:: :octicon:`mortar-board;1em;` What you will learn\n\n * Item 1\n * Item 2\n * Item 3\n\n .. grid-item-card:: :octicon:`list-unordered;1em;` Prerequisites\n\n * PyTorch v2.0.0\n * GPU ???\n * Other items 3\n\nIf you have a video, add it here like this:\n\n.. raw:: html\n\n <div style=\"margin-top:10px; margin-bottom:10px;\">\n <iframe width=\"560\" height=\"315\" src=\"https://www.youtube.com/embed/IC0_FRiX-sw\" frameborder=\"0\" allow=\"accelerometer; encrypted-media; gyroscope; picture-in-picture\" allowfullscreen></iframe>\n </div>\n\nTo test your tutorial locally, you can do one of the following:\n\n* You can control specific files that generate the results by using\n ``GALLERY_PATTERN`` environment variable. The GALLERY_PATTERN variable\n respects regular expressions.\n For example to run only ``neural_style_transfer_tutorial.py``,\n use the following command:\n \n```sh\nGALLERY_PATTERN=\"neural_style_transfer_tutorial.py\" make html\n```\n or\n \n```sh\nGALLERY_PATTERN=\"neural_style_transfer_tutorial.py\" sphinx-build . _build\n```\n* Make a copy of this repo and add only your\n tutorial to the `beginner_source` directory removing all other tutorials.\n Then run ``make html``.\n \nVerify that all outputs were generated correctly in the created HTML.\n"
19+
]
20+
},
21+
{
22+
"cell_type": "markdown",
23+
"metadata": {},
24+
"source": [
25+
"## Overview\n\nDescribe Why is this topic important? Add Links to relevant research papers.\n\nThis tutorial walks you through the process of....\n\n## Steps\n\nExample code (the output below is generated automatically):\n\n\n"
26+
]
27+
},
28+
{
29+
"cell_type": "code",
30+
"execution_count": null,
31+
"metadata": {
32+
"collapsed": false
33+
},
34+
"outputs": [],
35+
"source": [
36+
"import torch\nx = torch.rand(5, 3)\nprint(x)"
37+
]
38+
},
39+
{
40+
"cell_type": "markdown",
41+
"metadata": {},
42+
"source": [
43+
"## (Optional) Additional Exercises\n\nAdd additional practice exercises for users to test their knowledge.\nExample: [NLP from Scratch](https://pytorch.org/tutorials/intermediate/char_rnn_generation_tutorial.html#exercises)_.\n\n\n"
44+
]
45+
},
46+
{
47+
"cell_type": "markdown",
48+
"metadata": {},
49+
"source": [
50+
"## Conclusion\n\nSummarize the steps and concepts covered. Highlight key takeaways.\n\n## Further Reading\n\n* Link1\n* Link2\n\n"
51+
]
52+
}
53+
],
54+
"metadata": {
55+
"kernelspec": {
56+
"display_name": "Python 3",
57+
"language": "python",
58+
"name": "python3"
59+
},
60+
"language_info": {
61+
"codemirror_mode": {
62+
"name": "ipython",
63+
"version": 3
64+
},
65+
"file_extension": ".py",
66+
"mimetype": "text/x-python",
67+
"name": "python",
68+
"nbconvert_exporter": "python",
69+
"pygments_lexer": "ipython3",
70+
"version": "3.10.9"
71+
}
72+
},
73+
"nbformat": 4,
74+
"nbformat_minor": 0
75+
}
Lines changed: 92 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,92 @@
1+
# -*- coding: utf-8 -*-
2+
3+
"""
4+
Template Tutorial
5+
=================
6+
7+
**Author:** `FirstName LastName <https://github.com/username>`_
8+
9+
.. grid:: 2
10+
11+
.. grid-item-card:: :octicon:`mortar-board;1em;` What you will learn
12+
13+
* Item 1
14+
* Item 2
15+
* Item 3
16+
17+
.. grid-item-card:: :octicon:`list-unordered;1em;` Prerequisites
18+
19+
* PyTorch v2.0.0
20+
* GPU ???
21+
* Other items 3
22+
23+
If you have a video, add it here like this:
24+
25+
.. raw:: html
26+
27+
<div style="margin-top:10px; margin-bottom:10px;">
28+
<iframe width="560" height="315" src="https://www.youtube.com/embed/IC0_FRiX-sw" frameborder="0" allow="accelerometer; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>
29+
</div>
30+
31+
To test your tutorial locally, you can do one of the following:
32+
33+
* You can control specific files that generate the results by using
34+
``GALLERY_PATTERN`` environment variable. The GALLERY_PATTERN variable
35+
respects regular expressions.
36+
For example to run only ``neural_style_transfer_tutorial.py``,
37+
use the following command:
38+
39+
.. code-block:: sh
40+
41+
GALLERY_PATTERN="neural_style_transfer_tutorial.py" make html
42+
43+
or
44+
45+
.. code-block:: sh
46+
47+
GALLERY_PATTERN="neural_style_transfer_tutorial.py" sphinx-build . _build
48+
49+
* Make a copy of this repo and add only your
50+
tutorial to the `beginner_source` directory removing all other tutorials.
51+
Then run ``make html``.
52+
53+
Verify that all outputs were generated correctly in the created HTML.
54+
"""
55+
56+
#########################################################################
57+
# Overview
58+
# --------
59+
#
60+
# Describe Why is this topic important? Add Links to relevant research papers.
61+
#
62+
# This tutorial walks you through the process of....
63+
#
64+
# Steps
65+
# -----
66+
#
67+
# Example code (the output below is generated automatically):
68+
#
69+
import torch
70+
x = torch.rand(5, 3)
71+
print(x)
72+
73+
######################################################################
74+
# (Optional) Additional Exercises
75+
# -------------------------------
76+
#
77+
# Add additional practice exercises for users to test their knowledge.
78+
# Example: `NLP from Scratch <https://pytorch.org/tutorials/intermediate/char_rnn_generation_tutorial.html#exercises>`__.
79+
#
80+
81+
######################################################################
82+
# Conclusion
83+
# ----------
84+
#
85+
# Summarize the steps and concepts covered. Highlight key takeaways.
86+
#
87+
# Further Reading
88+
# ---------------
89+
#
90+
# * Link1
91+
# * Link2
92+
Loading
Loading
Loading
-1.63 KB
Loading
-92 Bytes
Loading
-19.6 KB
Loading
241 Bytes
Loading
1.26 KB
Loading
352 Bytes
Loading
21.3 KB
Loading
15.5 KB
Loading
25 Bytes
Loading
-208 Bytes
Loading
11.7 KB
Loading
-904 Bytes
Loading
Loading
Loading
Loading
Loading
Loading
Loading
Loading
-593 Bytes
Loading

_images/sphx_glr_trainingyt_001.png

-136 Bytes
Loading

_images/sphx_glr_trainingyt_thumb.png

7.28 KB
Loading
Loading
Loading
Loading

0 commit comments

Comments
 (0)