Pytorch is an open-source machine learning library. It is a framework that has been built upon the torch library. Using PyTorch you can build a computer vision and Natural Processing Language ( NLP ) application. If you have already installed pytorch in your system and want to uninstall it from your system then this post is for you. In this entire tutorial, you will learn how to uninstall PyTorch on different terminals.
How to uninstall PyTorch with Anaconda?
If you have installed Pytorch on Anaconda and want to uninstall it then you can use the conda command for that. Open your anaconda terminal and type the following conda command.
conda uninstall pytorch
It will successfully uninstall the Pytorch from the anaconda packages.

Uninstall PyTorch using pip
There is also another way to remove Pytorch from the python packages. To do you have to use the pip command. Pip is a python module that is already installed with the python module.
Before using the pip command you have to check the version of the python. If your system has python 3. xx installed then you will use the pip3 command. And if your system has python 2. xx then you will use the pip command.
To check the version of the python you have to run the below command.
python --version
Output

My system has python 3. xx installed, so I will use the pip3 command to uninstall PyTorch.
Run the below command to uninstall the PyTorch using pip.
pip3 uninstall torch

Uninstall PyTorch from Pycharm
If you have installed PyTorch in pycharm, then you can easily uninstall PyTorch. Follow the below steps to uninstall PyTorch from Pycharm.
Step 1: Go to File and click settings.
Step 2: Go to the project Interprete.
Here you will find all the packages installed in your PyTorch environment.

Step 3: Search for the torch package.
Step 4: Select on torch package and click on the ” – “ sign to uninstall the torch package.

Conclusion
Pytorch is a popular machine learning library for OpenCV and NLP applications. This framework is managed by open-source community and built by Facebook. If you want to uninstall Pytroch from your system then the above methods will work for you. I hope you have liked this tutorial. If you have any queries then you can contact us for more help.
Join our list
Subscribe to our mailing list and get interesting stuff and updates to your email inbox.