Home

Awesome

High-fidelity 3D Human Digitization from Single 2K Resolution Images (2K2K)

This repository contains the code of the 2K2K method for 3D human reconstruction.

Sang-Hun Han, Min-Gyu Park, Ju Hong Yoon, Ju-Mi Kang, Young-Jae Park, and <a href="https://scholar.google.com/citations?user=Ei00xroAAAAJ">Hae-Gon Jeon</a> <br>Accepted to <a href="https://cvpr2023.thecvf.com/">CVPR 2023</a>

<a href="https://arxiv.org/abs/2303.15108">Paper</a> | <a href="https://sanghunhan92.github.io/conference/2K2K/">Project Page</a> | <a href="https://github.com/ketiVision/2K2K">Dataset</a>

<!-- [![report](https://img.shields.io/badge/arxiv-report-red)](https://arxiv.org/abs/2303.15108) --> <br/> <p align="center"> <img src="https://github.com/SangHunHan92/SangHunHan92.github.io/blob/main/imgs/2K2K/hanni_zoom_resize2.gif?raw=true" alt="Sublime's custom image"/> </p> <!-- ![Teaser Image](https://github.com/SangHunHan92/SangHunHan92.github.io/blob/main/imgs/2K2K/hanni_zoom_resize2.gif?raw=true) -->

2K2K Method

<br/> <div align='center'><img src="https://github.com/SangHunHan92/SangHunHan92.github.io/blob/main/imgs/2K2K/Figure_4.png?raw=true" width=100%></div>

Installation

Environment

Ubuntu Installation

apt-get install -y freeglut3-dev libglib2.0-0 libsm6 libxrender1 libxext6 openexr libopenexr-dev libjpeg-dev zlib1g-dev
apt install -y libgl1-mesa-dri libegl1-mesa libgbm1 libgl1-mesa-glx libglib2.0-0
pip install -r requirements.txt

Docker Installation

  1. Create Docker Image From Dockerfile
docker build -t 2k2k:1.0 .
  1. Make Docker Container From Image (example below)
docker run -e NVIDIA_VISIBLE_DEVICES=all -i -t -d --runtime=nvidia --shm-size=512gb --name 2k2k --mount type=bind,source={path/to/2k2k_code},target=/workspace/code 2k2k:1.0 /bin/bash

Dataset Preparing

data
├ IndoorCVPR09
│  ├ airport_inside
│  └ ⋮
├ Joint3D
│  ├ RP
│  └ THuman2
├ list
├ obj
│  ├ RP
│  │  ├ rp_aaron_posed_013_OBJ
│  │  └ ⋮
│  └ THuman2
│     ├ data
│     └ smplx
├ PERS
│  ├ COLOR
│  ├ DEPTH
│  └ keypoint
└ (ORTH)

Background Images

Render Dataset (Image, Depth)

python render/render.py --data_path ./data --data_name RP
python render/render.py --data_path ./data --data_name THuman2 --smpl_model_path {smpl_model_path}

Render Dataset (Keypoint)

unzip data/Joint3D.zip -d data/Joint3D/
<!-- * Download 3D keypoints of RenderPeople and THuman2.0 dataset to `{data_folder}/Joint3D` from `!!!!!!` -->
python render/render_keypoint.py --data_path ./data --data_name RP
python render/render_keypoint.py --data_path ./data --data_name THuman2
<!-- **Baseline models** -->

Model Training

python train.py --data_path ./data --phase 1 --batch_size 1
python train.py --data_path ./data --phase 2 --batch_size 1 --load_ckpt {checkpoint_file_name}
CUDA_VISIBLE_DEVICES=0,1 \
python -m torch.distributed.run \
    --nnodes=1 \
    --nproc_per_node=4 \
    --rdzv_backend=c10d \
    train.py --use_ddp=True

Model Test

bin\OpenPoseDemo.exe --image_dir {test_folder} --write_json {test_folder} --hand --write_images {test_folder}\test --write_images_format jpg
cd checkpoints && wget https://github.com/SangHunHan92/2K2K/releases/download/Checkpoint/ckpt_bg_mask.pth.tar && cd ..
python test_02_model.py --load_ckpt {checkpoint_file_name} --save_path {result_save_folder}
python test_03_poisson.py --save_path {result_save_folder}

2K2K Dataset

Citation

@inproceedings{han2023high,
  title={High-fidelity 3D Human Digitization from Single 2K Resolution Images},
  author={Han, Sang-Hun and Park, Min-Gyu and Yoon, Ju Hong and Kang, Ju-Mi and Park, Young-Jae and Jeon, Hae-Gon},
  booktitle={Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR)},
  year={2023}
}