diff --git a/conf.py b/conf.py index d53fce24ed5..4de7b5f6128 100644 --- a/conf.py +++ b/conf.py @@ -44,7 +44,7 @@ except ImportError: import warnings warnings.warn('unable to load "torchvision" package') -import pytorch_sphinx_theme +#import pytorch_sphinx_theme # -- General configuration ------------------------------------------------ @@ -174,7 +174,7 @@ html_theme = 'pytorch_sphinx_theme' -html_theme_path = [pytorch_sphinx_theme.get_html_theme_path()] +html_theme_path = ['../../pytorch_sphinx_theme-1'] html_logo = '_static/img/pytorch-logo-dark.svg' html_theme_options = { 'pytorch_project': 'tutorials', @@ -250,4 +250,4 @@ def setup(app): app.add_directive('galleryitem', GalleryItemDirective) app.add_directive('customgalleryitem', CustomGalleryItemDirective) app.add_directive('customcarditem', CustomCardItemDirective) - app.add_directive('customcalloutitem', CustomCalloutItemDirective) \ No newline at end of file + app.add_directive('customcalloutitem', CustomCalloutItemDirective) diff --git a/custom_directives.py b/custom_directives.py index cfb1174409b..3cce19b510d 100644 --- a/custom_directives.py +++ b/custom_directives.py @@ -213,7 +213,8 @@ class CustomCardItemDirective(Directive): 'image': directives.unchanged, 'link': directives.unchanged, 'card_description': directives.unchanged, - 'tags': directives.unchanged} + 'tags': directives.unchanged, + 'level': directives.unchanged} def run(self): try: @@ -242,6 +243,11 @@ def run(self): else: tags = '' + if 'level' in self.options: + level = self.options['level'] + else: + level = '' + except FileNotFoundError as e: print(e) return [] @@ -254,7 +260,8 @@ def run(self): image=image, link=link, card_description=card_description, - tags=tags) + tags=tags, + level=level) card_list = StringList(card_rst.split('\n')) card = nodes.paragraph() self.state.nested_parse(card_list, self.content_offset, card) @@ -264,7 +271,7 @@ def run(self): CARD_TEMPLATE = """ .. raw:: html -
+
diff --git a/index.rst b/index.rst index 06a24e8c76d..2a6254597ab 100644 --- a/index.rst +++ b/index.rst @@ -32,9 +32,23 @@ Welcome to PyTorch Tutorials @@ -56,6 +70,7 @@ Welcome to PyTorch Tutorials :image: _static/img/thumbnails/cropped/60-min-blitz.png :link: beginner/deep_learning_60min_blitz.html :tags: Getting-Started + :level: beginner .. customcarditem:: :header: Learning PyTorch with Examples @@ -63,6 +78,7 @@ Welcome to PyTorch Tutorials :image: _static/img/thumbnails/cropped/learning-pytorch-with-examples.png :link: beginner/pytorch_with_examples.html :tags: Getting-Started + :level: beginner .. customcarditem:: :header: What is torch.nn really? @@ -70,6 +86,7 @@ Welcome to PyTorch Tutorials :image: _static/img/thumbnails/cropped/torch-nn.png :link: beginner/nn_tutorial.html :tags: Getting-Started + :level: beginner .. customcarditem:: :header: Visualizing Models, Data, and Training with Tensorboard @@ -77,6 +94,7 @@ Welcome to PyTorch Tutorials :image: _static/img/thumbnails/cropped/visualizing-with-tensorboard.png :link: intermediate/tensorboard_tutorial.html :tags: Interpretability,Getting-Started,Tensorboard + :level: beginner .. Image/Video @@ -86,6 +104,7 @@ Welcome to PyTorch Tutorials :image: _static/img/thumbnails/cropped/TorchVision-Object-Detection-Finetuning-Tutorial.png :link: intermediate/torchvision_tutorial.html :tags: Image/Video + :level: beginner .. customcarditem:: :header: Transfer Learning for Computer Vision Tutorial @@ -93,6 +112,7 @@ Welcome to PyTorch Tutorials :image: _static/img/thumbnails/cropped/Transfer-Learning-for-Computer-Vision-Tutorial.png :link: beginner/transfer_learning_tutorial.html :tags: Image/Video + :level: beginner .. customcarditem:: :header: Adversarial Example Generation @@ -100,6 +120,7 @@ Welcome to PyTorch Tutorials :image: _static/img/thumbnails/cropped/Adversarial-Example-Generation.png :link: beginner/fgsm_tutorial.html :tags: Image/Video + :level: beginner .. customcarditem:: :header: DCGAN Tutorial @@ -107,6 +128,7 @@ Welcome to PyTorch Tutorials :image: _static/img/thumbnails/cropped/DCGAN-Tutorial.png :link: beginner/dcgan_faces_tutorial.html :tags: Image/Video + :level: beginner .. Audio @@ -116,6 +138,7 @@ Welcome to PyTorch Tutorials :image: _static/img/thumbnails/cropped/torchaudio-Tutorial.png :link: beginner/audio_preprocessing_tutorial.html :tags: Audio + :level: beginner .. Text @@ -125,6 +148,7 @@ Welcome to PyTorch Tutorials :image: _static/img/thumbnails/cropped/Sequence-to-Sequence-Modeling-with-nnTransformer-andTorchText.png :link: beginner/transformer_tutorial.html :tags: Text + :level: beginner .. customcarditem:: :header: NLP from Scratch: Classifying Names with a Character-level RNN @@ -132,6 +156,7 @@ Welcome to PyTorch Tutorials :image: _static/img/thumbnails/cropped/NLP-From-Scratch-Classifying-Names-with-a-Character-Level-RNN.png :link: intermediate/char_rnn_classification_tutorial :tags: Text + :level: beginner .. customcarditem:: :header: NLP from Scratch: Generating Names with a Character-level RNN @@ -139,6 +164,7 @@ Welcome to PyTorch Tutorials :image: _static/img/thumbnails/cropped/NLP-From-Scratch-Generating-Names-with-a-Character-Level-RNN.png :link: intermediate/char_rnn_generation_tutorial.html :tags: Text + :level: beginner .. customcarditem:: :header: NLP from Scratch: Translation with a Sequence-to-sequence Network and Attention @@ -146,6 +172,7 @@ Welcome to PyTorch Tutorials :image: _static/img/thumbnails/cropped/NLP-From-Scratch-Translation-with-a-Sequence-to-Sequence-Network-and-Attention.png :link: intermediate/seq2seq_translation_tutorial.html :tags: Text + :level: beginner .. customcarditem:: :header: Text Classification with Torchtext @@ -153,6 +180,7 @@ Welcome to PyTorch Tutorials :image: _static/img/thumbnails/cropped/Text-Classification-with-TorchText.png :link: beginner/text_sentiment_ngrams_tutorial.html :tags: Text + :level: beginner .. customcarditem:: :header: Language Translation with Torchtext @@ -160,6 +188,7 @@ Welcome to PyTorch Tutorials :image: _static/img/thumbnails/cropped/Language-Translation-with-TorchText.png :link: beginner/torchtext_translation_tutorial.html :tags: Text + :level: beginner .. Reinforcement Learning @@ -169,6 +198,7 @@ Welcome to PyTorch Tutorials :image: _static/img/cartpole.gif :link: intermediate/reinforcement_q_learning.html :tags: Reinforcement-Learning + :level: beginner .. Deploying PyTorch Models in Production @@ -178,6 +208,7 @@ Welcome to PyTorch Tutorials :image: _static/img/thumbnails/cropped/Deploying-PyTorch-in-Python-via-a-REST-API-with-Flask.png :link: intermediate/flask_rest_api_tutorial.html :tags: Production + :level: beginner .. customcarditem:: :header: Introduction to TorchScript @@ -185,6 +216,7 @@ Welcome to PyTorch Tutorials :image: _static/img/thumbnails/cropped/Introduction-to-TorchScript.png :link: beginner/Intro_to_TorchScript_tutorial.html :tags: Production + :level: beginner .. customcarditem:: :header: Loading a TorchScript Model in C++ @@ -192,6 +224,7 @@ Welcome to PyTorch Tutorials :image: _static/img/thumbnails/cropped/Loading-a-TorchScript-Model-in-Cpp.png :link: advanced/cpp_export.html :tags: Production + :level: beginner .. customcarditem:: :header: (optional) Exporting a Model from PyTorch to ONNX and Running it using ONNX Runtime @@ -199,6 +232,7 @@ Welcome to PyTorch Tutorials :image: _static/img/thumbnails/cropped/optional-Exporting-a-Model-from-PyTorch-to-ONNX-and-Running-it-using-ONNX-Runtime.png :link: advanced/super_resolution_with_onnxruntime.html :tags: Production + :level: beginner .. Frontend APIs @@ -208,6 +242,7 @@ Welcome to PyTorch Tutorials :image: _static/img/thumbnails/cropped/experimental-Introduction-to-Named-Tensors-in-PyTorch.png :link: intermediate/named_tensor_tutorial.html :tags: Frontend-APIs,Named-Tensor,Best-Practice + :level: beginner .. customcarditem:: :header: (beta) Channels Last Memory Format in PyTorch @@ -215,6 +250,7 @@ Welcome to PyTorch Tutorials :image: _static/img/thumbnails/cropped/experimental-Channels-Last-Memory-Format-in-PyTorch.png :link: intermediate/memory_format_tutorial.html :tags: Memory-Format,Best-Practice + :level: beginner .. customcarditem:: :header: Using the PyTorch C++ Frontend @@ -222,6 +258,7 @@ Welcome to PyTorch Tutorials :image: _static/img/thumbnails/cropped/Using-the-PyTorch-Cpp-Frontend.png :link: advanced/cpp_frontend.html :tags: Frontend-APIs,C++ + :level: beginner .. customcarditem:: :header: Custom C++ and CUDA Extensions @@ -229,6 +266,7 @@ Welcome to PyTorch Tutorials :image: _static/img/thumbnails/cropped/Custom-Cpp-and-CUDA-Extensions.png :link: advanced/cpp_extension.html :tags: Frontend-APIs,C++,CUDA + :level: beginner .. customcarditem:: :header: Extending TorchScript with Custom C++ Operators @@ -236,6 +274,7 @@ Welcome to PyTorch Tutorials :image: _static/img/thumbnails/cropped/Extending-TorchScript-with-Custom-Cpp-Operators.png :link: advanced/torch_script_custom_ops.html :tags: Frontend-APIs,TorchScript,C++ + :level: beginner .. customcarditem:: :header: Extending TorchScript with Custom C++ Classes @@ -243,6 +282,7 @@ Welcome to PyTorch Tutorials :image: _static/img/thumbnails/cropped/Extending-TorchScript-with-Custom-Cpp-Classes.png :link: advanced/torch_script_custom_classes.html :tags: Frontend-APIs,TorchScript,C++ + :level: advanced .. customcarditem:: :header: Dynamic Parallelism in TorchScript @@ -250,6 +290,7 @@ Welcome to PyTorch Tutorials :image: _static/img/thumbnails/cropped/TorchScript-Parallelism.jpg :link: advanced/torch-script-parallelism.html :tags: Frontend-APIs,TorchScript,C++ + :level: advanced .. customcarditem:: :header: Autograd in C++ Frontend @@ -257,6 +298,7 @@ Welcome to PyTorch Tutorials :image: _static/img/thumbnails/cropped/Autograd-in-Cpp-Frontend.png :link: advanced/cpp_autograd.html :tags: Frontend-APIs,C++ + :level: advanced .. Model Optimization @@ -266,6 +308,7 @@ Welcome to PyTorch Tutorials :image: _static/img/ray-tune.png :link: beginner/hyperparameter_tuning_tutorial.html :tags: Model-Optimization,Best-Practice + :level: advanced .. customcarditem:: :header: Pruning Tutorial @@ -273,6 +316,7 @@ Welcome to PyTorch Tutorials :image: _static/img/thumbnails/cropped/Pruning-Tutorial.png :link: intermediate/pruning_tutorial.html :tags: Model-Optimization,Best-Practice + :level: advanced .. customcarditem:: :header: (beta) Dynamic Quantization on an LSTM Word Language Model @@ -280,6 +324,7 @@ Welcome to PyTorch Tutorials :image: _static/img/thumbnails/cropped/experimental-Dynamic-Quantization-on-an-LSTM-Word-Language-Model.png :link: advanced/dynamic_quantization_tutorial.html :tags: Text,Quantization,Model-Optimization + :level: advanced .. customcarditem:: :header: (beta) Dynamic Quantization on BERT @@ -287,6 +332,7 @@ Welcome to PyTorch Tutorials :image: _static/img/thumbnails/cropped/experimental-Dynamic-Quantization-on-BERT.png :link: intermediate/dynamic_quantization_bert_tutorial.html :tags: Text,Quantization,Model-Optimization + :level: advanced .. customcarditem:: :header: (beta) Static Quantization with Eager Mode in PyTorch @@ -294,6 +340,7 @@ Welcome to PyTorch Tutorials :image: _static/img/thumbnails/cropped/experimental-Static-Quantization-with-Eager-Mode-in-PyTorch.png :link: advanced/static_quantization_tutorial.html :tags: Image/Video,Quantization,Model-Optimization + :level: advanced .. customcarditem:: :header: (beta) Quantized Transfer Learning for Computer Vision Tutorial @@ -301,6 +348,7 @@ Welcome to PyTorch Tutorials :image: _static/img/thumbnails/cropped/experimental-Quantized-Transfer-Learning-for-Computer-Vision-Tutorial.png :link: advanced/static_quantization_tutorial.html :tags: Image/Video,Quantization,Model-Optimization + :level: advanced .. Parallel-and-Distributed-Training @@ -310,6 +358,7 @@ Welcome to PyTorch Tutorials :image: _static/img/thumbnails/cropped/PyTorch-Distributed-Overview.png :link: beginner/dist_overview.html :tags: Parallel-and-Distributed-Training + :level: advanced .. customcarditem:: :header: Single-Machine Model Parallel Best Practices @@ -317,6 +366,7 @@ Welcome to PyTorch Tutorials :image: _static/img/thumbnails/cropped/Model-Parallel-Best-Practices.png :link: intermediate/model_parallel_tutorial.html :tags: Parallel-and-Distributed-Training + :level: advanced .. customcarditem:: :header: Getting Started with Distributed Data Parallel @@ -324,6 +374,7 @@ Welcome to PyTorch Tutorials :image: _static/img/thumbnails/cropped/Getting-Started-with-Distributed-Data-Parallel.png :link: intermediate/ddp_tutorial.html :tags: Parallel-and-Distributed-Training + :level: advanced .. customcarditem:: :header: (advanced) PyTorch 1.0 Distributed Trainer with Amazon AWS @@ -331,6 +382,7 @@ Welcome to PyTorch Tutorials :image: _static/img/thumbnails/cropped/advanced-PyTorch-1point0-Distributed-Trainer-with-Amazon-AWS.png :link: beginner/aws_distributed_training_tutorial.html :tags: Parallel-and-Distributed-Training + :level: advanced .. customcarditem:: :header: Writing Distributed Applications with PyTorch @@ -338,6 +390,7 @@ Welcome to PyTorch Tutorials :image: _static/img/thumbnails/cropped/Writing-Distributed-Applications-with-PyTorch.png :link: intermediate/dist_tuto.html :tags: Parallel-and-Distributed-Training + :level: advanced .. customcarditem:: :header: Getting Started with Distributed RPC Framework @@ -345,6 +398,7 @@ Welcome to PyTorch Tutorials :image: _static/img/thumbnails/cropped/Getting Started with Distributed-RPC-Framework.png :link: intermediate/rpc_tutorial.html :tags: Parallel-and-Distributed-Training + :level: advanced .. customcarditem:: :header: Implementing a Parameter Server Using Distributed RPC Framework @@ -352,6 +406,7 @@ Welcome to PyTorch Tutorials :image: _static/img/thumbnails/cropped/Implementing-a-Parameter-Server-Using-Distributed-RPC-Framework.png :link: intermediate/rpc_param_server_tutorial.html :tags: Parallel-and-Distributed-Training + :level: advanced .. customcarditem:: :header: Distributed Pipeline Parallelism Using RPC @@ -359,6 +414,7 @@ Welcome to PyTorch Tutorials :image: _static/img/thumbnails/cropped/Distributed-Pipeline-Parallelism-Using-RPC.png :link: intermediate/dist_pipeline_parallel_tutorial.html :tags: Parallel-and-Distributed-Training + :level: advanced .. customcarditem:: :header: Implementing Batch RPC Processing Using Asynchronous Executions @@ -366,13 +422,15 @@ Welcome to PyTorch Tutorials :image: _static/img/thumbnails/cropped/Implementing-Batch-RPC-Processing-Using-Asynchronous-Executions.png :link: intermediate/rpc_async_execution.html :tags: Parallel-and-Distributed-Training - + :level: advanced + .. customcarditem:: :header: Combining Distributed DataParallel with Distributed RPC Framework :card_description: Walk through a through a simple example of how to combine distributed data parallelism with distributed model parallelism. :image: _static/img/thumbnails/cropped/Combining-Distributed-DataParallel-with-Distributed-RPC-Framework.png :link: advanced/rpc_ddp_tutorial.html :tags: Parallel-and-Distributed-Training + :level: advanced .. End of tutorial card section