ShineChen1024 commited on
Commit
4632139
ยท
verified ยท
1 Parent(s): 11c07d4

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +117 -1
README.md CHANGED
@@ -2,4 +2,120 @@
2
  license: cc-by-nc-sa-4.0
3
  ---
4
 
5
- Model weights of [Magic Clothing](https://github.com/ShineChen1024/MagicClothing)
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2
  license: cc-by-nc-sa-4.0
3
  ---
4
 
5
+ # Magic Clothing
6
+ This repository is the official implementation of Magic Clothing
7
+
8
+ Magic Clothing is a branch version of [OOTDiffusion](https://github.com/levihsu/OOTDiffusion), focusing on controllable garment-driven image synthesis
9
+
10
+ <!-- Please refer to our [previous paper](https://arxiv.org/abs/2403.01779) for more details -->
11
+
12
+ > **Magic Clothing: Controllable Garment-Driven Image Synthesis** [[arXiv paper](https://arxiv.org/abs/2404.09512)]<br>
13
+ > [Weifeng Chen](https://github.com/ShineChen1024)\*, [Tao Gu](https://github.com/T-Gu)\*, [Yuhao Xu](http://levihsu.github.io/), [Chengcai Chen](https://www.researchgate.net/profile/Chengcai-Chen)<br>
14
+ > \* Equal contribution<br>
15
+ > Xiao-i Research
16
+
17
+
18
+ ## News
19
+ ๐Ÿ”ฅ [2024/4/19] An 1024 version trained on both VTON-HD and DressCode for early access branch is avaliable now!
20
+
21
+ ๐Ÿ”ฅ [2024/4/19] We support AnimateDiff now for generating GIF!
22
+
23
+ ๐Ÿ”ฅ [2024/4/16] Our [paper](https://arxiv.org/abs/2404.09512) is available now!
24
+
25
+ ๐Ÿ”ฅ [2024/3/8] We released the model weights trained on the 768 resolution. The strength of clothing and text prompts can be independently adjusted.
26
+
27
+ ๐Ÿค— [Hugging Face link](https://huggingface.co/ShineChen1024/MagicClothing)
28
+
29
+ ๐Ÿ”ฅ [2024/2/28] We support [IP-Adapter-FaceID](https://huggingface.co/h94/IP-Adapter-FaceID) with [ControlNet-Openpose](https://github.com/lllyasviel/ControlNet-v1-1-nightly)! A portrait and a reference pose image can be used as additional conditions.
30
+
31
+ Have fun with ***gradio_ipadapter_openpose.py***
32
+
33
+ ๐Ÿ”ฅ [2024/2/23] We support [IP-Adapter-FaceID](https://huggingface.co/h94/IP-Adapter-FaceID) now! A portrait image can be used as an additional condition.
34
+
35
+ Have fun with ***gradio_ipadapter_faceid.py***
36
+
37
+ ![demo](images/demo.png)&nbsp;
38
+ ![workflow](images/workflow.png)&nbsp;
39
+
40
+ ***1024 version for upper-body lower-body and full-body clothes Demo***
41
+ <div align="left">
42
+ <img src="images/a0.jpg" alt="ๅ›พ็‰‡1" width="15%">
43
+ <img src="images/a1.png" alt="ๅ›พ็‰‡2" width="15%">
44
+ <img src="images/b0.jpg" alt="ๅ›พ็‰‡3" width="15%">
45
+ <img src="images/b1.png" alt="ๅ›พ็‰‡4" width="15%">
46
+ <img src="images/c0.jpg" alt="ๅ›พ็‰‡5" width="15%">
47
+ <img src="images/c1.png" alt="ๅ›พ็‰‡6" width="15%">
48
+ </div>
49
+
50
+ ***AnimateDiff Demo*** 'a beautiful girl with a smile'
51
+ <div align="center">
52
+ <img src="valid_cloth/t1.png" width="15%">
53
+ <img src="images/animatediff0.gif" alt="ๅ›พ็‰‡1" width="15%">
54
+ <img src="valid_cloth/t6.png" width="15%">
55
+ <img src="images/animatediff1.gif" alt="ๅ›พ็‰‡2" width="15%">
56
+ <img src="valid_cloth/t7.jpg" width="13%">
57
+ <img src="images/animatediff2.gif" alt="ๅ›พ็‰‡3" width="15%">
58
+ </div>
59
+
60
+ ## Installation
61
+
62
+ 1. Clone the repository
63
+
64
+ ```sh
65
+ git clone https://github.com/ShineChen1024/MagicClothing.git
66
+ ```
67
+
68
+ 2. Create a conda environment and install the required packages
69
+
70
+ ```sh
71
+ conda create -n magicloth python==3.10
72
+ conda activate magicloth
73
+ pip install torch==2.0.1 torchvision==0.15.2 numpy==1.25.1 diffusers==0.25.1 opencv-python==4.9.0.80 transformers==4.31.0 gradio==4.16.0 safetensors==0.3.1 controlnet-aux==0.0.6 accelerate==0.21.0
74
+ ```
75
+
76
+ ## Inference
77
+
78
+ 1. Python demo
79
+
80
+ > 512 weights
81
+
82
+ ```sh
83
+ python inference.py --cloth_path [your cloth path] --model_path [your model checkpoints path]
84
+ ```
85
+
86
+ > 768 weights
87
+
88
+ ```sh
89
+ python inference.py --cloth_path [your cloth path] --model_path [your model checkpoints path] --enable_cloth_guidance
90
+ ```
91
+
92
+ 2. Gradio demo
93
+
94
+ > 512 weights
95
+
96
+ ```sh
97
+ python gradio_generate.py --model_path [your model checkpoints path]
98
+ ```
99
+
100
+ > 768 weights
101
+
102
+ ```sh
103
+ python gradio_generate.py --model_path [your model checkpoints path] --enable_cloth_guidance
104
+ ```
105
+
106
+ ## Citation
107
+ ```
108
+ @article{chen2024magic,
109
+ title={Magic Clothing: Controllable Garment-Driven Image Synthesis},
110
+ author={Chen, Weifeng and Gu, Tao and Xu, Yuhao and Chen, Chengcai},
111
+ journal={arXiv preprint arXiv:2404.09512},
112
+ year={2024}
113
+ }
114
+ ```
115
+
116
+ ## TODO List
117
+ - [x] Paper
118
+ - [x] Gradio demo
119
+ - [x] Inference code
120
+ - [x] Model weights
121
+ - [ ] Training code