From d8a20834e3f8593eb12037bbcabd4f1704dcba68 Mon Sep 17 00:00:00 2001 From: Abolfazl Shahbazi Date: Tue, 2 Feb 2021 13:31:53 -0800 Subject: [PATCH] Paremeterize Python for easy version management --- .../onednn/centos-7-devel-jupyter.Dockerfile | 6 ++--- ...tos-7-devel-mpi-horovod-jupyter.Dockerfile | 6 ++--- ...s-7-devel-mpich-horovod-jupyter.Dockerfile | 6 ++--- .../onednn/centos-7-jupyter.Dockerfile | 6 ++--- .../centos-7-mpi-horovod-jupyter.Dockerfile | 10 ++++---- .../onednn/centos-7-mpi-horovod.Dockerfile | 4 ++-- .../centos-7-mpich-horovod-jupyter.Dockerfile | 10 ++++---- .../onednn/centos-7-mpich-horovod.Dockerfile | 4 ++-- .../onednn/centos-8-devel-jupyter.Dockerfile | 6 ++--- ...tos-8-devel-mpi-horovod-jupyter.Dockerfile | 6 ++--- ...s-8-devel-mpich-horovod-jupyter.Dockerfile | 6 ++--- .../onednn/centos-8-jupyter.Dockerfile | 6 ++--- .../centos-8-mpi-horovod-jupyter.Dockerfile | 10 ++++---- .../onednn/centos-8-mpi-horovod.Dockerfile | 4 ++-- .../centos-8-mpich-horovod-jupyter.Dockerfile | 10 ++++---- .../onednn/centos-8-mpich-horovod.Dockerfile | 4 ++-- .../ubuntu-16.04-devel-jupyter.Dockerfile | 10 ++++---- ...16.04-devel-mpi-horovod-jupyter.Dockerfile | 10 ++++---- .../ubuntu-16.04-devel-mpi-horovod.Dockerfile | 4 ++-- ....04-devel-mpich-horovod-jupyter.Dockerfile | 10 ++++---- ...buntu-16.04-devel-mpich-horovod.Dockerfile | 4 ++-- .../onednn/ubuntu-16.04-devel.Dockerfile | 4 ++-- .../onednn/ubuntu-16.04-jupyter.Dockerfile | 10 ++++---- ...buntu-16.04-mpi-horovod-jupyter.Dockerfile | 17 +++++++------- .../ubuntu-16.04-mpi-horovod.Dockerfile | 11 +++++---- ...ntu-16.04-mpich-horovod-jupyter.Dockerfile | 17 +++++++------- .../ubuntu-16.04-mpich-horovod.Dockerfile | 11 +++++---- .../onednn/ubuntu-16.04.Dockerfile | 4 ++-- .../ubuntu-18.04-devel-jupyter.Dockerfile | 16 ++++++------- ...18.04-devel-mpi-horovod-jupyter.Dockerfile | 16 ++++++------- .../ubuntu-18.04-devel-mpi-horovod.Dockerfile | 10 ++++---- ....04-devel-mpich-horovod-jupyter.Dockerfile | 16 ++++++------- ...buntu-18.04-devel-mpich-horovod.Dockerfile | 10 ++++---- .../onednn/ubuntu-18.04-devel.Dockerfile | 10 ++++---- .../onednn/ubuntu-18.04-jupyter.Dockerfile | 16 ++++++------- ...buntu-18.04-mpi-horovod-jupyter.Dockerfile | 23 ++++++++++--------- .../ubuntu-18.04-mpi-horovod.Dockerfile | 17 +++++++------- ...ntu-18.04-mpich-horovod-jupyter.Dockerfile | 23 ++++++++++--------- .../ubuntu-18.04-mpich-horovod.Dockerfile | 17 +++++++------- .../onednn/ubuntu-18.04.Dockerfile | 10 ++++---- .../ubuntu-20.04-devel-jupyter.Dockerfile | 16 ++++++------- ...20.04-devel-mpi-horovod-jupyter.Dockerfile | 16 ++++++------- .../ubuntu-20.04-devel-mpi-horovod.Dockerfile | 10 ++++---- ....04-devel-mpich-horovod-jupyter.Dockerfile | 16 ++++++------- ...buntu-20.04-devel-mpich-horovod.Dockerfile | 10 ++++---- .../onednn/ubuntu-20.04-devel.Dockerfile | 10 ++++---- .../onednn/ubuntu-20.04-jupyter.Dockerfile | 16 ++++++------- ...buntu-20.04-mpi-horovod-jupyter.Dockerfile | 22 +++++++++--------- .../ubuntu-20.04-mpi-horovod.Dockerfile | 16 ++++++------- ...ntu-20.04-mpich-horovod-jupyter.Dockerfile | 22 +++++++++--------- .../ubuntu-20.04-mpich-horovod.Dockerfile | 16 ++++++------- .../onednn/ubuntu-20.04.Dockerfile | 10 ++++---- .../centos/horovod-7.partial.Dockerfile | 4 ++-- .../onednn/centos/horovod.partial.Dockerfile | 4 ++-- .../onednn/jupyter.partial.Dockerfile | 6 ++--- .../ubuntu/1604-horovod.partial.Dockerfile | 7 +++--- .../ubuntu/2004-horovod.partial.Dockerfile | 6 ++--- .../onednn/ubuntu/horovod.partial.Dockerfile | 7 +++--- .../onednn/ubuntu/python.partial.Dockerfile | 10 ++++---- .../onednn/ubuntu/python3.partial.Dockerfile | 4 ++-- 60 files changed, 319 insertions(+), 309 deletions(-) diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-7-devel-jupyter.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-7-devel-jupyter.Dockerfile index a4018517584..df6108aedab 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-7-devel-jupyter.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-7-devel-jupyter.Dockerfile @@ -93,9 +93,9 @@ RUN mkdir /bazel && \ COPY bashrc /etc/bash.bashrc RUN chmod a+rwx /etc/bash.bashrc -RUN python3 -m pip install --no-cache-dir jupyter matplotlib +RUN ${PYTHON} -m pip install --no-cache-dir jupyter matplotlib # Pin ipykernel and nbformat; see https://github.com/ipython/ipykernel/issues/422 -RUN python3 -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 +RUN ${PYTHON} -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 RUN jupyter serverextension enable --py jupyter_http_over_ws RUN mkdir -p /tf/ && chmod -R a+rwx /tf/ @@ -103,6 +103,6 @@ RUN mkdir /.local && chmod a+rwx /.local WORKDIR /tf EXPOSE 8888 -RUN python3 -m ipykernel.kernelspec +RUN ${PYTHON} -m ipykernel.kernelspec CMD ["bash", "-c", "source /etc/bash.bashrc && jupyter notebook --notebook-dir=/tf --ip 0.0.0.0 --no-browser --allow-root"] diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-7-devel-mpi-horovod-jupyter.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-7-devel-mpi-horovod-jupyter.Dockerfile index 63a2ba59ba8..10d9c54ff8b 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-7-devel-mpi-horovod-jupyter.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-7-devel-mpi-horovod-jupyter.Dockerfile @@ -125,9 +125,9 @@ RUN test "${CHECKOUT_HOROVOD_SRC}" -eq 1 && git clone --branch "${HOROVOD_BRANCH COPY bashrc /etc/bash.bashrc RUN chmod a+rwx /etc/bash.bashrc -RUN python3 -m pip install --no-cache-dir jupyter matplotlib +RUN ${PYTHON} -m pip install --no-cache-dir jupyter matplotlib # Pin ipykernel and nbformat; see https://github.com/ipython/ipykernel/issues/422 -RUN python3 -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 +RUN ${PYTHON} -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 RUN jupyter serverextension enable --py jupyter_http_over_ws RUN mkdir -p /tf/ && chmod -R a+rwx /tf/ @@ -135,6 +135,6 @@ RUN mkdir /.local && chmod a+rwx /.local WORKDIR /tf EXPOSE 8888 -RUN python3 -m ipykernel.kernelspec +RUN ${PYTHON} -m ipykernel.kernelspec CMD ["bash", "-c", "source /etc/bash.bashrc && jupyter notebook --notebook-dir=/tf --ip 0.0.0.0 --no-browser --allow-root"] diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-7-devel-mpich-horovod-jupyter.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-7-devel-mpich-horovod-jupyter.Dockerfile index 142c279b547..d10bcbc3f3f 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-7-devel-mpich-horovod-jupyter.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-7-devel-mpich-horovod-jupyter.Dockerfile @@ -124,9 +124,9 @@ RUN test "${CHECKOUT_HOROVOD_SRC}" -eq 1 && git clone --branch "${HOROVOD_BRANCH COPY bashrc /etc/bash.bashrc RUN chmod a+rwx /etc/bash.bashrc -RUN python3 -m pip install --no-cache-dir jupyter matplotlib +RUN ${PYTHON} -m pip install --no-cache-dir jupyter matplotlib # Pin ipykernel and nbformat; see https://github.com/ipython/ipykernel/issues/422 -RUN python3 -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 +RUN ${PYTHON} -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 RUN jupyter serverextension enable --py jupyter_http_over_ws RUN mkdir -p /tf/ && chmod -R a+rwx /tf/ @@ -134,6 +134,6 @@ RUN mkdir /.local && chmod a+rwx /.local WORKDIR /tf EXPOSE 8888 -RUN python3 -m ipykernel.kernelspec +RUN ${PYTHON} -m ipykernel.kernelspec CMD ["bash", "-c", "source /etc/bash.bashrc && jupyter notebook --notebook-dir=/tf --ip 0.0.0.0 --no-browser --allow-root"] diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-7-jupyter.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-7-jupyter.Dockerfile index 7da758e4342..cf6e61e4bc1 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-7-jupyter.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-7-jupyter.Dockerfile @@ -60,9 +60,9 @@ RUN python3 -m pip install --no-cache-dir ${TF_PACKAGE}${TF_PACKAGE_VERSION:+==$ COPY bashrc /etc/bash.bashrc RUN chmod a+rwx /etc/bash.bashrc -RUN python3 -m pip install --no-cache-dir jupyter matplotlib +RUN ${PYTHON} -m pip install --no-cache-dir jupyter matplotlib # Pin ipykernel and nbformat; see https://github.com/ipython/ipykernel/issues/422 -RUN python3 -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 +RUN ${PYTHON} -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 RUN jupyter serverextension enable --py jupyter_http_over_ws RUN mkdir -p /tf/ && chmod -R a+rwx /tf/ @@ -70,6 +70,6 @@ RUN mkdir /.local && chmod a+rwx /.local WORKDIR /tf EXPOSE 8888 -RUN python3 -m ipykernel.kernelspec +RUN ${PYTHON} -m ipykernel.kernelspec CMD ["bash", "-c", "source /etc/bash.bashrc && jupyter notebook --notebook-dir=/tf --ip 0.0.0.0 --no-browser --allow-root"] diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-7-mpi-horovod-jupyter.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-7-mpi-horovod-jupyter.Dockerfile index deaadb1ea76..77b46fbc4bf 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-7-mpi-horovod-jupyter.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-7-mpi-horovod-jupyter.Dockerfile @@ -88,7 +88,7 @@ RUN cat /etc/ssh/sshd_config | grep -v StrictHostKeyChecking > /etc/ssh/sshd_con ARG HOROVOD_WITHOUT_PYTORCH=1 ARG HOROVOD_WITHOUT_MXNET=1 ARG HOROVOD_WITH_TENSORFLOW=1 -ARG HOROVOD_VERSION= +ARG HOROVOD_VERSION=v0.21.1 ENV LC_ALL=en_US.UTF-8 ENV LC_CTYPE=en_US.UTF-8 @@ -99,7 +99,7 @@ RUN yum update -y && \ devtoolset-8 \ devtoolset-8-make \ llvm-toolset-7-cmake \ - python3-devel \ + ${PYTHON}-devel \ sclo-git25 && \ yum clean all @@ -110,9 +110,9 @@ RUN ${PYTHON} -m pip install git+https://github.com/horovod/horovod.git@${HOROVO COPY bashrc /etc/bash.bashrc RUN chmod a+rwx /etc/bash.bashrc -RUN python3 -m pip install --no-cache-dir jupyter matplotlib +RUN ${PYTHON} -m pip install --no-cache-dir jupyter matplotlib # Pin ipykernel and nbformat; see https://github.com/ipython/ipykernel/issues/422 -RUN python3 -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 +RUN ${PYTHON} -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 RUN jupyter serverextension enable --py jupyter_http_over_ws RUN mkdir -p /tf/ && chmod -R a+rwx /tf/ @@ -120,6 +120,6 @@ RUN mkdir /.local && chmod a+rwx /.local WORKDIR /tf EXPOSE 8888 -RUN python3 -m ipykernel.kernelspec +RUN ${PYTHON} -m ipykernel.kernelspec CMD ["bash", "-c", "source /etc/bash.bashrc && jupyter notebook --notebook-dir=/tf --ip 0.0.0.0 --no-browser --allow-root"] diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-7-mpi-horovod.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-7-mpi-horovod.Dockerfile index a64941baf98..3ebb23d4a0b 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-7-mpi-horovod.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-7-mpi-horovod.Dockerfile @@ -88,7 +88,7 @@ RUN cat /etc/ssh/sshd_config | grep -v StrictHostKeyChecking > /etc/ssh/sshd_con ARG HOROVOD_WITHOUT_PYTORCH=1 ARG HOROVOD_WITHOUT_MXNET=1 ARG HOROVOD_WITH_TENSORFLOW=1 -ARG HOROVOD_VERSION= +ARG HOROVOD_VERSION=v0.21.1 ENV LC_ALL=en_US.UTF-8 ENV LC_CTYPE=en_US.UTF-8 @@ -99,7 +99,7 @@ RUN yum update -y && \ devtoolset-8 \ devtoolset-8-make \ llvm-toolset-7-cmake \ - python3-devel \ + ${PYTHON}-devel \ sclo-git25 && \ yum clean all diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-7-mpich-horovod-jupyter.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-7-mpich-horovod-jupyter.Dockerfile index 431922537e2..6acff148034 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-7-mpich-horovod-jupyter.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-7-mpich-horovod-jupyter.Dockerfile @@ -87,7 +87,7 @@ RUN cat /etc/ssh/sshd_config | grep -v StrictHostKeyChecking > /etc/ssh/sshd_con ARG HOROVOD_WITHOUT_PYTORCH=1 ARG HOROVOD_WITHOUT_MXNET=1 ARG HOROVOD_WITH_TENSORFLOW=1 -ARG HOROVOD_VERSION= +ARG HOROVOD_VERSION=v0.21.1 ENV LC_ALL=en_US.UTF-8 ENV LC_CTYPE=en_US.UTF-8 @@ -98,7 +98,7 @@ RUN yum update -y && \ devtoolset-8 \ devtoolset-8-make \ llvm-toolset-7-cmake \ - python3-devel \ + ${PYTHON}-devel \ sclo-git25 && \ yum clean all @@ -109,9 +109,9 @@ RUN ${PYTHON} -m pip install git+https://github.com/horovod/horovod.git@${HOROVO COPY bashrc /etc/bash.bashrc RUN chmod a+rwx /etc/bash.bashrc -RUN python3 -m pip install --no-cache-dir jupyter matplotlib +RUN ${PYTHON} -m pip install --no-cache-dir jupyter matplotlib # Pin ipykernel and nbformat; see https://github.com/ipython/ipykernel/issues/422 -RUN python3 -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 +RUN ${PYTHON} -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 RUN jupyter serverextension enable --py jupyter_http_over_ws RUN mkdir -p /tf/ && chmod -R a+rwx /tf/ @@ -119,6 +119,6 @@ RUN mkdir /.local && chmod a+rwx /.local WORKDIR /tf EXPOSE 8888 -RUN python3 -m ipykernel.kernelspec +RUN ${PYTHON} -m ipykernel.kernelspec CMD ["bash", "-c", "source /etc/bash.bashrc && jupyter notebook --notebook-dir=/tf --ip 0.0.0.0 --no-browser --allow-root"] diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-7-mpich-horovod.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-7-mpich-horovod.Dockerfile index e43bc8cafb0..b21c3178e9e 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-7-mpich-horovod.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-7-mpich-horovod.Dockerfile @@ -87,7 +87,7 @@ RUN cat /etc/ssh/sshd_config | grep -v StrictHostKeyChecking > /etc/ssh/sshd_con ARG HOROVOD_WITHOUT_PYTORCH=1 ARG HOROVOD_WITHOUT_MXNET=1 ARG HOROVOD_WITH_TENSORFLOW=1 -ARG HOROVOD_VERSION= +ARG HOROVOD_VERSION=v0.21.1 ENV LC_ALL=en_US.UTF-8 ENV LC_CTYPE=en_US.UTF-8 @@ -98,7 +98,7 @@ RUN yum update -y && \ devtoolset-8 \ devtoolset-8-make \ llvm-toolset-7-cmake \ - python3-devel \ + ${PYTHON}-devel \ sclo-git25 && \ yum clean all diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-8-devel-jupyter.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-8-devel-jupyter.Dockerfile index 3d37a3b56d2..fed78cc2d77 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-8-devel-jupyter.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-8-devel-jupyter.Dockerfile @@ -93,9 +93,9 @@ RUN mkdir /bazel && \ COPY bashrc /etc/bash.bashrc RUN chmod a+rwx /etc/bash.bashrc -RUN python3 -m pip install --no-cache-dir jupyter matplotlib +RUN ${PYTHON} -m pip install --no-cache-dir jupyter matplotlib # Pin ipykernel and nbformat; see https://github.com/ipython/ipykernel/issues/422 -RUN python3 -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 +RUN ${PYTHON} -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 RUN jupyter serverextension enable --py jupyter_http_over_ws RUN mkdir -p /tf/ && chmod -R a+rwx /tf/ @@ -103,6 +103,6 @@ RUN mkdir /.local && chmod a+rwx /.local WORKDIR /tf EXPOSE 8888 -RUN python3 -m ipykernel.kernelspec +RUN ${PYTHON} -m ipykernel.kernelspec CMD ["bash", "-c", "source /etc/bash.bashrc && jupyter notebook --notebook-dir=/tf --ip 0.0.0.0 --no-browser --allow-root"] diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-8-devel-mpi-horovod-jupyter.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-8-devel-mpi-horovod-jupyter.Dockerfile index 136ccf0ea6b..eb61e7cf3b4 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-8-devel-mpi-horovod-jupyter.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-8-devel-mpi-horovod-jupyter.Dockerfile @@ -125,9 +125,9 @@ RUN test "${CHECKOUT_HOROVOD_SRC}" -eq 1 && git clone --branch "${HOROVOD_BRANCH COPY bashrc /etc/bash.bashrc RUN chmod a+rwx /etc/bash.bashrc -RUN python3 -m pip install --no-cache-dir jupyter matplotlib +RUN ${PYTHON} -m pip install --no-cache-dir jupyter matplotlib # Pin ipykernel and nbformat; see https://github.com/ipython/ipykernel/issues/422 -RUN python3 -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 +RUN ${PYTHON} -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 RUN jupyter serverextension enable --py jupyter_http_over_ws RUN mkdir -p /tf/ && chmod -R a+rwx /tf/ @@ -135,6 +135,6 @@ RUN mkdir /.local && chmod a+rwx /.local WORKDIR /tf EXPOSE 8888 -RUN python3 -m ipykernel.kernelspec +RUN ${PYTHON} -m ipykernel.kernelspec CMD ["bash", "-c", "source /etc/bash.bashrc && jupyter notebook --notebook-dir=/tf --ip 0.0.0.0 --no-browser --allow-root"] diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-8-devel-mpich-horovod-jupyter.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-8-devel-mpich-horovod-jupyter.Dockerfile index 9a40e0648e8..8ffc7a36f3e 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-8-devel-mpich-horovod-jupyter.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-8-devel-mpich-horovod-jupyter.Dockerfile @@ -124,9 +124,9 @@ RUN test "${CHECKOUT_HOROVOD_SRC}" -eq 1 && git clone --branch "${HOROVOD_BRANCH COPY bashrc /etc/bash.bashrc RUN chmod a+rwx /etc/bash.bashrc -RUN python3 -m pip install --no-cache-dir jupyter matplotlib +RUN ${PYTHON} -m pip install --no-cache-dir jupyter matplotlib # Pin ipykernel and nbformat; see https://github.com/ipython/ipykernel/issues/422 -RUN python3 -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 +RUN ${PYTHON} -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 RUN jupyter serverextension enable --py jupyter_http_over_ws RUN mkdir -p /tf/ && chmod -R a+rwx /tf/ @@ -134,6 +134,6 @@ RUN mkdir /.local && chmod a+rwx /.local WORKDIR /tf EXPOSE 8888 -RUN python3 -m ipykernel.kernelspec +RUN ${PYTHON} -m ipykernel.kernelspec CMD ["bash", "-c", "source /etc/bash.bashrc && jupyter notebook --notebook-dir=/tf --ip 0.0.0.0 --no-browser --allow-root"] diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-8-jupyter.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-8-jupyter.Dockerfile index 8e64c7eb2bf..830547cafdc 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-8-jupyter.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-8-jupyter.Dockerfile @@ -57,9 +57,9 @@ RUN python3 -m pip install --no-cache-dir ${TF_PACKAGE}${TF_PACKAGE_VERSION:+==$ COPY bashrc /etc/bash.bashrc RUN chmod a+rwx /etc/bash.bashrc -RUN python3 -m pip install --no-cache-dir jupyter matplotlib +RUN ${PYTHON} -m pip install --no-cache-dir jupyter matplotlib # Pin ipykernel and nbformat; see https://github.com/ipython/ipykernel/issues/422 -RUN python3 -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 +RUN ${PYTHON} -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 RUN jupyter serverextension enable --py jupyter_http_over_ws RUN mkdir -p /tf/ && chmod -R a+rwx /tf/ @@ -67,6 +67,6 @@ RUN mkdir /.local && chmod a+rwx /.local WORKDIR /tf EXPOSE 8888 -RUN python3 -m ipykernel.kernelspec +RUN ${PYTHON} -m ipykernel.kernelspec CMD ["bash", "-c", "source /etc/bash.bashrc && jupyter notebook --notebook-dir=/tf --ip 0.0.0.0 --no-browser --allow-root"] diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-8-mpi-horovod-jupyter.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-8-mpi-horovod-jupyter.Dockerfile index 5ba6a1be458..3f948a540cc 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-8-mpi-horovod-jupyter.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-8-mpi-horovod-jupyter.Dockerfile @@ -85,7 +85,7 @@ RUN cat /etc/ssh/sshd_config | grep -v StrictHostKeyChecking > /etc/ssh/sshd_con ARG HOROVOD_WITHOUT_PYTORCH=1 ARG HOROVOD_WITHOUT_MXNET=1 ARG HOROVOD_WITH_TENSORFLOW=1 -ARG HOROVOD_VERSION=0.21.0 +ARG HOROVOD_VERSION=v0.21.1 RUN yum update -y && yum install -y \ cmake \ @@ -93,7 +93,7 @@ RUN yum update -y && yum install -y \ gcc-c++ \ git \ make \ - python36-devel && \ + ${PYTHON}-devel && \ yum clean all RUN ${PYTHON} -m pip install git+https://github.com/horovod/horovod.git@${HOROVOD_VERSION} @@ -101,9 +101,9 @@ RUN ${PYTHON} -m pip install git+https://github.com/horovod/horovod.git@${HOROVO COPY bashrc /etc/bash.bashrc RUN chmod a+rwx /etc/bash.bashrc -RUN python3 -m pip install --no-cache-dir jupyter matplotlib +RUN ${PYTHON} -m pip install --no-cache-dir jupyter matplotlib # Pin ipykernel and nbformat; see https://github.com/ipython/ipykernel/issues/422 -RUN python3 -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 +RUN ${PYTHON} -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 RUN jupyter serverextension enable --py jupyter_http_over_ws RUN mkdir -p /tf/ && chmod -R a+rwx /tf/ @@ -111,6 +111,6 @@ RUN mkdir /.local && chmod a+rwx /.local WORKDIR /tf EXPOSE 8888 -RUN python3 -m ipykernel.kernelspec +RUN ${PYTHON} -m ipykernel.kernelspec CMD ["bash", "-c", "source /etc/bash.bashrc && jupyter notebook --notebook-dir=/tf --ip 0.0.0.0 --no-browser --allow-root"] diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-8-mpi-horovod.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-8-mpi-horovod.Dockerfile index 5288e2eac84..3bdb5c67364 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-8-mpi-horovod.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-8-mpi-horovod.Dockerfile @@ -85,7 +85,7 @@ RUN cat /etc/ssh/sshd_config | grep -v StrictHostKeyChecking > /etc/ssh/sshd_con ARG HOROVOD_WITHOUT_PYTORCH=1 ARG HOROVOD_WITHOUT_MXNET=1 ARG HOROVOD_WITH_TENSORFLOW=1 -ARG HOROVOD_VERSION=0.21.0 +ARG HOROVOD_VERSION=v0.21.1 RUN yum update -y && yum install -y \ cmake \ @@ -93,7 +93,7 @@ RUN yum update -y && yum install -y \ gcc-c++ \ git \ make \ - python36-devel && \ + ${PYTHON}-devel && \ yum clean all RUN ${PYTHON} -m pip install git+https://github.com/horovod/horovod.git@${HOROVOD_VERSION} diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-8-mpich-horovod-jupyter.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-8-mpich-horovod-jupyter.Dockerfile index eeae8c8a0ad..3b9b3e4d729 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-8-mpich-horovod-jupyter.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-8-mpich-horovod-jupyter.Dockerfile @@ -84,7 +84,7 @@ RUN cat /etc/ssh/sshd_config | grep -v StrictHostKeyChecking > /etc/ssh/sshd_con ARG HOROVOD_WITHOUT_PYTORCH=1 ARG HOROVOD_WITHOUT_MXNET=1 ARG HOROVOD_WITH_TENSORFLOW=1 -ARG HOROVOD_VERSION=0.21.0 +ARG HOROVOD_VERSION=v0.21.1 RUN yum update -y && yum install -y \ cmake \ @@ -92,7 +92,7 @@ RUN yum update -y && yum install -y \ gcc-c++ \ git \ make \ - python36-devel && \ + ${PYTHON}-devel && \ yum clean all RUN ${PYTHON} -m pip install git+https://github.com/horovod/horovod.git@${HOROVOD_VERSION} @@ -100,9 +100,9 @@ RUN ${PYTHON} -m pip install git+https://github.com/horovod/horovod.git@${HOROVO COPY bashrc /etc/bash.bashrc RUN chmod a+rwx /etc/bash.bashrc -RUN python3 -m pip install --no-cache-dir jupyter matplotlib +RUN ${PYTHON} -m pip install --no-cache-dir jupyter matplotlib # Pin ipykernel and nbformat; see https://github.com/ipython/ipykernel/issues/422 -RUN python3 -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 +RUN ${PYTHON} -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 RUN jupyter serverextension enable --py jupyter_http_over_ws RUN mkdir -p /tf/ && chmod -R a+rwx /tf/ @@ -110,6 +110,6 @@ RUN mkdir /.local && chmod a+rwx /.local WORKDIR /tf EXPOSE 8888 -RUN python3 -m ipykernel.kernelspec +RUN ${PYTHON} -m ipykernel.kernelspec CMD ["bash", "-c", "source /etc/bash.bashrc && jupyter notebook --notebook-dir=/tf --ip 0.0.0.0 --no-browser --allow-root"] diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-8-mpich-horovod.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-8-mpich-horovod.Dockerfile index 035bb5fd6cd..be473cd0491 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-8-mpich-horovod.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/centos-8-mpich-horovod.Dockerfile @@ -84,7 +84,7 @@ RUN cat /etc/ssh/sshd_config | grep -v StrictHostKeyChecking > /etc/ssh/sshd_con ARG HOROVOD_WITHOUT_PYTORCH=1 ARG HOROVOD_WITHOUT_MXNET=1 ARG HOROVOD_WITH_TENSORFLOW=1 -ARG HOROVOD_VERSION=0.21.0 +ARG HOROVOD_VERSION=v0.21.1 RUN yum update -y && yum install -y \ cmake \ @@ -92,7 +92,7 @@ RUN yum update -y && yum install -y \ gcc-c++ \ git \ make \ - python36-devel && \ + ${PYTHON}-devel && \ yum clean all RUN ${PYTHON} -m pip install git+https://github.com/horovod/horovod.git@${HOROVOD_VERSION} diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-devel-jupyter.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-devel-jupyter.Dockerfile index 3b7a8ba424d..1e7507261e9 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-devel-jupyter.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-devel-jupyter.Dockerfile @@ -65,11 +65,11 @@ RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ RUN add-apt-repository ppa:deadsnakes/ppa -RUN apt-get update && \ - apt-get install -y --no-install-recommends --fix-missing \ +RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ ${PYTHON} RUN curl -fSsL https://bootstrap.pypa.io/get-pip.py | ${PYTHON} + RUN ${PYTHON} -m pip --no-cache-dir install --upgrade \ pip \ setuptools @@ -94,9 +94,9 @@ RUN mkdir /bazel && \ COPY bashrc /etc/bash.bashrc RUN chmod a+rwx /etc/bash.bashrc -RUN python3 -m pip install --no-cache-dir jupyter matplotlib +RUN ${PYTHON} -m pip install --no-cache-dir jupyter matplotlib # Pin ipykernel and nbformat; see https://github.com/ipython/ipykernel/issues/422 -RUN python3 -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 +RUN ${PYTHON} -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 RUN jupyter serverextension enable --py jupyter_http_over_ws RUN mkdir -p /tf/ && chmod -R a+rwx /tf/ @@ -104,6 +104,6 @@ RUN mkdir /.local && chmod a+rwx /.local WORKDIR /tf EXPOSE 8888 -RUN python3 -m ipykernel.kernelspec +RUN ${PYTHON} -m ipykernel.kernelspec CMD ["bash", "-c", "source /etc/bash.bashrc && jupyter notebook --notebook-dir=/tf --ip 0.0.0.0 --no-browser --allow-root"] diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-devel-mpi-horovod-jupyter.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-devel-mpi-horovod-jupyter.Dockerfile index c3180589d13..957fcee8a77 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-devel-mpi-horovod-jupyter.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-devel-mpi-horovod-jupyter.Dockerfile @@ -65,11 +65,11 @@ RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ RUN add-apt-repository ppa:deadsnakes/ppa -RUN apt-get update && \ - apt-get install -y --no-install-recommends --fix-missing \ +RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ ${PYTHON} RUN curl -fSsL https://bootstrap.pypa.io/get-pip.py | ${PYTHON} + RUN ${PYTHON} -m pip --no-cache-dir install --upgrade \ pip \ setuptools @@ -128,9 +128,9 @@ RUN test "${CHECKOUT_HOROVOD_SRC}" -eq 1 && git clone --branch "${HOROVOD_BRANCH COPY bashrc /etc/bash.bashrc RUN chmod a+rwx /etc/bash.bashrc -RUN python3 -m pip install --no-cache-dir jupyter matplotlib +RUN ${PYTHON} -m pip install --no-cache-dir jupyter matplotlib # Pin ipykernel and nbformat; see https://github.com/ipython/ipykernel/issues/422 -RUN python3 -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 +RUN ${PYTHON} -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 RUN jupyter serverextension enable --py jupyter_http_over_ws RUN mkdir -p /tf/ && chmod -R a+rwx /tf/ @@ -138,6 +138,6 @@ RUN mkdir /.local && chmod a+rwx /.local WORKDIR /tf EXPOSE 8888 -RUN python3 -m ipykernel.kernelspec +RUN ${PYTHON} -m ipykernel.kernelspec CMD ["bash", "-c", "source /etc/bash.bashrc && jupyter notebook --notebook-dir=/tf --ip 0.0.0.0 --no-browser --allow-root"] diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-devel-mpi-horovod.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-devel-mpi-horovod.Dockerfile index 72cd2d8f300..8db14e4247f 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-devel-mpi-horovod.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-devel-mpi-horovod.Dockerfile @@ -65,11 +65,11 @@ RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ RUN add-apt-repository ppa:deadsnakes/ppa -RUN apt-get update && \ - apt-get install -y --no-install-recommends --fix-missing \ +RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ ${PYTHON} RUN curl -fSsL https://bootstrap.pypa.io/get-pip.py | ${PYTHON} + RUN ${PYTHON} -m pip --no-cache-dir install --upgrade \ pip \ setuptools diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-devel-mpich-horovod-jupyter.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-devel-mpich-horovod-jupyter.Dockerfile index beff013a084..4d93eb5f1df 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-devel-mpich-horovod-jupyter.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-devel-mpich-horovod-jupyter.Dockerfile @@ -65,11 +65,11 @@ RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ RUN add-apt-repository ppa:deadsnakes/ppa -RUN apt-get update && \ - apt-get install -y --no-install-recommends --fix-missing \ +RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ ${PYTHON} RUN curl -fSsL https://bootstrap.pypa.io/get-pip.py | ${PYTHON} + RUN ${PYTHON} -m pip --no-cache-dir install --upgrade \ pip \ setuptools @@ -128,9 +128,9 @@ RUN test "${CHECKOUT_HOROVOD_SRC}" -eq 1 && git clone --branch "${HOROVOD_BRANCH COPY bashrc /etc/bash.bashrc RUN chmod a+rwx /etc/bash.bashrc -RUN python3 -m pip install --no-cache-dir jupyter matplotlib +RUN ${PYTHON} -m pip install --no-cache-dir jupyter matplotlib # Pin ipykernel and nbformat; see https://github.com/ipython/ipykernel/issues/422 -RUN python3 -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 +RUN ${PYTHON} -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 RUN jupyter serverextension enable --py jupyter_http_over_ws RUN mkdir -p /tf/ && chmod -R a+rwx /tf/ @@ -138,6 +138,6 @@ RUN mkdir /.local && chmod a+rwx /.local WORKDIR /tf EXPOSE 8888 -RUN python3 -m ipykernel.kernelspec +RUN ${PYTHON} -m ipykernel.kernelspec CMD ["bash", "-c", "source /etc/bash.bashrc && jupyter notebook --notebook-dir=/tf --ip 0.0.0.0 --no-browser --allow-root"] diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-devel-mpich-horovod.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-devel-mpich-horovod.Dockerfile index ef50f484353..aa8b1c8859c 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-devel-mpich-horovod.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-devel-mpich-horovod.Dockerfile @@ -65,11 +65,11 @@ RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ RUN add-apt-repository ppa:deadsnakes/ppa -RUN apt-get update && \ - apt-get install -y --no-install-recommends --fix-missing \ +RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ ${PYTHON} RUN curl -fSsL https://bootstrap.pypa.io/get-pip.py | ${PYTHON} + RUN ${PYTHON} -m pip --no-cache-dir install --upgrade \ pip \ setuptools diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-devel.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-devel.Dockerfile index 83a39184309..76fa5052c8e 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-devel.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-devel.Dockerfile @@ -65,11 +65,11 @@ RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ RUN add-apt-repository ppa:deadsnakes/ppa -RUN apt-get update && \ - apt-get install -y --no-install-recommends --fix-missing \ +RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ ${PYTHON} RUN curl -fSsL https://bootstrap.pypa.io/get-pip.py | ${PYTHON} + RUN ${PYTHON} -m pip --no-cache-dir install --upgrade \ pip \ setuptools diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-jupyter.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-jupyter.Dockerfile index 94da458f45c..e5dcde01b86 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-jupyter.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-jupyter.Dockerfile @@ -33,11 +33,11 @@ RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ RUN add-apt-repository ppa:deadsnakes/ppa -RUN apt-get update && \ - apt-get install -y --no-install-recommends --fix-missing \ +RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ ${PYTHON} RUN curl -fSsL https://bootstrap.pypa.io/get-pip.py | ${PYTHON} + RUN ${PYTHON} -m pip --no-cache-dir install --upgrade \ pip \ setuptools @@ -62,9 +62,9 @@ RUN python3 -m pip install --no-cache-dir ${TF_PACKAGE}${TF_PACKAGE_VERSION:+==$ COPY bashrc /etc/bash.bashrc RUN chmod a+rwx /etc/bash.bashrc -RUN python3 -m pip install --no-cache-dir jupyter matplotlib +RUN ${PYTHON} -m pip install --no-cache-dir jupyter matplotlib # Pin ipykernel and nbformat; see https://github.com/ipython/ipykernel/issues/422 -RUN python3 -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 +RUN ${PYTHON} -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 RUN jupyter serverextension enable --py jupyter_http_over_ws RUN mkdir -p /tf/ && chmod -R a+rwx /tf/ @@ -72,6 +72,6 @@ RUN mkdir /.local && chmod a+rwx /.local WORKDIR /tf EXPOSE 8888 -RUN python3 -m ipykernel.kernelspec +RUN ${PYTHON} -m ipykernel.kernelspec CMD ["bash", "-c", "source /etc/bash.bashrc && jupyter notebook --notebook-dir=/tf --ip 0.0.0.0 --no-browser --allow-root"] diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-mpi-horovod-jupyter.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-mpi-horovod-jupyter.Dockerfile index 1d202782ec1..a071f10abaa 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-mpi-horovod-jupyter.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-mpi-horovod-jupyter.Dockerfile @@ -33,11 +33,11 @@ RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ RUN add-apt-repository ppa:deadsnakes/ppa -RUN apt-get update && \ - apt-get install -y --no-install-recommends --fix-missing \ +RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ ${PYTHON} RUN curl -fSsL https://bootstrap.pypa.io/get-pip.py | ${PYTHON} + RUN ${PYTHON} -m pip --no-cache-dir install --upgrade \ pip \ setuptools @@ -92,7 +92,7 @@ RUN cat /etc/ssh/ssh_config | grep -v StrictHostKeyChecking > /etc/ssh/ssh_confi ARG HOROVOD_WITHOUT_PYTORCH=1 ARG HOROVOD_WITHOUT_MXNET=1 ARG HOROVOD_WITH_TENSORFLOW=1 -ARG HOROVOD_VERSION= +ARG HOROVOD_VERSION=v0.21.1 RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ software-properties-common @@ -107,19 +107,20 @@ RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ cmake \ g++-8 \ gcc-8 \ - python3-dev + git \ + ${PYTHON}-dev RUN update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-5 500 --slave /usr/bin/g++ g++ /usr/bin/g++-5 && \ update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-8 800 --slave /usr/bin/g++ g++ /usr/bin/g++-8 -RUN python3 -m pip install --no-cache-dir horovod${HOROVOD_VERSION:+==${HOROVOD_VERSION}} +RUN ${PYTHON} -m pip install git+https://github.com/horovod/horovod.git@${HOROVOD_VERSION} COPY bashrc /etc/bash.bashrc RUN chmod a+rwx /etc/bash.bashrc -RUN python3 -m pip install --no-cache-dir jupyter matplotlib +RUN ${PYTHON} -m pip install --no-cache-dir jupyter matplotlib # Pin ipykernel and nbformat; see https://github.com/ipython/ipykernel/issues/422 -RUN python3 -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 +RUN ${PYTHON} -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 RUN jupyter serverextension enable --py jupyter_http_over_ws RUN mkdir -p /tf/ && chmod -R a+rwx /tf/ @@ -127,6 +128,6 @@ RUN mkdir /.local && chmod a+rwx /.local WORKDIR /tf EXPOSE 8888 -RUN python3 -m ipykernel.kernelspec +RUN ${PYTHON} -m ipykernel.kernelspec CMD ["bash", "-c", "source /etc/bash.bashrc && jupyter notebook --notebook-dir=/tf --ip 0.0.0.0 --no-browser --allow-root"] diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-mpi-horovod.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-mpi-horovod.Dockerfile index 54979dbad77..a60923d87ee 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-mpi-horovod.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-mpi-horovod.Dockerfile @@ -33,11 +33,11 @@ RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ RUN add-apt-repository ppa:deadsnakes/ppa -RUN apt-get update && \ - apt-get install -y --no-install-recommends --fix-missing \ +RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ ${PYTHON} RUN curl -fSsL https://bootstrap.pypa.io/get-pip.py | ${PYTHON} + RUN ${PYTHON} -m pip --no-cache-dir install --upgrade \ pip \ setuptools @@ -92,7 +92,7 @@ RUN cat /etc/ssh/ssh_config | grep -v StrictHostKeyChecking > /etc/ssh/ssh_confi ARG HOROVOD_WITHOUT_PYTORCH=1 ARG HOROVOD_WITHOUT_MXNET=1 ARG HOROVOD_WITH_TENSORFLOW=1 -ARG HOROVOD_VERSION= +ARG HOROVOD_VERSION=v0.21.1 RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ software-properties-common @@ -107,12 +107,13 @@ RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ cmake \ g++-8 \ gcc-8 \ - python3-dev + git \ + ${PYTHON}-dev RUN update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-5 500 --slave /usr/bin/g++ g++ /usr/bin/g++-5 && \ update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-8 800 --slave /usr/bin/g++ g++ /usr/bin/g++-8 -RUN python3 -m pip install --no-cache-dir horovod${HOROVOD_VERSION:+==${HOROVOD_VERSION}} +RUN ${PYTHON} -m pip install git+https://github.com/horovod/horovod.git@${HOROVOD_VERSION} COPY bashrc /etc/bash.bashrc RUN chmod a+rwx /etc/bash.bashrc diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-mpich-horovod-jupyter.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-mpich-horovod-jupyter.Dockerfile index 50a2e09ebd9..9a3516d6eac 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-mpich-horovod-jupyter.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-mpich-horovod-jupyter.Dockerfile @@ -33,11 +33,11 @@ RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ RUN add-apt-repository ppa:deadsnakes/ppa -RUN apt-get update && \ - apt-get install -y --no-install-recommends --fix-missing \ +RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ ${PYTHON} RUN curl -fSsL https://bootstrap.pypa.io/get-pip.py | ${PYTHON} + RUN ${PYTHON} -m pip --no-cache-dir install --upgrade \ pip \ setuptools @@ -92,7 +92,7 @@ RUN cat /etc/ssh/ssh_config | grep -v StrictHostKeyChecking > /etc/ssh/ssh_confi ARG HOROVOD_WITHOUT_PYTORCH=1 ARG HOROVOD_WITHOUT_MXNET=1 ARG HOROVOD_WITH_TENSORFLOW=1 -ARG HOROVOD_VERSION= +ARG HOROVOD_VERSION=v0.21.1 RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ software-properties-common @@ -107,19 +107,20 @@ RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ cmake \ g++-8 \ gcc-8 \ - python3-dev + git \ + ${PYTHON}-dev RUN update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-5 500 --slave /usr/bin/g++ g++ /usr/bin/g++-5 && \ update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-8 800 --slave /usr/bin/g++ g++ /usr/bin/g++-8 -RUN python3 -m pip install --no-cache-dir horovod${HOROVOD_VERSION:+==${HOROVOD_VERSION}} +RUN ${PYTHON} -m pip install git+https://github.com/horovod/horovod.git@${HOROVOD_VERSION} COPY bashrc /etc/bash.bashrc RUN chmod a+rwx /etc/bash.bashrc -RUN python3 -m pip install --no-cache-dir jupyter matplotlib +RUN ${PYTHON} -m pip install --no-cache-dir jupyter matplotlib # Pin ipykernel and nbformat; see https://github.com/ipython/ipykernel/issues/422 -RUN python3 -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 +RUN ${PYTHON} -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 RUN jupyter serverextension enable --py jupyter_http_over_ws RUN mkdir -p /tf/ && chmod -R a+rwx /tf/ @@ -127,6 +128,6 @@ RUN mkdir /.local && chmod a+rwx /.local WORKDIR /tf EXPOSE 8888 -RUN python3 -m ipykernel.kernelspec +RUN ${PYTHON} -m ipykernel.kernelspec CMD ["bash", "-c", "source /etc/bash.bashrc && jupyter notebook --notebook-dir=/tf --ip 0.0.0.0 --no-browser --allow-root"] diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-mpich-horovod.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-mpich-horovod.Dockerfile index 433f756e12e..0b8f9162a98 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-mpich-horovod.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04-mpich-horovod.Dockerfile @@ -33,11 +33,11 @@ RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ RUN add-apt-repository ppa:deadsnakes/ppa -RUN apt-get update && \ - apt-get install -y --no-install-recommends --fix-missing \ +RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ ${PYTHON} RUN curl -fSsL https://bootstrap.pypa.io/get-pip.py | ${PYTHON} + RUN ${PYTHON} -m pip --no-cache-dir install --upgrade \ pip \ setuptools @@ -92,7 +92,7 @@ RUN cat /etc/ssh/ssh_config | grep -v StrictHostKeyChecking > /etc/ssh/ssh_confi ARG HOROVOD_WITHOUT_PYTORCH=1 ARG HOROVOD_WITHOUT_MXNET=1 ARG HOROVOD_WITH_TENSORFLOW=1 -ARG HOROVOD_VERSION= +ARG HOROVOD_VERSION=v0.21.1 RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ software-properties-common @@ -107,12 +107,13 @@ RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ cmake \ g++-8 \ gcc-8 \ - python3-dev + git \ + ${PYTHON}-dev RUN update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-5 500 --slave /usr/bin/g++ g++ /usr/bin/g++-5 && \ update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-8 800 --slave /usr/bin/g++ g++ /usr/bin/g++-8 -RUN python3 -m pip install --no-cache-dir horovod${HOROVOD_VERSION:+==${HOROVOD_VERSION}} +RUN ${PYTHON} -m pip install git+https://github.com/horovod/horovod.git@${HOROVOD_VERSION} COPY bashrc /etc/bash.bashrc RUN chmod a+rwx /etc/bash.bashrc diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04.Dockerfile index 684698d1758..2fed940d939 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-16.04.Dockerfile @@ -33,11 +33,11 @@ RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ RUN add-apt-repository ppa:deadsnakes/ppa -RUN apt-get update && \ - apt-get install -y --no-install-recommends --fix-missing \ +RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ ${PYTHON} RUN curl -fSsL https://bootstrap.pypa.io/get-pip.py | ${PYTHON} + RUN ${PYTHON} -m pip --no-cache-dir install --upgrade \ pip \ setuptools diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-devel-jupyter.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-devel-jupyter.Dockerfile index 94782b3428c..4992db22468 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-devel-jupyter.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-devel-jupyter.Dockerfile @@ -57,17 +57,17 @@ RUN test "${CHECKOUT_TF_SRC}" -eq 1 && git clone https://github.com/tensorflow/t # See http://bugs.python.org/issue19846 ENV LANG C.UTF-8 +ARG PYTHON=python3 RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ - python3 \ - python3-pip - -RUN python3 -m pip --no-cache-dir install --upgrade \ + ${PYTHON} \ + ${PYTHON}-pip +RUN ${PYTHON} -m pip --no-cache-dir install --upgrade \ pip \ setuptools # Some TF tools expect a "python" binary -RUN ln -s $(which python3) /usr/local/bin/python +RUN ln -s $(which ${PYTHON}) /usr/local/bin/python RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ curl @@ -83,9 +83,9 @@ RUN mkdir /bazel && \ COPY bashrc /etc/bash.bashrc RUN chmod a+rwx /etc/bash.bashrc -RUN python3 -m pip install --no-cache-dir jupyter matplotlib +RUN ${PYTHON} -m pip install --no-cache-dir jupyter matplotlib # Pin ipykernel and nbformat; see https://github.com/ipython/ipykernel/issues/422 -RUN python3 -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 +RUN ${PYTHON} -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 RUN jupyter serverextension enable --py jupyter_http_over_ws RUN mkdir -p /tf/ && chmod -R a+rwx /tf/ @@ -93,6 +93,6 @@ RUN mkdir /.local && chmod a+rwx /.local WORKDIR /tf EXPOSE 8888 -RUN python3 -m ipykernel.kernelspec +RUN ${PYTHON} -m ipykernel.kernelspec CMD ["bash", "-c", "source /etc/bash.bashrc && jupyter notebook --notebook-dir=/tf --ip 0.0.0.0 --no-browser --allow-root"] diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-devel-mpi-horovod-jupyter.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-devel-mpi-horovod-jupyter.Dockerfile index b5ef63d2516..eeb716664f5 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-devel-mpi-horovod-jupyter.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-devel-mpi-horovod-jupyter.Dockerfile @@ -57,17 +57,17 @@ RUN test "${CHECKOUT_TF_SRC}" -eq 1 && git clone https://github.com/tensorflow/t # See http://bugs.python.org/issue19846 ENV LANG C.UTF-8 +ARG PYTHON=python3 RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ - python3 \ - python3-pip - -RUN python3 -m pip --no-cache-dir install --upgrade \ + ${PYTHON} \ + ${PYTHON}-pip +RUN ${PYTHON} -m pip --no-cache-dir install --upgrade \ pip \ setuptools # Some TF tools expect a "python" binary -RUN ln -s $(which python3) /usr/local/bin/python +RUN ln -s $(which ${PYTHON}) /usr/local/bin/python RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ curl @@ -117,9 +117,9 @@ RUN test "${CHECKOUT_HOROVOD_SRC}" -eq 1 && git clone --branch "${HOROVOD_BRANCH COPY bashrc /etc/bash.bashrc RUN chmod a+rwx /etc/bash.bashrc -RUN python3 -m pip install --no-cache-dir jupyter matplotlib +RUN ${PYTHON} -m pip install --no-cache-dir jupyter matplotlib # Pin ipykernel and nbformat; see https://github.com/ipython/ipykernel/issues/422 -RUN python3 -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 +RUN ${PYTHON} -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 RUN jupyter serverextension enable --py jupyter_http_over_ws RUN mkdir -p /tf/ && chmod -R a+rwx /tf/ @@ -127,6 +127,6 @@ RUN mkdir /.local && chmod a+rwx /.local WORKDIR /tf EXPOSE 8888 -RUN python3 -m ipykernel.kernelspec +RUN ${PYTHON} -m ipykernel.kernelspec CMD ["bash", "-c", "source /etc/bash.bashrc && jupyter notebook --notebook-dir=/tf --ip 0.0.0.0 --no-browser --allow-root"] diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-devel-mpi-horovod.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-devel-mpi-horovod.Dockerfile index d9c3ef676cc..4cc9b316121 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-devel-mpi-horovod.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-devel-mpi-horovod.Dockerfile @@ -57,17 +57,17 @@ RUN test "${CHECKOUT_TF_SRC}" -eq 1 && git clone https://github.com/tensorflow/t # See http://bugs.python.org/issue19846 ENV LANG C.UTF-8 +ARG PYTHON=python3 RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ - python3 \ - python3-pip - -RUN python3 -m pip --no-cache-dir install --upgrade \ + ${PYTHON} \ + ${PYTHON}-pip +RUN ${PYTHON} -m pip --no-cache-dir install --upgrade \ pip \ setuptools # Some TF tools expect a "python" binary -RUN ln -s $(which python3) /usr/local/bin/python +RUN ln -s $(which ${PYTHON}) /usr/local/bin/python RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ curl diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-devel-mpich-horovod-jupyter.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-devel-mpich-horovod-jupyter.Dockerfile index 72e471c5080..fabfaf03448 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-devel-mpich-horovod-jupyter.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-devel-mpich-horovod-jupyter.Dockerfile @@ -57,17 +57,17 @@ RUN test "${CHECKOUT_TF_SRC}" -eq 1 && git clone https://github.com/tensorflow/t # See http://bugs.python.org/issue19846 ENV LANG C.UTF-8 +ARG PYTHON=python3 RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ - python3 \ - python3-pip - -RUN python3 -m pip --no-cache-dir install --upgrade \ + ${PYTHON} \ + ${PYTHON}-pip +RUN ${PYTHON} -m pip --no-cache-dir install --upgrade \ pip \ setuptools # Some TF tools expect a "python" binary -RUN ln -s $(which python3) /usr/local/bin/python +RUN ln -s $(which ${PYTHON}) /usr/local/bin/python RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ curl @@ -113,9 +113,9 @@ RUN test "${CHECKOUT_HOROVOD_SRC}" -eq 1 && git clone --branch "${HOROVOD_BRANCH COPY bashrc /etc/bash.bashrc RUN chmod a+rwx /etc/bash.bashrc -RUN python3 -m pip install --no-cache-dir jupyter matplotlib +RUN ${PYTHON} -m pip install --no-cache-dir jupyter matplotlib # Pin ipykernel and nbformat; see https://github.com/ipython/ipykernel/issues/422 -RUN python3 -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 +RUN ${PYTHON} -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 RUN jupyter serverextension enable --py jupyter_http_over_ws RUN mkdir -p /tf/ && chmod -R a+rwx /tf/ @@ -123,6 +123,6 @@ RUN mkdir /.local && chmod a+rwx /.local WORKDIR /tf EXPOSE 8888 -RUN python3 -m ipykernel.kernelspec +RUN ${PYTHON} -m ipykernel.kernelspec CMD ["bash", "-c", "source /etc/bash.bashrc && jupyter notebook --notebook-dir=/tf --ip 0.0.0.0 --no-browser --allow-root"] diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-devel-mpich-horovod.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-devel-mpich-horovod.Dockerfile index d04cac5c89f..9fd24387f6c 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-devel-mpich-horovod.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-devel-mpich-horovod.Dockerfile @@ -57,17 +57,17 @@ RUN test "${CHECKOUT_TF_SRC}" -eq 1 && git clone https://github.com/tensorflow/t # See http://bugs.python.org/issue19846 ENV LANG C.UTF-8 +ARG PYTHON=python3 RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ - python3 \ - python3-pip - -RUN python3 -m pip --no-cache-dir install --upgrade \ + ${PYTHON} \ + ${PYTHON}-pip +RUN ${PYTHON} -m pip --no-cache-dir install --upgrade \ pip \ setuptools # Some TF tools expect a "python" binary -RUN ln -s $(which python3) /usr/local/bin/python +RUN ln -s $(which ${PYTHON}) /usr/local/bin/python RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ curl diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-devel.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-devel.Dockerfile index cf0da5f1628..995bbc01b5b 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-devel.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-devel.Dockerfile @@ -57,17 +57,17 @@ RUN test "${CHECKOUT_TF_SRC}" -eq 1 && git clone https://github.com/tensorflow/t # See http://bugs.python.org/issue19846 ENV LANG C.UTF-8 +ARG PYTHON=python3 RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ - python3 \ - python3-pip - -RUN python3 -m pip --no-cache-dir install --upgrade \ + ${PYTHON} \ + ${PYTHON}-pip +RUN ${PYTHON} -m pip --no-cache-dir install --upgrade \ pip \ setuptools # Some TF tools expect a "python" binary -RUN ln -s $(which python3) /usr/local/bin/python +RUN ln -s $(which ${PYTHON}) /usr/local/bin/python RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ curl diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-jupyter.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-jupyter.Dockerfile index 61bce40308e..5c6e52c2799 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-jupyter.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-jupyter.Dockerfile @@ -25,17 +25,17 @@ FROM ubuntu:${UBUNTU_VERSION} as base # See http://bugs.python.org/issue19846 ENV LANG C.UTF-8 +ARG PYTHON=python3 RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ - python3 \ - python3-pip - -RUN python3 -m pip --no-cache-dir install --upgrade \ + ${PYTHON} \ + ${PYTHON}-pip +RUN ${PYTHON} -m pip --no-cache-dir install --upgrade \ pip \ setuptools # Some TF tools expect a "python" binary -RUN ln -s $(which python3) /usr/local/bin/python +RUN ln -s $(which ${PYTHON}) /usr/local/bin/python # Options: # tensorflow @@ -51,9 +51,9 @@ RUN python3 -m pip install --no-cache-dir ${TF_PACKAGE}${TF_PACKAGE_VERSION:+==$ COPY bashrc /etc/bash.bashrc RUN chmod a+rwx /etc/bash.bashrc -RUN python3 -m pip install --no-cache-dir jupyter matplotlib +RUN ${PYTHON} -m pip install --no-cache-dir jupyter matplotlib # Pin ipykernel and nbformat; see https://github.com/ipython/ipykernel/issues/422 -RUN python3 -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 +RUN ${PYTHON} -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 RUN jupyter serverextension enable --py jupyter_http_over_ws RUN mkdir -p /tf/ && chmod -R a+rwx /tf/ @@ -61,6 +61,6 @@ RUN mkdir /.local && chmod a+rwx /.local WORKDIR /tf EXPOSE 8888 -RUN python3 -m ipykernel.kernelspec +RUN ${PYTHON} -m ipykernel.kernelspec CMD ["bash", "-c", "source /etc/bash.bashrc && jupyter notebook --notebook-dir=/tf --ip 0.0.0.0 --no-browser --allow-root"] diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-mpi-horovod-jupyter.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-mpi-horovod-jupyter.Dockerfile index a11af9ebf1e..98f3b692fdd 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-mpi-horovod-jupyter.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-mpi-horovod-jupyter.Dockerfile @@ -25,17 +25,17 @@ FROM ubuntu:${UBUNTU_VERSION} as base # See http://bugs.python.org/issue19846 ENV LANG C.UTF-8 +ARG PYTHON=python3 RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ - python3 \ - python3-pip - -RUN python3 -m pip --no-cache-dir install --upgrade \ + ${PYTHON} \ + ${PYTHON}-pip +RUN ${PYTHON} -m pip --no-cache-dir install --upgrade \ pip \ setuptools # Some TF tools expect a "python" binary -RUN ln -s $(which python3) /usr/local/bin/python +RUN ln -s $(which ${PYTHON}) /usr/local/bin/python # Options: # tensorflow @@ -81,26 +81,27 @@ RUN cat /etc/ssh/ssh_config | grep -v StrictHostKeyChecking > /etc/ssh/ssh_confi ARG HOROVOD_WITHOUT_PYTORCH=1 ARG HOROVOD_WITHOUT_MXNET=1 ARG HOROVOD_WITH_TENSORFLOW=1 -ARG HOROVOD_VERSION= +ARG HOROVOD_VERSION=v0.21.1 RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ build-essential \ cmake \ g++-8 \ gcc-8 \ - python3-dev + git \ + ${PYTHON}-dev RUN update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-7 700 --slave /usr/bin/g++ g++ /usr/bin/g++-7 && \ update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-8 800 --slave /usr/bin/g++ g++ /usr/bin/g++-8 -RUN python3 -m pip install --no-cache-dir horovod${HOROVOD_VERSION:+==${HOROVOD_VERSION}} +RUN ${PYTHON} -m pip install git+https://github.com/horovod/horovod.git@${HOROVOD_VERSION} COPY bashrc /etc/bash.bashrc RUN chmod a+rwx /etc/bash.bashrc -RUN python3 -m pip install --no-cache-dir jupyter matplotlib +RUN ${PYTHON} -m pip install --no-cache-dir jupyter matplotlib # Pin ipykernel and nbformat; see https://github.com/ipython/ipykernel/issues/422 -RUN python3 -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 +RUN ${PYTHON} -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 RUN jupyter serverextension enable --py jupyter_http_over_ws RUN mkdir -p /tf/ && chmod -R a+rwx /tf/ @@ -108,6 +109,6 @@ RUN mkdir /.local && chmod a+rwx /.local WORKDIR /tf EXPOSE 8888 -RUN python3 -m ipykernel.kernelspec +RUN ${PYTHON} -m ipykernel.kernelspec CMD ["bash", "-c", "source /etc/bash.bashrc && jupyter notebook --notebook-dir=/tf --ip 0.0.0.0 --no-browser --allow-root"] diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-mpi-horovod.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-mpi-horovod.Dockerfile index 20ec6458ef4..8d97f9ad426 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-mpi-horovod.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-mpi-horovod.Dockerfile @@ -25,17 +25,17 @@ FROM ubuntu:${UBUNTU_VERSION} as base # See http://bugs.python.org/issue19846 ENV LANG C.UTF-8 +ARG PYTHON=python3 RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ - python3 \ - python3-pip - -RUN python3 -m pip --no-cache-dir install --upgrade \ + ${PYTHON} \ + ${PYTHON}-pip +RUN ${PYTHON} -m pip --no-cache-dir install --upgrade \ pip \ setuptools # Some TF tools expect a "python" binary -RUN ln -s $(which python3) /usr/local/bin/python +RUN ln -s $(which ${PYTHON}) /usr/local/bin/python # Options: # tensorflow @@ -81,19 +81,20 @@ RUN cat /etc/ssh/ssh_config | grep -v StrictHostKeyChecking > /etc/ssh/ssh_confi ARG HOROVOD_WITHOUT_PYTORCH=1 ARG HOROVOD_WITHOUT_MXNET=1 ARG HOROVOD_WITH_TENSORFLOW=1 -ARG HOROVOD_VERSION= +ARG HOROVOD_VERSION=v0.21.1 RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ build-essential \ cmake \ g++-8 \ gcc-8 \ - python3-dev + git \ + ${PYTHON}-dev RUN update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-7 700 --slave /usr/bin/g++ g++ /usr/bin/g++-7 && \ update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-8 800 --slave /usr/bin/g++ g++ /usr/bin/g++-8 -RUN python3 -m pip install --no-cache-dir horovod${HOROVOD_VERSION:+==${HOROVOD_VERSION}} +RUN ${PYTHON} -m pip install git+https://github.com/horovod/horovod.git@${HOROVOD_VERSION} COPY bashrc /etc/bash.bashrc RUN chmod a+rwx /etc/bash.bashrc diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-mpich-horovod-jupyter.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-mpich-horovod-jupyter.Dockerfile index 162d0a938fb..fbaaaa05de1 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-mpich-horovod-jupyter.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-mpich-horovod-jupyter.Dockerfile @@ -25,17 +25,17 @@ FROM ubuntu:${UBUNTU_VERSION} as base # See http://bugs.python.org/issue19846 ENV LANG C.UTF-8 +ARG PYTHON=python3 RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ - python3 \ - python3-pip - -RUN python3 -m pip --no-cache-dir install --upgrade \ + ${PYTHON} \ + ${PYTHON}-pip +RUN ${PYTHON} -m pip --no-cache-dir install --upgrade \ pip \ setuptools # Some TF tools expect a "python" binary -RUN ln -s $(which python3) /usr/local/bin/python +RUN ln -s $(which ${PYTHON}) /usr/local/bin/python # Options: # tensorflow @@ -77,26 +77,27 @@ RUN cat /etc/ssh/ssh_config | grep -v StrictHostKeyChecking > /etc/ssh/ssh_confi ARG HOROVOD_WITHOUT_PYTORCH=1 ARG HOROVOD_WITHOUT_MXNET=1 ARG HOROVOD_WITH_TENSORFLOW=1 -ARG HOROVOD_VERSION= +ARG HOROVOD_VERSION=v0.21.1 RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ build-essential \ cmake \ g++-8 \ gcc-8 \ - python3-dev + git \ + ${PYTHON}-dev RUN update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-7 700 --slave /usr/bin/g++ g++ /usr/bin/g++-7 && \ update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-8 800 --slave /usr/bin/g++ g++ /usr/bin/g++-8 -RUN python3 -m pip install --no-cache-dir horovod${HOROVOD_VERSION:+==${HOROVOD_VERSION}} +RUN ${PYTHON} -m pip install git+https://github.com/horovod/horovod.git@${HOROVOD_VERSION} COPY bashrc /etc/bash.bashrc RUN chmod a+rwx /etc/bash.bashrc -RUN python3 -m pip install --no-cache-dir jupyter matplotlib +RUN ${PYTHON} -m pip install --no-cache-dir jupyter matplotlib # Pin ipykernel and nbformat; see https://github.com/ipython/ipykernel/issues/422 -RUN python3 -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 +RUN ${PYTHON} -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 RUN jupyter serverextension enable --py jupyter_http_over_ws RUN mkdir -p /tf/ && chmod -R a+rwx /tf/ @@ -104,6 +105,6 @@ RUN mkdir /.local && chmod a+rwx /.local WORKDIR /tf EXPOSE 8888 -RUN python3 -m ipykernel.kernelspec +RUN ${PYTHON} -m ipykernel.kernelspec CMD ["bash", "-c", "source /etc/bash.bashrc && jupyter notebook --notebook-dir=/tf --ip 0.0.0.0 --no-browser --allow-root"] diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-mpich-horovod.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-mpich-horovod.Dockerfile index c36de1475dd..9a05a697f4f 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-mpich-horovod.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04-mpich-horovod.Dockerfile @@ -25,17 +25,17 @@ FROM ubuntu:${UBUNTU_VERSION} as base # See http://bugs.python.org/issue19846 ENV LANG C.UTF-8 +ARG PYTHON=python3 RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ - python3 \ - python3-pip - -RUN python3 -m pip --no-cache-dir install --upgrade \ + ${PYTHON} \ + ${PYTHON}-pip +RUN ${PYTHON} -m pip --no-cache-dir install --upgrade \ pip \ setuptools # Some TF tools expect a "python" binary -RUN ln -s $(which python3) /usr/local/bin/python +RUN ln -s $(which ${PYTHON}) /usr/local/bin/python # Options: # tensorflow @@ -77,19 +77,20 @@ RUN cat /etc/ssh/ssh_config | grep -v StrictHostKeyChecking > /etc/ssh/ssh_confi ARG HOROVOD_WITHOUT_PYTORCH=1 ARG HOROVOD_WITHOUT_MXNET=1 ARG HOROVOD_WITH_TENSORFLOW=1 -ARG HOROVOD_VERSION= +ARG HOROVOD_VERSION=v0.21.1 RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ build-essential \ cmake \ g++-8 \ gcc-8 \ - python3-dev + git \ + ${PYTHON}-dev RUN update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-7 700 --slave /usr/bin/g++ g++ /usr/bin/g++-7 && \ update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-8 800 --slave /usr/bin/g++ g++ /usr/bin/g++-8 -RUN python3 -m pip install --no-cache-dir horovod${HOROVOD_VERSION:+==${HOROVOD_VERSION}} +RUN ${PYTHON} -m pip install git+https://github.com/horovod/horovod.git@${HOROVOD_VERSION} COPY bashrc /etc/bash.bashrc RUN chmod a+rwx /etc/bash.bashrc diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04.Dockerfile index 9033cae3559..3c113723c47 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-18.04.Dockerfile @@ -25,17 +25,17 @@ FROM ubuntu:${UBUNTU_VERSION} as base # See http://bugs.python.org/issue19846 ENV LANG C.UTF-8 +ARG PYTHON=python3 RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ - python3 \ - python3-pip - -RUN python3 -m pip --no-cache-dir install --upgrade \ + ${PYTHON} \ + ${PYTHON}-pip +RUN ${PYTHON} -m pip --no-cache-dir install --upgrade \ pip \ setuptools # Some TF tools expect a "python" binary -RUN ln -s $(which python3) /usr/local/bin/python +RUN ln -s $(which ${PYTHON}) /usr/local/bin/python # Options: # tensorflow diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-devel-jupyter.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-devel-jupyter.Dockerfile index 94782b3428c..4992db22468 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-devel-jupyter.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-devel-jupyter.Dockerfile @@ -57,17 +57,17 @@ RUN test "${CHECKOUT_TF_SRC}" -eq 1 && git clone https://github.com/tensorflow/t # See http://bugs.python.org/issue19846 ENV LANG C.UTF-8 +ARG PYTHON=python3 RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ - python3 \ - python3-pip - -RUN python3 -m pip --no-cache-dir install --upgrade \ + ${PYTHON} \ + ${PYTHON}-pip +RUN ${PYTHON} -m pip --no-cache-dir install --upgrade \ pip \ setuptools # Some TF tools expect a "python" binary -RUN ln -s $(which python3) /usr/local/bin/python +RUN ln -s $(which ${PYTHON}) /usr/local/bin/python RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ curl @@ -83,9 +83,9 @@ RUN mkdir /bazel && \ COPY bashrc /etc/bash.bashrc RUN chmod a+rwx /etc/bash.bashrc -RUN python3 -m pip install --no-cache-dir jupyter matplotlib +RUN ${PYTHON} -m pip install --no-cache-dir jupyter matplotlib # Pin ipykernel and nbformat; see https://github.com/ipython/ipykernel/issues/422 -RUN python3 -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 +RUN ${PYTHON} -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 RUN jupyter serverextension enable --py jupyter_http_over_ws RUN mkdir -p /tf/ && chmod -R a+rwx /tf/ @@ -93,6 +93,6 @@ RUN mkdir /.local && chmod a+rwx /.local WORKDIR /tf EXPOSE 8888 -RUN python3 -m ipykernel.kernelspec +RUN ${PYTHON} -m ipykernel.kernelspec CMD ["bash", "-c", "source /etc/bash.bashrc && jupyter notebook --notebook-dir=/tf --ip 0.0.0.0 --no-browser --allow-root"] diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-devel-mpi-horovod-jupyter.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-devel-mpi-horovod-jupyter.Dockerfile index b5ef63d2516..eeb716664f5 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-devel-mpi-horovod-jupyter.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-devel-mpi-horovod-jupyter.Dockerfile @@ -57,17 +57,17 @@ RUN test "${CHECKOUT_TF_SRC}" -eq 1 && git clone https://github.com/tensorflow/t # See http://bugs.python.org/issue19846 ENV LANG C.UTF-8 +ARG PYTHON=python3 RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ - python3 \ - python3-pip - -RUN python3 -m pip --no-cache-dir install --upgrade \ + ${PYTHON} \ + ${PYTHON}-pip +RUN ${PYTHON} -m pip --no-cache-dir install --upgrade \ pip \ setuptools # Some TF tools expect a "python" binary -RUN ln -s $(which python3) /usr/local/bin/python +RUN ln -s $(which ${PYTHON}) /usr/local/bin/python RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ curl @@ -117,9 +117,9 @@ RUN test "${CHECKOUT_HOROVOD_SRC}" -eq 1 && git clone --branch "${HOROVOD_BRANCH COPY bashrc /etc/bash.bashrc RUN chmod a+rwx /etc/bash.bashrc -RUN python3 -m pip install --no-cache-dir jupyter matplotlib +RUN ${PYTHON} -m pip install --no-cache-dir jupyter matplotlib # Pin ipykernel and nbformat; see https://github.com/ipython/ipykernel/issues/422 -RUN python3 -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 +RUN ${PYTHON} -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 RUN jupyter serverextension enable --py jupyter_http_over_ws RUN mkdir -p /tf/ && chmod -R a+rwx /tf/ @@ -127,6 +127,6 @@ RUN mkdir /.local && chmod a+rwx /.local WORKDIR /tf EXPOSE 8888 -RUN python3 -m ipykernel.kernelspec +RUN ${PYTHON} -m ipykernel.kernelspec CMD ["bash", "-c", "source /etc/bash.bashrc && jupyter notebook --notebook-dir=/tf --ip 0.0.0.0 --no-browser --allow-root"] diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-devel-mpi-horovod.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-devel-mpi-horovod.Dockerfile index d9c3ef676cc..4cc9b316121 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-devel-mpi-horovod.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-devel-mpi-horovod.Dockerfile @@ -57,17 +57,17 @@ RUN test "${CHECKOUT_TF_SRC}" -eq 1 && git clone https://github.com/tensorflow/t # See http://bugs.python.org/issue19846 ENV LANG C.UTF-8 +ARG PYTHON=python3 RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ - python3 \ - python3-pip - -RUN python3 -m pip --no-cache-dir install --upgrade \ + ${PYTHON} \ + ${PYTHON}-pip +RUN ${PYTHON} -m pip --no-cache-dir install --upgrade \ pip \ setuptools # Some TF tools expect a "python" binary -RUN ln -s $(which python3) /usr/local/bin/python +RUN ln -s $(which ${PYTHON}) /usr/local/bin/python RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ curl diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-devel-mpich-horovod-jupyter.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-devel-mpich-horovod-jupyter.Dockerfile index 72e471c5080..fabfaf03448 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-devel-mpich-horovod-jupyter.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-devel-mpich-horovod-jupyter.Dockerfile @@ -57,17 +57,17 @@ RUN test "${CHECKOUT_TF_SRC}" -eq 1 && git clone https://github.com/tensorflow/t # See http://bugs.python.org/issue19846 ENV LANG C.UTF-8 +ARG PYTHON=python3 RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ - python3 \ - python3-pip - -RUN python3 -m pip --no-cache-dir install --upgrade \ + ${PYTHON} \ + ${PYTHON}-pip +RUN ${PYTHON} -m pip --no-cache-dir install --upgrade \ pip \ setuptools # Some TF tools expect a "python" binary -RUN ln -s $(which python3) /usr/local/bin/python +RUN ln -s $(which ${PYTHON}) /usr/local/bin/python RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ curl @@ -113,9 +113,9 @@ RUN test "${CHECKOUT_HOROVOD_SRC}" -eq 1 && git clone --branch "${HOROVOD_BRANCH COPY bashrc /etc/bash.bashrc RUN chmod a+rwx /etc/bash.bashrc -RUN python3 -m pip install --no-cache-dir jupyter matplotlib +RUN ${PYTHON} -m pip install --no-cache-dir jupyter matplotlib # Pin ipykernel and nbformat; see https://github.com/ipython/ipykernel/issues/422 -RUN python3 -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 +RUN ${PYTHON} -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 RUN jupyter serverextension enable --py jupyter_http_over_ws RUN mkdir -p /tf/ && chmod -R a+rwx /tf/ @@ -123,6 +123,6 @@ RUN mkdir /.local && chmod a+rwx /.local WORKDIR /tf EXPOSE 8888 -RUN python3 -m ipykernel.kernelspec +RUN ${PYTHON} -m ipykernel.kernelspec CMD ["bash", "-c", "source /etc/bash.bashrc && jupyter notebook --notebook-dir=/tf --ip 0.0.0.0 --no-browser --allow-root"] diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-devel-mpich-horovod.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-devel-mpich-horovod.Dockerfile index d04cac5c89f..9fd24387f6c 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-devel-mpich-horovod.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-devel-mpich-horovod.Dockerfile @@ -57,17 +57,17 @@ RUN test "${CHECKOUT_TF_SRC}" -eq 1 && git clone https://github.com/tensorflow/t # See http://bugs.python.org/issue19846 ENV LANG C.UTF-8 +ARG PYTHON=python3 RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ - python3 \ - python3-pip - -RUN python3 -m pip --no-cache-dir install --upgrade \ + ${PYTHON} \ + ${PYTHON}-pip +RUN ${PYTHON} -m pip --no-cache-dir install --upgrade \ pip \ setuptools # Some TF tools expect a "python" binary -RUN ln -s $(which python3) /usr/local/bin/python +RUN ln -s $(which ${PYTHON}) /usr/local/bin/python RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ curl diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-devel.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-devel.Dockerfile index cf0da5f1628..995bbc01b5b 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-devel.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-devel.Dockerfile @@ -57,17 +57,17 @@ RUN test "${CHECKOUT_TF_SRC}" -eq 1 && git clone https://github.com/tensorflow/t # See http://bugs.python.org/issue19846 ENV LANG C.UTF-8 +ARG PYTHON=python3 RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ - python3 \ - python3-pip - -RUN python3 -m pip --no-cache-dir install --upgrade \ + ${PYTHON} \ + ${PYTHON}-pip +RUN ${PYTHON} -m pip --no-cache-dir install --upgrade \ pip \ setuptools # Some TF tools expect a "python" binary -RUN ln -s $(which python3) /usr/local/bin/python +RUN ln -s $(which ${PYTHON}) /usr/local/bin/python RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ curl diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-jupyter.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-jupyter.Dockerfile index 61bce40308e..5c6e52c2799 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-jupyter.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-jupyter.Dockerfile @@ -25,17 +25,17 @@ FROM ubuntu:${UBUNTU_VERSION} as base # See http://bugs.python.org/issue19846 ENV LANG C.UTF-8 +ARG PYTHON=python3 RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ - python3 \ - python3-pip - -RUN python3 -m pip --no-cache-dir install --upgrade \ + ${PYTHON} \ + ${PYTHON}-pip +RUN ${PYTHON} -m pip --no-cache-dir install --upgrade \ pip \ setuptools # Some TF tools expect a "python" binary -RUN ln -s $(which python3) /usr/local/bin/python +RUN ln -s $(which ${PYTHON}) /usr/local/bin/python # Options: # tensorflow @@ -51,9 +51,9 @@ RUN python3 -m pip install --no-cache-dir ${TF_PACKAGE}${TF_PACKAGE_VERSION:+==$ COPY bashrc /etc/bash.bashrc RUN chmod a+rwx /etc/bash.bashrc -RUN python3 -m pip install --no-cache-dir jupyter matplotlib +RUN ${PYTHON} -m pip install --no-cache-dir jupyter matplotlib # Pin ipykernel and nbformat; see https://github.com/ipython/ipykernel/issues/422 -RUN python3 -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 +RUN ${PYTHON} -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 RUN jupyter serverextension enable --py jupyter_http_over_ws RUN mkdir -p /tf/ && chmod -R a+rwx /tf/ @@ -61,6 +61,6 @@ RUN mkdir /.local && chmod a+rwx /.local WORKDIR /tf EXPOSE 8888 -RUN python3 -m ipykernel.kernelspec +RUN ${PYTHON} -m ipykernel.kernelspec CMD ["bash", "-c", "source /etc/bash.bashrc && jupyter notebook --notebook-dir=/tf --ip 0.0.0.0 --no-browser --allow-root"] diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-mpi-horovod-jupyter.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-mpi-horovod-jupyter.Dockerfile index 2e2b338906c..1986628f1ab 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-mpi-horovod-jupyter.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-mpi-horovod-jupyter.Dockerfile @@ -25,17 +25,17 @@ FROM ubuntu:${UBUNTU_VERSION} as base # See http://bugs.python.org/issue19846 ENV LANG C.UTF-8 +ARG PYTHON=python3 RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ - python3 \ - python3-pip - -RUN python3 -m pip --no-cache-dir install --upgrade \ + ${PYTHON} \ + ${PYTHON}-pip +RUN ${PYTHON} -m pip --no-cache-dir install --upgrade \ pip \ setuptools # Some TF tools expect a "python" binary -RUN ln -s $(which python3) /usr/local/bin/python +RUN ln -s $(which ${PYTHON}) /usr/local/bin/python # Options: # tensorflow @@ -81,27 +81,27 @@ RUN cat /etc/ssh/ssh_config | grep -v StrictHostKeyChecking > /etc/ssh/ssh_confi ARG HOROVOD_WITHOUT_PYTORCH=1 ARG HOROVOD_WITHOUT_MXNET=1 ARG HOROVOD_WITH_TENSORFLOW=1 -ARG HOROVOD_VERSION= -ARG PYTHON=python3 +ARG HOROVOD_VERSION=v0.21.1 RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ build-essential \ cmake \ g++-8 \ gcc-8 \ + git \ ${PYTHON}-dev RUN update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-9 100 --slave /usr/bin/g++ g++ /usr/bin/g++-9 && \ update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-8 800 --slave /usr/bin/g++ g++ /usr/bin/g++-8 -RUN python3 -m pip install --no-cache-dir horovod${HOROVOD_VERSION:+==${HOROVOD_VERSION}} +RUN ${PYTHON} -m pip install git+https://github.com/horovod/horovod.git@${HOROVOD_VERSION} COPY bashrc /etc/bash.bashrc RUN chmod a+rwx /etc/bash.bashrc -RUN python3 -m pip install --no-cache-dir jupyter matplotlib +RUN ${PYTHON} -m pip install --no-cache-dir jupyter matplotlib # Pin ipykernel and nbformat; see https://github.com/ipython/ipykernel/issues/422 -RUN python3 -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 +RUN ${PYTHON} -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 RUN jupyter serverextension enable --py jupyter_http_over_ws RUN mkdir -p /tf/ && chmod -R a+rwx /tf/ @@ -109,6 +109,6 @@ RUN mkdir /.local && chmod a+rwx /.local WORKDIR /tf EXPOSE 8888 -RUN python3 -m ipykernel.kernelspec +RUN ${PYTHON} -m ipykernel.kernelspec CMD ["bash", "-c", "source /etc/bash.bashrc && jupyter notebook --notebook-dir=/tf --ip 0.0.0.0 --no-browser --allow-root"] diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-mpi-horovod.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-mpi-horovod.Dockerfile index 1a724af3ea9..0ae184a4212 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-mpi-horovod.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-mpi-horovod.Dockerfile @@ -25,17 +25,17 @@ FROM ubuntu:${UBUNTU_VERSION} as base # See http://bugs.python.org/issue19846 ENV LANG C.UTF-8 +ARG PYTHON=python3 RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ - python3 \ - python3-pip - -RUN python3 -m pip --no-cache-dir install --upgrade \ + ${PYTHON} \ + ${PYTHON}-pip +RUN ${PYTHON} -m pip --no-cache-dir install --upgrade \ pip \ setuptools # Some TF tools expect a "python" binary -RUN ln -s $(which python3) /usr/local/bin/python +RUN ln -s $(which ${PYTHON}) /usr/local/bin/python # Options: # tensorflow @@ -81,20 +81,20 @@ RUN cat /etc/ssh/ssh_config | grep -v StrictHostKeyChecking > /etc/ssh/ssh_confi ARG HOROVOD_WITHOUT_PYTORCH=1 ARG HOROVOD_WITHOUT_MXNET=1 ARG HOROVOD_WITH_TENSORFLOW=1 -ARG HOROVOD_VERSION= -ARG PYTHON=python3 +ARG HOROVOD_VERSION=v0.21.1 RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ build-essential \ cmake \ g++-8 \ gcc-8 \ + git \ ${PYTHON}-dev RUN update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-9 100 --slave /usr/bin/g++ g++ /usr/bin/g++-9 && \ update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-8 800 --slave /usr/bin/g++ g++ /usr/bin/g++-8 -RUN python3 -m pip install --no-cache-dir horovod${HOROVOD_VERSION:+==${HOROVOD_VERSION}} +RUN ${PYTHON} -m pip install git+https://github.com/horovod/horovod.git@${HOROVOD_VERSION} COPY bashrc /etc/bash.bashrc RUN chmod a+rwx /etc/bash.bashrc diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-mpich-horovod-jupyter.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-mpich-horovod-jupyter.Dockerfile index e24750a3b05..44acb448075 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-mpich-horovod-jupyter.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-mpich-horovod-jupyter.Dockerfile @@ -25,17 +25,17 @@ FROM ubuntu:${UBUNTU_VERSION} as base # See http://bugs.python.org/issue19846 ENV LANG C.UTF-8 +ARG PYTHON=python3 RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ - python3 \ - python3-pip - -RUN python3 -m pip --no-cache-dir install --upgrade \ + ${PYTHON} \ + ${PYTHON}-pip +RUN ${PYTHON} -m pip --no-cache-dir install --upgrade \ pip \ setuptools # Some TF tools expect a "python" binary -RUN ln -s $(which python3) /usr/local/bin/python +RUN ln -s $(which ${PYTHON}) /usr/local/bin/python # Options: # tensorflow @@ -77,27 +77,27 @@ RUN cat /etc/ssh/ssh_config | grep -v StrictHostKeyChecking > /etc/ssh/ssh_confi ARG HOROVOD_WITHOUT_PYTORCH=1 ARG HOROVOD_WITHOUT_MXNET=1 ARG HOROVOD_WITH_TENSORFLOW=1 -ARG HOROVOD_VERSION= -ARG PYTHON=python3 +ARG HOROVOD_VERSION=v0.21.1 RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ build-essential \ cmake \ g++-8 \ gcc-8 \ + git \ ${PYTHON}-dev RUN update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-9 100 --slave /usr/bin/g++ g++ /usr/bin/g++-9 && \ update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-8 800 --slave /usr/bin/g++ g++ /usr/bin/g++-8 -RUN python3 -m pip install --no-cache-dir horovod${HOROVOD_VERSION:+==${HOROVOD_VERSION}} +RUN ${PYTHON} -m pip install git+https://github.com/horovod/horovod.git@${HOROVOD_VERSION} COPY bashrc /etc/bash.bashrc RUN chmod a+rwx /etc/bash.bashrc -RUN python3 -m pip install --no-cache-dir jupyter matplotlib +RUN ${PYTHON} -m pip install --no-cache-dir jupyter matplotlib # Pin ipykernel and nbformat; see https://github.com/ipython/ipykernel/issues/422 -RUN python3 -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 +RUN ${PYTHON} -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 RUN jupyter serverextension enable --py jupyter_http_over_ws RUN mkdir -p /tf/ && chmod -R a+rwx /tf/ @@ -105,6 +105,6 @@ RUN mkdir /.local && chmod a+rwx /.local WORKDIR /tf EXPOSE 8888 -RUN python3 -m ipykernel.kernelspec +RUN ${PYTHON} -m ipykernel.kernelspec CMD ["bash", "-c", "source /etc/bash.bashrc && jupyter notebook --notebook-dir=/tf --ip 0.0.0.0 --no-browser --allow-root"] diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-mpich-horovod.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-mpich-horovod.Dockerfile index 3bedc39c259..a9fe557262c 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-mpich-horovod.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04-mpich-horovod.Dockerfile @@ -25,17 +25,17 @@ FROM ubuntu:${UBUNTU_VERSION} as base # See http://bugs.python.org/issue19846 ENV LANG C.UTF-8 +ARG PYTHON=python3 RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ - python3 \ - python3-pip - -RUN python3 -m pip --no-cache-dir install --upgrade \ + ${PYTHON} \ + ${PYTHON}-pip +RUN ${PYTHON} -m pip --no-cache-dir install --upgrade \ pip \ setuptools # Some TF tools expect a "python" binary -RUN ln -s $(which python3) /usr/local/bin/python +RUN ln -s $(which ${PYTHON}) /usr/local/bin/python # Options: # tensorflow @@ -77,20 +77,20 @@ RUN cat /etc/ssh/ssh_config | grep -v StrictHostKeyChecking > /etc/ssh/ssh_confi ARG HOROVOD_WITHOUT_PYTORCH=1 ARG HOROVOD_WITHOUT_MXNET=1 ARG HOROVOD_WITH_TENSORFLOW=1 -ARG HOROVOD_VERSION= -ARG PYTHON=python3 +ARG HOROVOD_VERSION=v0.21.1 RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ build-essential \ cmake \ g++-8 \ gcc-8 \ + git \ ${PYTHON}-dev RUN update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-9 100 --slave /usr/bin/g++ g++ /usr/bin/g++-9 && \ update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-8 800 --slave /usr/bin/g++ g++ /usr/bin/g++-8 -RUN python3 -m pip install --no-cache-dir horovod${HOROVOD_VERSION:+==${HOROVOD_VERSION}} +RUN ${PYTHON} -m pip install git+https://github.com/horovod/horovod.git@${HOROVOD_VERSION} COPY bashrc /etc/bash.bashrc RUN chmod a+rwx /etc/bash.bashrc diff --git a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04.Dockerfile b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04.Dockerfile index 9033cae3559..3c113723c47 100644 --- a/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04.Dockerfile +++ b/tensorflow/tools/dockerfiles/dockerfiles/onednn/ubuntu-20.04.Dockerfile @@ -25,17 +25,17 @@ FROM ubuntu:${UBUNTU_VERSION} as base # See http://bugs.python.org/issue19846 ENV LANG C.UTF-8 +ARG PYTHON=python3 RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ - python3 \ - python3-pip - -RUN python3 -m pip --no-cache-dir install --upgrade \ + ${PYTHON} \ + ${PYTHON}-pip +RUN ${PYTHON} -m pip --no-cache-dir install --upgrade \ pip \ setuptools # Some TF tools expect a "python" binary -RUN ln -s $(which python3) /usr/local/bin/python +RUN ln -s $(which ${PYTHON}) /usr/local/bin/python # Options: # tensorflow diff --git a/tensorflow/tools/dockerfiles/partials/onednn/centos/horovod-7.partial.Dockerfile b/tensorflow/tools/dockerfiles/partials/onednn/centos/horovod-7.partial.Dockerfile index 7f7c2af6d7b..c03863d2e60 100644 --- a/tensorflow/tools/dockerfiles/partials/onednn/centos/horovod-7.partial.Dockerfile +++ b/tensorflow/tools/dockerfiles/partials/onednn/centos/horovod-7.partial.Dockerfile @@ -2,7 +2,7 @@ ARG HOROVOD_WITHOUT_PYTORCH=1 ARG HOROVOD_WITHOUT_MXNET=1 ARG HOROVOD_WITH_TENSORFLOW=1 -ARG HOROVOD_VERSION= +ARG HOROVOD_VERSION=v0.21.1 ENV LC_ALL=en_US.UTF-8 ENV LC_CTYPE=en_US.UTF-8 @@ -13,7 +13,7 @@ RUN yum update -y && \ devtoolset-8 \ devtoolset-8-make \ llvm-toolset-7-cmake \ - python3-devel \ + ${PYTHON}-devel \ sclo-git25 && \ yum clean all diff --git a/tensorflow/tools/dockerfiles/partials/onednn/centos/horovod.partial.Dockerfile b/tensorflow/tools/dockerfiles/partials/onednn/centos/horovod.partial.Dockerfile index a0a3322400f..31e348a4586 100644 --- a/tensorflow/tools/dockerfiles/partials/onednn/centos/horovod.partial.Dockerfile +++ b/tensorflow/tools/dockerfiles/partials/onednn/centos/horovod.partial.Dockerfile @@ -2,7 +2,7 @@ ARG HOROVOD_WITHOUT_PYTORCH=1 ARG HOROVOD_WITHOUT_MXNET=1 ARG HOROVOD_WITH_TENSORFLOW=1 -ARG HOROVOD_VERSION=0.21.0 +ARG HOROVOD_VERSION=v0.21.1 RUN yum update -y && yum install -y \ cmake \ @@ -10,7 +10,7 @@ RUN yum update -y && yum install -y \ gcc-c++ \ git \ make \ - python36-devel && \ + ${PYTHON}-devel && \ yum clean all RUN ${PYTHON} -m pip install git+https://github.com/horovod/horovod.git@${HOROVOD_VERSION} diff --git a/tensorflow/tools/dockerfiles/partials/onednn/jupyter.partial.Dockerfile b/tensorflow/tools/dockerfiles/partials/onednn/jupyter.partial.Dockerfile index d01a945e5b6..0a9479cd1e7 100644 --- a/tensorflow/tools/dockerfiles/partials/onednn/jupyter.partial.Dockerfile +++ b/tensorflow/tools/dockerfiles/partials/onednn/jupyter.partial.Dockerfile @@ -1,6 +1,6 @@ -RUN python3 -m pip install --no-cache-dir jupyter matplotlib +RUN ${PYTHON} -m pip install --no-cache-dir jupyter matplotlib # Pin ipykernel and nbformat; see https://github.com/ipython/ipykernel/issues/422 -RUN python3 -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 +RUN ${PYTHON} -m pip install --no-cache-dir jupyter_http_over_ws ipykernel==5.1.1 nbformat==4.4.0 RUN jupyter serverextension enable --py jupyter_http_over_ws RUN mkdir -p /tf/ && chmod -R a+rwx /tf/ @@ -8,6 +8,6 @@ RUN mkdir /.local && chmod a+rwx /.local WORKDIR /tf EXPOSE 8888 -RUN python3 -m ipykernel.kernelspec +RUN ${PYTHON} -m ipykernel.kernelspec CMD ["bash", "-c", "source /etc/bash.bashrc && jupyter notebook --notebook-dir=/tf --ip 0.0.0.0 --no-browser --allow-root"] diff --git a/tensorflow/tools/dockerfiles/partials/onednn/ubuntu/1604-horovod.partial.Dockerfile b/tensorflow/tools/dockerfiles/partials/onednn/ubuntu/1604-horovod.partial.Dockerfile index ff2438e224d..8d1dd952e73 100644 --- a/tensorflow/tools/dockerfiles/partials/onednn/ubuntu/1604-horovod.partial.Dockerfile +++ b/tensorflow/tools/dockerfiles/partials/onednn/ubuntu/1604-horovod.partial.Dockerfile @@ -2,7 +2,7 @@ ARG HOROVOD_WITHOUT_PYTORCH=1 ARG HOROVOD_WITHOUT_MXNET=1 ARG HOROVOD_WITH_TENSORFLOW=1 -ARG HOROVOD_VERSION= +ARG HOROVOD_VERSION=v0.21.1 RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ software-properties-common @@ -17,9 +17,10 @@ RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ cmake \ g++-8 \ gcc-8 \ - python3-dev + git \ + ${PYTHON}-dev RUN update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-5 500 --slave /usr/bin/g++ g++ /usr/bin/g++-5 && \ update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-8 800 --slave /usr/bin/g++ g++ /usr/bin/g++-8 -RUN python3 -m pip install --no-cache-dir horovod${HOROVOD_VERSION:+==${HOROVOD_VERSION}} +RUN ${PYTHON} -m pip install git+https://github.com/horovod/horovod.git@${HOROVOD_VERSION} diff --git a/tensorflow/tools/dockerfiles/partials/onednn/ubuntu/2004-horovod.partial.Dockerfile b/tensorflow/tools/dockerfiles/partials/onednn/ubuntu/2004-horovod.partial.Dockerfile index fee735a0654..e4c29482436 100644 --- a/tensorflow/tools/dockerfiles/partials/onednn/ubuntu/2004-horovod.partial.Dockerfile +++ b/tensorflow/tools/dockerfiles/partials/onednn/ubuntu/2004-horovod.partial.Dockerfile @@ -2,17 +2,17 @@ ARG HOROVOD_WITHOUT_PYTORCH=1 ARG HOROVOD_WITHOUT_MXNET=1 ARG HOROVOD_WITH_TENSORFLOW=1 -ARG HOROVOD_VERSION= -ARG PYTHON=python3 +ARG HOROVOD_VERSION=v0.21.1 RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ build-essential \ cmake \ g++-8 \ gcc-8 \ + git \ ${PYTHON}-dev RUN update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-9 100 --slave /usr/bin/g++ g++ /usr/bin/g++-9 && \ update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-8 800 --slave /usr/bin/g++ g++ /usr/bin/g++-8 -RUN python3 -m pip install --no-cache-dir horovod${HOROVOD_VERSION:+==${HOROVOD_VERSION}} +RUN ${PYTHON} -m pip install git+https://github.com/horovod/horovod.git@${HOROVOD_VERSION} diff --git a/tensorflow/tools/dockerfiles/partials/onednn/ubuntu/horovod.partial.Dockerfile b/tensorflow/tools/dockerfiles/partials/onednn/ubuntu/horovod.partial.Dockerfile index abc750f2442..0d65c788fb2 100644 --- a/tensorflow/tools/dockerfiles/partials/onednn/ubuntu/horovod.partial.Dockerfile +++ b/tensorflow/tools/dockerfiles/partials/onednn/ubuntu/horovod.partial.Dockerfile @@ -2,16 +2,17 @@ ARG HOROVOD_WITHOUT_PYTORCH=1 ARG HOROVOD_WITHOUT_MXNET=1 ARG HOROVOD_WITH_TENSORFLOW=1 -ARG HOROVOD_VERSION= +ARG HOROVOD_VERSION=v0.21.1 RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ build-essential \ cmake \ g++-8 \ gcc-8 \ - python3-dev + git \ + ${PYTHON}-dev RUN update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-7 700 --slave /usr/bin/g++ g++ /usr/bin/g++-7 && \ update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-8 800 --slave /usr/bin/g++ g++ /usr/bin/g++-8 -RUN python3 -m pip install --no-cache-dir horovod${HOROVOD_VERSION:+==${HOROVOD_VERSION}} +RUN ${PYTHON} -m pip install git+https://github.com/horovod/horovod.git@${HOROVOD_VERSION} diff --git a/tensorflow/tools/dockerfiles/partials/onednn/ubuntu/python.partial.Dockerfile b/tensorflow/tools/dockerfiles/partials/onednn/ubuntu/python.partial.Dockerfile index be4c4a08c03..f5aa4236e48 100644 --- a/tensorflow/tools/dockerfiles/partials/onednn/ubuntu/python.partial.Dockerfile +++ b/tensorflow/tools/dockerfiles/partials/onednn/ubuntu/python.partial.Dockerfile @@ -1,13 +1,13 @@ # See http://bugs.python.org/issue19846 ENV LANG C.UTF-8 +ARG PYTHON=python3 RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ - python3 \ - python3-pip - -RUN python3 -m pip --no-cache-dir install --upgrade \ + ${PYTHON} \ + ${PYTHON}-pip +RUN ${PYTHON} -m pip --no-cache-dir install --upgrade \ pip \ setuptools # Some TF tools expect a "python" binary -RUN ln -s $(which python3) /usr/local/bin/python +RUN ln -s $(which ${PYTHON}) /usr/local/bin/python diff --git a/tensorflow/tools/dockerfiles/partials/onednn/ubuntu/python3.partial.Dockerfile b/tensorflow/tools/dockerfiles/partials/onednn/ubuntu/python3.partial.Dockerfile index 2ca27c6ca9b..d3d1d9256bd 100644 --- a/tensorflow/tools/dockerfiles/partials/onednn/ubuntu/python3.partial.Dockerfile +++ b/tensorflow/tools/dockerfiles/partials/onednn/ubuntu/python3.partial.Dockerfile @@ -8,11 +8,11 @@ RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ RUN add-apt-repository ppa:deadsnakes/ppa -RUN apt-get update && \ - apt-get install -y --no-install-recommends --fix-missing \ +RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ ${PYTHON} RUN curl -fSsL https://bootstrap.pypa.io/get-pip.py | ${PYTHON} + RUN ${PYTHON} -m pip --no-cache-dir install --upgrade \ pip \ setuptools