The docker-python
directory can be used to release mxnet python docker images to dockerhub after any mxnet release.
It uses the appropriate pip binaries to build different docker images. Both python2 (default) and python3 images are available as -
- {version}_cpu
- {version}_cpu_mkl
- {version}_gpu_cu92
- {version}_gpu_cu92_mkl
- {version}_cpu_py3
- {version}_cpu_mkl_py3
- {version}_gpu_cu92_py3
- {version}_gpu_cu92_mkl_py3
And the following tags will be available without the version string in the image name (for Benchmarking and other use cases):
- latest (same as {version}_cpu)
- gpu (same as {version}_gpu_cu90)
- latest_cpu_mkl_py2 (same as {version}_cpu_mkl)
- latest_cpu_mkl_py3 (same as {version}_cpu_mkl_py3)
- latest_gpu_mkl_py2 (same as {version}_gpu_cu90_mkl)
- latest_gpu_mkl_py3 (same as {version}_gpu_cu90_mkl_py3)
Refer: https://pypi.org/project/mxnet/
./build_python_dockerfile.sh <mxnet_version> <pip_tag> <path_to_cloned_mxnet_repo>
For example:
./build_python_dockerfile.sh 1.3.0 1.3.0.post0 ~/build-docker/incubator-mxnet
- test_mxnet.py: This script is used to make sure that the docker image builds the expected mxnet version. That is, the version picked by pip is the same as as the version passed as a parameter.
Dockerhub credentials will be required to push images at the end of this script. Credentials can be provided in the following ways:
- Interactive Login: Run the script as is and it will ask you for credentials interactively.
- Be Already Logged in: Login to the mxnet dockerhub account before you run the build script and the script will complete build, test and push.
- Set Environment Variables: Set the following environment variables which the script will pick up to login to dockerhub at runtime -
- $MXNET_DOCKERHUB_PASSWORD
- $MXNET_DOCKERHUB_USERNAME
-
The MXNet Python Docker images can be found here: https://hub.docker.com/r/mxnet/python/
-
Docker Pull Command:
docker pull mxnet/python:<image_tag>
-
Get started:
docker run -it mxnet/python:<image_tag> bash