Coding With Fun
Home Docker Django Node.js Articles Python pip guide FAQ Policy
 

How to install tf-gpu via python pip




tf-gpu - TensorFlow is an open source machine learning framework for everyone., it belongs to Classifiers:

- Environment :: GPU
- Environment :: GPU :: NVIDIA CUDA
- Environment :: GPU :: NVIDIA CUDA :: 11.2
- Intended Audience :: Education
- Topic :: Scientific/Engineering :: Artificial Intelligence

When you know about this project and you want to new install tf-gpu to support your project or you get trouble as ModuleNotFoundError: No module named "tf-gpu" or ImportError: cannot import name "tf-gpu" in your project, let follow this tutorial to install tf-gpu



Installation:

Step 1: First, ensure you installed pip in your os, to check pip has been installed on your computer

In Windows (CMD):

py -m pip --version

In Unix/macOS:

python3 -m pip --version

Ensure pip, setuptools, and wheel are up to date:

In Windows (CMD):

py -m pip install --upgrade pip setuptools wheel

In Unix/macOS:

python3 -m pip install --upgrade pip setuptools wheel


Optional - If you want to install in virtual environment:

In Windows (CMD):

- Install virtualenv - if you installed it, please ignore

py -m pip install --user virtualenv

- Create a virtual environment

py -m venv test_tf-gpu_env

- Active the virtual environment

test_tf-gpu_env\Scripts\active

In Unix/macOS:

- Install virtualenv - if you installed it, please ignore

pip3 install virtualenv

- Create a virtual environment

python3 -m venv test_tf-gpu_env

- Active the virtual environment

source test_tf-gpu_env/bin/active


Step 2: OK, now, let flow below content to start the installation tf-gpu

To install tf-gpu on Windows(CMD):

py -m pip install tf-gpu

To install tf-gpu on Unix/macOs:

pip install tf-gpu


Step 3: If you want to install a specific tf-gpu version, add ==<tf-gpu version> to the end command line

Example:

pip install tf-gpu==1.15.5.2204


Please see the version list below table:

VersionReleased dateCommand
tf-gpu 2.9.12022-05-26T08:06:54Windows:

py -m pip install tf-gpu==2.9.1

Unix/macOs:

pip install tf-gpu==2.9.1

tf-gpu 2.9.02022-05-26T12:00:55Windows:

py -m pip install tf-gpu==2.9.0

Unix/macOs:

pip install tf-gpu==2.9.0

tf-gpu 2.8.22022-05-26T03:34:14Windows:

py -m pip install tf-gpu==2.8.2

Unix/macOs:

pip install tf-gpu==2.8.2

tf-gpu 2.8.12022-05-25T08:55:42Windows:

py -m pip install tf-gpu==2.8.1

Unix/macOs:

pip install tf-gpu==2.8.1

tf-gpu 2.8.02022-05-25T13:44:48Windows:

py -m pip install tf-gpu==2.8.0

Unix/macOs:

pip install tf-gpu==2.8.0

tf-gpu 2.7.32022-06-05T07:28:04Windows:

py -m pip install tf-gpu==2.7.3

Unix/macOs:

pip install tf-gpu==2.7.3

tf-gpu 2.6.52022-06-05T01:33:41Windows:

py -m pip install tf-gpu==2.6.5

Unix/macOs:

pip install tf-gpu==2.6.5

tf-gpu 1.15.5.22062022-08-07T06:37:19Windows:

py -m pip install tf-gpu==1.15.5.2206

Unix/macOs:

pip install tf-gpu==1.15.5.2206

tf-gpu 1.15.5.22052022-06-04T12:48:52Windows:

py -m pip install tf-gpu==1.15.5.2205

Unix/macOs:

pip install tf-gpu==1.15.5.2205

tf-gpu 1.15.5.22042022-05-25T02:16:04Windows:

py -m pip install tf-gpu==1.15.5.2204

Unix/macOs:

pip install tf-gpu==1.15.5.2204


Step 4: Otherwise, you can install tf-gpu from local archives:

Download the distribution file from tf_gpu-2.9.1-cp310-cp310-manylinux2014_x86_64.whl or the specific tf-gpu version in the below list of distribution

After that, install by command:

On Windows(CMD):

py -m pip install <path_to_tf-gpu_downloaded_file>

On Unix/macOs:

pip install <path_to_tf-gpu_downloaded_file>


List distribution:


Project link:

- Homepage
- Download