Skip to content

Instantly share code, notes, and snippets.

@LeeTsinghua
LeeTsinghua / install.bash
Created December 8, 2022 05:40 — forked from Otteri/install.bash
Pytorch+cuda installation script for Ubuntu 20.04 LTS WSL
#!/bin/bash
# Installs Pytorch development environment
# on Ubuntu 20.04 LTS (WSL2) host machine
# First make sure that Windows GPU driver and WSL2 installations are ok,
# then launch WSL, create a new user and execute commands.
# Reference: https://docs.nvidia.com/cuda/wsl-user-guide/index.html
# 1) Install cuda stuff
sudo apt-key adv --fetch-keys http://developer.download.nvidia.com/compute/cuda/repos/ubuntu2004/x86_64/7fa2af80.pub