-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #450 from yandexdataschool/spring20
Merge spring20 into master
- Loading branch information
Showing
142 changed files
with
200,559 additions
and
219,602 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,75 +1,65 @@ | ||
FROM ubuntu:16.04 | ||
ARG device | ||
ARG username="jovyan" | ||
|
||
FROM ubuntu:18.04 AS base-cpu | ||
|
||
FROM nvidia/cuda:10.2-base-ubuntu18.04 AS base-gpu | ||
|
||
FROM base-$device AS base | ||
|
||
ARG username | ||
ENV DEBIAN_FRONTEND=noninteractive | ||
|
||
RUN apt-get -qq update && \ | ||
apt-get install -y wget unzip git cmake xvfb sudo freeglut3-dev ffmpeg | ||
|
||
RUN adduser --disabled-password --gecos "Default user" $username && \ | ||
adduser $username sudo && \ | ||
echo "%sudo ALL=(ALL) NOPASSWD:ALL" >> /etc/sudoers && \ | ||
mkdir /notebooks && \ | ||
chown -R $username /notebooks | ||
|
||
RUN su $username -c \ | ||
"wget https://repo.anaconda.com/archive/Anaconda3-2020.02-Linux-x86_64.sh \ | ||
-O /tmp/anaconda3.sh" && \ | ||
mkdir -p /opt/conda && \ | ||
chown -R $username /opt/conda && \ | ||
su $username -c "/bin/bash /tmp/anaconda3.sh -b -p /opt/conda -u" && \ | ||
rm /tmp/anaconda3.sh && \ | ||
ln -s /opt/conda/etc/profile.d/conda.sh /etc/profile.d/conda.sh && \ | ||
su $username -c "echo '. /opt/conda/etc/profile.d/conda.sh' >> ~/.bashrc" && \ | ||
su $username -c "echo 'conda activate base' >> ~/.bashrc" | ||
|
||
ADD deeplearning.yaml /tmp/deeplearning-template.yaml | ||
|
||
USER $username | ||
SHELL ["/bin/bash", "-i", "-c"] | ||
RUN conda install -y jupyter | ||
|
||
FROM base AS stage-cpu | ||
RUN sed -e "s/{tensorflow}/tensorflow/g" -e "s/{pytorch}/pytorch/g" /tmp/deeplearning-template.yaml > /tmp/deeplearning.yaml | ||
|
||
FROM base AS stage-gpu | ||
RUN sed -e "s/{tensorflow}/tensorflow-gpu/g" -e "s/{pytorch}/pytorch-gpu/g" /tmp/deeplearning-template.yaml > /tmp/deeplearning.yaml | ||
|
||
FROM stage-$device as final | ||
|
||
LABEL maintainer "Alexander Panin <justheuristic@gmail.com>, Dmitry Mittov <mittov@gmail.com>" | ||
|
||
ARG username | ||
USER $username | ||
SHELL ["/bin/bash", "-i", "-c"] | ||
|
||
RUN echo "deb http://archive.ubuntu.com/ubuntu trusty-backports main restricted universe multiverse" >> /etc/apt/sources.list && \ | ||
apt-get -qq update && \ | ||
apt-get install -y cmake \ | ||
wget \ | ||
unzip \ | ||
git \ | ||
zlib1g-dev \ | ||
libjpeg-dev \ | ||
xvfb \ | ||
libav-tools \ | ||
xorg-dev \ | ||
python-opengl \ | ||
swig3.0 \ | ||
python-dev \ | ||
python3-dev \ | ||
python-pip \ | ||
python3-pip \ | ||
libopenblas-dev \ | ||
liblapack-dev \ | ||
libsdl2-dev \ | ||
libboost-all-dev \ | ||
graphviz \ | ||
gcc \ | ||
g++ && \ | ||
ln -s /usr/bin/swig3.0 /usr/bin/swig | ||
|
||
RUN pip install --upgrade pip==9.0.3 && \ | ||
pip install --upgrade numpy scipy && \ | ||
pip install --upgrade sklearn \ | ||
jupyter \ | ||
tqdm \ | ||
graphviz \ | ||
gym gym[box2d] gym[atari] \ | ||
matplotlib \ | ||
seaborn && \ | ||
pip install --upgrade https://github.com/Theano/Theano/archive/master.zip \ | ||
https://github.com/Lasagne/Lasagne/archive/master.zip \ | ||
https://github.com/yandexdataschool/AgentNet/archive/master.zip \ | ||
tensorflow \ | ||
https://download.pytorch.org/whl/cpu/torch-1.0.1.post2-cp27-cp27mu-linux_x86_64.whl \ | ||
torchvision \ | ||
keras | ||
|
||
RUN pip install --upgrade gym_pull ppaquette-gym-doom | ||
|
||
|
||
RUN pip3 install --upgrade pip==9.0.3 && \ | ||
pip3 install --upgrade numpy scipy && \ | ||
pip3 install --upgrade sklearn \ | ||
jupyter \ | ||
tqdm \ | ||
graphviz \ | ||
gym gym[box2d] gym[atari] \ | ||
matplotlib \ | ||
seaborn && \ | ||
pip3 install --upgrade https://github.com/Theano/Theano/archive/master.zip \ | ||
https://github.com/Lasagne/Lasagne/archive/master.zip \ | ||
https://github.com/yandexdataschool/AgentNet/archive/master.zip \ | ||
https://download.pytorch.org/whl/cpu/torch-1.0.1.post2-cp35-cp35m-linux_x86_64.whl \ | ||
torchvision \ | ||
tensorflow \ | ||
keras && \ | ||
python3 -m ipykernel.kernelspec | ||
RUN conda env create -f /tmp/deeplearning.yaml && \ | ||
conda activate deeplearning && \ | ||
python -m ipykernel install --user --name python3 --display-name "Python 3" | ||
|
||
RUN sudo rm /tmp/deeplearning*.yaml | ||
|
||
EXPOSE 8888 | ||
VOLUME /notebooks | ||
WORKDIR /notebooks | ||
ENV PATH /opt/conda/bin:$PATH | ||
|
||
COPY run_jupyter.sh / | ||
CMD ["/run_jupyter.sh"] |
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
name: deeplearning | ||
channels: | ||
- defaults | ||
dependencies: | ||
- graphviz | ||
- python-graphviz | ||
- ipykernel | ||
- keras | ||
- numpy=1.16.6 | ||
- pip | ||
- scipy | ||
- {tensorflow}=1.13.1 | ||
- tqdm | ||
- pyopengl-accelerate | ||
- {pytorch} | ||
- torchvision | ||
- opencv | ||
- pip: | ||
- atari-py | ||
- sklearn | ||
- matplotlib | ||
- seaborn | ||
- scikit-image | ||
- imageio | ||
- pyglet | ||
- psutil | ||
- gym | ||
- gym[box2d] | ||
- gym[atari] | ||
- requests | ||
- editdistance | ||
prefix: /opt/conda/envs/deeplearning |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,2 @@ | ||
#!/usr/bin/env bash | ||
jupyter notebook --no-browser --allow-root --ip 0.0.0.0 | ||
|
||
jupyter notebook --no-browser --ip 0.0.0.0 |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,5 @@ | ||
#!/bin/bash | ||
# a setup script for google colab. Will be updated | ||
pip install gym | ||
apt-get install -y xvfb | ||
wget https://raw.githubusercontent.com/yandexdataschool/Practical_DL/fall18/xvfb -O ../xvfb | ||
apt-get install -y python-opengl ffmpeg | ||
pip install pyglet==1.2.4 | ||
#!/usr/bin/env bash | ||
|
||
apt-get -qq update | ||
apt-get -qq install -y xvfb | ||
wget -q https://raw.githubusercontent.com/yandexdataschool/Practical_RL/spring20/xvfb -O ../xvfb |
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
Oops, something went wrong.
d51a1ee
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Review Jupyter notebook diffs for this commit on
You can open a pull request to discuss changes and offer feedback.
Powered by ReviewNB