Sign inSign up

zachduan/3d-vision

By zachduan

•Updated about 2 years ago

A series of mirrors prepared for 3D vision. For example cuda, pytorch, 3DGS, COLMAP, etc.

Image
Machine learning & AI
0

877

zachduan/3d-vision repository overview

⁠Base

nvidia/cuda:11.8.0-cudnn8-devel-ubuntu22.04

⁠Tags

⁠Dockerfile

Build image:

docker build  -t zachduan/3d-vision:cu118-torch21 . --network host

Launch container:

sudo docker run --gpus all -it --ipc=host --ulimit memlock=-1 --ulimit stack=67108864 --user root -v /mnt/:/mnt/ -v ~/workspace/:~/workspace/ --network host zachduan/3d-vision:cu118-torch21

Dockerfile:

FROM nvidia/cuda:11.8.0-cudnn8-devel-ubuntu22.04

# tells docker to use bash as shell and the -c tells bash to run the following command
SHELL ["/bin/bash", "-c"]

# Add some dependencies
RUN sed -i 's#http://archive.ubuntu.com/#http://mirrors.tuna.tsinghua.edu.cn/#' /etc/apt/sources.list

RUN apt-get update && \
    apt-get -y install curl unzip wget git tmux htop vim net-tools openssh-server

# Install Miniconda
RUN wget -c https://repo.anaconda.com/miniconda/Miniconda3-py310_24.1.2-0-Linux-x86_64.sh -O Miniconda.sh && \
    sh Miniconda.sh -b -p /opt/miniconda3 && \
    rm Miniconda.sh && \
    /opt/miniconda3/bin/conda init bash

# ssh server
RUN sed -i 's/#Port 22/Port 2222/' /etc/ssh/sshd_config && \
    mkdir -p /run/sshd && \
    echo "/usr/sbin/sshd" >> ~/.bashrc

# pip and conda config
RUN source /opt/miniconda3/bin/activate && \
    pip install torch==2.1.0 torchvision==0.16.0 torchaudio==2.1.0 -i https://download.pytorch.org/whl/cu118 && \
    pip config set global.index-url https://pypi.tuna.tsinghua.edu.cn/simple && \
    conda config --set show_channel_urls yes && \
    conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main && \
    conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/r && \
    conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/msys2

# if you need tensorflow
# RUN pip install numpy==1.23.5 scipy==1.14.1 tensorflow-gpu==2.10.1

RUN /bin/bash


# # You'd better not install cmake with apt, cmake>=3.24 is better. 
# RUN wget -c https://cmake.org/files/v3.24/cmake-3.24.3-linux-x86_64.sh -O cmake.sh && \
#     sh cmake.sh --skip-license --prefix=/usr/local && \
#     rm cmake.sh
# # COLMAP
# apt-get install \
#     git \
#     ninja-build \
#     build-essential \
#     libboost-program-options-dev \
#     libboost-filesystem-dev \
#     libboost-graph-dev \
#     libboost-system-dev \
#     libeigen3-dev \
#     libflann-dev \
#     libfreeimage-dev \
#     libmetis-dev \
#     libgoogle-glog-dev \
#     libgtest-dev \
#     libsqlite3-dev \
#     libglew-dev \
#     qtbase5-dev \
#     libqt5opengl5-dev \
#     libcgal-dev \
#     libceres-dev
# git clone https://github.com/colmap/colmap.git
# cd colmap
# mkdir build
# cd build
# cmake .. -GNinja
# ninja

Tag summary

Content type

Image

Digest

sha256:40e817e73…

Size

11.6 GB

Last updated

about 2 years ago

docker pull zachduan/3d-vision:cu118-torch21-3dgs