@@ -10,14 +10,14 @@ There are a few ways to set up your environment to use TensorFlow Quantum (TFQ):
1010 Python's pip package manager.
1111* Or build TensorFlow Quantum from source.
1212
13- TensorFlow Quantum is supported on Python 3.7 , 3.8 , and 3.9 and depends directly on [ Cirq] ( https://github.com/quantumlib/Cirq ) .
13+ TensorFlow Quantum is supported on Python 3.9 , 3.10 , and 3.11 and depends directly on [ Cirq] ( https://github.com/quantumlib/Cirq ) .
1414
1515## Pip package
1616
1717### Requirements
1818
19- * pip 19.0 or later (requires ` manylinux2010 ` support)
20- * [ TensorFlow == 2.11 .0] ( https://www.tensorflow.org/install/pip )
19+ * pip 19.0 or later (requires ` manylinux2014 ` support)
20+ * [ TensorFlow == 2.15 .0] ( https://www.tensorflow.org/install/pip )
2121
2222See the [ TensorFlow install guide] ( https://www.tensorflow.org/install/pip ) to
2323set up your Python development environment and an (optional) virtual environment.
@@ -27,7 +27,7 @@ Upgrade `pip` and install TensorFlow
2727<!-- common_typos_disable -->
2828<pre class =" devsite-click-to-copy " >
2929 <code class =" devsite-terminal " >pip3 install --upgrade pip</code >
30- <code class =" devsite-terminal " >pip3 install tensorflow==2.11 .0</code >
30+ <code class =" devsite-terminal " >pip3 install tensorflow==2.15 .0</code >
3131</pre >
3232<!-- common_typos_enable -->
3333
@@ -57,13 +57,13 @@ The following steps are tested for Ubuntu-like systems.
5757
5858### 1. Set up a Python 3 development environment
5959
60- First we need the Python 3.8 development tools.
60+ First we need the Python 3.10 development tools.
6161<!-- common_typos_disable -->
6262<pre class =" devsite-click-to-copy " >
6363 <code class =" devsite-terminal " >sudo apt update</code >
64- <code class =" devsite-terminal " >sudo apt-get install pkg-config zip g++ zlib1g-dev unzip python3.8 </code >
65- <code class =" devsite-terminal " >sudo apt install python3.8 python3.8 -dev python3.8 -venv python3-pip</code >
66- <code class =" devsite-terminal " >python3.8 -m pip install --upgrade pip</code >
64+ <code class =" devsite-terminal " >sudo apt-get install pkg-config zip g++ zlib1g-dev unzip python3.10 </code >
65+ <code class =" devsite-terminal " >sudo apt install python3.10 python3.10 -dev python3.10 -venv python3-pip</code >
66+ <code class =" devsite-terminal " >python3.10 -m pip install --upgrade pip</code >
6767</pre >
6868<!-- common_typos_enable -->
6969
@@ -72,7 +72,7 @@ First we need the Python 3.8 development tools.
7272Go to your workspace directory and make a virtual environment for TFQ development.
7373<!-- common_typos_disable -->
7474<pre class =" devsite-click-to-copy " >
75- <code class =" devsite-terminal " >python3.8 -m venv quantum_env</code >
75+ <code class =" devsite-terminal " >python3.10 -m venv quantum_env</code >
7676 <code class =" devsite-terminal " >source quantum_env/bin/activate</code >
7777</pre >
7878<!-- common_typos_enable -->
@@ -84,21 +84,20 @@ As noted in the TensorFlow
8484guide, the <a href =" https://bazel.build/ " class =" external " >Bazel</a >
8585build system will be required.
8686
87- Our latest source builds use TensorFlow 2.11.0. To ensure compatibility we use ` bazel ` version 5.3.0. To remove any existing version of Bazel:
88-
87+ Our latest source builds use TensorFlow 2.15.0. To ensure compatibility we use ` bazel ` version 6.5.0. To remove any existing version of Bazel:
8988<!-- common_typos_disable -->
9089<pre class =" devsite-click-to-copy " >
9190 <code class =" devsite-terminal " >sudo apt-get remove bazel</code >
9291</pre >
9392<!-- common_typos_enable -->
9493
95- Download and install ` bazel ` version 5.3 .0:
94+ Download and install ` bazel ` version 6.5 .0:
9695
9796<!-- common_typos_disable -->
9897<pre class =" devsite-click-to-copy " >
99- <code class =" devsite-terminal " >wget https://github.com/bazelbuild/bazel/releases/download/5.3.0/bazel_5.3 .0-linux-x86_64.deb
98+ <code class =" devsite-terminal " >wget https://github.com/bazelbuild/bazel/releases/download/6.5.0/bazel_6.5 .0-linux-x86_64.deb
10099</code >
101- <code class =" devsite-terminal " >sudo dpkg -i bazel_5.3 .0-linux-x86_64.deb</code >
100+ <code class =" devsite-terminal " >sudo dpkg -i bazel_6.5 .0-linux-x86_64.deb</code >
102101</pre >
103102<!-- common_typos_enable -->
104103
@@ -122,7 +121,7 @@ Finally, confirm installation of the correct `bazel` version:
122121### 4. Build TensorFlow from source
123122
124123Here we adapt instructions from the TensorFlow [ build from source] ( https://www.tensorflow.org/install/source )
125- guide, see the link for further details. TensorFlow Quantum is compatible with TensorFlow version  ; 2.11 .0.
124+ guide, see the link for further details. TensorFlow Quantum is compatible with TensorFlow version  ; 2.15 .0.
126125
127126Download the
128127<a href =" https://github.com/tensorflow/tensorflow " class =" external " >TensorFlow source code</a >:
@@ -131,7 +130,7 @@ Download the
131130<pre class =" devsite-click-to-copy " >
132131 <code class =" devsite-terminal " >git clone https://github.com/tensorflow/tensorflow.git</code >
133132 <code class =" devsite-terminal " >cd tensorflow</code >
134- <code class =" devsite-terminal " >git checkout v2.11 .0</code >
133+ <code class =" devsite-terminal " >git checkout v2.15 .0</code >
135134</pre >
136135
137136Be sure the virtual environment you created in step 2 is activated. Then, install the TensorFlow dependencies:
@@ -141,7 +140,7 @@ Be sure the virtual environment you created in step 2 is activated. Then, instal
141140 <code class =" devsite-terminal " >pip install -U pip six numpy wheel setuptools mock 'future>=0.17.1'</code >
142141 <code class =" devsite-terminal " >pip install -U keras_applications --no-deps</code >
143142 <code class =" devsite-terminal " >pip install -U keras_preprocessing --no-deps</code >
144- <code class =" devsite-terminal " >pip install numpy==1.24.2 </code >
143+ <code class =" devsite-terminal " >pip install numpy==1.23.5 </code >
145144 <code class =" devsite-terminal " >pip install packaging requests</code >
146145</pre >
147146<!-- common_typos_enable -->
0 commit comments