Skip to content
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

Implement with Stable Diffusion repositories #7

Open
ExponentialML opened this issue Sep 10, 2022 · 4 comments
Open

Implement with Stable Diffusion repositories #7

ExponentialML opened this issue Sep 10, 2022 · 4 comments

Comments

@ExponentialML
Copy link

Hello, thanks for the implementation! It works very well.

As a suggestion, it may be helpful to provide code that works with the broader Github community. While the Diffusers library does allow for better ease of use and a more streamlined experience, it can possibly hinder the freedom to use across similar implementations due to how their library works.

@bloc97
Copy link
Owner

bloc97 commented Sep 11, 2022

I believe the easiest way for someone to get started is to simply download the diffusers library and run this jupyter notebook. While it does require the diffusers library, it is not using any of the pre-implemented pipelines, diffusers is only used to download and load the neural network with schedulers, all of the diffusion logic is in the jupyter notebook.

If you are using another library, simply replace the unet, vae and scheduler variables with the ones from another library. I might be wrong but I think the cross attention modules should be implemented similarly, but maybe you have to modify slightly the code injection as the variable names might be different.

@sunwoo76
Copy link

sunwoo76 commented Sep 15, 2022

Hello, thanks for the implementation! It works very well.

As a suggestion, it may be helpful to provide code that works with the broader Github community. While the Diffusers library does allow for better ease of use and a more streamlined experience, it can possibly hinder the freedom to use across similar implementations due to how their library works.

I reproduced cross attention control based on the stable diffusion repository referring to this repository. However, I'm not sure the codes reproduced properly.
Refer to my repository: https://github.com/sunwoo76/CrossAttentionControl-stablediffusion

@bloc97, your repository, and comments were good guidance to me. Could you check my implementation too? Thanks :)

@bloc97
Copy link
Owner

bloc97 commented Sep 15, 2022

@sunwoo76 Awesome! I didn't look very deeply in the code but it looks good at first glance from reading the README. I think showing a visualization of the attention maps is a very good feature!

@ExponentialML
Copy link
Author

Hello, thanks for the implementation! It works very well.
As a suggestion, it may be helpful to provide code that works with the broader Github community. While the Diffusers library does allow for better ease of use and a more streamlined experience, it can possibly hinder the freedom to use across similar implementations due to how their library works.

I reproduced cross attention control based on the stable diffusion repository referring to this repository. However, I'm not sure the codes reproduced properly. Refer to my repository: https://github.com/sunwoo76/CrossAttentionControl-stablediffusion

@bloc97, your repository, and comments were good guidance to me. Could you check my implementation too? Thanks :)

Amazing work!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants