-
Notifications
You must be signed in to change notification settings - Fork 34
/
Copy pathDockerfile
67 lines (52 loc) · 1.8 KB
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
# Dockerfile
#
# Created on Tue Nov 14 2023 by Florian Pfleiderer
#
# Copyright (c) 2023 TU Wien
# Use an official PyTorch base image
# FROM pytorch/pytorch:1.10.0-cuda11.3-cudnn8-runtime
# nvidia cuda base image
FROM nvidia/cuda:11.6.1-base-ubuntu20.04
# Set the working directory in the container
WORKDIR /point-slam
# Set noninteractive mode
ENV DEBIAN_FRONTEND=noninteractive
# Install git and wget
RUN apt-get update && \
apt-get install -y git wget cmake gcc g++ libgl1-mesa-glx libglib2.0-0 unzip && \
apt-get clean && \
rm -rf /var/lib/apt/lists/*
# Reset noninteractive mode
ENV DEBIAN_FRONTEND=dialog
# Install miniconda.
ENV CONDA_DIR $HOME/miniconda3
RUN wget --quiet https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh -O ~/miniconda.sh && \
chmod +x ~/miniconda.sh && \
~/miniconda.sh -b -p $CONDA_DIR && \
rm ~/miniconda.sh
# Make non-activate conda commands available.
ENV PATH=$CONDA_DIR/bin:$PATH
# Make conda activate command available from /bin/bash --login shells.
RUN echo ". $CONDA_DIR/etc/profile.d/conda.sh" >> ~/.profile
# Make conda activate command available from /bin/bash --interative shells.
RUN conda init bash
# start shell in login mode
SHELL ["/bin/bash", "--login", "-c"]
# run updates
RUN conda update -n base -c defaults conda
# copy environment file
COPY env.yaml env.yaml
# Create a Conda environment
RUN conda env create -f env.yaml
# start container in cyws3d env
RUN touch ~/.bashrc && echo "conda activate point-slam" >> ~/.bashrc
COPY scripts/ scripts/
# RUN bash scripts/download_replica.sh
# copy source code
COPY configs/ configs/
COPY cull_replica_mesh/ cull_replica_mesh/
COPY pretrained/ pretrained/
COPY src/ src/
COPY repro.sh run.py test_deterministic.py ./
# Set the default command to run when the container starts
CMD ["bash"]