Simple exploratory materials for pytorch with Linux laptop containing an NVIDIA GPU
The purpose of this project is to capture the things needed to consider when getting started with PyTorch on Fedora Linux running on a laptop containing an NVIDIA GPU.
To install Fedora 39 (40 will be released soon) go to LINK and download the Fedora Media Writer.
You can write the installer to a thumb drive of about 20GB or so.
To install the CUDA NVIDIA driver on Fedora 39 see installation instructions
Fedora 39 comes with Python 3.12.2. But, to be certain ...
$ sudo dnf install python3.12
Install pdm
. See https://pdm-project.org/latest/#recommended-installation-method.
Then execute the following in this repo to create the virtualenv and install Python dependencies.
$ pdm create
To install VS Code on Fedora follow these MS instructions.
Then install the Python extensions. VS Code Python Quick Start
Run All
in jupyter/pytorch-install-jul-2020.ipynb
See this project for a tool to disable the GPU: nvidia_more_battery
Once you have nvidia_more_battery enabled
and have rebooted run the tests again to see the difference!
- light-weight performance test jupyter/t81_558_class_03_2_pytorch.ipynb
- performance test runs in ~3 mins w/GPU; >24 mins w/CPU jupyter/t81_558_class_08_4_bayesian_hyperparameter_opt.ipynb
- PyTorch docs
- PyTorch Tutorials
- PyTorch GitHub repo
- How to Install PyTorch on Linux for CPU or GPU - No Driver Install Needed - YT (~10 mins)
- NVIDIA CUDA in 100 Seconds
- NVIDIA XFree86 README
- Chapter 17. Using the NVIDIA Driver with Optimus Laptops
- Chapter 35. PRIME Render Offload
- archwiki PRIME
- archwiki NVIDIA
- How to Install NVIDIA Drivers on Fedora 39, 38 Linux
- T81 558: Applications of Deep Neural Networks
- Original T81 558:Applications of Deep Neural Networks this commit still contains some PyTorch content