Last active
March 22, 2020 06:47
-
-
Save taross-f/504b36787a1d933216dbf9d6e814017d to your computer and use it in GitHub Desktop.
Dockerfile for Python3.6 with OpenVINO 2020.1.023
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM ubuntu:18.04 | |
USER root | |
WORKDIR / | |
ARG DEPENDENCIES="autoconf \ | |
automake \ | |
build-essential \ | |
cmake \ | |
cpio \ | |
curl \ | |
gnupg2 \ | |
libdrm2 \ | |
libglib2.0-0 \ | |
lsb-release \ | |
libgtk-3-0 \ | |
libtool \ | |
python3-pip \ | |
udev \ | |
unzip \ | |
sudo " | |
RUN apt-get update && \ | |
apt-get install -y --no-install-recommends ${DEPENDENCIES} && \ | |
rm -rf /var/lib/apt/lists/* | |
ARG DOWNLOAD_LINK=http://registrationcenter-download.intel.com/akdlm/irc_nas/16345/l_openvino_toolkit_p_2020.1.023.tgz | |
RUN export OV_BUILD OV_FOLDER | |
SHELL ["/bin/bash", "-o", "pipefail", "-c"] | |
RUN curl -LOJ "${DOWNLOAD_LINK}" && \ | |
tar -xzf ./*.tgz && \ | |
OV_BUILD="$(ls -lA | grep openvino | tr -s " " | cut -d\ -f9 | cut -d_ -f7 | head -n 1)" && \ | |
OV_FOLDER="$(ls -lA | grep openvino | tr -s " " | cut -d\ -f9 | head -n 1)" && \ | |
mkdir -p /opt/intel/openvino_"$OV_BUILD"/ && \ | |
cp -rf "$OV_FOLDER"/* /opt/intel/openvino_"$OV_BUILD"/ && \ | |
rm -rf /tmp/"$OV_FOLDER" && \ | |
rm -rf /tmp/*.tgz && \ | |
ln --symbolic /opt/intel/openvino_"$OV_BUILD"/ /opt/intel/openvino | |
ENV INSTALLDIR=/opt/intel/openvino | |
RUN $INSTALLDIR/install_openvino_dependencies.sh | |
RUN $INSTALLDIR/install.sh -s $INSTALLDIR/silent.cfg --accept_eula | |
RUN bash -c 'source /opt/intel/openvino/bin/setupvars.sh' | |
RUN pip3 install setuptools && pip3 install --upgrade pip pyyaml requests pipenv | |
COPY models.txt $INSTALLDIR/deployment_tools/tools/model_downloader/models.txt | |
RUN python3 -mpip install --user -r $INSTALLDIR/deployment_tools/tools/model_downloader/requirements.in | |
RUN $INSTALLDIR/deployment_tools/tools/model_downloader/downloader.py --list $INSTALLDIR/deployment_tools/tools/model_downloader/models.txt -o ~/model |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment