Skip to content

Conversation

@yiyixuxu
Copy link
Collaborator

@yiyixuxu yiyixuxu commented Feb 23, 2023

This PR is the first example of how we can integrate the notebook into the doc page itself

for https://huggingface.co/docs/diffusers/using-diffusers/img2img

there are a lot of other doc pages that have a link to a colab notebook - plan to integrate them all after I get feedback for this one (so that we don't have to maintain these notebooks separately)

for example
https://huggingface.co/docs/diffusers/stable_diffusion
https://huggingface.co/docs/diffusers/using-diffusers/inpaint
https://huggingface.co/docs/diffusers/using-diffusers/rl
https://huggingface.co/docs/diffusers/using-diffusers/other-modalities

@HuggingFaceDocBuilderDev
Copy link

HuggingFaceDocBuilderDev commented Feb 23, 2023

The documentation is not available anymore as the PR was closed or merged.

# Text-Guided Image-to-Image Generation

The [`StableDiffusionImg2ImgPipeline`] lets you pass a text prompt and an initial image to condition the generation of new images.
[[open-in-colab]]
Copy link
Contributor

Choose a reason for hiding this comment

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

Where is the corresponding generated google colab?

Copy link
Contributor

@patrickvonplaten patrickvonplaten left a comment

Choose a reason for hiding this comment

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

Can you also link the google colab that is automatically generated from this doc?

Co-authored-by: Patrick von Platen <patrick.v.platen@gmail.com>
@yiyixuxu
Copy link
Collaborator Author

yiyixuxu commented Mar 6, 2023

@patrickvonplaten I think with this line [[open-in-colab]] - the doc-builder will automatically convert it to a notebook, push to huggingface/notebooks and link it once the PR is merged

Maria and Steven told me so - we can merge this one and see what happens.


As you can see, when using a lower value for `strength`, the generated image is more closer to the original `image`

Now let's use a different scheduler - [LMSDiscreteScheduler](https://huggingface.co/docs/diffusers/api/schedulers#diffusers.LMSDiscreteScheduler)
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
Now let's use a different scheduler - [LMSDiscreteScheduler](https://huggingface.co/docs/diffusers/api/schedulers#diffusers.LMSDiscreteScheduler)
Now let's use a different scheduler - [LMSDiscreteScheduler](https://huggingface.co/docs/diffusers/api/schedulers#diffusers.LMSDiscreteScheduler)

Let's use maybe a different scheduler here, such as DPMSolverMultistepScheduler -> LMS requires another dependency and not the best scheduler anymore

Copy link
Contributor

@patrickvonplaten patrickvonplaten left a comment

Choose a reason for hiding this comment

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

Ok for me,

Note that the notebooks don't seem to be created automatically yet though - but ok to merge and check later.

Also, let's make sure to use the most up-to-date schedulers in our docs

@yiyixuxu yiyixuxu merged commit d2a5247 into huggingface:main Mar 8, 2023
@yiyixuxu yiyixuxu deleted the add-notebook-doc-img2img branch March 8, 2023 06:01
mengfei25 pushed a commit to mengfei25/diffusers that referenced this pull request Mar 27, 2023
* convert img2img.mdx into notebook doc

* fix

* Update docs/source/en/using-diffusers/img2img.mdx

Co-authored-by: Patrick von Platen <patrick.v.platen@gmail.com>

---------

Co-authored-by: yiyixuxu <yixu@yis-macbook-pro.lan>
Co-authored-by: Patrick von Platen <patrick.v.platen@gmail.com>
w4ffl35 pushed a commit to w4ffl35/diffusers that referenced this pull request Apr 14, 2023
* convert img2img.mdx into notebook doc

* fix

* Update docs/source/en/using-diffusers/img2img.mdx

Co-authored-by: Patrick von Platen <patrick.v.platen@gmail.com>

---------

Co-authored-by: yiyixuxu <yixu@yis-macbook-pro.lan>
Co-authored-by: Patrick von Platen <patrick.v.platen@gmail.com>
AmericanPresidentJimmyCarter pushed a commit to AmericanPresidentJimmyCarter/diffusers that referenced this pull request Apr 26, 2024
* convert img2img.mdx into notebook doc

* fix

* Update docs/source/en/using-diffusers/img2img.mdx

Co-authored-by: Patrick von Platen <patrick.v.platen@gmail.com>

---------

Co-authored-by: yiyixuxu <yixu@yis-macbook-pro.lan>
Co-authored-by: Patrick von Platen <patrick.v.platen@gmail.com>
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.

3 participants