Docker image for Deep Learning. Based on floydhub/dl-docker.
- Ubuntu 16.04
- CUDA 8.0
- cuDNN v6
- Tensorflow
- Keras
- iPython/Jupyter Notebook with Python3 kernel by default
- Numpy
- SciPy
- Pandas
- Scikit Learn
- Matplotlib
- PyTorch
- OpenCV
TODO:
- Some Python libraries for NLP
- Some Linux distro (compatibility checked with Gentoo and Ubuntu), NVIDIA GPU
- Docker https://docs.docker.com/engine/installation/
- NVIDIA drivers https://www.nvidia.com/Download/index.aspx?lang=en-us
- NVIDIA-Docker https://github.com/NVIDIA/nvidia-docker
You can download the Docker image from Docker Hub, or build an image locally.
You can pull an image from Docker Hub repository.
docker pull robolamp/k-gpu-compute-docker:gpu
- Clone this repository
git clone https://github.com/robolamp/KGPUComputeDocker.git
cd KGPUComputeDocker
- Check Docker's Base Device Size parameter using this guide
We need at least 16 GB of memory
- Build the image
You can build the image which includes buidling TensorFlow and OpenCV from sources:
docker build -t robolamp/k-gpu-compute-docker:gpu -f Dockerfile.gpu .
But it will take a lot of time. Alternatively, you can build the image which is using pre-built packages:
docker build -t robolamp/k-gpu-compute-docker:gpu -f Dockerfile.bin.gpu .
Don't forget to prepare a directory to share with container using Docker volumes
You can run container with an access to container's bash:
nvidia-docker run -it -p 4444:8888 -p 3003:6006 -v /sharedfolder:/root/sharedfolder robolamp/k-gpu-compute-docker:gpu bash
Alternatively, you can run jupiter notebook in container.
- Prepare the password for your jupiter notebook
Run python in your terminal:
python
Encrypt your password using notebook.auth.security.passwd():
>>> from notebook.auth import passwd
>>> passwd()
Enter password:
Verify password:
- Launch container with notebook
Copy your password hash and insert it into the following command and run it:
nvidia-docker run -d -p 4444:8888 -p 3003:6006 -v /sharedfolder:/root/sharedfolder robolamp/k-gpu-compute-docker:gpu jupyter notebook --NotebookApp.password='your_password_hash' --allow-root