Deformable 3DGS代码Github仓库链接:ingra14m/Deformable-3D-Gaussians: [CVPR 2024] Official implementation of "Deformable 3D Gaussians for High-Fidelity Monocular Dynamic Scene Reconstruction" (github.com)https://github.com/ingra14m/Deformable-3D-Gaussians
Deformable 3DGS论文链接:[2309.13101] Deformable 3D Gaussians for High-Fidelity Monocular Dynamic Scene Reconstruction (arxiv.org)https://arxiv.org/abs/2309.13101
1. 环境配置:
1. 将代码克隆至本地,注意原仓库中有几个子文件是引用的其他仓库 需要使用 --recursive,需要进行递归克隆。
git clone https://github.com/ingra14m/Deformable-3D-Gaussians --recursive
cd Deformable-3D-Gaussians
conda create -n deformable_gaussian_env python=3.7
conda activate deformable_gaussian_env
# install pytorch
pip install torch==1.13.1+cu116 torchvision==0.14.1+cu116 --extra-index-url https://download.pytorch.org/whl/cu116
# Pytorch与cuda版本也不一定非得和这个一模一样, 也可以略高一些
# install dependencies
pip install -r requirements.txt
PS:若克隆速度慢或者无法递归克隆可以直接下载对用的子文件的包,再进行安装:
simple-knn下载链接https://github.com/YixunLiang/simple-knn
注意: 下载diff-gaussian-rasterization的时候,diff-gaussian-rasterization/third_party/glm文件夹可能没有下载,导致安装的时候出现报错,需要找到对应的文件夹重新下载并放到对应目录里,在安装diff-gaussian-rasterization。
glm下载链接https://github.com/g-truc/glm/tree/5c46b9c07008ae65cb81ab79cd677ecc1934b903然后安装diff-gaussian-rasterization 与 simple-knn,进入对应目录,然后执行安装:python setup.py install.
cd diff-gaussian-rasterization
python setup.py install
cd simple-knn
python setup.py install
最后,大家可以自行下载开源数据进行测试。
2. 典型问题及解决方案
出现报错:TypeError: forward() got an unexpected keyword argument 'means2D_densify'
原因:安装的diff-gaussian-rasterization是3dgs原版或其他版本,作者在Deformable 3DGS中对其进行了扩展,请卸载后(pip uninstall diff-gaussian-rasterization),重新安装至正确的版本:
正确版本的diff_gaussian_rasterization/__init__.py中多了means2D_densify