Git Product home page Git Product logo

pixel-gs's Introduction

Pixel-GS

Density Control with Pixel-aware Gradient for 3D Gaussian Splatting

Zheng Zhang1 · Wenbo Hu2+ · Yixing Lao1 · Tong He3 · Hengshuang Zhao1+

1The University of Hong Kong · 2Tencent AI Lab · 3Shanghai AI Lab

+corresponding authors

3DGS* Pixel-GS

3DGS* (left) tends to exhibit blurring and needle-like artifacts in areas with insufficient point cloud initialization, while Pixel-GS (right) by considering the conditions for point cloud growth from the pixel perspective effectively models these areas. * indicates retraining for better performance.

Installation

conda create -n pixelgs python=3.9 -y

conda install pytorch==2.0.1 torchvision==0.15.2 torchaudio==2.0.2 pytorch-cuda=11.8 -c pytorch -c nvidia

pip install -r requirements.txt

cd submodules
pip install ./diff-gaussian-rasterization
pip install ./simple-knn

Dataset

Mip-NeRF 360 Dataset

Please download the Mip-NeRF 360 dataset processed by colmap from Mip-NeRF 360, and after unzipping "Dataset Pt. 1" and "Dataset Pt. 2", combine the scenes. Finally, the current directory should contain the following folders:

Pixel-GS
|---360_v2
    |---bicycle
    |   |---images
    |   |   |---<image 0>
    |   |   |---<image 1>
    |   |   |---...
    |   |---images_2
    |   |---images_4
    |   |---images_8
    |   |---sparse
    |       |---0
    |           |---cameras.bin
    |           |---images.bin
    |           |---points3D.bin
    |---bonsai
    |---...

Tanks and Temples Dataset

Option 1

The processed Tanks and Temples dataset is available for direct download via OneDrive. Please agree the official license before download it.

Option 2

Tanks and Temples is divided into three parts, comprising a total of 21 scenes: Intermediate ('Family', 'Francis', 'Horse', 'Lighthouse', 'M60', 'Panther', 'Playground', 'Train'), Advanced ('Auditorium', 'Ballroom', 'Courtroom', 'Museum', 'Palace', 'Temple'), and Training Data ('Barn', 'Caterpillar', 'Church', 'Courthouse', 'Ignatius', 'Meetingroom', 'Truck').

Please download the "image set" of all scenes from the Tanks and Temples dataset from Tanks and Temples. After unzipping, rename the image folder directories of all scenes to "input". The organized folder structure is as follows:

Pixel-GS
|---tanks_and_temples
    |---Auditorium
    |   |---input
    |   |   |---<image 0>
    |   |   |---<image 1>
    |   |   |---...
    |---Ballroom
    |---...

After configuring libraries such as colmap according to the method in the original 3DGS code, use the following command to generate camera poses for all scenes in Tanks and Temples:

python ./prepose.py

Finally, the current directory should contain the following folders:

Pixel-GS
|---tanks_and_temples
    |---Auditorium
    |   |---images
    |   |   |---<image 0>
    |   |   |---<image 1>
    |   |   |---...
    |   |---images_2
    |   |---images_4
    |   |---images_8
    |   |---sparse
    |       |---0
    |           |---cameras.bin
    |           |---images.bin
    |           |---points3D.bin
    |---Ballroom
    |---...

Then, you need to rename the folder 'images_2' to 'images', since the resolution we are working with is close to 980x545. You can also avoid renaming by simply changing factors = [1] * len(scenes) to factors = [2] * len(scenes) in ./script/tanks_and_temples.py. This modification will instruct the code to reshape the images upon loading during training.

Your Own Dataset

Our method requires the same data format as 3DGS. For your own data, you can use the processing method found in the "Processing your own Scenes" section of the original 3DGS code.

Training and Evaluation

We have written two scripts that can run the training and testing for all scenes of the Mip-NeRF 360 dataset and the Tanks and Temples dataset with a single command. The launch instructions are as follows:

# Mip-NeRF 360
python ./script/mipnerf360.py
# Tanks and Temples
python ./script/tanks_and_temples.py

For training and testing individual scenes, our commands are identical to those in the original 3DGS code. For details, please refer to Running and Evaluation.

Viewer

Since the rendering process and point cloud storage format of our method are identical to those of the original 3DGS, our method can use the same viewer as the original 3DGS. For specific usage tutorials, please refer to Interactive Viewers.

Acknowledgements

This project is built upon 3DGS. Please follow the license of 3DGS. We thank all the authors for their great work and repos.

Citation

If you find this project useful, please consider citing:

@article{zhang2024pixelgs,
  title     = {Pixel-GS: Density Control with Pixel-aware Gradient for 3D Gaussian Splatting},
  author    = {Zhang, Zheng and Hu, Wenbo and Lao, Yixing and He, Tong and Zhao, Hengshuang},
  journal   = {arXiv:2403.15530},
  year      = {2024},
}

pixel-gs's People

Contributors

zhengzhang01 avatar nickisdope avatar wbhu avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.