kakaobrain / flame

Official implementation of the paper "FLAME: Free-form Language-based Motion Synthesis & Editing"
https://kakaobrain.github.io/flame/
Apache License 2.0
108 stars 6 forks source link

classifier free guidance #14

Closed hyung-gun closed 1 year ago

hyung-gun commented 1 year ago

Hello,

I appreciate your great work on the project. I have a question regarding the sampling code for generating motion from the text.

The code snippet in 'sample_util.py' half_eps = uncond_eps + guidance_scale * (cond_eps - uncond_eps) sample_util.py line 80

Regarding the classifier-free guidance paper, should this line be updated to the following? half_eps = cond_eps + guidance_scale * (cond_eps - uncond_eps)

I appreciate your time and look forward to your response.

delta-func commented 1 year ago

Hi, thank you for the interest in our project.

Note the two equations you mentioned are actually the same, except the guidance_scale from the first equals the guidance_scale from the second plus one.

So it is just matter of notations. The first equation is from our paper and the GLIDE paper (Nichol et. al., 2021), whereas the second equation is from the "classifier-free diffusion guidance paper" (Ho & Salimans, 2022).

hyung-gun commented 1 year ago

I appreciate the clarification.