Skip to content

Commit bfc279e

Browse files
authored
Merge branch 'master' into patch-2
2 parents cc409cb + 237311d commit bfc279e

File tree

10 files changed

+355
-61
lines changed

10 files changed

+355
-61
lines changed

.circleci/config.yml

Lines changed: 44 additions & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -598,48 +598,47 @@ workflows:
598598
branches:
599599
only:
600600
- master
601-
- pytorch_tutorial_windows_pr_build_worker_0:
602-
filters:
603-
branches:
604-
ignore:
605-
- master
606-
- pytorch_tutorial_windows_pr_build_worker_1:
607-
filters:
608-
branches:
609-
ignore:
610-
- master
611-
- pytorch_tutorial_windows_pr_build_worker_2:
612-
filters:
613-
branches:
614-
ignore:
615-
- master
616-
- pytorch_tutorial_windows_pr_build_worker_3:
617-
filters:
618-
branches:
619-
ignore:
620-
- master
621-
- pytorch_tutorial_windows_master_build_worker_0:
622-
context: org-member
623-
filters:
624-
branches:
625-
only:
626-
- master
627-
- pytorch_tutorial_windows_master_build_worker_1:
628-
context: org-member
629-
filters:
630-
branches:
631-
only:
632-
- master
633-
- pytorch_tutorial_windows_master_build_worker_2:
634-
context: org-member
635-
filters:
636-
branches:
637-
only:
638-
- master
639-
- pytorch_tutorial_windows_master_build_worker_3:
640-
context: org-member
641-
filters:
642-
branches:
643-
only:
644-
- master
645-
601+
# - pytorch_tutorial_windows_pr_build_worker_0:
602+
# filters:
603+
# branches:
604+
# ignore:
605+
# - master
606+
# - pytorch_tutorial_windows_pr_build_worker_1:
607+
# filters:
608+
# branches:
609+
# ignore:
610+
# - master
611+
# - pytorch_tutorial_windows_pr_build_worker_2:
612+
# filters:
613+
# branches:
614+
# ignore:
615+
# - master
616+
# - pytorch_tutorial_windows_pr_build_worker_3:
617+
# filters:
618+
# branches:
619+
# ignore:
620+
# - master
621+
# - pytorch_tutorial_windows_master_build_worker_0:
622+
# context: org-member
623+
# filters:
624+
# branches:
625+
# only:
626+
# - master
627+
# - pytorch_tutorial_windows_master_build_worker_1:
628+
# context: org-member
629+
# filters:
630+
# branches:
631+
# only:
632+
# - master
633+
# - pytorch_tutorial_windows_master_build_worker_2:
634+
# context: org-member
635+
# filters:
636+
# branches:
637+
# only:
638+
# - master
639+
# - pytorch_tutorial_windows_master_build_worker_3:
640+
# context: org-member
641+
# filters:
642+
# branches:
643+
# only:
644+
# - master

.devcontainer/requirements.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ ipython
2424
# to run examples
2525
pandas
2626
scikit-image
27-
pillow==8.3.2
27+
pillow==9.0.0
2828
wget
2929

3030
# for codespaces env
34.9 KB
Loading

beginner_source/basics/data_tutorial.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -160,7 +160,7 @@ def __getitem__(self, idx):
160160

161161

162162
def __init__(self, annotations_file, img_dir, transform=None, target_transform=None):
163-
self.img_labels = pd.read_csv(annotations_file, names=['file_name', 'label'])
163+
self.img_labels = pd.read_csv(annotations_file)
164164
self.img_dir = img_dir
165165
self.transform = transform
166166
self.target_transform = target_transform

beginner_source/basics/quickstart_tutorial.py

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,7 @@
2626
from torch import nn
2727
from torch.utils.data import DataLoader
2828
from torchvision import datasets
29-
from torchvision.transforms import ToTensor, Lambda, Compose
30-
import matplotlib.pyplot as plt
29+
from torchvision.transforms import ToTensor
3130

3231
######################################################################
3332
# PyTorch offers domain-specific libraries such as `TorchText <https://pytorch.org/text/stable/index.html>`_,
@@ -67,8 +66,8 @@
6766
test_dataloader = DataLoader(test_data, batch_size=batch_size)
6867

6968
for X, y in test_dataloader:
70-
print("Shape of X [N, C, H, W]: ", X.shape)
71-
print("Shape of y: ", y.shape, y.dtype)
69+
print(f"Shape of X [N, C, H, W]: {X.shape}")
70+
print(f"Shape of y: {y.shape} {y.dtype}")
7271
break
7372

7473
######################################################################

beginner_source/basics/tensorqs_tutorial.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@
112112

113113
# We move our tensor to the GPU if available
114114
if torch.cuda.is_available():
115-
tensor = tensor.to('cuda')
115+
tensor = tensor.to("cuda")
116116

117117

118118
######################################################################
@@ -124,9 +124,9 @@
124124
# **Standard numpy-like indexing and slicing:**
125125

126126
tensor = torch.ones(4, 4)
127-
print('First row: ', tensor[0])
128-
print('First column: ', tensor[:, 0])
129-
print('Last column:', tensor[..., -1])
127+
print(f"First row: {tensor[0]}")
128+
print(f"First column: {tensor[:, 0]}")
129+
print(f"Last column: {tensor[..., -1]}")
130130
tensor[:,1] = 0
131131
print(tensor)
132132

@@ -172,7 +172,7 @@
172172
# Operations that store the result into the operand are called in-place. They are denoted by a ``_`` suffix.
173173
# For example: ``x.copy_(y)``, ``x.t_()``, will change ``x``.
174174

175-
print(tensor, "\n")
175+
print(f"{tensor} \n")
176176
tensor.add_(5)
177177
print(tensor)
178178

index.rst

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ Welcome to PyTorch Tutorials
5555
:image: _static/img/thumbnails/cropped/60-min-blitz.png
5656
:link: beginner/basics/intro.html
5757
:tags: Getting-Started
58-
58+
5959
.. customcarditem::
6060
:header: Introduction to PyTorch on YouTube
6161
:card_description: An introduction to building a complete ML workflow with PyTorch. Follows the PyTorch Beginner Series on YouTube.
@@ -120,7 +120,7 @@ Welcome to PyTorch Tutorials
120120
:image: _static/img/thumbnails/cropped/DCGAN-Tutorial.png
121121
:link: beginner/dcgan_faces_tutorial.html
122122
:tags: Image/Video
123-
123+
124124
.. customcarditem::
125125
:header: Spatial Transformer Networks Tutorial
126126
:card_description: Learn how to augment your network using a visual attention mechanism.
@@ -496,6 +496,13 @@ Welcome to PyTorch Tutorials
496496
:link: intermediate/dist_tuto.html
497497
:tags: Parallel-and-Distributed-Training
498498

499+
.. customcarditem::
500+
:header: Customize Process Group Backends Using Cpp Extensions
501+
:card_description: Extend ProcessGroup with custom collective communication implementations.
502+
:image: _static/img/thumbnails/cropped/Customize-Process-Group-Backends-Using-Cpp-Extensions.png
503+
:link: intermediate/process_group_cpp_extension_tutorial.html
504+
:tags: Parallel-and-Distributed-Training
505+
499506
.. customcarditem::
500507
:header: Getting Started with Distributed RPC Framework
501508
:card_description: Learn how to build distributed training using the torch.distributed.rpc package.
@@ -646,7 +653,7 @@ Additional Resources
646653
beginner/basics/autogradqs_tutorial
647654
beginner/basics/optimization_tutorial
648655
beginner/basics/saveloadrun_tutorial
649-
656+
650657
.. toctree::
651658
:maxdepth: 2
652659
:hidden:
@@ -799,6 +806,7 @@ Additional Resources
799806
intermediate/model_parallel_tutorial
800807
intermediate/ddp_tutorial
801808
intermediate/dist_tuto
809+
intermediate/process_group_cpp_extension_tutorial
802810
intermediate/rpc_tutorial
803811
intermediate/rpc_param_server_tutorial
804812
intermediate/dist_pipeline_parallel_tutorial

intermediate_source/fx_profiling_tutorial.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -218,7 +218,7 @@ def summary(self, should_sort : bool = False) -> str:
218218
# https://github.com/pytorch/pytorch/issues/51393
219219
# * BatchNorm2d also takes up significant time. We can continue this
220220
# line of thinking and optimize this in the Conv-BN Fusion with FX
221-
# tutorial TODO: link
221+
# `tutorial <https://pytorch.org/tutorials/intermediate/fx_conv_bn_fuser.html>`_.
222222
#
223223
#
224224
# Conclusion

0 commit comments

Comments
 (0)