Skip to content

XYZ-99/MVS

Repository files navigation

Photo2Model-MVS

Photo2Model is a complete 3D reconstruction pipeline based on COLMAP and PointMVSNet that only requires a set of photos as inputs.

display

Prerequisite

  • COLMAP, tested under versions >= 3.6

Download

git clone https://github.com/PKU-VCL-3DV/MVS.git && cd MVS

Install Dependencies

bash ./install_dependencies.sh

Compile CUDA extensions

bash ./compile.sh

Photo2Model

Photos

Photos should be placed under ./data/images. Make sure that photos are named in an ordered {:08d}.png(or {:08d}.jpg) format, starting from 00000000.png(or 00000000.jpg).

To help rename your photos, EITHER run

python ./renamePhotos.py

OR, to delete the unrenamed photos,

python ./renamePhotos.py -d

COLMAP

This step requires a GPU, so make sure to check the script before you run on the specified GPU. To calibrate the cameras using COLMAP, run

bash ./runCOLMAP.sh

Convert Parameters into Matrices

python ./colmap2matrices.py

PointMVSNet

Remember to adjust the image resolution and the number of virtual planes in ./configs/photo2model.yaml.

Under the conda environment Photo2Model, run

python pointmvsnet/test.py --cfg configs/photo2model.yaml TEST.WEIGHT ./model.pth

Fuse

To convert the depth maps into a complete 3D model, run

python fuse_depthmaps.py

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages