import{s as ct,o as mt,n as dt}from"../chunks/scheduler.53228c21.js";import{S as gt,i as ht,e as r,s,c as d,h as ut,a as l,d as t,b as a,f as J,g as c,j as _,k as x,l as i,m as o,n as m,t as g,o as h,p as u}from"../chunks/index.100fac89.js";import{C as _t}from"../chunks/CopyLLMTxtMenu.20a72e0e.js";import{D as $}from"../chunks/Docstring.49101787.js";import{C as Ne}from"../chunks/CodeBlock.d30a6509.js";import{E as pt}from"../chunks/ExampleCodeBlock.4a9effb9.js";import{H as E,E as ft}from"../chunks/MermaidChart.svelte_svelte_type_style_lang.4d82655d.js";function yt(fe){let f,U="Examples:",T,y,k;return y=new Ne({props:{code:"aW1wb3J0JTIwdG9yY2glMEFmcm9tJTIwZGlmZnVzZXJzJTIwaW1wb3J0JTIwS2FuZGluc2t5NVQySVBpcGVsaW5lJTBBJTBBJTIzJTIwQXZhaWxhYmxlJTIwbW9kZWxzJTNBJTBBJTIzJTIwa2FuZGluc2t5bGFiJTJGS2FuZGluc2t5LTUuMC1UMkktTGl0ZS1zZnQtRGlmZnVzZXJzJTBBJTIzJTIwa2FuZGluc2t5bGFiJTJGS2FuZGluc2t5LTUuMC1UMkktTGl0ZS1wcmV0cmFpbi1EaWZmdXNlcnMlMEElMEFtb2RlbF9pZCUyMCUzRCUyMCUyMmthbmRpbnNreWxhYiUyRkthbmRpbnNreS01LjAtVDJJLUxpdGUtc2Z0LURpZmZ1c2VycyUyMiUwQXBpcGUlMjAlM0QlMjBLYW5kaW5za3k1VDJJUGlwZWxpbmUuZnJvbV9wcmV0cmFpbmVkKG1vZGVsX2lkJTJDJTIwdG9yY2hfZHR5cGUlM0R0b3JjaC5iZmxvYXQxNiklMEFwaXBlJTIwJTNEJTIwcGlwZS50byglMjJjdWRhJTIyKSUwQSUwQXByb21wdCUyMCUzRCUyMCUyMkElMjBjYXQlMjBhbmQlMjBhJTIwZG9nJTIwYmFraW5nJTIwYSUyMGNha2UlMjB0b2dldGhlciUyMGluJTIwYSUyMGtpdGNoZW4uJTIyJTBBJTBBb3V0cHV0JTIwJTNEJTIwcGlwZSglMEElMjAlMjAlMjAlMjBwcm9tcHQlM0Rwcm9tcHQlMkMlMEElMjAlMjAlMjAlMjBuZWdhdGl2ZV9wcm9tcHQlM0QlMjIlMjIlMkMlMEElMjAlMjAlMjAlMjBoZWlnaHQlM0QxMDI0JTJDJTBBJTIwJTIwJTIwJTIwd2lkdGglM0QxMDI0JTJDJTBBJTIwJTIwJTIwJTIwbnVtX2luZmVyZW5jZV9zdGVwcyUzRDUwJTJDJTBBJTIwJTIwJTIwJTIwZ3VpZGFuY2Vfc2NhbGUlM0QzLjUlMkMlMEEpLmZyYW1lcyU1QjAlNUQ=",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">import</span> torch
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> diffusers <span class="hljs-keyword">import</span> Kandinsky5T2IPipeline

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Available models:</span>
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># kandinskylab/Kandinsky-5.0-T2I-Lite-sft-Diffusers</span>
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># kandinskylab/Kandinsky-5.0-T2I-Lite-pretrain-Diffusers</span>

<span class="hljs-meta">&gt;&gt;&gt; </span>model_id = <span class="hljs-string">&quot;kandinskylab/Kandinsky-5.0-T2I-Lite-sft-Diffusers&quot;</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>pipe = Kandinsky5T2IPipeline.from_pretrained(model_id, torch_dtype=torch.bfloat16)
<span class="hljs-meta">&gt;&gt;&gt; </span>pipe = pipe.to(<span class="hljs-string">&quot;cuda&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>prompt = <span class="hljs-string">&quot;A cat and a dog baking a cake together in a kitchen.&quot;</span>

<span class="hljs-meta">&gt;&gt;&gt; </span>output = pipe(
<span class="hljs-meta">... </span>    prompt=prompt,
<span class="hljs-meta">... </span>    negative_prompt=<span class="hljs-string">&quot;&quot;</span>,
<span class="hljs-meta">... </span>    height=<span class="hljs-number">1024</span>,
<span class="hljs-meta">... </span>    width=<span class="hljs-number">1024</span>,
<span class="hljs-meta">... </span>    num_inference_steps=<span class="hljs-number">50</span>,
<span class="hljs-meta">... </span>    guidance_scale=<span class="hljs-number">3.5</span>,
<span class="hljs-meta">... </span>).frames[<span class="hljs-number">0</span>]`,wrap:!1}}),{c(){f=r("p"),f.textContent=U,T=s(),d(y.$$.fragment)},l(p){f=l(p,"P",{"data-svelte-h":!0}),_(f)!=="svelte-kvfsh7"&&(f.textContent=U),T=a(p),c(y.$$.fragment,p)},m(p,w){o(p,f,w),o(p,T,w),m(y,p,w),k=!0},p:dt,i(p){k||(g(y.$$.fragment,p),k=!0)},o(p){h(y.$$.fragment,p),k=!1},d(p){p&&(t(f),t(T)),u(y,p)}}}function bt(fe){let f,U="Examples:",T,y,k;return y=new Ne({props:{code:"aW1wb3J0JTIwdG9yY2glMEFmcm9tJTIwZGlmZnVzZXJzJTIwaW1wb3J0JTIwS2FuZGluc2t5NUkySVBpcGVsaW5lJTBBJTBBJTIzJTIwQXZhaWxhYmxlJTIwbW9kZWxzJTNBJTBBJTIzJTIwa2FuZGluc2t5bGFiJTJGS2FuZGluc2t5LTUuMC1JMkktTGl0ZS1zZnQtRGlmZnVzZXJzJTBBJTIzJTIwa2FuZGluc2t5bGFiJTJGS2FuZGluc2t5LTUuMC1JMkktTGl0ZS1wcmV0cmFpbi1EaWZmdXNlcnMlMEElMEFtb2RlbF9pZCUyMCUzRCUyMCUyMmthbmRpbnNreWxhYiUyRkthbmRpbnNreS01LjAtSTJJLUxpdGUtc2Z0LURpZmZ1c2VycyUyMiUwQXBpcGUlMjAlM0QlMjBLYW5kaW5za3k1STJJUGlwZWxpbmUuZnJvbV9wcmV0cmFpbmVkKG1vZGVsX2lkJTJDJTIwdG9yY2hfZHR5cGUlM0R0b3JjaC5iZmxvYXQxNiklMEFwaXBlJTIwJTNEJTIwcGlwZS50byglMjJjdWRhJTIyKSUwQSUwQXByb21wdCUyMCUzRCUyMCUyMkElMjBjYXQlMjBhbmQlMjBhJTIwZG9nJTIwYmFraW5nJTIwYSUyMGNha2UlMjB0b2dldGhlciUyMGluJTIwYSUyMGtpdGNoZW4uJTIyJTBBJTBBb3V0cHV0JTIwJTNEJTIwcGlwZSglMEElMjAlMjAlMjAlMjBwcm9tcHQlM0Rwcm9tcHQlMkMlMEElMjAlMjAlMjAlMjBuZWdhdGl2ZV9wcm9tcHQlM0QlMjIlMjIlMkMlMEElMjAlMjAlMjAlMjBoZWlnaHQlM0QxMDI0JTJDJTBBJTIwJTIwJTIwJTIwd2lkdGglM0QxMDI0JTJDJTBBJTIwJTIwJTIwJTIwbnVtX2luZmVyZW5jZV9zdGVwcyUzRDUwJTJDJTBBJTIwJTIwJTIwJTIwZ3VpZGFuY2Vfc2NhbGUlM0QzLjUlMkMlMEEpLmZyYW1lcyU1QjAlNUQ=",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">import</span> torch
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> diffusers <span class="hljs-keyword">import</span> Kandinsky5I2IPipeline

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Available models:</span>
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># kandinskylab/Kandinsky-5.0-I2I-Lite-sft-Diffusers</span>
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># kandinskylab/Kandinsky-5.0-I2I-Lite-pretrain-Diffusers</span>

<span class="hljs-meta">&gt;&gt;&gt; </span>model_id = <span class="hljs-string">&quot;kandinskylab/Kandinsky-5.0-I2I-Lite-sft-Diffusers&quot;</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>pipe = Kandinsky5I2IPipeline.from_pretrained(model_id, torch_dtype=torch.bfloat16)
<span class="hljs-meta">&gt;&gt;&gt; </span>pipe = pipe.to(<span class="hljs-string">&quot;cuda&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>prompt = <span class="hljs-string">&quot;A cat and a dog baking a cake together in a kitchen.&quot;</span>

<span class="hljs-meta">&gt;&gt;&gt; </span>output = pipe(
<span class="hljs-meta">... </span>    prompt=prompt,
<span class="hljs-meta">... </span>    negative_prompt=<span class="hljs-string">&quot;&quot;</span>,
<span class="hljs-meta">... </span>    height=<span class="hljs-number">1024</span>,
<span class="hljs-meta">... </span>    width=<span class="hljs-number">1024</span>,
<span class="hljs-meta">... </span>    num_inference_steps=<span class="hljs-number">50</span>,
<span class="hljs-meta">... </span>    guidance_scale=<span class="hljs-number">3.5</span>,
<span class="hljs-meta">... </span>).frames[<span class="hljs-number">0</span>]`,wrap:!1}}),{c(){f=r("p"),f.textContent=U,T=s(),d(y.$$.fragment)},l(p){f=l(p,"P",{"data-svelte-h":!0}),_(f)!=="svelte-kvfsh7"&&(f.textContent=U),T=a(p),c(y.$$.fragment,p)},m(p,w){o(p,f,w),o(p,T,w),m(y,p,w),k=!0},p:dt,i(p){k||(g(y.$$.fragment,p),k=!0)},o(p){h(y.$$.fragment,p),k=!1},d(p){p&&(t(f),t(T)),u(y,p)}}}function Mt(fe){let f,U,T,y,k,p,w,Qe,q,Ln='<a href="https://arxiv.org/abs/2511.14993" rel="nofollow">Kandinsky 5.0</a> is a family of diffusion models for Video &amp; Image generation.',Ee,Y,Nn="Kandinsky 5.0 Image Lite is a lightweight image generation model (6B parameters).",qe,F,Qn="The model introduces several key innovations:",Ye,S,En="<li><strong>Latent diffusion pipeline</strong> with <strong>Flow Matching</strong> for improved training stability</li> <li><strong>Diffusion Transformer (DiT)</strong> as the main generative backbone with cross-attention to text embeddings</li> <li>Dual text encoding using <strong>Qwen2.5-VL</strong> and <strong>CLIP</strong> for comprehensive text understanding</li> <li><strong>Flux VAE</strong> for efficient image encoding and decoding</li>",Fe,z,qn='The original codebase can be found at <a href="https://github.com/kandinskylab/Kandinsky-5" rel="nofollow">kandinskylab/Kandinsky-5</a>.',Se,W,Yn='<p>Check out the <a href="https://huggingface.co/kandinskylab" rel="nofollow">Kandinsky Lab</a> organization on the Hub for the official model checkpoints for text-to-video generation, including pretrained, SFT, no-CFG, and distilled variants.</p>',ze,R,Re,D,Fn="Kandinsky 5.0 Image Lite:",De,A,Sn='<thead><tr><th>model_id</th> <th>Description</th> <th>Use Cases</th></tr></thead> <tbody><tr><td><a href="https://huggingface.co/kandinskylab/Kandinsky-5.0-T2I-Lite-sft-Diffusers" rel="nofollow"><strong>kandinskylab/Kandinsky-5.0-T2I-Lite-sft-Diffusers</strong></a></td> <td>6B image Supervised Fine-Tuned model</td> <td>Highest generation quality</td></tr> <tr><td><a href="https://huggingface.co/kandinskylab/Kandinsky-5.0-I2I-Lite-sft-Diffusers" rel="nofollow"><strong>kandinskylab/Kandinsky-5.0-I2I-Lite-sft-Diffusers</strong></a></td> <td>6B image editing Supervised Fine-Tuned model</td> <td>Highest generation quality</td></tr> <tr><td><a href="https://huggingface.co/kandinskylab/Kandinsky-5.0-T2I-Lite-pretrain-Diffusers" rel="nofollow"><strong>kandinskylab/Kandinsky-5.0-T2I-Lite-pretrain-Diffusers</strong></a></td> <td>6B image Base pretrained model</td> <td>Research and fine-tuning</td></tr> <tr><td><a href="https://huggingface.co/kandinskylab/Kandinsky-5.0-I2I-Lite-pretrain-Diffusers" rel="nofollow"><strong>kandinskylab/Kandinsky-5.0-I2I-Lite-pretrain-Diffusers</strong></a></td> <td>6B image editing Base pretrained model</td> <td>Research and fine-tuning</td></tr></tbody>',Ae,X,Xe,H,He,O,Oe,ee,en,ne,nn,te,tn,b,se,gn,ye,zn="Pipeline for text-to-image generation using Kandinsky 5.0.",hn,be,Rn=`This model inherits from <a href="/docs/diffusers/main/en/api/pipelines/overview#diffusers.DiffusionPipeline">DiffusionPipeline</a>. Check the superclass documentation for the generic methods
implemented for all pipelines (downloading, saving, running on a particular device, etc.).`,un,j,ae,_n,Me,Dn="The call function to the pipeline for text-to-image generation.",fn,V,yn,L,ie,bn,ke,An="Validate input parameters for the pipeline.",Mn,C,oe,kn,Ie,Xn="Encodes a single prompt (positive or negative) into text encoder hidden states.",In,Te,Hn=`This method combines embeddings from both Qwen2.5-VL and CLIP text encoders to create comprehensive text
representations for image generation.`,Tn,P,re,wn,we,On="Prepare initial latent variables for text-to-image generation.",vn,ve,et="This method creates random noise latents",sn,le,an,M,pe,xn,xe,nt="Pipeline for image-to-image generation using Kandinsky 5.0.",Jn,Je,tt=`This model inherits from <a href="/docs/diffusers/main/en/api/pipelines/overview#diffusers.DiffusionPipeline">DiffusionPipeline</a>. Check the superclass documentation for the generic methods
implemented for all pipelines (downloading, saving, running on a particular device, etc.).`,Un,G,de,jn,Ue,st="The call function to the pipeline for image-to-image generation.",Cn,N,Pn,Q,ce,Gn,je,at="Validate input parameters for the pipeline.",Zn,Z,me,Bn,Ce,it="Encodes a single prompt (positive or negative) into text encoder hidden states.",$n,Pe,ot=`This method combines embeddings from both Qwen2.5-VL and CLIP text encoders to create comprehensive text
representations for image generation.`,Kn,B,ge,Wn,Ge,rt="Prepare initial latent variables for image-to-image generation.",Vn,Ze,lt="This method creates random noise latents with encoded image,",on,he,rn,ue,ln,_e,pn,Le,dn;return k=new _t({props:{containerStyle:"float: right; margin-left: 10px; display: inline-flex; position: relative; z-index: 10;"}}),w=new E({props:{title:"Kandinsky 5.0 Image",local:"kandinsky-50-image",headingTag:"h1"}}),R=new E({props:{title:"Available Models",local:"available-models",headingTag:"h2"}}),X=new E({props:{title:"Usage Examples",local:"usage-examples",headingTag:"h2"}}),H=new E({props:{title:"Basic Text-to-Image Generation",local:"basic-text-to-image-generation",headingTag:"h3"}}),O=new Ne({props:{code:"aW1wb3J0JTIwdG9yY2glMEFmcm9tJTIwZGlmZnVzZXJzJTIwaW1wb3J0JTIwS2FuZGluc2t5NVQySVBpcGVsaW5lJTBBJTBBJTIzJTIwTG9hZCUyMHRoZSUyMHBpcGVsaW5l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oJTBBJTIwJTIwJTIwJTIwcHJvbXB0JTNEcHJvbXB0JTJDJTBBJTIwJTIwJTIwJTIwbmVnYXRpdmVfcHJvbXB0JTNEJTIyJTIyJTJDJTBBJTIwJTIwJTIwJTIwaGVpZ2h0JTNEMTAyNCUyQyUwQSUyMCUyMCUyMCUyMHdpZHRoJTNEMTAyNCUyQyUwQSUyMCUyMCUyMCUyMG51bV9pbmZlcmVuY2Vfc3RlcHMlM0Q1MCUyQyUwQSUyMCUyMCUyMCUyMGd1aWRhbmNlX3NjYWxlJTNEMy41JTJDJTBBKS5pbWFnZSU1QjAlNUQ=",highlighted:`<span class="hljs-keyword">import</span> torch
<span class="hljs-keyword">from</span> diffusers <span class="hljs-keyword">import</span> Kandinsky5T2IPipeline

<span class="hljs-comment"># Load the pipeline</span>
model_id = <span class="hljs-string">&quot;kandinskylab/Kandinsky-5.0-T2I-Lite-sft-Diffusers&quot;</span>
pipe = Kandinsky5T2IPipeline.from_pretrained(model_id)
_ = pipe.to(device=<span class="hljs-string">&#x27;cuda&#x27;</span>,dtype=torch.bfloat16)

<span class="hljs-comment"># Generate image</span>
prompt = <span class="hljs-string">&quot;A fluffy, expressive cat wearing a bright red hat with a soft, slightly textured fabric. The hat should look cozy and well-fitted on the cat’s head. On the front of the hat, add clean, bold white text that reads “SWEET”, clearly visible and neatly centered. Ensure the overall lighting highlights the hat’s color and the cat’s fur details.&quot;</span>

output = pipe(
    prompt=prompt,
    negative_prompt=<span class="hljs-string">&quot;&quot;</span>,
    height=<span class="hljs-number">1024</span>,
    width=<span class="hljs-number">1024</span>,
    num_inference_steps=<span class="hljs-number">50</span>,
    guidance_scale=<span class="hljs-number">3.5</span>,
).image[<span class="hljs-number">0</span>]`,wrap:!1}}),ee=new E({props:{title:"Basic Image-to-Image Generation",local:"basic-image-to-image-generation",headingTag:"h3"}}),ne=new Ne({props:{code:"aW1wb3J0JTIwdG9yY2glMEFmcm9tJTIwZGlmZnVzZXJzJTIwaW1wb3J0JTIwS2F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MjAlM0QlMjBwaXBlKCUwQSUyMCUyMCUyMCUyMGltYWdlJTNEaW1hZ2UlMkMlMEElMjAlMjAlMjAlMjBwcm9tcHQlM0Rwcm9tcHQlMkMlMEElMjAlMjAlMjAlMjBuZWdhdGl2ZV9wcm9tcHQlM0RuZWdhdGl2ZV9wcm9tcHQlMkMlMEElMjAlMjAlMjAlMjBndWlkYW5jZV9zY2FsZSUzRDMuNSUyQyUwQSkuaW1hZ2UlNUIwJTVE",highlighted:`<span class="hljs-keyword">import</span> torch
<span class="hljs-keyword">from</span> diffusers <span class="hljs-keyword">import</span> Kandinsky5I2IPipeline
<span class="hljs-keyword">from</span> diffusers.utils <span class="hljs-keyword">import</span> load_image 
<span class="hljs-comment"># Load the pipeline</span>
model_id = <span class="hljs-string">&quot;kandinskylab/Kandinsky-5.0-I2I-Lite-sft-Diffusers&quot;</span>
pipe = Kandinsky5I2IPipeline.from_pretrained(model_id)

_ = pipe.to(device=<span class="hljs-string">&#x27;cuda&#x27;</span>,dtype=torch.bfloat16)
pipe.enable_model_cpu_offload()                                               <span class="hljs-comment"># &lt;--- Enable CPU offloading for single GPU inference</span>

<span class="hljs-comment"># Edit the input image</span>
image = load_image(
    <span class="hljs-string">&quot;https://huggingface.co/kandinsky-community/kandinsky-3/resolve/main/assets/title.jpg?download=true&quot;</span>
)

prompt = <span class="hljs-string">&quot;Change the background from a winter night scene to a bright summer day. Place the character on a sandy beach with clear blue sky, soft sunlight, and gentle waves in the distance. Replace the winter clothing with a light short-sleeved T-shirt (in soft pastel colors) and casual shorts. Ensure the character’s fur reflects warm daylight instead of cold winter tones. Add small beach details such as seashells, footprints in the sand, and a few scattered beach toys nearby. Keep the oranges in the scene, but place them naturally on the sand.&quot;</span>
negative_prompt = <span class="hljs-string">&quot;&quot;</span>

output = pipe(
    image=image,
    prompt=prompt,
    negative_prompt=negative_prompt,
    guidance_scale=<span class="hljs-number">3.5</span>,
).image[<span class="hljs-number">0</span>]`,wrap:!1}}),te=new E({props:{title:"Kandinsky5T2IPipeline",local:"diffusers.Kandinsky5T2IPipeline",headingTag:"h2"}}),se=new $({props:{name:"class diffusers.Kandinsky5T2IPipeline",anchor:"diffusers.Kandinsky5T2IPipeline",parameters:[{name:"transformer",val:": Kandinsky5Transformer3DModel"},{name:"vae",val:": AutoencoderKL"},{name:"text_encoder",val:": Qwen2_5_VLForConditionalGeneration"},{name:"tokenizer",val:": Qwen2VLProcessor"},{name:"text_encoder_2",val:": CLIPTextModel"},{name:"tokenizer_2",val:": CLIPTokenizer"},{name:"scheduler",val:": FlowMatchEulerDiscreteScheduler"}],parametersDescription:[{anchor:"diffusers.Kandinsky5T2IPipeline.transformer",description:`<strong>transformer</strong> (<code>Kandinsky5Transformer3DModel</code>) &#x2014;
Conditional Transformer to denoise the encoded image latents.`,name:"transformer"},{anchor:"diffusers.Kandinsky5T2IPipeline.vae",description:`<strong>vae</strong> (<a href="/docs/diffusers/main/en/api/models/autoencoderkl#diffusers.AutoencoderKL">AutoencoderKL</a>) &#x2014;
Variational Auto-Encoder Model <a href="https://huggingface.co/black-forest-labs/FLUX.1-dev" rel="nofollow">black-forest-labs/FLUX.1-dev
(vae)</a> to encode and decode videos to and from latent
representations.`,name:"vae"},{anchor:"diffusers.Kandinsky5T2IPipeline.text_encoder",description:`<strong>text_encoder</strong> (<code>Qwen2_5_VLForConditionalGeneration</code>) &#x2014;
Frozen text-encoder <a href="https://huggingface.co/Qwen/Qwen2.5-VL-7B-Instruct" rel="nofollow">Qwen2.5-VL</a>.`,name:"text_encoder"},{anchor:"diffusers.Kandinsky5T2IPipeline.tokenizer",description:`<strong>tokenizer</strong> (<code>AutoProcessor</code>) &#x2014;
Tokenizer for Qwen2.5-VL.`,name:"tokenizer"},{anchor:"diffusers.Kandinsky5T2IPipeline.text_encoder_2",description:`<strong>text_encoder_2</strong> (<code>CLIPTextModel</code>) &#x2014;
Frozen <a href="https://huggingface.co/docs/transformers/model_doc/clip#transformers.CLIPTextModel" rel="nofollow">CLIP</a>,
specifically the <a href="https://huggingface.co/openai/clip-vit-large-patch14" rel="nofollow">clip-vit-large-patch14</a> variant.`,name:"text_encoder_2"},{anchor:"diffusers.Kandinsky5T2IPipeline.tokenizer_2",description:`<strong>tokenizer_2</strong> (<code>CLIPTokenizer</code>) &#x2014;
Tokenizer for CLIP.`,name:"tokenizer_2"},{anchor:"diffusers.Kandinsky5T2IPipeline.scheduler",description:`<strong>scheduler</strong> (<a href="/docs/diffusers/main/en/api/schedulers/flow_match_euler_discrete#diffusers.FlowMatchEulerDiscreteScheduler">FlowMatchEulerDiscreteScheduler</a>) &#x2014;
A scheduler to be used in combination with <code>transformer</code> to denoise the encoded image latents.`,name:"scheduler"}],source:"https://github.com/huggingface/diffusers/blob/main/src/diffusers/pipelines/kandinsky5/pipeline_kandinsky_t2i.py#L120"}}),ae=new $({props:{name:"__call__",anchor:"diffusers.Kandinsky5T2IPipeline.__call__",parameters:[{name:"prompt",val:": typing.Union[str, typing.List[str]] = None"},{name:"negative_prompt",val:": typing.Union[str, typing.List[str], NoneType] = None"},{name:"height",val:": int = 1024"},{name:"width",val:": int = 1024"},{name:"num_inference_steps",val:": int = 50"},{name:"guidance_scale",val:": float = 3.5"},{name:"num_images_per_prompt",val:": typing.Optional[int] = 1"},{name:"generator",val:": typing.Union[torch._C.Generator, typing.List[torch._C.Generator], NoneType] = None"},{name:"latents",val:": typing.Optional[torch.Tensor] = None"},{name:"prompt_embeds_qwen",val:": typing.Optional[torch.Tensor] = None"},{name:"prompt_embeds_clip",val:": typing.Optional[torch.Tensor] = None"},{name:"negative_prompt_embeds_qwen",val:": typing.Optional[torch.Tensor] = None"},{name:"negative_prompt_embeds_clip",val:": typing.Optional[torch.Tensor] = None"},{name:"prompt_cu_seqlens",val:": typing.Optional[torch.Tensor] = None"},{name:"negative_prompt_cu_seqlens",val:": typing.Optional[torch.Tensor] = None"},{name:"output_type",val:": typing.Optional[str] = 'pil'"},{name:"return_dict",val:": bool = True"},{name:"callback_on_step_end",val:": typing.Union[typing.Callable[[int, int, typing.Dict], NoneType], diffusers.callbacks.PipelineCallback, diffusers.callbacks.MultiPipelineCallbacks, NoneType] = None"},{name:"callback_on_step_end_tensor_inputs",val:": typing.List[str] = ['latents']"},{name:"max_sequence_length",val:": int = 512"}],parametersDescription:[{anchor:"diffusers.Kandinsky5T2IPipeline.__call__.prompt",description:`<strong>prompt</strong> (<code>str</code> or <code>List[str]</code>, <em>optional</em>) &#x2014;
The prompt or prompts to guide the image generation. If not defined, pass <code>prompt_embeds</code> instead.`,name:"prompt"},{anchor:"diffusers.Kandinsky5T2IPipeline.__call__.negative_prompt",description:`<strong>negative_prompt</strong> (<code>str</code> or <code>List[str]</code>, <em>optional</em>) &#x2014;
The prompt or prompts to avoid during image generation. If not defined, pass <code>negative_prompt_embeds</code>
instead. Ignored when not using guidance (<code>guidance_scale</code> &lt; <code>1</code>).`,name:"negative_prompt"},{anchor:"diffusers.Kandinsky5T2IPipeline.__call__.height",description:`<strong>height</strong> (<code>int</code>, defaults to <code>1024</code>) &#x2014;
The height in pixels of the generated image.`,name:"height"},{anchor:"diffusers.Kandinsky5T2IPipeline.__call__.width",description:`<strong>width</strong> (<code>int</code>, defaults to <code>1024</code>) &#x2014;
The width in pixels of the generated image.`,name:"width"},{anchor:"diffusers.Kandinsky5T2IPipeline.__call__.num_inference_steps",description:`<strong>num_inference_steps</strong> (<code>int</code>, defaults to <code>50</code>) &#x2014;
The number of denoising steps.`,name:"num_inference_steps"},{anchor:"diffusers.Kandinsky5T2IPipeline.__call__.guidance_scale",description:`<strong>guidance_scale</strong> (<code>float</code>, defaults to <code>5.0</code>) &#x2014;
Guidance scale as defined in classifier-free guidance.`,name:"guidance_scale"},{anchor:"diffusers.Kandinsky5T2IPipeline.__call__.num_images_per_prompt",description:`<strong>num_images_per_prompt</strong> (<code>int</code>, <em>optional</em>, defaults to 1) &#x2014;
The number of images to generate per prompt.`,name:"num_images_per_prompt"},{anchor:"diffusers.Kandinsky5T2IPipeline.__call__.generator",description:`<strong>generator</strong> (<code>torch.Generator</code> or <code>List[torch.Generator]</code>, <em>optional</em>) &#x2014;
A torch generator to make generation deterministic.`,name:"generator"},{anchor:"diffusers.Kandinsky5T2IPipeline.__call__.latents",description:`<strong>latents</strong> (<code>torch.Tensor</code>, <em>optional</em>) &#x2014;
Pre-generated noisy latents.`,name:"latents"},{anchor:"diffusers.Kandinsky5T2IPipeline.__call__.prompt_embeds_qwen",description:`<strong>prompt_embeds_qwen</strong> (<code>torch.Tensor</code>, <em>optional</em>) &#x2014;
Pre-generated Qwen text embeddings.`,name:"prompt_embeds_qwen"},{anchor:"diffusers.Kandinsky5T2IPipeline.__call__.prompt_embeds_clip",description:`<strong>prompt_embeds_clip</strong> (<code>torch.Tensor</code>, <em>optional</em>) &#x2014;
Pre-generated CLIP text embeddings.`,name:"prompt_embeds_clip"},{anchor:"diffusers.Kandinsky5T2IPipeline.__call__.negative_prompt_embeds_qwen",description:`<strong>negative_prompt_embeds_qwen</strong> (<code>torch.Tensor</code>, <em>optional</em>) &#x2014;
Pre-generated Qwen negative text embeddings.`,name:"negative_prompt_embeds_qwen"},{anchor:"diffusers.Kandinsky5T2IPipeline.__call__.negative_prompt_embeds_clip",description:`<strong>negative_prompt_embeds_clip</strong> (<code>torch.Tensor</code>, <em>optional</em>) &#x2014;
Pre-generated CLIP negative text embeddings.`,name:"negative_prompt_embeds_clip"},{anchor:"diffusers.Kandinsky5T2IPipeline.__call__.prompt_cu_seqlens",description:`<strong>prompt_cu_seqlens</strong> (<code>torch.Tensor</code>, <em>optional</em>) &#x2014;
Pre-generated cumulative sequence lengths for Qwen positive prompt.`,name:"prompt_cu_seqlens"},{anchor:"diffusers.Kandinsky5T2IPipeline.__call__.negative_prompt_cu_seqlens",description:`<strong>negative_prompt_cu_seqlens</strong> (<code>torch.Tensor</code>, <em>optional</em>) &#x2014;
Pre-generated cumulative sequence lengths for Qwen negative prompt.`,name:"negative_prompt_cu_seqlens"},{anchor:"diffusers.Kandinsky5T2IPipeline.__call__.output_type",description:`<strong>output_type</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;pil&quot;</code>) &#x2014;
The output format of the generated image.`,name:"output_type"},{anchor:"diffusers.Kandinsky5T2IPipeline.__call__.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code>) &#x2014;
Whether or not to return a <code>KandinskyImagePipelineOutput</code>.`,name:"return_dict"},{anchor:"diffusers.Kandinsky5T2IPipeline.__call__.callback_on_step_end",description:`<strong>callback_on_step_end</strong> (<code>Callable</code>, <code>PipelineCallback</code>, <code>MultiPipelineCallbacks</code>, <em>optional</em>) &#x2014;
A function that is called at the end of each denoising step.`,name:"callback_on_step_end"},{anchor:"diffusers.Kandinsky5T2IPipeline.__call__.callback_on_step_end_tensor_inputs",description:`<strong>callback_on_step_end_tensor_inputs</strong> (<code>List</code>, <em>optional</em>) &#x2014;
The list of tensor inputs for the <code>callback_on_step_end</code> function.`,name:"callback_on_step_end_tensor_inputs"},{anchor:"diffusers.Kandinsky5T2IPipeline.__call__.max_sequence_length",description:`<strong>max_sequence_length</strong> (<code>int</code>, defaults to <code>512</code>) &#x2014;
The maximum sequence length for text encoding.`,name:"max_sequence_length"}],source:"https://github.com/huggingface/diffusers/blob/main/src/diffusers/pipelines/kandinsky5/pipeline_kandinsky_t2i.py#L534",returnDescription:`<script context="module">export const metadata = 'undefined';<\/script>


<p>If <code>return_dict</code> is <code>True</code>, <code>KandinskyImagePipelineOutput</code> is returned, otherwise a <code>tuple</code> is
returned where the first element is a list with the generated images.</p>
`,returnType:`<script context="module">export const metadata = 'undefined';<\/script>


<p><code>~KandinskyImagePipelineOutput</code> or <code>tuple</code></p>
`}}),V=new pt({props:{anchor:"diffusers.Kandinsky5T2IPipeline.__call__.example",$$slots:{default:[yt]},$$scope:{ctx:fe}}}),ie=new $({props:{name:"check_inputs",anchor:"diffusers.Kandinsky5T2IPipeline.check_inputs",parameters:[{name:"prompt",val:""},{name:"negative_prompt",val:""},{name:"height",val:""},{name:"width",val:""},{name:"prompt_embeds_qwen",val:" = None"},{name:"prompt_embeds_clip",val:" = None"},{name:"negative_prompt_embeds_qwen",val:" = None"},{name:"negative_prompt_embeds_clip",val:" = None"},{name:"prompt_cu_seqlens",val:" = None"},{name:"negative_prompt_cu_seqlens",val:" = None"},{name:"callback_on_step_end_tensor_inputs",val:" = None"},{name:"max_sequence_length",val:" = None"}],parametersDescription:[{anchor:"diffusers.Kandinsky5T2IPipeline.check_inputs.prompt",description:"<strong>prompt</strong> &#x2014; Input prompt",name:"prompt"},{anchor:"diffusers.Kandinsky5T2IPipeline.check_inputs.negative_prompt",description:"<strong>negative_prompt</strong> &#x2014; Negative prompt for guidance",name:"negative_prompt"},{anchor:"diffusers.Kandinsky5T2IPipeline.check_inputs.height",description:"<strong>height</strong> &#x2014; Image height",name:"height"},{anchor:"diffusers.Kandinsky5T2IPipeline.check_inputs.width",description:"<strong>width</strong> &#x2014; Image width",name:"width"},{anchor:"diffusers.Kandinsky5T2IPipeline.check_inputs.prompt_embeds_qwen",description:"<strong>prompt_embeds_qwen</strong> &#x2014; Pre-computed Qwen prompt embeddings",name:"prompt_embeds_qwen"},{anchor:"diffusers.Kandinsky5T2IPipeline.check_inputs.prompt_embeds_clip",description:"<strong>prompt_embeds_clip</strong> &#x2014; Pre-computed CLIP prompt embeddings",name:"prompt_embeds_clip"},{anchor:"diffusers.Kandinsky5T2IPipeline.check_inputs.negative_prompt_embeds_qwen",description:"<strong>negative_prompt_embeds_qwen</strong> &#x2014; Pre-computed Qwen negative prompt embeddings",name:"negative_prompt_embeds_qwen"},{anchor:"diffusers.Kandinsky5T2IPipeline.check_inputs.negative_prompt_embeds_clip",description:"<strong>negative_prompt_embeds_clip</strong> &#x2014; Pre-computed CLIP negative prompt embeddings",name:"negative_prompt_embeds_clip"},{anchor:"diffusers.Kandinsky5T2IPipeline.check_inputs.prompt_cu_seqlens",description:"<strong>prompt_cu_seqlens</strong> &#x2014; Pre-computed cumulative sequence lengths for Qwen positive prompt",name:"prompt_cu_seqlens"},{anchor:"diffusers.Kandinsky5T2IPipeline.check_inputs.negative_prompt_cu_seqlens",description:"<strong>negative_prompt_cu_seqlens</strong> &#x2014; Pre-computed cumulative sequence lengths for Qwen negative prompt",name:"negative_prompt_cu_seqlens"},{anchor:"diffusers.Kandinsky5T2IPipeline.check_inputs.callback_on_step_end_tensor_inputs",description:"<strong>callback_on_step_end_tensor_inputs</strong> &#x2014; Callback tensor inputs",name:"callback_on_step_end_tensor_inputs"}],source:"https://github.com/huggingface/diffusers/blob/main/src/diffusers/pipelines/kandinsky5/pipeline_kandinsky_t2i.py#L380",raiseDescription:`<script context="module">export const metadata = 'undefined';<\/script>


<ul>
<li><code>ValueError</code> — If inputs are invalid</li>
</ul>
`,raiseType:`<script context="module">export const metadata = 'undefined';<\/script>


<p><code>ValueError</code></p>
`}}),oe=new $({props:{name:"encode_prompt",anchor:"diffusers.Kandinsky5T2IPipeline.encode_prompt",parameters:[{name:"prompt",val:": typing.Union[str, typing.List[str]]"},{name:"num_images_per_prompt",val:": int = 1"},{name:"max_sequence_length",val:": int = 512"},{name:"device",val:": typing.Optional[torch.device] = None"},{name:"dtype",val:": typing.Optional[torch.dtype] = None"}],parametersDescription:[{anchor:"diffusers.Kandinsky5T2IPipeline.encode_prompt.prompt",description:`<strong>prompt</strong> (<code>str</code> or <code>List[str]</code>) &#x2014;
Prompt to be encoded.`,name:"prompt"},{anchor:"diffusers.Kandinsky5T2IPipeline.encode_prompt.num_images_per_prompt",description:`<strong>num_images_per_prompt</strong> (<code>int</code>, <em>optional</em>, defaults to 1) &#x2014;
Number of images to generate per prompt.`,name:"num_images_per_prompt"},{anchor:"diffusers.Kandinsky5T2IPipeline.encode_prompt.max_sequence_length",description:`<strong>max_sequence_length</strong> (<code>int</code>, <em>optional</em>, defaults to 512) &#x2014;
Maximum sequence length for text encoding. Must be less than 1024`,name:"max_sequence_length"},{anchor:"diffusers.Kandinsky5T2IPipeline.encode_prompt.device",description:`<strong>device</strong> (<code>torch.device</code>, <em>optional</em>) &#x2014;
Torch device.`,name:"device"},{anchor:"diffusers.Kandinsky5T2IPipeline.encode_prompt.dtype",description:`<strong>dtype</strong> (<code>torch.dtype</code>, <em>optional</em>) &#x2014;
Torch dtype.`,name:"dtype"}],source:"https://github.com/huggingface/diffusers/blob/main/src/diffusers/pipelines/kandinsky5/pipeline_kandinsky_t2i.py#L289",returnDescription:`<script context="module">export const metadata = 'undefined';<\/script>


<ul>
<li>Qwen text embeddings of shape (batch_size * num_images_per_prompt, sequence_length, embedding_dim)</li>
<li>CLIP pooled embeddings of shape (batch_size * num_images_per_prompt, clip_embedding_dim)</li>
<li>Cumulative sequence lengths (<code>cu_seqlens</code>) for Qwen embeddings of shape (batch_size *
num_images_per_prompt + 1,)</li>
</ul>
`,returnType:`<script context="module">export const metadata = 'undefined';<\/script>


<p>Tuple[torch.Tensor, torch.Tensor, torch.Tensor]</p>
`}}),re=new $({props:{name:"prepare_latents",anchor:"diffusers.Kandinsky5T2IPipeline.prepare_latents",parameters:[{name:"batch_size",val:": int"},{name:"num_channels_latents",val:": int = 16"},{name:"height",val:": int = 1024"},{name:"width",val:": int = 1024"},{name:"dtype",val:": typing.Optional[torch.dtype] = None"},{name:"device",val:": typing.Optional[torch.device] = None"},{name:"generator",val:": typing.Union[torch._C.Generator, typing.List[torch._C.Generator], NoneType] = None"},{name:"latents",val:": typing.Optional[torch.Tensor] = None"}],parametersDescription:[{anchor:"diffusers.Kandinsky5T2IPipeline.prepare_latents.batch_size",description:"<strong>batch_size</strong> (int) &#x2014; Number of images to generate",name:"batch_size"},{anchor:"diffusers.Kandinsky5T2IPipeline.prepare_latents.num_channels_latents",description:"<strong>num_channels_latents</strong> (int) &#x2014; Number of channels in latent space",name:"num_channels_latents"},{anchor:"diffusers.Kandinsky5T2IPipeline.prepare_latents.height",description:"<strong>height</strong> (int) &#x2014; Height of generated image",name:"height"},{anchor:"diffusers.Kandinsky5T2IPipeline.prepare_latents.width",description:"<strong>width</strong> (int) &#x2014; Width of generated image",name:"width"},{anchor:"diffusers.Kandinsky5T2IPipeline.prepare_latents.dtype",description:"<strong>dtype</strong> (torch.dtype) &#x2014; Data type for latents",name:"dtype"},{anchor:"diffusers.Kandinsky5T2IPipeline.prepare_latents.device",description:"<strong>device</strong> (torch.device) &#x2014; Device to create latents on",name:"device"},{anchor:"diffusers.Kandinsky5T2IPipeline.prepare_latents.generator",description:"<strong>generator</strong> (torch.Generator) &#x2014; Random number generator",name:"generator"},{anchor:"diffusers.Kandinsky5T2IPipeline.prepare_latents.latents",description:"<strong>latents</strong> (torch.Tensor) &#x2014; Pre-existing latents to use",name:"latents"}],source:"https://github.com/huggingface/diffusers/blob/main/src/diffusers/pipelines/kandinsky5/pipeline_kandinsky_t2i.py#L469",returnDescription:`<script context="module">export const metadata = 'undefined';<\/script>


<p>Prepared latent tensor</p>
`,returnType:`<script context="module">export const metadata = 'undefined';<\/script>


<p>torch.Tensor</p>
`}}),le=new E({props:{title:"Kandinsky5I2IPipeline",local:"diffusers.Kandinsky5I2IPipeline",headingTag:"h2"}}),pe=new $({props:{name:"class diffusers.Kandinsky5I2IPipeline",anchor:"diffusers.Kandinsky5I2IPipeline",parameters:[{name:"transformer",val:": Kandinsky5Transformer3DModel"},{name:"vae",val:": AutoencoderKL"},{name:"text_encoder",val:": Qwen2_5_VLForConditionalGeneration"},{name:"tokenizer",val:": Qwen2VLProcessor"},{name:"text_encoder_2",val:": CLIPTextModel"},{name:"tokenizer_2",val:": CLIPTokenizer"},{name:"scheduler",val:": FlowMatchEulerDiscreteScheduler"}],parametersDescription:[{anchor:"diffusers.Kandinsky5I2IPipeline.transformer",description:`<strong>transformer</strong> (<code>Kandinsky5Transformer3DModel</code>) &#x2014;
Conditional Transformer to denoise the encoded image latents.`,name:"transformer"},{anchor:"diffusers.Kandinsky5I2IPipeline.vae",description:`<strong>vae</strong> (<a href="/docs/diffusers/main/en/api/models/autoencoderkl#diffusers.AutoencoderKL">AutoencoderKL</a>) &#x2014;
Variational Auto-Encoder Model <a href="https://huggingface.co/black-forest-labs/FLUX.1-dev" rel="nofollow">black-forest-labs/FLUX.1-dev
(vae)</a> to encode and decode videos to and from latent
representations.`,name:"vae"},{anchor:"diffusers.Kandinsky5I2IPipeline.text_encoder",description:`<strong>text_encoder</strong> (<code>Qwen2_5_VLForConditionalGeneration</code>) &#x2014;
Frozen text-encoder <a href="https://huggingface.co/Qwen/Qwen2.5-VL-7B-Instruct" rel="nofollow">Qwen2.5-VL</a>.`,name:"text_encoder"},{anchor:"diffusers.Kandinsky5I2IPipeline.tokenizer",description:`<strong>tokenizer</strong> (<code>AutoProcessor</code>) &#x2014;
Tokenizer for Qwen2.5-VL.`,name:"tokenizer"},{anchor:"diffusers.Kandinsky5I2IPipeline.text_encoder_2",description:`<strong>text_encoder_2</strong> (<code>CLIPTextModel</code>) &#x2014;
Frozen <a href="https://huggingface.co/docs/transformers/model_doc/clip#transformers.CLIPTextModel" rel="nofollow">CLIP</a>,
specifically the <a href="https://huggingface.co/openai/clip-vit-large-patch14" rel="nofollow">clip-vit-large-patch14</a> variant.`,name:"text_encoder_2"},{anchor:"diffusers.Kandinsky5I2IPipeline.tokenizer_2",description:`<strong>tokenizer_2</strong> (<code>CLIPTokenizer</code>) &#x2014;
Tokenizer for CLIP.`,name:"tokenizer_2"},{anchor:"diffusers.Kandinsky5I2IPipeline.scheduler",description:`<strong>scheduler</strong> (<a href="/docs/diffusers/main/en/api/schedulers/flow_match_euler_discrete#diffusers.FlowMatchEulerDiscreteScheduler">FlowMatchEulerDiscreteScheduler</a>) &#x2014;
A scheduler to be used in combination with <code>transformer</code> to denoise the encoded image latents.`,name:"scheduler"}],source:"https://github.com/huggingface/diffusers/blob/main/src/diffusers/pipelines/kandinsky5/pipeline_kandinsky_i2i.py#L120"}}),de=new $({props:{name:"__call__",anchor:"diffusers.Kandinsky5I2IPipeline.__call__",parameters:[{name:"image",val:": typing.Union[PIL.Image.Image, numpy.ndarray, torch.Tensor, typing.List[PIL.Image.Image], typing.List[numpy.ndarray], typing.List[torch.Tensor]]"},{name:"prompt",val:": typing.Union[str, typing.List[str]] = None"},{name:"negative_prompt",val:": typing.Union[str, typing.List[str], NoneType] = None"},{name:"height",val:": typing.Optional[int] = None"},{name:"width",val:": typing.Optional[int] = None"},{name:"num_inference_steps",val:": int = 50"},{name:"guidance_scale",val:": float = 3.5"},{name:"num_images_per_prompt",val:": typing.Optional[int] = 1"},{name:"generator",val:": typing.Union[torch._C.Generator, typing.List[torch._C.Generator], NoneType] = None"},{name:"latents",val:": typing.Optional[torch.Tensor] = None"},{name:"prompt_embeds_qwen",val:": typing.Optional[torch.Tensor] = None"},{name:"prompt_embeds_clip",val:": typing.Optional[torch.Tensor] = None"},{name:"negative_prompt_embeds_qwen",val:": typing.Optional[torch.Tensor] = None"},{name:"negative_prompt_embeds_clip",val:": typing.Optional[torch.Tensor] = None"},{name:"prompt_cu_seqlens",val:": typing.Optional[torch.Tensor] = None"},{name:"negative_prompt_cu_seqlens",val:": typing.Optional[torch.Tensor] = None"},{name:"output_type",val:": typing.Optional[str] = 'pil'"},{name:"return_dict",val:": bool = True"},{name:"callback_on_step_end",val:": typing.Union[typing.Callable[[int, int, typing.Dict], NoneType], diffusers.callbacks.PipelineCallback, diffusers.callbacks.MultiPipelineCallbacks, NoneType] = None"},{name:"callback_on_step_end_tensor_inputs",val:": typing.List[str] = ['latents']"},{name:"max_sequence_length",val:": int = 1024"}],parametersDescription:[{anchor:"diffusers.Kandinsky5I2IPipeline.__call__.image",description:`<strong>image</strong> (<code>PipelineImageInput</code>) &#x2014;
The input image to condition the generation on. Must be an image, a list of images or a <code>torch.Tensor</code>.`,name:"image"},{anchor:"diffusers.Kandinsky5I2IPipeline.__call__.prompt",description:`<strong>prompt</strong> (<code>str</code> or <code>List[str]</code>, <em>optional</em>) &#x2014;
The prompt or prompts to guide the image generation. If not defined, pass <code>prompt_embeds</code> instead.`,name:"prompt"},{anchor:"diffusers.Kandinsky5I2IPipeline.__call__.negative_prompt",description:`<strong>negative_prompt</strong> (<code>str</code> or <code>List[str]</code>, <em>optional</em>) &#x2014;
The prompt or prompts to avoid during image generation. If not defined, pass <code>negative_prompt_embeds</code>
instead. Ignored when not using guidance (<code>guidance_scale</code> &lt; <code>1</code>).`,name:"negative_prompt"},{anchor:"diffusers.Kandinsky5I2IPipeline.__call__.height",description:`<strong>height</strong> (<code>int</code>) &#x2014;
The height in pixels of the generated image.`,name:"height"},{anchor:"diffusers.Kandinsky5I2IPipeline.__call__.width",description:`<strong>width</strong> (<code>int</code>) &#x2014;
The width in pixels of the generated image.`,name:"width"},{anchor:"diffusers.Kandinsky5I2IPipeline.__call__.num_inference_steps",description:`<strong>num_inference_steps</strong> (<code>int</code>, defaults to <code>50</code>) &#x2014;
The number of denoising steps.`,name:"num_inference_steps"},{anchor:"diffusers.Kandinsky5I2IPipeline.__call__.guidance_scale",description:`<strong>guidance_scale</strong> (<code>float</code>, defaults to <code>5.0</code>) &#x2014;
Guidance scale as defined in classifier-free guidance.`,name:"guidance_scale"},{anchor:"diffusers.Kandinsky5I2IPipeline.__call__.num_images_per_prompt",description:`<strong>num_images_per_prompt</strong> (<code>int</code>, <em>optional</em>, defaults to 1) &#x2014;
The number of images to generate per prompt.`,name:"num_images_per_prompt"},{anchor:"diffusers.Kandinsky5I2IPipeline.__call__.generator",description:`<strong>generator</strong> (<code>torch.Generator</code> or <code>List[torch.Generator]</code>, <em>optional</em>) &#x2014;
A torch generator to make generation deterministic.`,name:"generator"},{anchor:"diffusers.Kandinsky5I2IPipeline.__call__.latents",description:`<strong>latents</strong> (<code>torch.Tensor</code>, <em>optional</em>) &#x2014;
Pre-generated noisy latents.`,name:"latents"},{anchor:"diffusers.Kandinsky5I2IPipeline.__call__.prompt_embeds_qwen",description:`<strong>prompt_embeds_qwen</strong> (<code>torch.Tensor</code>, <em>optional</em>) &#x2014;
Pre-generated Qwen text embeddings.`,name:"prompt_embeds_qwen"},{anchor:"diffusers.Kandinsky5I2IPipeline.__call__.prompt_embeds_clip",description:`<strong>prompt_embeds_clip</strong> (<code>torch.Tensor</code>, <em>optional</em>) &#x2014;
Pre-generated CLIP text embeddings.`,name:"prompt_embeds_clip"},{anchor:"diffusers.Kandinsky5I2IPipeline.__call__.negative_prompt_embeds_qwen",description:`<strong>negative_prompt_embeds_qwen</strong> (<code>torch.Tensor</code>, <em>optional</em>) &#x2014;
Pre-generated Qwen negative text embeddings.`,name:"negative_prompt_embeds_qwen"},{anchor:"diffusers.Kandinsky5I2IPipeline.__call__.negative_prompt_embeds_clip",description:`<strong>negative_prompt_embeds_clip</strong> (<code>torch.Tensor</code>, <em>optional</em>) &#x2014;
Pre-generated CLIP negative text embeddings.`,name:"negative_prompt_embeds_clip"},{anchor:"diffusers.Kandinsky5I2IPipeline.__call__.prompt_cu_seqlens",description:`<strong>prompt_cu_seqlens</strong> (<code>torch.Tensor</code>, <em>optional</em>) &#x2014;
Pre-generated cumulative sequence lengths for Qwen positive prompt.`,name:"prompt_cu_seqlens"},{anchor:"diffusers.Kandinsky5I2IPipeline.__call__.negative_prompt_cu_seqlens",description:`<strong>negative_prompt_cu_seqlens</strong> (<code>torch.Tensor</code>, <em>optional</em>) &#x2014;
Pre-generated cumulative sequence lengths for Qwen negative prompt.`,name:"negative_prompt_cu_seqlens"},{anchor:"diffusers.Kandinsky5I2IPipeline.__call__.output_type",description:`<strong>output_type</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;pil&quot;</code>) &#x2014;
The output format of the generated image.`,name:"output_type"},{anchor:"diffusers.Kandinsky5I2IPipeline.__call__.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code>) &#x2014;
Whether or not to return a <code>KandinskyImagePipelineOutput</code>.`,name:"return_dict"},{anchor:"diffusers.Kandinsky5I2IPipeline.__call__.callback_on_step_end",description:`<strong>callback_on_step_end</strong> (<code>Callable</code>, <code>PipelineCallback</code>, <code>MultiPipelineCallbacks</code>, <em>optional</em>) &#x2014;
A function that is called at the end of each denoising step.`,name:"callback_on_step_end"},{anchor:"diffusers.Kandinsky5I2IPipeline.__call__.callback_on_step_end_tensor_inputs",description:`<strong>callback_on_step_end_tensor_inputs</strong> (<code>List</code>, <em>optional</em>) &#x2014;
The list of tensor inputs for the <code>callback_on_step_end</code> function.`,name:"callback_on_step_end_tensor_inputs"},{anchor:"diffusers.Kandinsky5I2IPipeline.__call__.max_sequence_length",description:`<strong>max_sequence_length</strong> (<code>int</code>, defaults to <code>1024</code>) &#x2014;
The maximum sequence length for text and image qwen encoding. Must be less than 1024`,name:"max_sequence_length"}],source:"https://github.com/huggingface/diffusers/blob/main/src/diffusers/pipelines/kandinsky5/pipeline_kandinsky_i2i.py#L566",returnDescription:`<script context="module">export const metadata = 'undefined';<\/script>


<p>If <code>return_dict</code> is <code>True</code>, <code>KandinskyImagePipelineOutput</code> is returned, otherwise a <code>tuple</code> is
returned where the first element is a list with the generated images.</p>
`,returnType:`<script context="module">export const metadata = 'undefined';<\/script>


<p><code>~KandinskyImagePipelineOutput</code> or <code>tuple</code></p>
`}}),N=new pt({props:{anchor:"diffusers.Kandinsky5I2IPipeline.__call__.example",$$slots:{default:[bt]},$$scope:{ctx:fe}}}),ce=new $({props:{name:"check_inputs",anchor:"diffusers.Kandinsky5I2IPipeline.check_inputs",parameters:[{name:"prompt",val:""},{name:"negative_prompt",val:""},{name:"image",val:""},{name:"height",val:""},{name:"width",val:""},{name:"prompt_embeds_qwen",val:" = None"},{name:"prompt_embeds_clip",val:" = None"},{name:"negative_prompt_embeds_qwen",val:" = None"},{name:"negative_prompt_embeds_clip",val:" = None"},{name:"prompt_cu_seqlens",val:" = None"},{name:"negative_prompt_cu_seqlens",val:" = None"},{name:"callback_on_step_end_tensor_inputs",val:" = None"},{name:"max_sequence_length",val:" = None"}],parametersDescription:[{anchor:"diffusers.Kandinsky5I2IPipeline.check_inputs.prompt",description:"<strong>prompt</strong> &#x2014; Input prompt",name:"prompt"},{anchor:"diffusers.Kandinsky5I2IPipeline.check_inputs.negative_prompt",description:"<strong>negative_prompt</strong> &#x2014; Negative prompt for guidance",name:"negative_prompt"},{anchor:"diffusers.Kandinsky5I2IPipeline.check_inputs.image",description:"<strong>image</strong> &#x2014; Input image for conditioning",name:"image"},{anchor:"diffusers.Kandinsky5I2IPipeline.check_inputs.height",description:"<strong>height</strong> &#x2014; Image height",name:"height"},{anchor:"diffusers.Kandinsky5I2IPipeline.check_inputs.width",description:"<strong>width</strong> &#x2014; Image width",name:"width"},{anchor:"diffusers.Kandinsky5I2IPipeline.check_inputs.prompt_embeds_qwen",description:"<strong>prompt_embeds_qwen</strong> &#x2014; Pre-computed Qwen prompt embeddings",name:"prompt_embeds_qwen"},{anchor:"diffusers.Kandinsky5I2IPipeline.check_inputs.prompt_embeds_clip",description:"<strong>prompt_embeds_clip</strong> &#x2014; Pre-computed CLIP prompt embeddings",name:"prompt_embeds_clip"},{anchor:"diffusers.Kandinsky5I2IPipeline.check_inputs.negative_prompt_embeds_qwen",description:"<strong>negative_prompt_embeds_qwen</strong> &#x2014; Pre-computed Qwen negative prompt embeddings",name:"negative_prompt_embeds_qwen"},{anchor:"diffusers.Kandinsky5I2IPipeline.check_inputs.negative_prompt_embeds_clip",description:"<strong>negative_prompt_embeds_clip</strong> &#x2014; Pre-computed CLIP negative prompt embeddings",name:"negative_prompt_embeds_clip"},{anchor:"diffusers.Kandinsky5I2IPipeline.check_inputs.prompt_cu_seqlens",description:"<strong>prompt_cu_seqlens</strong> &#x2014; Pre-computed cumulative sequence lengths for Qwen positive prompt",name:"prompt_cu_seqlens"},{anchor:"diffusers.Kandinsky5I2IPipeline.check_inputs.negative_prompt_cu_seqlens",description:"<strong>negative_prompt_cu_seqlens</strong> &#x2014; Pre-computed cumulative sequence lengths for Qwen negative prompt",name:"negative_prompt_cu_seqlens"},{anchor:"diffusers.Kandinsky5I2IPipeline.check_inputs.callback_on_step_end_tensor_inputs",description:"<strong>callback_on_step_end_tensor_inputs</strong> &#x2014; Callback tensor inputs",name:"callback_on_step_end_tensor_inputs"}],source:"https://github.com/huggingface/diffusers/blob/main/src/diffusers/pipelines/kandinsky5/pipeline_kandinsky_i2i.py#L388",raiseDescription:`<script context="module">export const metadata = 'undefined';<\/script>


<ul>
<li><code>ValueError</code> — If inputs are invalid</li>
</ul>
`,raiseType:`<script context="module">export const metadata = 'undefined';<\/script>


<p><code>ValueError</code></p>
`}}),me=new $({props:{name:"encode_prompt",anchor:"diffusers.Kandinsky5I2IPipeline.encode_prompt",parameters:[{name:"prompt",val:": typing.Union[str, typing.List[str]]"},{name:"image",val:": Tensor"},{name:"num_images_per_prompt",val:": int = 1"},{name:"max_sequence_length",val:": int = 1024"},{name:"device",val:": typing.Optional[torch.device] = None"},{name:"dtype",val:": typing.Optional[torch.dtype] = None"}],parametersDescription:[{anchor:"diffusers.Kandinsky5I2IPipeline.encode_prompt.prompt",description:`<strong>prompt</strong> (<code>str</code> or <code>List[str]</code>) &#x2014;
Prompt to be encoded.`,name:"prompt"},{anchor:"diffusers.Kandinsky5I2IPipeline.encode_prompt.num_images_per_prompt",description:`<strong>num_images_per_prompt</strong> (<code>int</code>, <em>optional</em>, defaults to 1) &#x2014;
Number of images to generate per prompt.`,name:"num_images_per_prompt"},{anchor:"diffusers.Kandinsky5I2IPipeline.encode_prompt.max_sequence_length",description:`<strong>max_sequence_length</strong> (<code>int</code>, <em>optional</em>, defaults to 1024) &#x2014;
Maximum sequence length for text encoding. Must be less than 1024`,name:"max_sequence_length"},{anchor:"diffusers.Kandinsky5I2IPipeline.encode_prompt.device",description:`<strong>device</strong> (<code>torch.device</code>, <em>optional</em>) &#x2014;
Torch device.`,name:"device"},{anchor:"diffusers.Kandinsky5I2IPipeline.encode_prompt.dtype",description:`<strong>dtype</strong> (<code>torch.dtype</code>, <em>optional</em>) &#x2014;
Torch dtype.`,name:"dtype"}],source:"https://github.com/huggingface/diffusers/blob/main/src/diffusers/pipelines/kandinsky5/pipeline_kandinsky_i2i.py#L295",returnDescription:`<script context="module">export const metadata = 'undefined';<\/script>


<ul>
<li>Qwen text embeddings of shape (batch_size * num_images_per_prompt, sequence_length, embedding_dim)</li>
<li>CLIP pooled embeddings of shape (batch_size * num_images_per_prompt, clip_embedding_dim)</li>
<li>Cumulative sequence lengths (<code>cu_seqlens</code>) for Qwen embeddings of shape (batch_size *
num_images_per_prompt + 1,)</li>
</ul>
`,returnType:`<script context="module">export const metadata = 'undefined';<\/script>


<p>Tuple[torch.Tensor, torch.Tensor, torch.Tensor]</p>
`}}),ge=new $({props:{name:"prepare_latents",anchor:"diffusers.Kandinsky5I2IPipeline.prepare_latents",parameters:[{name:"image",val:": typing.Union[PIL.Image.Image, numpy.ndarray, torch.Tensor, typing.List[PIL.Image.Image], typing.List[numpy.ndarray], typing.List[torch.Tensor]]"},{name:"batch_size",val:": int"},{name:"num_channels_latents",val:": int = 16"},{name:"height",val:": int = 1024"},{name:"width",val:": int = 1024"},{name:"dtype",val:": typing.Optional[torch.dtype] = None"},{name:"device",val:": typing.Optional[torch.device] = None"},{name:"generator",val:": typing.Union[torch._C.Generator, typing.List[torch._C.Generator], NoneType] = None"},{name:"latents",val:": typing.Optional[torch.Tensor] = None"}],parametersDescription:[{anchor:"diffusers.Kandinsky5I2IPipeline.prepare_latents.image",description:"<strong>image</strong> (PipelineImageInput) &#x2014; Input image to condition the generation on",name:"image"},{anchor:"diffusers.Kandinsky5I2IPipeline.prepare_latents.batch_size",description:"<strong>batch_size</strong> (int) &#x2014; Number of images to generate",name:"batch_size"},{anchor:"diffusers.Kandinsky5I2IPipeline.prepare_latents.num_channels_latents",description:"<strong>num_channels_latents</strong> (int) &#x2014; Number of channels in latent space",name:"num_channels_latents"},{anchor:"diffusers.Kandinsky5I2IPipeline.prepare_latents.height",description:"<strong>height</strong> (int) &#x2014; Height of generated image",name:"height"},{anchor:"diffusers.Kandinsky5I2IPipeline.prepare_latents.width",description:"<strong>width</strong> (int) &#x2014; Width of generated image",name:"width"},{anchor:"diffusers.Kandinsky5I2IPipeline.prepare_latents.dtype",description:"<strong>dtype</strong> (torch.dtype) &#x2014; Data type for latents",name:"dtype"},{anchor:"diffusers.Kandinsky5I2IPipeline.prepare_latents.device",description:"<strong>device</strong> (torch.device) &#x2014; Device to create latents on",name:"device"},{anchor:"diffusers.Kandinsky5I2IPipeline.prepare_latents.generator",description:"<strong>generator</strong> (torch.Generator) &#x2014; Random number generator",name:"generator"},{anchor:"diffusers.Kandinsky5I2IPipeline.prepare_latents.latents",description:"<strong>latents</strong> (torch.Tensor) &#x2014; Pre-existing latents to use",name:"latents"}],source:"https://github.com/huggingface/diffusers/blob/main/src/diffusers/pipelines/kandinsky5/pipeline_kandinsky_i2i.py#L482",returnDescription:`<script context="module">export const metadata = 'undefined';<\/script>


<p>Prepared latent tensor with encoded image</p>
`,returnType:`<script context="module">export const metadata = 'undefined';<\/script>


<p>torch.Tensor</p>
`}}),he=new E({props:{title:"Citation",local:"citation",headingTag:"h2"}}),ue=new Ne({props:{code:"JTQwbWlzYyU3QmthbmRpbnNreTIwMjUlMkMlMEElMjAlMjAlMjAlMjBhdXRob3IlMjAlM0QlMjAlN0JBbGV4YW5kZXIlMjBCZWx5a2glMjBhbmQlMjBBbGV4YW5kZXIlMjBWYXJsYW1vdiUyMGFuZCUyMEFsZXhleSUyMExldHVub3Zza2l5JTIwYW5kJTIwQW5hc3Rhc2lhJTIwQWxpYXNraW5hJTIwYW5kJTIwQW5hc3Rhc2lhJTIwTWFsdHNldmElMjBhbmQlMjBBbmFzdGFzaWlhJTIwS2FyZ2Fwb2x0c2V2YSUyMGFuZCUyMEFuZHJleSUyMFNodXRraW4lMjBhbmQlMjBBbm5hJTIwQXZlcmNoZW5rb3ZhJTIwYW5kJTIwQW5uYSUyMERtaXRyaWVua28lMjBhbmQlMjBCdWxhdCUyMEFraG1hdG92JTIwYW5kJTIwRGVuaXMlMjBEaW1pdHJvdiUyMGFuZCUyMERlbmlzJTIwS29wb3NvdiUyMGFuZCUyMERlbmlzJTIwUGFya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RCUyMCU3QiU1Q3VybCU3Qmh0dHBzJTNBJTJGJTJGZ2l0aHViLmNvbSUyRmthbmRpbnNreWxhYiUyRkthbmRpbnNreS01JTdEJTdEJTJDJTBBJTIwJTIwJTIwJTIweWVhciUyMCUzRCUyMDIwMjUlMEElN0Q=",highlighted:`<span class="hljs-comment">@misc{kandinsky2025,</span>
    author = {Alexander Belykh <span class="hljs-keyword">and</span> Alexander Varlamov <span class="hljs-keyword">and</span> Alexey Letunovskiy <span class="hljs-keyword">and</span> Anastasia Aliaskina <span class="hljs-keyword">and</span> Anastasia Maltseva <span class="hljs-keyword">and</span> Anastasiia Kargapoltseva <span class="hljs-keyword">and</span> Andrey Shutkin <span class="hljs-keyword">and</span> Anna Averchenkova <span class="hljs-keyword">and</span> Anna Dmitrienko <span class="hljs-keyword">and</span> Bulat Akhmatov <span class="hljs-keyword">and</span> Denis Dimitrov <span class="hljs-keyword">and</span> Denis Koposov <span class="hljs-keyword">and</span> Denis Parkhomenko <span class="hljs-keyword">and</span> Dmitrii <span class="hljs-keyword">and</span> Ilya Vasiliev <span class="hljs-keyword">and</span> Ivan Kirillov <span class="hljs-keyword">and</span> Julia Agafonova <span class="hljs-keyword">and</span> Kirill Chernyshev <span class="hljs-keyword">and</span> Kormilitsyn Semen <span class="hljs-keyword">and</span> Lev Novitskiy <span class="hljs-keyword">and</span> Maria Kovaleva <span class="hljs-keyword">and</span> Mikhail Mamaev <span class="hljs-keyword">and</span> Mikhailov <span class="hljs-keyword">and</span> Nikita Kiselev <span class="hljs-keyword">and</span> Nikita Osterov <span class="hljs-keyword">and</span> Nikolai Gerasimenko <span class="hljs-keyword">and</span> Nikolai Vaulin <span class="hljs-keyword">and</span> Olga Kim <span class="hljs-keyword">and</span> Olga Vdovchenko <span class="hljs-keyword">and</span> Polina Gavrilova <span class="hljs-keyword">and</span> Polina Mikhailova <span class="hljs-keyword">and</span> Tatiana Nikulina <span class="hljs-keyword">and</span> Viacheslav Vasilev <span class="hljs-keyword">and</span> Vladimir Arkhipkin <span class="hljs-keyword">and</span> Vladimir Korviakov <span class="hljs-keyword">and</span> Vladimir Polovnikov <span class="hljs-keyword">and</span> Yury Kolabushin},
    title = {Kandinsky <span class="hljs-number">5</span>.<span class="hljs-number">0</span>: A family of diffusion models for Video &amp; Image generation},
    howpublished = {\\url{https:<span class="hljs-comment">//github.com/kandinskylab/Kandinsky-5}},</span>
    year = <span class="hljs-number">2025</span>
}`,wrap:!1}}),_e=new ft({props:{source:"https://github.com/huggingface/diffusers/blob/main/docs/source/en/api/pipelines/kandinsky5_image.md"}}),{c(){f=r("meta"),U=s(),T=r("p"),y=s(),d(k.$$.fragment),p=s(),d(w.$$.fragment),Qe=s(),q=r("p"),q.innerHTML=Ln,Ee=s(),Y=r("p"),Y.textContent=Nn,qe=s(),F=r("p"),F.textContent=Qn,Ye=s(),S=r("ul"),S.innerHTML=En,Fe=s(),z=r("p"),z.innerHTML=qn,Se=s(),W=r("blockquote"),W.innerHTML=Yn,ze=s(),d(R.$$.fragment),Re=s(),D=r("p"),D.textContent=Fn,De=s(),A=r("table"),A.innerHTML=Sn,Ae=s(),d(X.$$.fragment),Xe=s(),d(H.$$.fragment),He=s(),d(O.$$.fragment),Oe=s(),d(ee.$$.fragment),en=s(),d(ne.$$.fragment),nn=s(),d(te.$$.fragment),tn=s(),b=r("div"),d(se.$$.fragment),gn=s(),ye=r("p"),ye.textContent=zn,hn=s(),be=r("p"),be.innerHTML=Rn,un=s(),j=r("div"),d(ae.$$.fragment),_n=s(),Me=r("p"),Me.textContent=Dn,fn=s(),d(V.$$.fragment),yn=s(),L=r("div"),d(ie.$$.fragment),bn=s(),ke=r("p"),ke.textContent=An,Mn=s(),C=r("div"),d(oe.$$.fragment),kn=s(),Ie=r("p"),Ie.textContent=Xn,In=s(),Te=r("p"),Te.textContent=Hn,Tn=s(),P=r("div"),d(re.$$.fragment),wn=s(),we=r("p"),we.textContent=On,vn=s(),ve=r("p"),ve.textContent=et,sn=s(),d(le.$$.fragment),an=s(),M=r("div"),d(pe.$$.fragment),xn=s(),xe=r("p"),xe.textContent=nt,Jn=s(),Je=r("p"),Je.innerHTML=tt,Un=s(),G=r("div"),d(de.$$.fragment),jn=s(),Ue=r("p"),Ue.textContent=st,Cn=s(),d(N.$$.fragment),Pn=s(),Q=r("div"),d(ce.$$.fragment),Gn=s(),je=r("p"),je.textContent=at,Zn=s(),Z=r("div"),d(me.$$.fragment),Bn=s(),Ce=r("p"),Ce.textContent=it,$n=s(),Pe=r("p"),Pe.textContent=ot,Kn=s(),B=r("div"),d(ge.$$.fragment),Wn=s(),Ge=r("p"),Ge.textContent=rt,Vn=s(),Ze=r("p"),Ze.textContent=lt,on=s(),d(he.$$.fragment),rn=s(),d(ue.$$.fragment),ln=s(),d(_e.$$.fragment),pn=s(),Le=r("p"),this.h()},l(e){const n=ut("svelte-u9bgzb",document.head);f=l(n,"META",{name:!0,content:!0}),n.forEach(t),U=a(e),T=l(e,"P",{}),J(T).forEach(t),y=a(e),c(k.$$.fragment,e),p=a(e),c(w.$$.fragment,e),Qe=a(e),q=l(e,"P",{"data-svelte-h":!0}),_(q)!=="svelte-1lk8td8"&&(q.innerHTML=Ln),Ee=a(e),Y=l(e,"P",{"data-svelte-h":!0}),_(Y)!=="svelte-j35whm"&&(Y.textContent=Nn),qe=a(e),F=l(e,"P",{"data-svelte-h":!0}),_(F)!=="svelte-cwew0b"&&(F.textContent=Qn),Ye=a(e),S=l(e,"UL",{"data-svelte-h":!0}),_(S)!=="svelte-172agwb"&&(S.innerHTML=En),Fe=a(e),z=l(e,"P",{"data-svelte-h":!0}),_(z)!=="svelte-729g83"&&(z.innerHTML=qn),Se=a(e),W=l(e,"BLOCKQUOTE",{class:!0,"data-svelte-h":!0}),_(W)!=="svelte-131mg47"&&(W.innerHTML=Yn),ze=a(e),c(R.$$.fragment,e),Re=a(e),D=l(e,"P",{"data-svelte-h":!0}),_(D)!=="svelte-1gbu1pw"&&(D.textContent=Fn),De=a(e),A=l(e,"TABLE",{"data-svelte-h":!0}),_(A)!=="svelte-6e62wj"&&(A.innerHTML=Sn),Ae=a(e),c(X.$$.fragment,e),Xe=a(e),c(H.$$.fragment,e),He=a(e),c(O.$$.fragment,e),Oe=a(e),c(ee.$$.fragment,e),en=a(e),c(ne.$$.fragment,e),nn=a(e),c(te.$$.fragment,e),tn=a(e),b=l(e,"DIV",{class:!0});var I=J(b);c(se.$$.fragment,I),gn=a(I),ye=l(I,"P",{"data-svelte-h":!0}),_(ye)!=="svelte-1r29wj1"&&(ye.textContent=zn),hn=a(I),be=l(I,"P",{"data-svelte-h":!0}),_(be)!=="svelte-496sm0"&&(be.innerHTML=Rn),un=a(I),j=l(I,"DIV",{class:!0});var K=J(j);c(ae.$$.fragment,K),_n=a(K),Me=l(K,"P",{"data-svelte-h":!0}),_(Me)!=="svelte-l1jslf"&&(Me.textContent=Dn),fn=a(K),c(V.$$.fragment,K),K.forEach(t),yn=a(I),L=l(I,"DIV",{class:!0});var cn=J(L);c(ie.$$.fragment,cn),bn=a(cn),ke=l(cn,"P",{"data-svelte-h":!0}),_(ke)!=="svelte-11b6rmu"&&(ke.textContent=An),cn.forEach(t),Mn=a(I),C=l(I,"DIV",{class:!0});var Be=J(C);c(oe.$$.fragment,Be),kn=a(Be),Ie=l(Be,"P",{"data-svelte-h":!0}),_(Ie)!=="svelte-1vxta4j"&&(Ie.textContent=Xn),In=a(Be),Te=l(Be,"P",{"data-svelte-h":!0}),_(Te)!=="svelte-9fbstq"&&(Te.textContent=Hn),Be.forEach(t),Tn=a(I),P=l(I,"DIV",{class:!0});var $e=J(P);c(re.$$.fragment,$e),wn=a($e),we=l($e,"P",{"data-svelte-h":!0}),_(we)!=="svelte-7ftil2"&&(we.textContent=On),vn=a($e),ve=l($e,"P",{"data-svelte-h":!0}),_(ve)!=="svelte-bj1keu"&&(ve.textContent=et),$e.forEach(t),I.forEach(t),sn=a(e),c(le.$$.fragment,e),an=a(e),M=l(e,"DIV",{class:!0});var v=J(M);c(pe.$$.fragment,v),xn=a(v),xe=l(v,"P",{"data-svelte-h":!0}),_(xe)!=="svelte-x3jqyj"&&(xe.textContent=nt),Jn=a(v),Je=l(v,"P",{"data-svelte-h":!0}),_(Je)!=="svelte-496sm0"&&(Je.innerHTML=tt),Un=a(v),G=l(v,"DIV",{class:!0});var Ke=J(G);c(de.$$.fragment,Ke),jn=a(Ke),Ue=l(Ke,"P",{"data-svelte-h":!0}),_(Ue)!=="svelte-xac1e3"&&(Ue.textContent=st),Cn=a(Ke),c(N.$$.fragment,Ke),Ke.forEach(t),Pn=a(v),Q=l(v,"DIV",{class:!0});var mn=J(Q);c(ce.$$.fragment,mn),Gn=a(mn),je=l(mn,"P",{"data-svelte-h":!0}),_(je)!=="svelte-11b6rmu"&&(je.textContent=at),mn.forEach(t),Zn=a(v),Z=l(v,"DIV",{class:!0});var We=J(Z);c(me.$$.fragment,We),Bn=a(We),Ce=l(We,"P",{"data-svelte-h":!0}),_(Ce)!=="svelte-1vxta4j"&&(Ce.textContent=it),$n=a(We),Pe=l(We,"P",{"data-svelte-h":!0}),_(Pe)!=="svelte-9fbstq"&&(Pe.textContent=ot),We.forEach(t),Kn=a(v),B=l(v,"DIV",{class:!0});var Ve=J(B);c(ge.$$.fragment,Ve),Wn=a(Ve),Ge=l(Ve,"P",{"data-svelte-h":!0}),_(Ge)!=="svelte-eoucjy"&&(Ge.textContent=rt),Vn=a(Ve),Ze=l(Ve,"P",{"data-svelte-h":!0}),_(Ze)!=="svelte-pb8sip"&&(Ze.textContent=lt),Ve.forEach(t),v.forEach(t),on=a(e),c(he.$$.fragment,e),rn=a(e),c(ue.$$.fragment,e),ln=a(e),c(_e.$$.fragment,e),pn=a(e),Le=l(e,"P",{}),J(Le).forEach(t),this.h()},h(){x(f,"name","hf:doc:metadata"),x(f,"content",kt),x(W,"class","tip"),x(j,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),x(L,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),x(C,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),x(P,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),x(b,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),x(G,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),x(Q,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),x(Z,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),x(B,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),x(M,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8")},m(e,n){i(document.head,f),o(e,U,n),o(e,T,n),o(e,y,n),m(k,e,n),o(e,p,n),m(w,e,n),o(e,Qe,n),o(e,q,n),o(e,Ee,n),o(e,Y,n),o(e,qe,n),o(e,F,n),o(e,Ye,n),o(e,S,n),o(e,Fe,n),o(e,z,n),o(e,Se,n),o(e,W,n),o(e,ze,n),m(R,e,n),o(e,Re,n),o(e,D,n),o(e,De,n),o(e,A,n),o(e,Ae,n),m(X,e,n),o(e,Xe,n),m(H,e,n),o(e,He,n),m(O,e,n),o(e,Oe,n),m(ee,e,n),o(e,en,n),m(ne,e,n),o(e,nn,n),m(te,e,n),o(e,tn,n),o(e,b,n),m(se,b,null),i(b,gn),i(b,ye),i(b,hn),i(b,be),i(b,un),i(b,j),m(ae,j,null),i(j,_n),i(j,Me),i(j,fn),m(V,j,null),i(b,yn),i(b,L),m(ie,L,null),i(L,bn),i(L,ke),i(b,Mn),i(b,C),m(oe,C,null),i(C,kn),i(C,Ie),i(C,In),i(C,Te),i(b,Tn),i(b,P),m(re,P,null),i(P,wn),i(P,we),i(P,vn),i(P,ve),o(e,sn,n),m(le,e,n),o(e,an,n),o(e,M,n),m(pe,M,null),i(M,xn),i(M,xe),i(M,Jn),i(M,Je),i(M,Un),i(M,G),m(de,G,null),i(G,jn),i(G,Ue),i(G,Cn),m(N,G,null),i(M,Pn),i(M,Q),m(ce,Q,null),i(Q,Gn),i(Q,je),i(M,Zn),i(M,Z),m(me,Z,null),i(Z,Bn),i(Z,Ce),i(Z,$n),i(Z,Pe),i(M,Kn),i(M,B),m(ge,B,null),i(B,Wn),i(B,Ge),i(B,Vn),i(B,Ze),o(e,on,n),m(he,e,n),o(e,rn,n),m(ue,e,n),o(e,ln,n),m(_e,e,n),o(e,pn,n),o(e,Le,n),dn=!0},p(e,[n]){const I={};n&2&&(I.$$scope={dirty:n,ctx:e}),V.$set(I);const K={};n&2&&(K.$$scope={dirty:n,ctx:e}),N.$set(K)},i(e){dn||(g(k.$$.fragment,e),g(w.$$.fragment,e),g(R.$$.fragment,e),g(X.$$.fragment,e),g(H.$$.fragment,e),g(O.$$.fragment,e),g(ee.$$.fragment,e),g(ne.$$.fragment,e),g(te.$$.fragment,e),g(se.$$.fragment,e),g(ae.$$.fragment,e),g(V.$$.fragment,e),g(ie.$$.fragment,e),g(oe.$$.fragment,e),g(re.$$.fragment,e),g(le.$$.fragment,e),g(pe.$$.fragment,e),g(de.$$.fragment,e),g(N.$$.fragment,e),g(ce.$$.fragment,e),g(me.$$.fragment,e),g(ge.$$.fragment,e),g(he.$$.fragment,e),g(ue.$$.fragment,e),g(_e.$$.fragment,e),dn=!0)},o(e){h(k.$$.fragment,e),h(w.$$.fragment,e),h(R.$$.fragment,e),h(X.$$.fragment,e),h(H.$$.fragment,e),h(O.$$.fragment,e),h(ee.$$.fragment,e),h(ne.$$.fragment,e),h(te.$$.fragment,e),h(se.$$.fragment,e),h(ae.$$.fragment,e),h(V.$$.fragment,e),h(ie.$$.fragment,e),h(oe.$$.fragment,e),h(re.$$.fragment,e),h(le.$$.fragment,e),h(pe.$$.fragment,e),h(de.$$.fragment,e),h(N.$$.fragment,e),h(ce.$$.fragment,e),h(me.$$.fragment,e),h(ge.$$.fragment,e),h(he.$$.fragment,e),h(ue.$$.fragment,e),h(_e.$$.fragment,e),dn=!1},d(e){e&&(t(U),t(T),t(y),t(p),t(Qe),t(q),t(Ee),t(Y),t(qe),t(F),t(Ye),t(S),t(Fe),t(z),t(Se),t(W),t(ze),t(Re),t(D),t(De),t(A),t(Ae),t(Xe),t(He),t(Oe),t(en),t(nn),t(tn),t(b),t(sn),t(an),t(M),t(on),t(rn),t(ln),t(pn),t(Le)),t(f),u(k,e),u(w,e),u(R,e),u(X,e),u(H,e),u(O,e),u(ee,e),u(ne,e),u(te,e),u(se),u(ae),u(V),u(ie),u(oe),u(re),u(le,e),u(pe),u(de),u(N),u(ce),u(me),u(ge),u(he,e),u(ue,e),u(_e,e)}}}const kt='{"title":"Kandinsky 5.0 Image","local":"kandinsky-50-image","sections":[{"title":"Available Models","local":"available-models","sections":[],"depth":2},{"title":"Usage Examples","local":"usage-examples","sections":[{"title":"Basic Text-to-Image Generation","local":"basic-text-to-image-generation","sections":[],"depth":3},{"title":"Basic Image-to-Image Generation","local":"basic-image-to-image-generation","sections":[],"depth":3}],"depth":2},{"title":"Kandinsky5T2IPipeline","local":"diffusers.Kandinsky5T2IPipeline","sections":[],"depth":2},{"title":"Kandinsky5I2IPipeline","local":"diffusers.Kandinsky5I2IPipeline","sections":[],"depth":2},{"title":"Citation","local":"citation","sections":[],"depth":2}],"depth":1}';function It(fe){return mt(()=>{new URLSearchParams(window.location.search).get("fw")}),[]}class Ct extends gt{constructor(f){super(),ht(this,f,It,Mt,ct,{})}}export{Ct as component};
