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

image editing with XL model #33

Open
SlZeroth opened this issue Nov 30, 2023 · 6 comments
Open

image editing with XL model #33

SlZeroth opened this issue Nov 30, 2023 · 6 comments

Comments

@SlZeroth
Copy link

Hi! I m so happy to use image editing code

I have a question about the image editing with XL model. how can I do that?

@rohitgandikota
Copy link
Owner

Hi, thanks for the question!

I believe the only missing piece in the puzzle to implement image editing with XL is to figure out the Null Inversion method for SDXL models. I could not find a good resource for it and didn't have time to figure it out on my own. Would appreciate it if you find a resource and share it here - I will be happy to add it to the demo notebooks.

@xpeng
Copy link

xpeng commented Dec 13, 2023

can we use DDIM inversion for XL pipelines?

# DDIM inversion

from diffusers.utils import load_image
import inversion
import numpy as np

src_prompt = 'Man laying in a bed'
image_path = './example_image/medieval-bed.jpeg'

num_inference_steps = 50
x0 = np.array(load_image(image_path).resize((1024, 1024)))
zts = inversion.ddim_inversion(pipeline, x0, src_prompt, num_inference_steps, 2)
mediapy.show_image(x0, title="innput reference image", height=256)

as project Sytle-Aligned does:https://github.com/google/style-aligned/blob/main/style_aligned_transfer_sdxl.ipynb

@rohitgandikota
Copy link
Owner

That's an excellent point - we definitely can use it. But I suspect that it might not be as effective as null inversion. If you happen to implement it, please share the results here. Thanks!

@chabrarahul
Copy link

Has anyone tried implementing Image editing with SDXL ?

@JasonBourne1998
Copy link

Has anyone tried implementing Image editing with SDXL ?

Same question, have you tried it?

@JasonBourne1998
Copy link

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

5 participants