1 # Install Horovod 2 ARG HOROVOD_WITHOUT_PYTORCH=1 3 ARG HOROVOD_WITHOUT_MXNET=1 4 ARG HOROVOD_WITH_TENSORFLOW=1 5 ARG HOROVOD_VERSION=v0.21.1 6 7 RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ 8 software-properties-common 9 10 RUN cd /usr/lib/python3/dist-packages && \ 11 ln -sf apt_pkg.cpython-35m-x86_64-linux-gnu.so apt_pkg.so 12 13 RUN add-apt-repository ppa:ubuntu-toolchain-r/test 14 15 RUN apt-get update && apt-get install -y --no-install-recommends --fix-missing \ 16 build-essential \ 17 cmake \ 18 g++-8 \ 19 gcc-8 \ 20 git \ 21 ${PYTHON}-dev 22 23 RUN update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-5 500 --slave /usr/bin/g++ g++ /usr/bin/g++-5 && \ 24 update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-8 800 --slave /usr/bin/g++ g++ /usr/bin/g++-8 25 26 RUN ${PYTHON} -m pip install git+https://github.com/horovod/horovod.git@${HOROVOD_VERSION}