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

sana support #1106

Merged
merged 15 commits into from
Jan 30, 2025
Merged

sana support #1106

merged 15 commits into from
Jan 30, 2025

Conversation

eaidova
Copy link
Collaborator

@eaidova eaidova commented Jan 13, 2025

What does this PR do?

  • provided opportunity to select model checkpoint variant for loading
  • supported Sana image generation model family

Example of usage:

import torch

from optimum.intel.openvino import OVDiffusionPipeline


pipe = OVDiffusionPipeline.from_pretrained("Efficient-Large-Model/Sana_600M_512px_diffusers", variant="fp16")
prompt = 'a cyberpunk cat in neon style'
image = pipe(
    prompt=prompt,
    generator=torch.Generator(device="cpu").manual_seed(142),
)[0]

image[0].save("sana_fp16.png")

Generated image:
sana_fp16

Before submitting

  • This PR fixes a typo or improves the docs (you can dismiss the other checks if that's the case).
  • Did you make sure to update the documentation with your changes?
  • Did you write any new necessary tests?

@eaidova eaidova changed the title Ea/sana support sana support Jan 13, 2025
@HuggingFaceDocBuilderDev

The docs for this PR live here. All of your documentation changes will be reflected on that endpoint. The docs are available until 30 days after the last update.

@eaidova eaidova marked this pull request as ready for review January 17, 2025 08:10
@andrei-kochin
Copy link
Contributor

@echarlaix @IlyasMoutawwakil could you please take a look?

@eaidova
Copy link
Collaborator Author

eaidova commented Jan 30, 2025

@IlyasMoutawwakil all comments applied (failed test is not related and already fixed on main), could you please take a look one more time?
Thanks!

Co-authored-by: Ilyas Moutawwakil <[email protected]>
Copy link
Collaborator

@echarlaix echarlaix left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the addition @eaidova

tests/openvino/test_diffusion.py Show resolved Hide resolved
@echarlaix echarlaix merged commit 78a74ce into huggingface:main Jan 30, 2025
22 checks passed
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

Successfully merging this pull request may close these issues.

6 participants