Code Monkey home page Code Monkey logo

gp-nerf's Introduction

GP-NeRF: Geometry-Guided Progressive NeRF for Generalizable and Efficient Neural Human Rendering (ECCV2022)

Paper

ENV

  • System: Ubuntu 16.04
  • Nvidia: TITAN Xp
  • Torch version: 1.4.0+cu100, torchvision: 0.4.0

Install Env

We provide two ways to install the environment:

  1. Conda-based:
conda create -n gpnerf python=3.7
conda activate gpnerf

# make sure that the pytorch cuda is consistent with the system cuda
# e.g., if your system cuda is 10.0, install torch 1.4 built from cuda 10.0
pip install torch==1.4.0+cu100 -f https://download.pytorch.org/whl/torch_stable.html
pip install -r requirements.txt

# Install spconv
git clone https://github.com/traveller59/spconv --recursive
cd spconv
git checkout abf0acf30f5526ea93e687e3f424f62d9cd8313a
export CUDA_HOME="/usr/local/cuda-10.0"
python setup.py bdist_wheel
cd dist
pip install spconv-1.2.1-cp36-cp36m-linux_x86_64.whl
  1. Docker-based:
docker pull caiyj/neuralbody:imi-server
# if there's any problem with spconv, try the following commands
cd ~/spconv
python setup.py bdist_wheel
cd dist
pip uninstall spconv-1.2.1-cp36-cp36m-linux_x86_64.whl
pip install spconv-1.2.1-cp36-cp36m-linux_x86_64.whl
pip install yacs

Set up datasets

  1. Download the ZJU-Mocap dataset here.
  2. Create a soft link:
    ROOT=/path/to/neuralbody
    cd $ROOT/data
    ln -s /path/to/zju_mocap zju_mocap
    

Train

Train on ZJU-Mocap dataset, eval on ZJU-Mocap dataset:

CUDA_VISIBLE_DEVICES=0 python tools/train.py -cfg configs/trainzju_valzju.yaml

Train on THuman dataset, eval on ZJU-Mocap dataset:

CUDA_VISIBLE_DEVICES=0 python3 tools/train.py --cfg configs/trainthu_valzju.yaml

Evaluation and Visualization

Train on ZJU-Mocap dataset, eval on ZJU-Mocap dataset:

CUDA_VISIBLE_DEVICES=0 python3 tools/inference.py --cfg configs/trainzju_valzju.yaml render.resume_path checkpoints/cam3zju_zjuval_70.pth test.test_seq 'demo_zjutrain_zjuval' dataset.test.seq_list "'CoreView_387', 'CoreView_393', 'CoreView_392'," \ test.is_vis True dataset.test.sampler 'FrameSampler' dataset.test.shuffle False render.file 'demo_render'

Train on THuman dataset, eval on ZJU-Mocap dataset:

CUDA_VISIBLE_DEVICES=0 python3 tools/inference.py --cfg configs/trainthu_valzju.yaml render.resume_path checkpoints/cam3thu_zjuval_dim16_100.pth test.test_seq 'demo_thutrain_zjuval' dataset.test.seq_list "'CoreView_387', 'CoreView_393', 'CoreView_392'," \ test.is_vis True dataset.test.sampler 'FrameSampler' dataset.test.shuffle False render.file 'demo_render' head.sigma.code_dim 16

Visualization setting: test.is_vis = True, visualization dir path = [result_dir]/[test.test_seq].

We have provided two pretrained weights files and the corresponding training logs and visualization results here for reference.

Notice

  • If loading the provided checkpoint, please make sure the version of PyTorch and spconv are consistent with the provided code.
  • You can change the dataset root by modifying dataset.train.data_root and dataset.test.data_root in the config file.
  • Please set dataset.test.sampler to '' if you want to test every frame of the test set.
  • To ensure the testing performance, the environment especially PyTorch version and spconv version should be consistent between the training and testing.

Acknowledgement

BibTex

Please cite this paper if you find the code/model helpful in your research:

@inproceedings{chen2022gpnerf,
	title={Geometry-guided progressive NeRF for generalizable and efficient neural human rendering},
	author={Chen, Mingfei and Zhang, Jianfeng and Xu, Xiangyu and Liu, Lijuan and Cai, Yujun and Feng, Jiashi and Yan, Shuicheng},
	booktitle={ECCV},
	year={2022}
}

gp-nerf's People

Contributors

jiabinliang avatar sewformer avatar xuxy09 avatar yoyomimi avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

gp-nerf's Issues

The error about the spconv

Hi, when I used the docker-based, I have troubled in the error about the spconv. However, after trying the provided command in 'Readme', I haven't solved this error. Would you like to help me to solve this. Thank you.
Best wishes.

How to perform full evaluation?

Hi,
Thanks for your great job.
May I ask how to perform full evaluation under different settings as in the paper?
Thanks,

Training error problems

A separate GPU is used for training, and "assert self._parent_pid == os.getpid(), can only test a child process" is displayed at the end of the first epoch. How to solved it?

Progressive rendering step

Hi Xiangyu,
Thanks for inspiring work! I am a little confused about the Progressive Rendering step. Does it exist only in the test time since with code demo_render.py? It seems that in the training Base_Render.py, the only function to speed up the rendering process is to mask out the sampled points with less than 2 observations. Am I missing something? Thanks!

The training and testing human id are not consistent with NHP.

Hi,

It seems that the human split in ZjumocapDataset.py is not in line with the one used in NHP?
For example, the human used for training in GP-NeRF is 313, 377, 394, 315, 386, 390, while NHP uses 313, 377, 315, 386, 390, 392, 396 for training.

Best,

Thuman dataset

Hi, is it possible to release the preprocessed Thuman datasets with rendered images and cameras or the preprocessing steps which are compatible with the current CustomDataset.py? Thanks!

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.