pytorch / pytorch/tutorials

Make codeblocks non-executable

Open
#792 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

60_min_blitz
Dominant language
Python
Stars
9.3k
Forks
4.4k
Avg merge
1d 21h
Merged PRs (30d)
4

Description

Certain codeblocks in the Training a Classifier colab should be non-executable; otherwise, users will run and expect output and be confused when they get an error. Specifically the code under the "2. Define a Convolution Neural Network" and the "3. Define a Loss function and optimizer" sections.

They should match the html version: https://pytorch.org/tutorials/beginner/blitz/cifar10_tutorial.html#sphx-glr-beginner-blitz-cifar10-tutorial-py

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Open the linked Training a Classifier Colab notebook and compare the sections "2. Define a Convolution Neural Network" and "3. Define a Loss function and optimizer" with the linked HTML version. Update the notebook so those codeblocks are non-executable, then verify they no longer invite users to run code that produces the reported error.

Written by the indexing model from the issue text.

Assessment

Tech stack
jupyter-notebook, python
Domain
documentation
Issue type
Documentation
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.