Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added pinning to remote dependencies #65

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
41 changes: 24 additions & 17 deletions Docker/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM nvidia/cuda:10.2-cudnn7-devel-ubuntu18.04
FROM nvidia/cuda:10.2-cudnn7-devel-ubuntu18.04

RUN apt-get update && apt-get install -y \
cmake \
Expand All @@ -7,7 +7,7 @@ RUN apt-get update && apt-get install -y \
git \
rsync \
sudo \
zip \
zip \
vim \
ssh \
unzip \
Expand All @@ -27,25 +27,28 @@ RUN apt-get update && apt-get install -y \
libxi-dev \
libatlas-base-dev \
libsuitesparse-dev \
libcgal-dev \
libcgal-dev \
libeigen3-dev \
libmetis-dev \
&& rm -rf /var/lib/apt/lists/*

# Install Ceres Solver
RUN git clone https://ceres-solver.googlesource.com/ceres-solver
RUN mkdir -p ceres-solver/build
WORKDIR ceres-solver/build
RUN cmake -DBUILD_TESTING=OFF -DBUILD_EXAMPLES=OFF .. && make -j$(nproc) && make install && make clean
WORKDIR ceres-solver
RUN git checkout 1.14.0
WORKDIR build
RUN cmake -DBUILD_TESTING=OFF -DBUILD_EXAMPLES=OFF .. && make -j$(nproc) && make install && make clean
WORKDIR /

# Install Colmap
RUN git clone https://github.com/colmap/colmap
RUN mkdir -p colmap/build
WORKDIR colmap/build
WORKDIR colmap
RUN git reset --hard 30521f1
WORKDIR build
RUN cmake -DCMAKE_BUILD_TYPE=Release -DTESTS_ENABLED=OFF .. && make -j$(nproc) && make install && make clean
WORKDIR /


# Install Miniconda
RUN curl -so /miniconda.sh https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh \
&& chmod +x /miniconda.sh \
Expand All @@ -54,7 +57,6 @@ RUN curl -so /miniconda.sh https://repo.anaconda.com/miniconda/Miniconda3-latest

ENV PATH=/miniconda/bin:$PATH


# Create a Python 3.6 environment
RUN conda install -y conda-build \
&& conda create -y --name py36 python=3.6.7 \
Expand All @@ -70,17 +72,21 @@ RUN conda install -y pytorch=1.5.0 torchvision=0.6.0 cudatoolkit=10.2 -c pytorch
RUN conda install opencv

RUN pip install \
open3d>=0.10.0.0 \
trimesh>=3.7.6 \
pyquaternion>=0.9.5 \
pytorch-lightning>=0.8.5 \
open3d==0.10.0.0 \
trimesh==3.7.6 \
pyquaternion==0.9.5 \
protobuf===3.6.0 \
pytorch-lightning==0.8.5 \
pyrender>=0.1.43 \
scikit-image
RUN python -m pip install detectron2 -f https://dl.fbaipublicfiles.com/detectron2/wheels/cu102/torch1.5/index.html

# For 16bit mixed precision
RUN git clone https://github.com/NVIDIA/apex
RUN pip install -v --no-cache-dir --global-option="--cpp_ext" --global-option="--cuda_ext" ./apex
WORKDIR apex
RUN git reset --hard 3fe10b5597ba14a748ebb271a6ab97c09c5701ac
RUN pip install -v --no-cache-dir --global-option="--cpp_ext" --global-option="--cuda_ext" ./
WORKDIR /

# add headless support for pyrender
# https://pyrender.readthedocs.io/en/latest/install/index.html
Expand All @@ -91,13 +97,14 @@ RUN apt update -y \
&& apt install -f -y
# install a Compatible Fork of PyOpenGL
RUN git clone https://github.com/mmatl/pyopengl.git \
&& pip install ./pyopengl

&& cd pyopengl \
&& git reset --hard 76d1261 \
&& pip install .

RUN echo "export PATH=$CONDA_PREFIX/bin:$PATH" >> /etc/profile
RUN echo "export PYTHONPATH=/miniconda/envs/lib/python3.6/site-packages:$PYTHONPATH" >> /etc/profile
RUN echo "export NCCL_LL_THRESHOLD=0" >> /etc/profile
RUN echo "umask 002" >> /etc/profile
RUN echo "source activate py36" > ~/.bashrc

ENV NCCL_LL_THRESHOLD=0

2 changes: 1 addition & 1 deletion inference_colmap.py
Original file line number Diff line number Diff line change
Expand Up @@ -171,4 +171,4 @@ def main():
for scene in scenes:
process(scene, args.pathout, args.stride, args.scale)

main()
main()