Ezi commited on
Commit
f8c808b
1 Parent(s): 24cd2c4

Model Card

Browse files

Hello hello!
This PR has a preliminary model card, based on the format we are using as part of our effort to standardisee model cards at Hugging Face. Please see this [doc of an annotated model card](https://huggingface.co/docs/hub/model-card-annotated)
Any additions, inputs and/or edits are greatly welcomed 🤗

Files changed (1) hide show
  1. README.md +242 -0
README.md CHANGED
@@ -0,0 +1,242 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ license: mit
3
+ library_name: diffusers
4
+ pipeline_tag: text-to-video
5
+ ---
6
+
7
+ # Model Card for FollowYourPose V1
8
+
9
+ <!-- Provide a quick summary of what the model is/does. -->
10
+
11
+ ## Model Details
12
+
13
+ ### Model Description
14
+
15
+ <!-- Provide a longer summary of what this model is. -->
16
+ The authors note in the [assoicated paper](https://arxiv.org/abs/2304.01186):
17
+ >**Pose-Guided Text-to-Video Generation**.
18
+ > We propose an efficient training scheme to empower the ability of the pretrained text-to-image model (i.e., Stable Diffusion) to generate pose-controllable character videos with minimal data requirements.
19
+ > We can generate various high-definition pose-controllable character videos that are well-aligned with the pose sequences and the semantics of text prompts.
20
+
21
+
22
+ - **Developed by:** [Yue Ma](https://mayuelala.github.io/), [Yingqing He](https://github.com/YingqingHe), [Xintao Wang](https://xinntao.github.io/), [Ying Shan](https://scholar.google.com/citations?user=4oXBp9UAAAAJ&hl=zh-CN), [Xiu Li](https://scholar.google.com/citations?user=Xrh1OIUAAAAJ&hl=zh-CN), [Qifeng Chen](http://cqf.io)
23
+ - **Shared by:** [Yue (Jack) Ma](https://mayuelala.github.io)
24
+ - **Model type:** Text-to-Video
25
+ - **Language(s) (NLP):** [More Information Needed]
26
+ - **License:** MIT
27
+ - **Finetuned from model:** [Stable Diffusion T2I](https://huggingface.co/CompVis/stable-diffusion-v1-4)
28
+
29
+ ### Model Sources
30
+
31
+ <!-- Provide the basic links for the model. -->
32
+
33
+ - **Repository:** [GitHub Repo](https://github.com/mayuelala/FollowYourPose)
34
+ - **Paper:** [Associated Paper](https://arxiv.org/abs/2304.01186)
35
+ - **Demo:** [HF Demo](https://huggingface.co/spaces/YueMafighting/FollowYourPose)
36
+
37
+ ## Uses
38
+
39
+ <!-- Address questions around how the model is intended to be used, including the foreseeable users of the model and those affected by the model. -->
40
+
41
+ ### Direct Use
42
+
43
+ <!-- This section is for the model use without fine-tuning or plugging into a larger ecosystem/app. -->
44
+
45
+ Text to Video
46
+
47
+ ### Downstream Use
48
+
49
+ - Character replacement
50
+ - Background change
51
+ - Style transfer
52
+ - Multiple characters
53
+
54
+
55
+ ### Out-of-Scope Use
56
+
57
+ <!-- This section addresses misuse, malicious use, and uses that the model will not work well for. -->
58
+
59
+ *Note: This section as adpated from the [Stable Diffusion v1 model card](https://huggingface.co/CompVis/stable-diffusion-v1-4).*
60
+ The model was not trained to be factual or true representations of people or events, and therefore using the model to generate such content is out-of-scope for the abilities of this model.
61
+
62
+ ## Bias, Risks, and Limitations
63
+
64
+ <!-- This section is meant to convey both technical and sociotechnical limitations. -->
65
+
66
+ *Note: This section is adpted from the [DALLE-MINI model card](https://huggingface.co/dalle-mini/dalle-mini).*
67
+
68
+ The model should not be used to intentionally create or disseminate videos that create hostile or alienating environments for people. This includes generating videos that people would foreseeably find disturbing, distressing, or offensive; or content that propagates historical or current stereotypes.
69
+
70
+
71
+
72
+ ### Recommendations
73
+
74
+ <!-- This section is meant to convey recommendations with respect to the bias, risk, and technical limitations. -->
75
+
76
+ Users (both direct and downstream) should be made aware of the risks, biases and limitations of the model. More information needed for further recommendations.
77
+
78
+ ## How to Get Started with the Model
79
+
80
+ Use the code below to get started with the model.
81
+
82
+ ```python
83
+ from diffusers import DiffusionPipeline
84
+
85
+ pipeline = DiffusionPipeline.from_pretrained("YueMafighting/FollowYourPose_v1")
86
+ ```
87
+
88
+ ## Training Details
89
+
90
+ ### Training Data
91
+
92
+ <!-- This should link to a Data Card, perhaps with a short stub of information on what the training data is all about as well as documentation related to data pre-processing or additional filtering. -->
93
+ **Stage 1 Training Data:** Pose-Controllable Text-to-Image Gen- eration.
94
+ The authors note in the [assoicated paper](https://arxiv.org/abs/2304.01186) that they colected
95
+ > the human skeleton images in the **LAION** by Mpose, only retaining images that could be detected more than 50% of the key point
96
+ > which formed a dataset named LAION-Pose from.
97
+
98
+ The autheors note in the [associated paper](https://arxiv.org/abs/2304.01186) about LAION-Pose:
99
+ > This dataset contains diverse human-like characters with various back- ground contexts.
100
+
101
+ **Stage 2 Training Data: Video Generation via Pose-free Videos.**
102
+ > However, the stage 1 model can generate similar pose videos yet the background is inconsistent.
103
+ > Thus, we further finetune the model from our first stage on the pose- free video dataset **HDVLIA**
104
+ > This dataset contains con- tinuous in-the-wild video text pairs.
105
+
106
+ ### Training Procedure
107
+
108
+ <!-- This relates heavily to the Technical Specifications. Content here should link to that section when it is relevant to the training procedure. -->
109
+
110
+ #### Preprocessing
111
+
112
+ The authors note in the [assoicated paper](https://arxiv.org/abs/2304.01186):
113
+ >We learn a zero-initialized convolutional encoder to encode the pose information
114
+ >We finetune the motion of the above network via a pose-free video dataset by adding the learnable temporal self-attention and reformed cross-frame self-attention blocks.
115
+
116
+
117
+ #### Training Hyperparameters
118
+
119
+ - **Training regime:** [More Information Needed] <!--fp32, fp16 mixed precision, bf16 mixed precision, bf16 non-mixed precision, fp16 non-mixed precision, fp8 mixed precision -->
120
+
121
+ #### Speeds, Sizes, Times [optional]
122
+
123
+ <!-- This section provides information about throughput, start/end time, checkpoint size if relevant, etc. -->
124
+
125
+ [More Information Needed]
126
+
127
+ ## Evaluation
128
+
129
+ <!-- This section describes the evaluation protocols and provides the results. -->
130
+
131
+ ### Testing Data, Factors & Metrics
132
+
133
+ #### Testing Data
134
+
135
+ <!-- This should link to a Data Card if possible. -->
136
+
137
+ [More Information Needed]
138
+
139
+ #### Factors
140
+
141
+ <!-- These are the things the evaluation is disaggregating by, e.g., subpopulations or domains. -->
142
+
143
+ [More Information Needed]
144
+
145
+ #### Metrics
146
+
147
+ <!-- These are the evaluation metrics being used, ideally with a description of why. -->
148
+ The authors note in the [assoicated paper](https://arxiv.org/abs/2304.01186):
149
+ > - **CLIP score (CS):** CLIP score or video-text alignment. We compute CLIP score for each frame and then average them across all frames.
150
+ > The final CLIP score is calculated on 1024 video samples.
151
+ > - **Quality (QU):** We conduct the human evaluation of videos’ quality across a test set containing 32 videos.
152
+ > In detail, we display three videos in random order and request the evaluators to iden- tify the one with superior quality
153
+ > - **Pose Accuracy (FQ):** We regard the input pose sentence as ground truth video and evaluate the average precision of the skeleton on 1024 video samples.
154
+ > For a fair comparison, we adopt the same pose detector for both the processing of LAION-Pose collecting and evaluation.
155
+ > - **Frame Consistency (FC):** Following we report frame consistency measured via CLIP cosine similarity of consecutive frames
156
+
157
+ ### Results
158
+
159
+ | Method | CS | QU (%) | PA (%) | FC (%) |
160
+ |----------------|-----------|-----------|-----------|-----------|
161
+ | Tune-A-Video | 23.57 | 34.81 | 27.74 | **93.78** |
162
+ | ControlNet | 22.31 | 6.69 | 33.23 | 54.35 |
163
+ | T2I adapter | 22.42 | 8.27 | 33.47 | 53.86 |
164
+ | FollowYourPose | **24.09** | **50.23** | **34.92** | 93.36 |
165
+
166
+ #### Summary
167
+
168
+
169
+
170
+ ## Model Examination [optional]
171
+
172
+ <!-- Relevant interpretability work for the model goes here -->
173
+
174
+ [More Information Needed]
175
+
176
+ ## Environmental Impact
177
+
178
+ <!-- Total emissions (in grams of CO2eq) and additional considerations, such as electricity usage, go here. Edit the suggested text below accordingly -->
179
+
180
+ Carbon emissions can be estimated using the [Machine Learning Impact calculator](https://mlco2.github.io/impact#compute) presented in [Lacoste et al. (2019)](https://arxiv.org/abs/1910.09700).
181
+
182
+ - **Hardware Type:** 8 NVIDIA Tesla 40G-A100 GPUs
183
+ - **Hours used:** 48
184
+ - **Cloud Provider:** [More Information Needed]
185
+ - **Compute Region:** [More Information Needed]
186
+ - **Carbon Emitted:** [More Information Needed]
187
+
188
+ ## Technical Specifications [optional]
189
+
190
+ ### Model Architecture and Objective
191
+ The authors note in the [assoicated paper](https://arxiv.org/abs/2304.01186):
192
+ > To make the pre-trained T2I model suitable for video inputs, we make several key modifications.
193
+ > Firstly, we add extra temporal self-attention layers, to the stable diffusion network.
194
+ > Secondly, inspired by the recent one-shot video generation model, we reshape the attention to cross-frame attention for better content consistency.
195
+
196
+ ### Compute Infrastructure
197
+
198
+ [More Information Needed]
199
+
200
+ #### Hardware
201
+
202
+ [More Information Needed]
203
+
204
+ #### Software
205
+
206
+ [More Information Needed]
207
+
208
+ ## Citation [optional]
209
+
210
+ <!-- If there is a paper or blog post introducing the model, the APA and Bibtex information for that should go in this section. -->
211
+
212
+ **BibTeX:**
213
+ ```bibtex
214
+ @article{ma2023follow,
215
+ title={Follow Your Pose: Pose-Guided Text-to-Video Generation using Pose-Free Videos},
216
+ author={Ma, Yue and He, Yingqing and Cun, Xiaodong and Wang, Xintao and Shan, Ying and Li, Xiu and Chen, Qifeng},
217
+ journal={arXiv preprint arXiv:2304.01186},
218
+ year={2023}
219
+ }
220
+ ```
221
+
222
+ **APA:**
223
+
224
+ [More Information Needed]
225
+
226
+ ## Glossary [optional]
227
+
228
+ <!-- If relevant, include terms and calculations in this section that can help readers understand the model or model card. -->
229
+
230
+ [More Information Needed]
231
+
232
+ ## More Information [optional]
233
+
234
+ [More Information Needed]
235
+
236
+ ## Model Card Authors [optional]
237
+
238
+ [Yue Ma](mailto:[email protected]) in collaberation with [Ezi Ozoani](https://huggingface.co/Ezi) and the Hugging Face team.
239
+
240
+ ## Model Card Contact
241
+
242
+ If you have any questions or ideas to discuss, feel free to contact [Yue Ma](mailto:[email protected]) or [Yingqing He](https://github.com/YingqingHe) or [Xiaodong Cun](mailto:[email protected]).