Skip to content

Commit

Permalink
Refactor docker location
Browse files Browse the repository at this point in the history
  • Loading branch information
radekd91 committed Jan 15, 2024
1 parent 3064891 commit 32fdfb3
Show file tree
Hide file tree
Showing 10 changed files with 195 additions and 5 deletions.
4 changes: 1 addition & 3 deletions docker/Dockerfile → docker/work38/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
# Start from an NVIDIA CUDA base image
# FROM nvidia/cuda:11.0-base-ubuntu20.04
# FROM nvidia/cuda:11.8.0-runtime-ubuntu20.04
FROM nvidia/cuda:11.8.0-devel-ubuntu20.04
FROM nvidia/cuda:12.3.1-devel-ubuntu20.04
LABEL maintainer="RadekDanecek"

# Set a non-interactive shell to avoid prompts during the build process
Expand Down
50 changes: 50 additions & 0 deletions docker/work38/Dockerfile_cudagl
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
# Start from an NVIDIA CUDA base image
# FROM nvidia/cuda:11.0-base-ubuntu20.04
# FROM nvidia/cuda:11.8.0-runtime-ubuntu20.04
FROM nvidia/cudagl:11.4.2-devel-ubuntu20.04
LABEL maintainer="RadekDanecek"

# Set a non-interactive shell to avoid prompts during the build process
ARG DEBIAN_FRONTEND=noninteractive

# Update and install necessary packages for X11 and OpenGL
RUN apt-get update && apt-get install -y --no-install-recommends \
software-properties-common \
build-essential \
gcc \
g++ \
libboost-dev \
cmake \
curl \
wget \
zip \
unzip \
nano \
git
# \
# && rm -rf /var/lib/apt/lists/*
RUN add-apt-repository ppa:ubuntu-toolchain-r/test
RUN apt-get update && apt-get install -y --no-install-recommends \
libstdc++6 \
&& rm -rf /var/lib/apt/lists/*


# Set the working directory in the container
WORKDIR /workspace/repos

# # Set the DISPLAY environment variable for X11 forwarding
# ENV DISPLAY=:0

# Add a startup script to the image
COPY install_38_docker.sh /usr/local/bin/install_script.sh
COPY startup_script.sh /usr/local/bin/startup_script.sh
COPY environment.yaml /workspace/environment.yaml
COPY requirements.txt /workspace/requirements.txt
RUN chmod +x /usr/local/bin/install_script.sh

# Set the script to run on container start
RUN bash /usr/local/bin/install_script.sh

# Set the script to run on container start
CMD ["/usr/local/bin/startup_script.sh"]

45 changes: 45 additions & 0 deletions docker/work38/Dockerfile_egl
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
# Start from an NVIDIA CUDA base image
# FROM nvidia/cuda:11.0-base-ubuntu20.04
# FROM nvidia/cuda:11.8.0-runtime-ubuntu20.04
FROM nvidia/cuda:11.8.0-devel-ubuntu20.04
LABEL maintainer="RadekDanecek"

# Set a non-interactive shell to avoid prompts during the build process
ARG DEBIAN_FRONTEND=noninteractive

# Update and install necessary packages for X11 and OpenGL
RUN apt-get update && apt-get install -y --no-install-recommends \
build-essential \
gcc \
g++ \
libboost-dev \
libegl1 \
mesa-utils \
cmake \
curl \
wget \
zip \
unzip \
nano \
git \
&& rm -rf /var/lib/apt/lists/*

# Set the working directory in the container
WORKDIR /workspace/repos

# # Set the DISPLAY environment variable for X11 forwarding
# ENV DISPLAY=:0

# Add a startup script to the image
COPY install_38_docker.sh /usr/local/bin/install_script.sh
COPY startup_script.sh /usr/local/bin/startup_script.sh
COPY environment.yaml /workspace/environment.yaml
COPY requirements.txt /workspace/requirements.txt
RUN chmod +x /usr/local/bin/install_script.sh

# Set the script to run on container start
RUN bash /usr/local/bin/install_script.sh

# Set the script to run on container start
CMD ["/usr/local/bin/startup_script.sh"]

File renamed without changes.
4 changes: 2 additions & 2 deletions docker/build_docker.sh → docker/work38/build_docker.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/bin/bash
echo "Building docker image"
cp ../conda-environment_py38_cu11.yaml environment.yaml
cp ../requirements38.txt requirements.txt
cp ../../conda-environment_py38_cu11.yaml environment.yaml
cp ../../requirements38.txt requirements.txt
docker build -t inferno_docker .
# docker build -t inferno_docker_egl . > build_log_egl.out 2> build_log_egl.err
# docker build --no-cache -t inferno_docker_egl . > build_log_egl.out 2> build_log_egl.err
Expand Down
64 changes: 64 additions & 0 deletions docker/work38/environment.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
name: work38
channels:
- tensorly
- pytorch
- huggingface
- conda-forge
dependencies:
- python>=3.8, <3.9
- pytorch=1.12.1
- cudatoolkit=11.3.1
- torchaudio=0.12.1
- torchvision=0.13.1
- librosa=0.9.2
- onnx=1.10.2
- onnx2torch=1.5
- pandas=1.4.2
- pip=21.2.4
- pyopengl=3.1
- pyrender=0.1.45
- pyvista=0.35
# - pyvistaqt=0.10
- pyvistaqt
- resampy=0.2.2
- scikit-image=0.19.2
- scikit-learn=1.0.2
- scikit-video=1.1.11
- seaborn=0.11.0
- tensorly=0.6.0
- pip:
- albumentations==1.0.3
- compress-pickle==1.2.0
- chumpy==0.70
- Cython==0.29
- decord==0.6.0
- face-alignment==1.3.5
- facenet-pytorch==2.5.2
- gdown==4.5.1
- h5py==3.8.0
- hickle==5.0.2
- huggingface-hub==0.16.4
- hydra-core==1.0.7
- imgaug==0.4.0
- insightface==0.6.2
- kornia==0.6.5
- matplotlib==3.2.2
- mediapipe==0.8.10
- munch==2.5.0
- numpy==1.23.0
- onnxruntime-gpu==1.9.0
- opencv-contrib-python==4.7.0.72
- opencv-python==4.7.0.72
- opencv-python-headless==4.7.0.72
- psbody-mesh @ git+https://github.com/MPI-IS/[email protected]
- python-speech-features==0.6
- pytorch-lightning==1.4.9
- pytorch3d @ git+https://github.com/facebookresearch/[email protected]
- torchgeometry==0.1.2
- torchmetrics==0.6.2
- torchfile==0.1.0
- transformers==4.22.2
- trimesh==3.6.43
- wandb==0.10.33


File renamed without changes.
33 changes: 33 additions & 0 deletions docker/work38/requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
albumentations==1.0.3
compress-pickle==1.2.0
chumpy==0.70
Cython==0.29
decord==0.6.0
face-alignment==1.3.5
facenet-pytorch==2.5.2
gdown==4.5.1
h5py==3.8.0
hickle==5.0.2
huggingface-hub==0.16.4
hydra-core==1.0.7
imgaug==0.4.0
insightface==0.6.2
kornia==0.6.5
matplotlib==3.2.2
mediapipe==0.8.10
munch==2.5.0
numpy==1.23.0
onnxruntime-gpu==1.9.0
opencv-contrib-python==4.7.0.72
opencv-python==4.7.0.72
opencv-python-headless==4.7.0.72
psbody-mesh @ git+https://github.com/MPI-IS/[email protected]
python-speech-features==0.6
pytorch-lightning==1.4.9
pytorch3d @ git+https://github.com/facebookresearch/[email protected]
torchgeometry==0.1.2
torchmetrics==0.6.2
torchfile==0.1.0
transformers==4.22.2
trimesh==3.6.43
wandb==0.10.33
File renamed without changes.
File renamed without changes.

0 comments on commit 32fdfb3

Please sign in to comment.