apt-get update
apt install apt-transport-https curl gnupg patchelf -y
curl -fsSL https://bazel.build/bazel-release.pub.gpg | gpg --dearmor >bazel-archive-keyring.gpg
mv bazel-archive-keyring.gpg /usr/share/keyrings
echo "deb [arch=amd64 signed-by=/usr/share/keyrings/bazel-archive-keyring.gpg] https://storage.googleapis.com/bazel-apt stable jdk1.8" | tee /etc/apt/sources.list.d/bazel.list
apt-get update
apt-get install bazel=5.3.0
apt install python3-dev python3-pip
pip install -U --user pip numpy wheel packaging requests opt_einsum
pip install -U --user keras_preprocessing --no-deps
apt-get install wget
wget "https://github.com/tensorflow/tensorflow/archive/refs/tags/v2.11.1.zip"
unzip v2.11.1.zip
cd tensorflow-2.11.1/
./configure
bazel build -c opt --copt="-mtune=generic" --copt="-march=x86-64" //tensorflow/tools/pip_package:build_pip_package
./bazel-bin/tensorflow/tools/pip_package/build_pip_package /tmp/tensorflow_pkg
pip install numpy==1.23.1
Last active
April 5, 2023 07:00
-
-
Save tosiara/64fa09ded8d2785557bdcc1d4d1387d6 to your computer and use it in GitHub Desktop.
Build tensorflow without cpu optimizations
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Example of a build for Atom CPU: https://github.com/tosiara/Tensorflow-Intel-Atom-CPU/releases/tag/2.13