-
Notifications
You must be signed in to change notification settings - Fork 130
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How to determine cond_fn in condition_mean #69
Comments
Can you please point to the line of the code in question? |
Thanks for your reply. Yes of course. The condition_mean method is Line 403-416 in base.py Also in the manipulate case: cond2 = cond2 + 0.3 * math.sqrt(512) * F.normalize(cls_model.classifier.weight[cls_id][None, :], dim=1) could you please share how you determine the coefficient (0.3*sqrt(512))? Thanks for your help! |
I believe the line 403-416 was not used in DiffAE at all, and hence not related to DiffAE. It was a legacy code from the base repo that we built upon. Regarding your second question, |
Really appreciate your reply. But I think line 403-416 actually used in img = model.render(xT, cond2, T=100) from block[33] of manipulate.ipynb. In which the render method can be conditioned based on cond_fn. But I don't find anywhere cond_fn be defined. So could you please provide me some clue on how to implement this conditional render? Thank you! |
Hello everyone,
I'm trying to implement the manipulate method. And I find the key to manipulate is to modify the cond in render_condition() function. And the condition_mean() function will calculate a new mean for diffusion for sampling. However, I can not see where the cond_fn comes from and how to determine it. Much appreciate if you have any clue!
The text was updated successfully, but these errors were encountered: