Unverified Commit 10f4ecd1 authored by stano's avatar stano Committed by GitHub
Browse files

Fix the Kandinsky docstring examples (#3695)

- use the correct Prior hub model id
 - use the new names in KandinskyPriorPipelineOutput
parent de16f646
...@@ -41,13 +41,13 @@ EXAMPLE_DOC_STRING = """ ...@@ -41,13 +41,13 @@ EXAMPLE_DOC_STRING = """
>>> from diffusers import KandinskyPipeline, KandinskyPriorPipeline >>> from diffusers import KandinskyPipeline, KandinskyPriorPipeline
>>> import torch >>> import torch
>>> pipe_prior = KandinskyPriorPipeline.from_pretrained("kandinsky-community/Kandinsky-prior") >>> pipe_prior = KandinskyPriorPipeline.from_pretrained("kandinsky-community/Kandinsky-2-1-prior")
>>> pipe_prior.to("cuda") >>> pipe_prior.to("cuda")
>>> prompt = "red cat, 4k photo" >>> prompt = "red cat, 4k photo"
>>> out = pipe_prior(prompt) >>> out = pipe_prior(prompt)
>>> image_emb = out.images >>> image_emb = out.image_embeds
>>> zero_image_emb = out.zero_embeds >>> negative_image_emb = out.negative_image_embeds
>>> pipe = KandinskyPipeline.from_pretrained("kandinsky-community/kandinsky-2-1") >>> pipe = KandinskyPipeline.from_pretrained("kandinsky-community/kandinsky-2-1")
>>> pipe.to("cuda") >>> pipe.to("cuda")
...@@ -55,7 +55,7 @@ EXAMPLE_DOC_STRING = """ ...@@ -55,7 +55,7 @@ EXAMPLE_DOC_STRING = """
>>> image = pipe( >>> image = pipe(
... prompt, ... prompt,
... image_embeds=image_emb, ... image_embeds=image_emb,
... negative_image_embeds=zero_image_emb, ... negative_image_embeds=negative_image_emb,
... height=768, ... height=768,
... width=768, ... width=768,
... num_inference_steps=100, ... num_inference_steps=100,
......
...@@ -45,8 +45,8 @@ EXAMPLE_DOC_STRING = """ ...@@ -45,8 +45,8 @@ EXAMPLE_DOC_STRING = """
>>> prompt = "red cat, 4k photo" >>> prompt = "red cat, 4k photo"
>>> out = pipe_prior(prompt) >>> out = pipe_prior(prompt)
>>> image_emb = out.images >>> image_emb = out.image_embeds
>>> zero_image_emb = out.zero_embeds >>> negative_image_emb = out.negative_image_embeds
>>> pipe = KandinskyPipeline.from_pretrained("kandinsky-community/kandinsky-2-1") >>> pipe = KandinskyPipeline.from_pretrained("kandinsky-community/kandinsky-2-1")
>>> pipe.to("cuda") >>> pipe.to("cuda")
...@@ -54,7 +54,7 @@ EXAMPLE_DOC_STRING = """ ...@@ -54,7 +54,7 @@ EXAMPLE_DOC_STRING = """
>>> image = pipe( >>> image = pipe(
... prompt, ... prompt,
... image_embeds=image_emb, ... image_embeds=image_emb,
... negative_image_embeds=zero_image_emb, ... negative_image_embeds=negative_image_emb,
... height=768, ... height=768,
... width=768, ... width=768,
... num_inference_steps=100, ... num_inference_steps=100,
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment