RuiLiFeng / Deep-Generative-Projection

83 stars 13 forks source link

DGP(Deep Generative Projection) - Official Tensorflow Implementation of CVPR2022 Paper Weakly Supervised High-Fidelity Clothing Model Generation

Weakly Supervised High-Fidelity Clothing Model Generation

In CVPR 2022
[Project Page] [Paper] [Supp] [arxiv]
Clothing Model Generation
Abstract: The development of online economics arouses the demand of generating images of models on product clothes, to display new clothes and promote sales. However, the expensive proprietary model images challenge the existing image virtual try-on methods in this scenario, as most of them need to be trained on considerable amounts of model images accompanied with paired clothes images. In this paper, we propose a cheap yet scalable weakly-supervised method called Deep Generative Projection (DGP) to address this specific scenario. Lying in the heart of the proposed method is to imitate the process of human predicting the wearing effect, which is an unsupervised imagination based on life experience rather than computation rules learned from supervisions. Here a pretrained StyleGAN is used to capture the practical experience of wearing. Experiments show that projecting the rough alignment of clothing and body onto the StyleGAN space can yield photo-realistic wearing results. Experiments on real scene proprietary model images demonstrate the superiority of DGP over several state-of-the-art supervised methods when generating clothing model images.

Installation

Requirements: TensorFlow 1.14, CUDA 10.0, cuDNN 7.5

conda create -n DGP python=3.6 cudatoolkit=10.0
conda activate DGP
pip install -r requirements.txt

Dataset

The E-Shop Fashion (ESF) Dataset

The Commercial Model Image (CMI) Dataset

Dataset Preprocess

The data are organized as follows. Note each model contains a model_info directory, which contains cropped model image and corresponding parsing info. Each model has multiple cloth directories, which contains cloth img, cloth parse, coarse aligned img, and the resudial mask.

data/
  |_model_1/
    |_model_info/
      |_model_img.png
      |_model_parse.png
    |_cloth_1/
      |_cloth_parse.png
      |_coarse_align.png
      |_residual_parse.png
    |_cloth_2/
      ...
  |_model_2/
    ...

We will release the related models and prepsocess scripts to get preprocessed data soon.

TODO List:

Pretrained models

download the pretrained models zip file and unzip to the current directory

unzip pretrained_models.zip

you will get the following models in pretrained_models/:

Run the demo

python deepGenPro.py --cloth_dir=./data/model_1/cloth_1/ --model_dir=./data/model_1/model_info/ --cloth_sleeve=short --output_dir=./output/

the results are in the save file:

Clothing Model Generation

Docker usage

BibTeX

@InProceedings{Feng_2022_CVPR,
    author    = {Feng, Ruili and Ma, Cheng and Shen, Chengji and Gao, Xin and Liu, Zhenjiang and Li, Xiaobo and Ou, Kairi and Zhao, Deli and Zha, Zheng-Jun},
    title     = {Weakly Supervised High-Fidelity Clothing Model Generation},
    booktitle = {Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR)},
    month     = {June},
    year      = {2022},
    pages     = {3440-3449}
}