Install TensorFlow With Pip - TensorFlow
Install TensorFlow With Pip - TensorFlow
tensorflow —Latest stable release with CPU and GPU support (https://www.tensor ow.org/install/gpu) (Ubuntu and Windows)
tf-nightly —Preview build (unstable). Ubuntu and Windows include GPU support (https://www.tensor ow.org/install/gpu).
System requirements
Python 3.5–3.7
Hardware requirements
Read the GPU support guide (https://www.tensor ow.org/install/gpu) to set up a CUDA®-enabled GPU card on Ubuntu or Windows.
ed
Python 3 Python 2.7
thon3 --version
p3 --version
rtualenv --version
https://www.tensorflow.org/install/pip 1/3
2/20/2020 Install TensorFlow with pip | TensorFlow
Python virtual environments are used to isolate package installation from the system.
( )
Create a new virtual environment by choosing a Python interpreter and making a ./venv directory to hold it:
When virtualenv is active, your shell prompt is pre xed with (venv).
Install packages within a virtual environment without affecting the host system setup. Start by upgrading pip:
(venv) $ pip list # show packages installed within the virtual environment
Choose one of the following TensorFlow packages to install from PyPI (https://pypi.org/project/tensor ow/):
tensorflow —Latest stable release with CPU and GPU support (https://www.tensor ow.org/install/gpu) (Ubuntu and Windows).
tf-nightly —Preview build (unstable). Ubuntu and Windows include GPU support (https://www.tensor ow.org/install/gpu).
( )
https://www.tensorflow.org/install/pip 2/3
2/20/2020 Install TensorFlow with pip | TensorFlow
ss: TensorFlow is now installed. Read the tutorials (https://www.tensor ow.org/tutorials) to get started.
Package location
A few installation mechanisms require the URL of the TensorFlow Python package. The value you specify depends on your Python version.
Version URL
Linux
macOS (CPU-only)
Windows
Raspberry PI (CPU-only)
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License (https://creativecommons.org/licenses/by/4.0/),
and code samples are licensed under the Apache 2.0 License (https://www.apache.org/licenses/LICENSE-2.0). For details, see the Google Developers Site Policies
(https://developers.google.com/site-policies). Java is a registered trademark of Oracle and/or its a liates.
https://www.tensorflow.org/install/pip 3/3