Files
wehub-resource-sync 37c25cd088
make_docs / deploy (push) Has been cancelled
chore: import upstream snapshot with attribution
2026-07-13 13:27:58 +08:00

16 lines
1.4 KiB
Markdown

# 05. PyTorch Going Modular
The main goal of section [05. PyTorch Going Modular](https://www.learnpytorch.io/05_pytorch_going_modular/) is to: **turn useful notebook code cells into reusable Python scripts (`.py` files)**.
This directory contains all the necessary materials for doing so.
They breakdown as follows:
* `going_modular/` - directory of Python helper scripts for running PyTorch code (generated by `05_pytorch_going_modular_script_mode.ipynb`).
* `models/` - trained PyTorch models that come as a result of running notebook 05. Going Modular Part 1 and Part 2.
* [`05_pytorch_going_modular_cell_mode.ipynb`](https://github.com/mrdbourke/pytorch-deep-learning/blob/main/going_modular/05_pytorch_going_modular_cell_mode.ipynb) - Part 1/2 notebooks for teaching the materials for section 05. This notebook takes the most useful code from notebook 04 and streamlines it.
* [`05_pytorch_going_modular_script_mode.ipynb`](https://github.com/mrdbourke/pytorch-deep-learning/blob/main/going_modular/05_pytorch_going_modular_script_mode.ipynb) - Part 2/2 notebooks for teaching the materials for section 05. This notebooks turns the most useful code cells from Part 1 into the Python scripts contained in `going_modular/`.
For this section, we're going to see how the Part 1 notebook (cell mode) turns into the Part 2 notebook (script mode).
Doing this will result in us having a directory with the same structure as the `going_modular/` directory above.