Sign inSign up

hccz95/mattersim

By hccz95

•Updated 11 months ago

Image
1

3.7K

hccz95/mattersim repository overview

⁠tag:18.04

# ubuntu:18.04 + web vnc作为基础镜像
FROM ubuntu:18.04

# 安装依赖
RUN apt-get update && \
    DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
        wget doxygen curl \
        libjsoncpp-dev libepoxy-dev \
        libglm-dev libosmesa6 libosmesa6-dev libegl1-mesa-dev libglew-dev \
        libopencv-dev python3-opencv python3-dev python3-pip \
        build-essential cmake git unzip && \
    apt-get clean && rm -rf /var/lib/apt/lists/*

ENV PYTHONPATH=/root/mount/Matterport3DSimulator/build

# 克隆并编译Matterport3DSimulator
RUN git clone --recursive https://github.com/peteanderson80/Matterport3DSimulator.git /root/mount/Matterport3DSimulator && \
    cd /root/mount/Matterport3DSimulator && \
    mkdir build && cd build && \
    cmake -DEGL_RENDERING=ON .. && \
    make

# 下载并解压数据集,仅下载了两个房间(1LXtFkjw3qL和pa4otMbVnkk)的matterport_skybox_images和undistorted_camera_parameters
RUN wget http://kaldir.vc.in.tum.de/matterport/download_mp.py && \
    sed -i 's/^\(.*key = raw_input.*\)$/#\1/' download_mp.py && \
    python2 download_mp.py -o /root/mount/Matterport3DSimulator/data --type matterport_skybox_images --id 1LXtFkjw3qL && \
    python2 download_mp.py -o /root/mount/Matterport3DSimulator/data --type undistorted_camera_parameters --id 1LXtFkjw3qL && \
    python2 download_mp.py -o /root/mount/Matterport3DSimulator/data --type matterport_skybox_images --id pa4otMbVnkk && \
    python2 download_mp.py -o /root/mount/Matterport3DSimulator/data --type undistorted_camera_parameters --id pa4otMbVnkk && \
    cd /root/mount/Matterport3DSimulator/data/v1/scans && \
    unzip 1LXtFkjw3qL/matterport_skybox_images.zip && \
    unzip 1LXtFkjw3qL/undistorted_camera_parameters.zip && \
    unzip pa4otMbVnkk/matterport_skybox_images.zip && \
    unzip pa4otMbVnkk/undistorted_camera_parameters.zip && \
    rm ./*/*.zip

# 数据预处理(运行demo之前必须的步骤),由于我们只下载了两个房间的数据集,因此需要修改scans.txt文件
RUN cd /root/mount/Matterport3DSimulator/connectivity && \
    mv scans.txt scans.txt.bak && \
    echo "1LXtFkjw3qL\npa4otMbVnkk" > scans.txt && \
    pip3 install --only-binary=:all: opencv-python && \
    cd /root/mount/Matterport3DSimulator/ && \
    python3 scripts/downsize_skybox.py

⁠tag:webvnc

# ubuntu:18.04 + web vnc作为基础镜像
FROM dorowu/ubuntu-desktop-lxde-vnc:bionic

# 安装依赖
RUN apt-get update && \
    DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
        wget doxygen curl \
        libjsoncpp-dev libepoxy-dev \
        libglm-dev libosmesa6 libosmesa6-dev libegl1-mesa-dev libglew-dev \
        libopencv-dev python3-opencv python3-dev python3-pip \
        build-essential cmake git unzip && \
    apt-get clean && rm -rf /var/lib/apt/lists/*

ENV PYTHONPATH=/root/mount/Matterport3DSimulator/build

# 克隆并编译Matterport3DSimulator
RUN git clone --recursive https://github.com/peteanderson80/Matterport3DSimulator.git /root/mount/Matterport3DSimulator && \
    cd /root/mount/Matterport3DSimulator && \
    mkdir build && cd build && \
    cmake -DEGL_RENDERING=ON .. && \
    make

# 下载并解压数据集,仅下载了两个房间(1LXtFkjw3qL和pa4otMbVnkk)的matterport_skybox_images和undistorted_camera_parameters
RUN wget http://kaldir.vc.in.tum.de/matterport/download_mp.py && \
    sed -i 's/^\(.*key = raw_input.*\)$/#\1/' download_mp.py && \
    python2 download_mp.py -o /root/mount/Matterport3DSimulator/data --type matterport_skybox_images --id 1LXtFkjw3qL && \
    python2 download_mp.py -o /root/mount/Matterport3DSimulator/data --type undistorted_camera_parameters --id 1LXtFkjw3qL && \
    python2 download_mp.py -o /root/mount/Matterport3DSimulator/data --type matterport_skybox_images --id pa4otMbVnkk && \
    python2 download_mp.py -o /root/mount/Matterport3DSimulator/data --type undistorted_camera_parameters --id pa4otMbVnkk && \
    cd /root/mount/Matterport3DSimulator/data/v1/scans && \
    unzip 1LXtFkjw3qL/matterport_skybox_images.zip && \
    unzip 1LXtFkjw3qL/undistorted_camera_parameters.zip && \
    unzip pa4otMbVnkk/matterport_skybox_images.zip && \
    unzip pa4otMbVnkk/undistorted_camera_parameters.zip && \
    rm ./*/*.zip

# 数据预处理(运行demo之前必须的步骤),由于我们只下载了两个房间的数据集,因此需要修改scans.txt文件
RUN cd /root/mount/Matterport3DSimulator/connectivity && \
    mv scans.txt scans.txt.bak && \
    echo "1LXtFkjw3qL\npa4otMbVnkk" > scans.txt && \
    pip3 install --only-binary=:all: opencv-python && \
    cd /root/mount/Matterport3DSimulator/ && \
    python3 scripts/downsize_skybox.py

⁠tag: py38

FROM hccz95/ubuntu:18.04-py38

RUN apt-get update && \
    DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
        wget doxygen curl libjsoncpp-dev libepoxy-dev libglm-dev libosmesa6 libosmesa6-dev libegl1-mesa-dev libglew-dev libopencv-dev python3-opencv python3-dev build-essential cmake && \
    apt-get clean && rm -rf /var/lib/apt/lists/*

ENV PYTHONPATH=/root/mount/Matterport3DSimulator/build

RUN mkdir /root/mount && cd /root/mount && \
    git clone https://github.com/peteanderson80/Matterport3DSimulator --recursive
RUN rm /usr/bin/python3.6
RUN cd /root/mount/Matterport3DSimulator && \
    mkdir build && cd build && \
    cmake -DEGL_RENDERING=ON .. && \
    make && \
    cd ../

tag: all

FROM hccz95/mattersim:20.04

RUN cd /root/mount/Matterport3DSimulator && \
    git remote set-url origin https://github.com/xmlnudt/Matterport3DSimulator && \
    git pull origin master

RUN pip install --no-cache-dir --only-binary=:all: opencv-python pandas

RUN apt-get update && apt-get install -y python2-dev

# 下载并解压数据集,仅下载了两个房间(1LXtFkjw3qL和pa4otMbVnkk)的matterport_skybox_images和undistorted_camera_parameters
RUN wget http://kaldir.vc.in.tum.de/matterport/download_mp.py && \
    sed -i 's/^\(.*key = raw_input.*\)$/#\1/' download_mp.py && \
    python2 download_mp.py -o /root/mount/Matterport3DSimulator/data --type matterport_skybox_images --id 1LXtFkjw3qL && \
    python2 download_mp.py -o /root/mount/Matterport3DSimulator/data --type undistorted_camera_parameters --id 1LXtFkjw3qL && \
    python2 download_mp.py -o /root/mount/Matterport3DSimulator/data --type matterport_skybox_images --id pa4otMbVnkk && \
    python2 download_mp.py -o /root/mount/Matterport3DSimulator/data --type undistorted_camera_parameters --id pa4otMbVnkk && \
    cd /root/mount/Matterport3DSimulator/data/v1/scans && \
    unzip 1LXtFkjw3qL/matterport_skybox_images.zip && \
    unzip 1LXtFkjw3qL/undistorted_camera_parameters.zip && \
    unzip pa4otMbVnkk/matterport_skybox_images.zip && \
    unzip pa4otMbVnkk/undistorted_camera_parameters.zip && \
    rm ./*/*.zip

# 数据预处理(运行demo之前必须的步骤),由于我们只下载了两个房间的数据集,因此需要修改scans.txt文件
RUN cd /root/mount/Matterport3DSimulator/connectivity && \
    mv scans.txt scans.txt.bak && \
    echo "1LXtFkjw3qL\npa4otMbVnkk" > scans.txt && \
    pip3 install --only-binary=:all: opencv-python && \
    cd /root/mount/Matterport3DSimulator/ && \
    python3 scripts/downsize_skybox.py

RUN wget https://www.dropbox.com/s/o57kxh2mn5rkx4o/ResNet-152-imagenet.zip && \
    unzip ResNet-152-imagenet.zip -d /root/mount/Matterport3DSimulator/img_features/ && \
    rm ResNet-152-imagenet.zip
RUN cd /root/mount/Matterport3DSimulator && \   
    bash ./tasks/R2R/data/download.sh

RUN pip install --no-cache-dir \
    jsonlines==2.0.0 \
    tqdm==4.62.0 \
    easydict==1.9 \
    Shapely==1.7.1 \
    h5py==2.10.0 \
    torch==1.13 \
    networkx==2.5.1 \
    numpy==1.20.3 \
    tensorboardX==2.4.1 \
    transformers==4.30.0 \
    protobuf==3.20

RUN cd /root/mount/Matterport3DSimulator && \
    git pull origin main

# # for .gitignore_global
# RUN touch /root/.gitignore_global
# RUN echo "/tasks/R2R/" >> /root/.gitignore_global
# RUN git config --global core.excludesfile /root/.gitignore_global

Tag summary

Content type

Image

Digest

sha256:80b05d813…

Size

1.3 GB

Last updated

over 2 years ago

docker pull hccz95/mattersim