Install Tensorflow on Linux
In this article, we are going to see how to install TensorFlow in Linux. It is a completely open-source library for numerical computation using data flow graphs.
- Python 3.6 to 3.8.
- Pip 19.0 or higher.
- Ubuntu 16.04 or higher.
Step 1: Create a virtual environment for the python venv model.
sudo apt install python3-venv python3-dev
Step 2: Create a python 3 virtual environment.
mkdir tensor cd tensor/ python3 -m venv <virtual_environment_name>
Step 3: Now check the pip version in a virtual environment.
Here our pip is 9, so we need to upgrade the pip using –upgrade:
pip install --upgrade pip
Step 4: Install TensorFlow using pip:
pip install --upgrade tensorflow
Step 5: Check it is installed properly or not.
import tensorflow as tf print(tf.__version__);
Attention geek! Strengthen your foundations with the Python Programming Foundation Course and learn the basics.
To begin with, your interview preparations Enhance your Data Structures concepts with the Python DS Course. And to begin with your Machine Learning Journey, join the Machine Learning – Basic Level Course