Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Setup Python development in Windows 10

Python Setup

Download and install Python 3.8.

Open the folder using VSCode.

Open the VSCode terminal using CTRL + J.

Then create new virtualenv using the following command:

python -m venv venv

This will create new folder named venv.

Then activate the virtualenv using the following command:

.\venv\Scripts\activate.bat

Now you can use pip to install the python package.

Jupyter Notebook Setup

Once the virtualenv is activated, you can install the jupyter notebook using the following command:

pip install jupyter

Then you can run the jupyter notebook using the following command:

jupyter notebook

CUDA Setup

To check wether CUDA is installed or not run the following command:

nvcc --version

If installed it should print the following information:

nvcc: NVIDIA (R) Cuda compiler driver
Copyright (c) 2005-2019 NVIDIA Corporation
Built on Sun_Jul_28_19:12:52_Pacific_Daylight_Time_2019
Cuda compilation tools, release 10.1, V10.1.243

If not then you need to download and install CUDA.

PyTorch Setup

Run the following command to install PyTorch:

pip install torch===1.4.0 torchvision===0.5.0 -f https://download.pytorch.org/whl/torch_stable.html
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.