Photo2Model is a complete 3D reconstruction pipeline based on COLMAP and PointMVSNet that only requires a set of photos as inputs.
- COLMAP, tested under versions >= 3.6
git clone https://github.com/PKU-VCL-3DV/MVS.git && cd MVSbash ./install_dependencies.shCompile CUDA extensions
bash ./compile.shPhotos 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.pyOR, to delete the unrenamed photos,
python ./renamePhotos.py -dThis 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.shpython ./colmap2matrices.pyRemember 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.pthTo convert the depth maps into a complete 3D model, run
python fuse_depthmaps.py