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

This version vs SD 1.4(CompVis) #7

Open
yuhaoliu7456 opened this issue Nov 7, 2023 · 5 comments
Open

This version vs SD 1.4(CompVis) #7

yuhaoliu7456 opened this issue Nov 7, 2023 · 5 comments

Comments

@yuhaoliu7456
Copy link

I test two images using SD 1.4 from CompVis and this consistencydecoder, and is seems that no obvious difference between of them. Anyone else found this?

@Godofnothing
Copy link

@yuhaoliu7456 could you provide more context? I tried myself and the outputs of SD v1.4 VAEDecoder and ConsistencyDecoder differ significantly.

Code:

vae = AutoencoderKL.from_pretrained(
    "CompVis/stable-diffusion-v1-4", 
    subfolder="vae",
    revision="fp16", 
    torch_dtype=torch.float16,
).to(device)

sample_vae = vae.decode(latent).sample.detach()

sample_consistency = decoder_consistency(latent)

VAE
real_madrid_vae
ConsistencyDistillation
real_martid_consistency

@yuhaoliu7456
Copy link
Author

@yuhaoliu7456 could you provide more context? I tried myself and the outputs of SD v1.4 VAEDecoder and ConsistencyDecoder differ significantly.

Code:

vae = AutoencoderKL.from_pretrained(
    "CompVis/stable-diffusion-v1-4", 
    subfolder="vae",
    revision="fp16", 
    torch_dtype=torch.float16,
).to(device)

sample_vae = vae.decode(latent).sample.detach()

sample_consistency = decoder_consistency(latent)

VAE real_madrid_vae ConsistencyDistillation real_martid_consistency

Can you provide this original image and I can test it by myself? Thanks

@Godofnothing
Copy link

@yuhaoliu7456 Sure, you can upload it from this url:
https://img.championat.com/c/900x900/news/big/p/l/real-madrid_1651732892490413154.jpg

@Kallamamran
Copy link

Is it possible to load a local VAE encoder instead of pointing to Huggingface?

@Godofnothing
Copy link

Godofnothing commented Nov 7, 2023

@Kallamamran if you have directory with model weights and config.json you can try:
AutoencoderKL.from_pretrained(path_to_local_dir, subfolder="vae" or no subfolder)

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