Sign inSign up

sameli/glearn

By sameli

•Updated over 2 years ago

Gaussian Process for Machine Learning

Image
0

264

sameli/glearn repository overview

⁠glearn

An Ubuntu 20.04 image with glearn⁠ python package built with NVIDIA CUDA Toolkit 11.4 support.

⁠Download
docker pull sameli/glearn
⁠Usage
  • To run the container and open python interpreter directly at startup:

    docker run -it sameli/glearn
    

    This also imports glearn package automatically.

  • To run the container and open ipython interpreter directly at startup:

    docker run -it sameli/glearn ipython
    

    This also imports glearn package automatically.

  • To open bash shell only:

    docker run -it --entrypoint /bin/bash sameli/glearn
    
  • To mount the host directory /home/user/project on the docker's container directory /root, use:

    docker run -it -v /home/user/project:/root sameli/glearn
    
⁠Using Host's GPU

To access host's GPU device from the container, install Nvidia Container Toolkit as follows.

  1. Add the package to the repository:

    distribution=$(. /etc/os-release;echo $ID$VERSION_ID)
    curl -s -L https://nvidia.github.io/nvidia-docker/gpgkey | sudo apt-key add -
    curl -s -L https://nvidia.github.io/nvidia-docker/$distribution/nvidia-docker.list | sudo tee /etc/apt/sources.list.d/nvidia-docker.list
    
  2. Install nvidia-contaner-toolkit by:

    sudo apt-get update && sudo apt-get install -y nvidia-container-toolkit
    
  3. Restart docker to be able to use it:

    sudo systemctl restart docker
    

To use host's GPU, add --gpus all to any of the docker commands given before, such as:

docker run --gpus all -it sameli/glearn

To check the host's Nvidia driver version, CUDA runtime library version, and list of available GPU devices, run nvida-smi command, such as by:

docker run --gpus all sameli/glearn nvidia-smi
⁠Installed programs
  • CUDA 11: /usr/local/cuda
  • Python 3.9: /usr/bin/python3
  • Python interpreters: ipython, jupyter
  • Editor: vim
  • LaTeX (texlive)

Tag summary

Content type

Image

Digest

sha256:e911b5816…

Size

1 GB

Last updated

over 2 years ago

docker pull sameli/glearn