import{S as Kn,i as Qn,s as Zn,e as i,k as l,w as $,t as r,M as es,c as n,d as o,m as d,a as s,x as w,h as a,b as c,G as e,g as b,y as P,q as E,o as D,B as x,v as ts,L as Rn}from"../../chunks/vendor-hf-doc-builder.js";import{T as tn}from"../../chunks/Tip-hf-doc-builder.js";import{D as q}from"../../chunks/Docstring-hf-doc-builder.js";import{C as Jn}from"../../chunks/CodeBlock-hf-doc-builder.js";import{I as ao}from"../../chunks/IconCopyLink-hf-doc-builder.js";import{E as Gn}from"../../chunks/ExampleCodeBlock-hf-doc-builder.js";function os(S){let f;return{c(){f=r("One should not use the Diffusion Pipeline class for training or fine-tuning a diffusion model. Individual \n	components of diffusion pipelines are usually trained individually, so we suggest to directly work \n	with `UNetModel` and `UNetConditionModel`.")},l(y){f=a(y,"One should not use the Diffusion Pipeline class for training or fine-tuning a diffusion model. Individual \n	components of diffusion pipelines are usually trained individually, so we suggest to directly work \n	with `UNetModel` and `UNetConditionModel`.")},m(y,h){b(y,f,h)},d(y){y&&o(f)}}}function is(S){let f,y,h,g,k;return g=new Jn({props:{code:`import torch
from diffusers import DiffusionPipeline
from xformers.ops import MemoryEfficientAttentionFlashAttentionOp

pipe = DiffusionPipeline.from_pretrained("stabilityai/stable-diffusion-2-1", torch_dtype=torch.float16)
pipe = pipe.to("cuda")
pipe.enable_xformers_memory_efficient_attention(attention_op=MemoryEfficientAttentionFlashAttentionOp)
# Workaround for not accepting attention shape using VAE for Flash Attention
pipe.vae.enable_xformers_memory_efficient_attention(attention_op=None)`,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> DiffusionPipeline
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> xformers.ops <span class="hljs-keyword">import</span> MemoryEfficientAttentionFlashAttentionOp

<span class="hljs-meta">&gt;&gt;&gt; </span>pipe = DiffusionPipeline.from_pretrained(<span class="hljs-string">&quot;stabilityai/stable-diffusion-2-1&quot;</span>, torch_dtype=torch.float16)
<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>pipe.enable_xformers_memory_efficient_attention(attention_op=MemoryEfficientAttentionFlashAttentionOp)
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Workaround for not accepting attention shape using VAE for Flash Attention</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>pipe.vae.enable_xformers_memory_efficient_attention(attention_op=<span class="hljs-literal">None</span>)`}}),{c(){f=i("p"),y=r("Examples:"),h=l(),$(g.$$.fragment)},l(p){f=n(p,"P",{});var v=s(f);y=a(v,"Examples:"),v.forEach(o),h=d(p),w(g.$$.fragment,p)},m(p,v){b(p,f,v),e(f,y),b(p,h,v),P(g,p,v),k=!0},p:Rn,i(p){k||(E(g.$$.fragment,p),k=!0)},o(p){D(g.$$.fragment,p),k=!1},d(p){p&&o(f),p&&o(h),x(g,p)}}}function ns(S){let f,y,h,g,k,p,v,M,V,K,L,F,N;return{c(){f=i("p"),y=r("It is required to be logged in ("),h=i("code"),g=r("huggingface-cli login"),k=r(") when you want to use private or "),p=i("a"),v=r(`gated
models`),M=r(", "),V=i("em"),K=r("e.g."),L=l(),F=i("code"),N=r('"runwayml/stable-diffusion-v1-5"'),this.h()},l(U){f=n(U,"P",{});var O=s(f);y=a(O,"It is required to be logged in ("),h=n(O,"CODE",{});var X=s(h);g=a(X,"huggingface-cli login"),X.forEach(o),k=a(O,") when you want to use private or "),p=n(O,"A",{href:!0,rel:!0});var Xe=s(p);v=a(Xe,`gated
models`),Xe.forEach(o),M=a(O,", "),V=n(O,"EM",{});var ze=s(V);K=a(ze,"e.g."),ze.forEach(o),L=d(O),F=n(O,"CODE",{});var ue=s(F);N=a(ue,'"runwayml/stable-diffusion-v1-5"'),ue.forEach(o),O.forEach(o),this.h()},h(){c(p,"href","https://huggingface.co/docs/hub/models-gated#gated-models"),c(p,"rel","nofollow")},m(U,O){b(U,f,O),e(f,y),e(f,h),e(h,g),e(f,k),e(f,p),e(p,v),e(f,M),e(f,V),e(V,K),e(f,L),e(f,F),e(F,N)},d(U){U&&o(f)}}}function ss(S){let f,y,h,g,k;return{c(){f=i("p"),y=r("Activate the special "),h=i("a"),g=r("\u201Coffline-mode\u201D"),k=r(` to use
this method in a firewalled environment.`),this.h()},l(p){f=n(p,"P",{});var v=s(f);y=a(v,"Activate the special "),h=n(v,"A",{href:!0,rel:!0});var M=s(h);g=a(M,"\u201Coffline-mode\u201D"),M.forEach(o),k=a(v,` to use
this method in a firewalled environment.`),v.forEach(o),this.h()},h(){c(h,"href","https://huggingface.co/diffusers/installation.html#offline-mode"),c(h,"rel","nofollow")},m(p,v){b(p,f,v),e(f,y),e(f,h),e(h,g),e(f,k)},d(p){p&&o(f)}}}function rs(S){let f,y,h,g,k;return g=new Jn({props:{code:`from diffusers import DiffusionPipeline

# Download pipeline from huggingface.co and cache.
pipeline = DiffusionPipeline.from_pretrained("CompVis/ldm-text2im-large-256")

# Download pipeline that requires an authorization token
# For more information on access tokens, please refer to this section
# of the documentation](https://huggingface.co/docs/hub/security-tokens)
pipeline = DiffusionPipeline.from_pretrained("runwayml/stable-diffusion-v1-5")

# Use a different scheduler
from diffusers import LMSDiscreteScheduler

scheduler = LMSDiscreteScheduler.from_config(pipeline.scheduler.config)
pipeline.scheduler = scheduler`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> diffusers <span class="hljs-keyword">import</span> DiffusionPipeline

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Download pipeline from huggingface.co and cache.</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>pipeline = DiffusionPipeline.from_pretrained(<span class="hljs-string">&quot;CompVis/ldm-text2im-large-256&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Download pipeline that requires an authorization token</span>
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># For more information on access tokens, please refer to this section</span>
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># of the documentation](https://huggingface.co/docs/hub/security-tokens)</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>pipeline = DiffusionPipeline.from_pretrained(<span class="hljs-string">&quot;runwayml/stable-diffusion-v1-5&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Use a different scheduler</span>
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> diffusers <span class="hljs-keyword">import</span> LMSDiscreteScheduler

<span class="hljs-meta">&gt;&gt;&gt; </span>scheduler = LMSDiscreteScheduler.from_config(pipeline.scheduler.config)
<span class="hljs-meta">&gt;&gt;&gt; </span>pipeline.scheduler = scheduler`}}),{c(){f=i("p"),y=r("Examples:"),h=l(),$(g.$$.fragment)},l(p){f=n(p,"P",{});var v=s(f);y=a(v,"Examples:"),v.forEach(o),h=d(p),w(g.$$.fragment,p)},m(p,v){b(p,f,v),e(f,y),b(p,h,v),P(g,p,v),k=!0},p:Rn,i(p){k||(E(g.$$.fragment,p),k=!0)},o(p){D(g.$$.fragment,p),k=!1},d(p){p&&o(f),p&&o(h),x(g,p)}}}function as(S){let f,y,h,g,k,p,v,M,V,K,L,F,N,U,O,X,Xe,ze,ue,Q,Ct,I,lo,We,po,fo,Re,co,mo,Ve,uo,ho,Je,go,_o,Ke,vo,bo,Qe,yo,$o,qt,Z,wo,Fe,Po,Eo,St,H,ee,Ze,he,Do,et,xo,Mt,m,ge,ko,tt,Ao,Io,Ue,He,jo,Oo,Lo,_e,ot,To,Co,it,qo,So,nt,Mo,No,ve,te,st,Xo,zo,rt,Wo,Vo,Fo,oe,at,Uo,Ho,lt,Yo,Bo,Go,ie,be,Ro,dt,Jo,Ko,Ye,ye,Qo,Be,$e,Zo,ne,we,ei,Pe,ti,pt,oi,ii,ni,se,Ee,si,ft,ri,ai,z,De,li,ct,di,pi,mt,fi,ci,T,xe,mi,ut,ui,hi,ht,gi,_i,gt,vi,bi,re,yi,A,ke,$i,_t,wi,Pi,Ae,Ei,vt,Di,xi,ki,Ie,Ai,bt,Ii,ji,Oi,je,Li,yt,Ti,Ci,qi,ae,Si,le,Mi,de,Ni,pe,Oe,Xi,$t,zi,Wi,fe,Le,Vi,Te,Fi,wt,Ui,Hi,Nt,Y,ce,Pt,Ce,Yi,Et,Bi,Xt,B,qe,Gi,Dt,Ri,zt,G,me,xt,Se,Ji,kt,Ki,Wt,R,Me,Qi,At,Zi,Vt;return p=new ao({}),Q=new tn({props:{$$slots:{default:[os]},$$scope:{ctx:S}}}),he=new ao({}),ge=new q({props:{name:"class diffusers.DiffusionPipeline",anchor:"diffusers.DiffusionPipeline",parameters:[],source:"https://github.com/huggingface/diffusers/blob/v0.12.0/src/diffusers/pipelines/pipeline_utils.py#L140"}}),be=new q({props:{name:"__call__",anchor:"diffusers.DiffusionPipeline.__call__",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}]}}),ye=new q({props:{name:"device",anchor:"diffusers.DiffusionPipeline.device",parameters:[],source:"https://github.com/huggingface/diffusers/blob/v0.12.0/src/diffusers/pipelines/pipeline_utils.py#L275",returnDescription:`
<p>The torch device on which the pipeline is located.</p>
`,returnType:`
<p><code>torch.device</code></p>
`}}),$e=new q({props:{name:"to",anchor:"diffusers.DiffusionPipeline.to",parameters:[{name:"torch_device",val:": typing.Union[str, torch.device, NoneType] = None"}],source:"https://github.com/huggingface/diffusers/blob/v0.12.0/src/diffusers/pipelines/pipeline_utils.py#L256"}}),we=new q({props:{name:"disable_attention_slicing",anchor:"diffusers.DiffusionPipeline.disable_attention_slicing",parameters:[],source:"https://github.com/huggingface/diffusers/blob/v0.12.0/src/diffusers/pipelines/pipeline_utils.py#L918"}}),Ee=new q({props:{name:"disable_xformers_memory_efficient_attention",anchor:"diffusers.DiffusionPipeline.disable_xformers_memory_efficient_attention",parameters:[],source:"https://github.com/huggingface/diffusers/blob/v0.12.0/src/diffusers/pipelines/pipeline_utils.py#L877"}}),De=new q({props:{name:"enable_attention_slicing",anchor:"diffusers.DiffusionPipeline.enable_attention_slicing",parameters:[{name:"slice_size",val:": typing.Union[str, int, NoneType] = 'auto'"}],parametersDescription:[{anchor:"diffusers.DiffusionPipeline.enable_attention_slicing.slice_size",description:`<strong>slice_size</strong> (<code>str</code> or <code>int</code>, <em>optional</em>, defaults to <code>&quot;auto&quot;</code>) &#x2014;
When <code>&quot;auto&quot;</code>, halves the input to the attention heads, so attention will be computed in two steps. If
<code>&quot;max&quot;</code>, maxium amount of memory will be saved by running only one slice at a time. If a number is
provided, uses as many slices as <code>attention_head_dim // slice_size</code>. In this case, <code>attention_head_dim</code>
must be a multiple of <code>slice_size</code>.`,name:"slice_size"}],source:"https://github.com/huggingface/diffusers/blob/v0.12.0/src/diffusers/pipelines/pipeline_utils.py#L902"}}),xe=new q({props:{name:"enable_xformers_memory_efficient_attention",anchor:"diffusers.DiffusionPipeline.enable_xformers_memory_efficient_attention",parameters:[{name:"attention_op",val:": typing.Optional[typing.Callable] = None"}],parametersDescription:[{anchor:"diffusers.DiffusionPipeline.enable_xformers_memory_efficient_attention.attention_op",description:`<strong>attention_op</strong> (<code>Callable</code>, <em>optional</em>) &#x2014;
Override the default <code>None</code> operator for use as <code>op</code> argument to the
<a href="https://facebookresearch.github.io/xformers/components/ops.html#xformers.ops.memory_efficient_attention" rel="nofollow"><code>memory_efficient_attention()</code></a>
function of xFormers.`,name:"attention_op"}],source:"https://github.com/huggingface/diffusers/blob/v0.12.0/src/diffusers/pipelines/pipeline_utils.py#L845"}}),re=new Gn({props:{anchor:"diffusers.DiffusionPipeline.enable_xformers_memory_efficient_attention.example",$$slots:{default:[is]},$$scope:{ctx:S}}}),ke=new q({props:{name:"from_pretrained",anchor:"diffusers.DiffusionPipeline.from_pretrained",parameters:[{name:"pretrained_model_name_or_path",val:": typing.Union[str, os.PathLike, NoneType]"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"diffusers.DiffusionPipeline.from_pretrained.pretrained_model_name_or_path",description:`<strong>pretrained_model_name_or_path</strong> (<code>str</code> or <code>os.PathLike</code>, <em>optional</em>) &#x2014;
Can be either:</p>
<ul>
<li>A string, the <em>repo id</em> of a pretrained pipeline hosted inside a model repo on
<a href="https://huggingface.co/" rel="nofollow">https://huggingface.co/</a> Valid repo ids have to be located under a user or organization name, like
<code>CompVis/ldm-text2im-large-256</code>.</li>
<li>A path to a <em>directory</em> containing pipeline weights saved using
<a href="/docs/diffusers/v0.12.0/en/api/diffusion_pipeline#diffusers.DiffusionPipeline.save_pretrained">save_pretrained()</a>, e.g., <code>./my_pipeline_directory/</code>.</li>
</ul>`,name:"pretrained_model_name_or_path"},{anchor:"diffusers.DiffusionPipeline.from_pretrained.torch_dtype",description:`<strong>torch_dtype</strong> (<code>str</code> or <code>torch.dtype</code>, <em>optional</em>) &#x2014;
Override the default <code>torch.dtype</code> and load the model under this dtype. If <code>&quot;auto&quot;</code> is passed the dtype
will be automatically derived from the model&#x2019;s weights.`,name:"torch_dtype"},{anchor:"diffusers.DiffusionPipeline.from_pretrained.custom_pipeline",description:`<strong>custom_pipeline</strong> (<code>str</code>, <em>optional</em>) &#x2014;</p>
<div class="course-tip course-tip-orange bg-gradient-to-br dark:bg-gradient-to-r before:border-orange-500 dark:before:border-orange-800 from-orange-50 dark:from-gray-900 to-white dark:to-gray-950 border border-orange-50 text-orange-700 dark:text-gray-400">
						
<p>This is an experimental feature and is likely to change in the future.</p>

					</div>
<p>Can be either:</p>
<ul>
<li>
<p>A string, the <em>repo id</em> of a custom pipeline hosted inside a model repo on
<a href="https://huggingface.co/" rel="nofollow">https://huggingface.co/</a>. Valid repo ids have to be located under a user or organization name,
like <code>hf-internal-testing/diffusers-dummy-pipeline</code>.</p>
<div class="course-tip  bg-gradient-to-br dark:bg-gradient-to-r before:border-green-500 dark:before:border-green-800 from-green-50 dark:from-gray-900 to-white dark:to-gray-950 border border-green-50 text-green-700 dark:text-gray-400">
						
<p>It is required that the model repo has a file, called <code>pipeline.py</code> that defines the custom
pipeline.</p>

					</div>
</li>
<li>
<p>A string, the <em>file name</em> of a community pipeline hosted on GitHub under
<a href="https://github.com/huggingface/diffusers/tree/main/examples/community" rel="nofollow">https://github.com/huggingface/diffusers/tree/main/examples/community</a>. Valid file names have to
match exactly the file name without <code>.py</code> located under the above link, <em>e.g.</em>
<code>clip_guided_stable_diffusion</code>.</p>
<div class="course-tip  bg-gradient-to-br dark:bg-gradient-to-r before:border-green-500 dark:before:border-green-800 from-green-50 dark:from-gray-900 to-white dark:to-gray-950 border border-green-50 text-green-700 dark:text-gray-400">
						
<p>Community pipelines are always loaded from the current <code>main</code> branch of GitHub.</p>

					</div>
</li>
<li>
<p>A path to a <em>directory</em> containing a custom pipeline, e.g., <code>./my_pipeline_directory/</code>.</p>
<div class="course-tip  bg-gradient-to-br dark:bg-gradient-to-r before:border-green-500 dark:before:border-green-800 from-green-50 dark:from-gray-900 to-white dark:to-gray-950 border border-green-50 text-green-700 dark:text-gray-400">
						
<p>It is required that the directory has a file, called <code>pipeline.py</code> that defines the custom
pipeline.</p>

					</div>
</li>
</ul>
<p>For more information on how to load and create custom pipelines, please have a look at <a href="https://huggingface.co/docs/diffusers/using-diffusers/custom_pipeline_overview" rel="nofollow">Loading and
Adding Custom
Pipelines</a>`,name:"custom_pipeline"},{anchor:"diffusers.DiffusionPipeline.from_pretrained.torch_dtype",description:"<strong>torch_dtype</strong> (<code>str</code> or <code>torch.dtype</code>, <em>optional</em>) &#x2014;",name:"torch_dtype"},{anchor:"diffusers.DiffusionPipeline.from_pretrained.force_download",description:`<strong>force_download</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether or not to force the (re-)download of the model weights and configuration files, overriding the
cached versions if they exist.`,name:"force_download"},{anchor:"diffusers.DiffusionPipeline.from_pretrained.resume_download",description:`<strong>resume_download</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether or not to delete incompletely received files. Will attempt to resume the download if such a
file exists.`,name:"resume_download"},{anchor:"diffusers.DiffusionPipeline.from_pretrained.proxies",description:`<strong>proxies</strong> (<code>Dict[str, str]</code>, <em>optional</em>) &#x2014;
A dictionary of proxy servers to use by protocol or endpoint, e.g., <code>{&apos;http&apos;: &apos;foo.bar:3128&apos;, &apos;http://hostname&apos;: &apos;foo.bar:4012&apos;}</code>. The proxies are used on each request.`,name:"proxies"},{anchor:"diffusers.DiffusionPipeline.from_pretrained.output_loading_info(bool,",description:`<strong>output_loading_info(<code>bool</code>,</strong> <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether or not to also return a dictionary containing missing keys, unexpected keys and error messages.`,name:"output_loading_info(bool,"},{anchor:"diffusers.DiffusionPipeline.from_pretrained.local_files_only(bool,",description:`<strong>local_files_only(<code>bool</code>,</strong> <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether or not to only look at local files (i.e., do not try to download the model).`,name:"local_files_only(bool,"},{anchor:"diffusers.DiffusionPipeline.from_pretrained.use_auth_token",description:`<strong>use_auth_token</strong> (<code>str</code> or <em>bool</em>, <em>optional</em>) &#x2014;
The token to use as HTTP bearer authorization for remote files. If <code>True</code>, will use the token generated
when running <code>huggingface-cli login</code> (stored in <code>~/.huggingface</code>).`,name:"use_auth_token"},{anchor:"diffusers.DiffusionPipeline.from_pretrained.revision",description:`<strong>revision</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;main&quot;</code>) &#x2014;
The specific model version to use. It can be a branch name, a tag name, or a commit id, since we use a
git-based system for storing models and other artifacts on huggingface.co, so <code>revision</code> can be any
identifier allowed by git.`,name:"revision"},{anchor:"diffusers.DiffusionPipeline.from_pretrained.custom_revision",description:`<strong>custom_revision</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;main&quot;</code> when loading from the Hub and to local version of <code>diffusers</code> when loading from GitHub) &#x2014;
The specific model version to use. It can be a branch name, a tag name, or a commit id similar to
<code>revision</code> when loading a custom pipeline from the Hub. It can be a diffusers version when loading a
custom pipeline from GitHub.`,name:"custom_revision"},{anchor:"diffusers.DiffusionPipeline.from_pretrained.mirror",description:`<strong>mirror</strong> (<code>str</code>, <em>optional</em>) &#x2014;
Mirror source to accelerate downloads in China. If you are from China and have an accessibility
problem, you can set this option to resolve it. Note that we do not guarantee the timeliness or safety.
Please refer to the mirror site for more information. specify the folder name here.`,name:"mirror"},{anchor:"diffusers.DiffusionPipeline.from_pretrained.device_map",description:`<strong>device_map</strong> (<code>str</code> or <code>Dict[str, Union[int, str, torch.device]]</code>, <em>optional</em>) &#x2014;
A map that specifies where each submodule should go. It doesn&#x2019;t need to be refined to each
parameter/buffer name, once a given module name is inside, every submodule of it will be sent to the
same device.</p>
<p>To have Accelerate compute the most optimized <code>device_map</code> automatically, set <code>device_map=&quot;auto&quot;</code>. For
more information about each option see <a href="https://hf.co/docs/accelerate/main/en/usage_guides/big_modeling#designing-a-device-map" rel="nofollow">designing a device
map</a>.`,name:"device_map"},{anchor:"diffusers.DiffusionPipeline.from_pretrained.low_cpu_mem_usage",description:`<strong>low_cpu_mem_usage</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code> if torch version &gt;= 1.9.0 else <code>False</code>) &#x2014;
Speed up model loading by not initializing the weights and only loading the pre-trained weights. This
also tries to not use more than 1x model size in CPU memory (including peak memory) while loading the
model. This is only supported when torch version &gt;= 1.9.0. If you are using an older version of torch,
setting this argument to <code>True</code> will raise an error.`,name:"low_cpu_mem_usage"},{anchor:"diffusers.DiffusionPipeline.from_pretrained.return_cached_folder",description:`<strong>return_cached_folder</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
If set to <code>True</code>, path to downloaded cached folder will be returned in addition to loaded pipeline.`,name:"return_cached_folder"},{anchor:"diffusers.DiffusionPipeline.from_pretrained.kwargs",description:`<strong>kwargs</strong> (remaining dictionary of keyword arguments, <em>optional</em>) &#x2014;
Can be used to overwrite load - and saveable variables - <em>i.e.</em> the pipeline components - of the
specific pipeline class. The overwritten components are then directly passed to the pipelines
<code>__init__</code> method. See example below for more information.`,name:"kwargs"}],source:"https://github.com/huggingface/diffusers/blob/v0.12.0/src/diffusers/pipelines/pipeline_utils.py#L288"}}),ae=new tn({props:{$$slots:{default:[ns]},$$scope:{ctx:S}}}),le=new tn({props:{$$slots:{default:[ss]},$$scope:{ctx:S}}}),de=new Gn({props:{anchor:"diffusers.DiffusionPipeline.from_pretrained.example",$$slots:{default:[rs]},$$scope:{ctx:S}}}),Oe=new q({props:{name:"numpy_to_pil",anchor:"diffusers.DiffusionPipeline.numpy_to_pil",parameters:[{name:"images",val:""}],source:"https://github.com/huggingface/diffusers/blob/v0.12.0/src/diffusers/pipelines/pipeline_utils.py#L811"}}),Le=new q({props:{name:"save_pretrained",anchor:"diffusers.DiffusionPipeline.save_pretrained",parameters:[{name:"save_directory",val:": typing.Union[str, os.PathLike]"},{name:"safe_serialization",val:": bool = False"}],parametersDescription:[{anchor:"diffusers.DiffusionPipeline.save_pretrained.save_directory",description:`<strong>save_directory</strong> (<code>str</code> or <code>os.PathLike</code>) &#x2014;
Directory to which to save. Will be created if it doesn&#x2019;t exist.`,name:"save_directory"},{anchor:"diffusers.DiffusionPipeline.save_pretrained.safe_serialization",description:`<strong>safe_serialization</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether to save the model using <code>safetensors</code> or the traditional PyTorch way (that uses <code>pickle</code>).`,name:"safe_serialization"}],source:"https://github.com/huggingface/diffusers/blob/v0.12.0/src/diffusers/pipelines/pipeline_utils.py#L193"}}),Ce=new ao({}),qe=new q({props:{name:"class diffusers.ImagePipelineOutput",anchor:"diffusers.ImagePipelineOutput",parameters:[{name:"images",val:": typing.Union[typing.List[PIL.Image.Image], numpy.ndarray]"}],parametersDescription:[{anchor:"diffusers.ImagePipelineOutput.images",description:`<strong>images</strong> (<code>List[PIL.Image.Image]</code> or <code>np.ndarray</code>) &#x2014;
List of denoised PIL images of length <code>batch_size</code> or numpy array of shape <code>(batch_size, height, width, num_channels)</code>. PIL images or numpy array present the denoised images of the diffusion pipeline.`,name:"images"}],source:"https://github.com/huggingface/diffusers/blob/v0.12.0/src/diffusers/pipelines/pipeline_utils.py#L96"}}),Se=new ao({}),Me=new q({props:{name:"class diffusers.AudioPipelineOutput",anchor:"diffusers.AudioPipelineOutput",parameters:[{name:"audios",val:": ndarray"}],parametersDescription:[{anchor:"diffusers.AudioPipelineOutput.audios",description:`<strong>audios</strong> (<code>np.ndarray</code>) &#x2014;
List of denoised samples of shape <code>(batch_size, num_channels, sample_rate)</code>. Numpy array present the
denoised audio samples of the diffusion pipeline.`,name:"audios"}],source:"https://github.com/huggingface/diffusers/blob/v0.12.0/src/diffusers/pipelines/pipeline_utils.py#L110"}}),{c(){f=i("meta"),y=l(),h=i("h1"),g=i("a"),k=i("span"),$(p.$$.fragment),v=l(),M=i("span"),V=r("Pipelines"),K=l(),L=i("p"),F=r("The "),N=i("a"),U=r("DiffusionPipeline"),O=r(" is the easiest way to load any pretrained diffusion pipeline from the "),X=i("a"),Xe=r("Hub"),ze=r(" and to use it in inference."),ue=l(),$(Q.$$.fragment),Ct=l(),I=i("p"),lo=r("Any diffusion pipeline that is loaded with "),We=i("a"),po=r("from_pretrained()"),fo=r(` will automatically
detect the pipeline type, `),Re=i("em"),co=r("e.g."),mo=l(),Ve=i("a"),uo=r("StableDiffusionPipeline"),ho=r(` and consequently load each component of the
pipeline and pass them into the `),Je=i("code"),go=r("__init__"),_o=r(" function of the pipeline, "),Ke=i("em"),vo=r("e.g."),bo=l(),Qe=i("code"),yo=r("__init__()"),$o=r("."),qt=l(),Z=i("p"),wo=r("Any pipeline object can be saved locally with "),Fe=i("a"),Po=r("save_pretrained()"),Eo=r("."),St=l(),H=i("h2"),ee=i("a"),Ze=i("span"),$(he.$$.fragment),Do=l(),et=i("span"),xo=r("DiffusionPipeline"),Mt=l(),m=i("div"),$(ge.$$.fragment),ko=l(),tt=i("p"),Ao=r("Base class for all models."),Io=l(),Ue=i("p"),He=i("a"),jo=r("DiffusionPipeline"),Oo=r(` takes care of storing all components (models, schedulers, processors) for diffusion pipelines
and handles methods for loading, downloading and saving models as well as a few methods common to all pipelines to:`),Lo=l(),_e=i("ul"),ot=i("li"),To=r("move all PyTorch modules to the device of your choice"),Co=l(),it=i("li"),qo=r("enabling/disabling the progress bar for the denoising iteration"),So=l(),nt=i("p"),Mo=r("Class attributes:"),No=l(),ve=i("ul"),te=i("li"),st=i("strong"),Xo=r("config_name"),zo=r(" ("),rt=i("code"),Wo=r("str"),Vo=r(`) \u2014 name of the config file that will store the class and module names of all
components of the diffusion pipeline.`),Fo=l(),oe=i("li"),at=i("strong"),Uo=r("_optional_components"),Ho=r(" (List"),lt=i("code"),Yo=r("str"),Bo=r(`) \u2014 list of all components that are optional so they don\u2019t have to be
passed for the pipeline to function (should be overridden by subclasses).`),Go=l(),ie=i("div"),$(be.$$.fragment),Ro=l(),dt=i("p"),Jo=r("Call self as a function."),Ko=l(),Ye=i("div"),$(ye.$$.fragment),Qo=l(),Be=i("div"),$($e.$$.fragment),Zo=l(),ne=i("div"),$(we.$$.fragment),ei=l(),Pe=i("p"),ti=r("Disable sliced attention computation. If "),pt=i("code"),oi=r("enable_attention_slicing"),ii=r(` was previously invoked, this method will go
back to computing attention in one step.`),ni=l(),se=i("div"),$(Ee.$$.fragment),si=l(),ft=i("p"),ri=r("Disable memory efficient attention as implemented in xformers."),ai=l(),z=i("div"),$(De.$$.fragment),li=l(),ct=i("p"),di=r("Enable sliced attention computation."),pi=l(),mt=i("p"),fi=r(`When this option is enabled, the attention module will split the input tensor in slices, to compute attention
in several steps. This is useful to save some memory in exchange for a small speed decrease.`),ci=l(),T=i("div"),$(xe.$$.fragment),mi=l(),ut=i("p"),ui=r("Enable memory efficient attention as implemented in xformers."),hi=l(),ht=i("p"),gi=r(`When this option is enabled, you should observe lower GPU memory usage and a potential speed up at inference
time. Speed up at training time is not guaranteed.`),_i=l(),gt=i("p"),vi=r(`Warning: When Memory Efficient Attention and Sliced attention are both enabled, the Memory Efficient Attention
is used.`),bi=l(),$(re.$$.fragment),yi=l(),A=i("div"),$(ke.$$.fragment),$i=l(),_t=i("p"),wi=r("Instantiate a PyTorch diffusion pipeline from pre-trained pipeline weights."),Pi=l(),Ae=i("p"),Ei=r("The pipeline is set in evaluation mode by default using "),vt=i("code"),Di=r("model.eval()"),xi=r(" (Dropout modules are deactivated)."),ki=l(),Ie=i("p"),Ai=r("The warning "),bt=i("em"),Ii=r("Weights from XXX not initialized from pretrained model"),ji=r(` means that the weights of XXX do not come
pretrained with the rest of the model. It is up to you to train those weights with a downstream fine-tuning
task.`),Oi=l(),je=i("p"),Li=r("The warning "),yt=i("em"),Ti=r("Weights from XXX not used in YYY"),Ci=r(` means that the layer XXX is not used by YYY, therefore those
weights are discarded.`),qi=l(),$(ae.$$.fragment),Si=l(),$(le.$$.fragment),Mi=l(),$(de.$$.fragment),Ni=l(),pe=i("div"),$(Oe.$$.fragment),Xi=l(),$t=i("p"),zi=r("Convert a numpy image or a batch of images to a PIL image."),Wi=l(),fe=i("div"),$(Le.$$.fragment),Vi=l(),Te=i("p"),Fi=r(`Save all variables of the pipeline that can be saved and loaded as well as the pipelines configuration file to
a directory. A pipeline variable can be saved and loaded if its class implements both a save and loading
method. The pipeline can easily be re-loaded using the `),wt=i("code"),Ui=r("[from_pretrained()](/docs/diffusers/v0.12.0/en/api/diffusion_pipeline#diffusers.DiffusionPipeline.from_pretrained)"),Hi=r(" class method."),Nt=l(),Y=i("h2"),ce=i("a"),Pt=i("span"),$(Ce.$$.fragment),Yi=l(),Et=i("span"),Bi=r("ImagePipelineOutput"),Xt=r(`

By default diffusion pipelines return an object of class
`),B=i("div"),$(qe.$$.fragment),Gi=l(),Dt=i("p"),Ri=r("Output class for image pipelines."),zt=l(),G=i("h2"),me=i("a"),xt=i("span"),$(Se.$$.fragment),Ji=l(),kt=i("span"),Ki=r("AudioPipelineOutput"),Wt=r(`

By default diffusion pipelines return an object of class
`),R=i("div"),$(Me.$$.fragment),Qi=l(),At=i("p"),Zi=r("Output class for audio pipelines."),this.h()},l(t){const u=es('[data-svelte="svelte-1phssyn"]',document.head);f=n(u,"META",{name:!0,content:!0}),u.forEach(o),y=d(t),h=n(t,"H1",{class:!0});var Ne=s(h);g=n(Ne,"A",{id:!0,class:!0,href:!0});var It=s(g);k=n(It,"SPAN",{});var jt=s(k);w(p.$$.fragment,jt),jt.forEach(o),It.forEach(o),v=d(Ne),M=n(Ne,"SPAN",{});var Ot=s(M);V=a(Ot,"Pipelines"),Ot.forEach(o),Ne.forEach(o),K=d(t),L=n(t,"P",{});var J=s(L);F=a(J,"The "),N=n(J,"A",{href:!0});var on=s(N);U=a(on,"DiffusionPipeline"),on.forEach(o),O=a(J," is the easiest way to load any pretrained diffusion pipeline from the "),X=n(J,"A",{href:!0,rel:!0});var nn=s(X);Xe=a(nn,"Hub"),nn.forEach(o),ze=a(J," and to use it in inference."),J.forEach(o),ue=d(t),w(Q.$$.fragment,t),Ct=d(t),I=n(t,"P",{});var C=s(I);lo=a(C,"Any diffusion pipeline that is loaded with "),We=n(C,"A",{href:!0});var sn=s(We);po=a(sn,"from_pretrained()"),sn.forEach(o),fo=a(C,` will automatically
detect the pipeline type, `),Re=n(C,"EM",{});var rn=s(Re);co=a(rn,"e.g."),rn.forEach(o),mo=d(C),Ve=n(C,"A",{href:!0});var an=s(Ve);uo=a(an,"StableDiffusionPipeline"),an.forEach(o),ho=a(C,` and consequently load each component of the
pipeline and pass them into the `),Je=n(C,"CODE",{});var ln=s(Je);go=a(ln,"__init__"),ln.forEach(o),_o=a(C," function of the pipeline, "),Ke=n(C,"EM",{});var dn=s(Ke);vo=a(dn,"e.g."),dn.forEach(o),bo=d(C),Qe=n(C,"CODE",{});var pn=s(Qe);yo=a(pn,"__init__()"),pn.forEach(o),$o=a(C,"."),C.forEach(o),qt=d(t),Z=n(t,"P",{});var Ft=s(Z);wo=a(Ft,"Any pipeline object can be saved locally with "),Fe=n(Ft,"A",{href:!0});var fn=s(Fe);Po=a(fn,"save_pretrained()"),fn.forEach(o),Eo=a(Ft,"."),Ft.forEach(o),St=d(t),H=n(t,"H2",{class:!0});var Ut=s(H);ee=n(Ut,"A",{id:!0,class:!0,href:!0});var cn=s(ee);Ze=n(cn,"SPAN",{});var mn=s(Ze);w(he.$$.fragment,mn),mn.forEach(o),cn.forEach(o),Do=d(Ut),et=n(Ut,"SPAN",{});var un=s(et);xo=a(un,"DiffusionPipeline"),un.forEach(o),Ut.forEach(o),Mt=d(t),m=n(t,"DIV",{class:!0});var _=s(m);w(ge.$$.fragment,_),ko=d(_),tt=n(_,"P",{});var hn=s(tt);Ao=a(hn,"Base class for all models."),hn.forEach(o),Io=d(_),Ue=n(_,"P",{});var en=s(Ue);He=n(en,"A",{href:!0});var gn=s(He);jo=a(gn,"DiffusionPipeline"),gn.forEach(o),Oo=a(en,` takes care of storing all components (models, schedulers, processors) for diffusion pipelines
and handles methods for loading, downloading and saving models as well as a few methods common to all pipelines to:`),en.forEach(o),Lo=d(_),_e=n(_,"UL",{});var Ht=s(_e);ot=n(Ht,"LI",{});var _n=s(ot);To=a(_n,"move all PyTorch modules to the device of your choice"),_n.forEach(o),Co=d(Ht),it=n(Ht,"LI",{});var vn=s(it);qo=a(vn,"enabling/disabling the progress bar for the denoising iteration"),vn.forEach(o),Ht.forEach(o),So=d(_),nt=n(_,"P",{});var bn=s(nt);Mo=a(bn,"Class attributes:"),bn.forEach(o),No=d(_),ve=n(_,"UL",{});var Yt=s(ve);te=n(Yt,"LI",{});var Lt=s(te);st=n(Lt,"STRONG",{});var yn=s(st);Xo=a(yn,"config_name"),yn.forEach(o),zo=a(Lt," ("),rt=n(Lt,"CODE",{});var $n=s(rt);Wo=a($n,"str"),$n.forEach(o),Vo=a(Lt,`) \u2014 name of the config file that will store the class and module names of all
components of the diffusion pipeline.`),Lt.forEach(o),Fo=d(Yt),oe=n(Yt,"LI",{});var Tt=s(oe);at=n(Tt,"STRONG",{});var wn=s(at);Uo=a(wn,"_optional_components"),wn.forEach(o),Ho=a(Tt," (List"),lt=n(Tt,"CODE",{});var Pn=s(lt);Yo=a(Pn,"str"),Pn.forEach(o),Bo=a(Tt,`) \u2014 list of all components that are optional so they don\u2019t have to be
passed for the pipeline to function (should be overridden by subclasses).`),Tt.forEach(o),Yt.forEach(o),Go=d(_),ie=n(_,"DIV",{class:!0});var Bt=s(ie);w(be.$$.fragment,Bt),Ro=d(Bt),dt=n(Bt,"P",{});var En=s(dt);Jo=a(En,"Call self as a function."),En.forEach(o),Bt.forEach(o),Ko=d(_),Ye=n(_,"DIV",{class:!0});var Dn=s(Ye);w(ye.$$.fragment,Dn),Dn.forEach(o),Qo=d(_),Be=n(_,"DIV",{class:!0});var xn=s(Be);w($e.$$.fragment,xn),xn.forEach(o),Zo=d(_),ne=n(_,"DIV",{class:!0});var Gt=s(ne);w(we.$$.fragment,Gt),ei=d(Gt),Pe=n(Gt,"P",{});var Rt=s(Pe);ti=a(Rt,"Disable sliced attention computation. If "),pt=n(Rt,"CODE",{});var kn=s(pt);oi=a(kn,"enable_attention_slicing"),kn.forEach(o),ii=a(Rt,` was previously invoked, this method will go
back to computing attention in one step.`),Rt.forEach(o),Gt.forEach(o),ni=d(_),se=n(_,"DIV",{class:!0});var Jt=s(se);w(Ee.$$.fragment,Jt),si=d(Jt),ft=n(Jt,"P",{});var An=s(ft);ri=a(An,"Disable memory efficient attention as implemented in xformers."),An.forEach(o),Jt.forEach(o),ai=d(_),z=n(_,"DIV",{class:!0});var Ge=s(z);w(De.$$.fragment,Ge),li=d(Ge),ct=n(Ge,"P",{});var In=s(ct);di=a(In,"Enable sliced attention computation."),In.forEach(o),pi=d(Ge),mt=n(Ge,"P",{});var jn=s(mt);fi=a(jn,`When this option is enabled, the attention module will split the input tensor in slices, to compute attention
in several steps. This is useful to save some memory in exchange for a small speed decrease.`),jn.forEach(o),Ge.forEach(o),ci=d(_),T=n(_,"DIV",{class:!0});var W=s(T);w(xe.$$.fragment,W),mi=d(W),ut=n(W,"P",{});var On=s(ut);ui=a(On,"Enable memory efficient attention as implemented in xformers."),On.forEach(o),hi=d(W),ht=n(W,"P",{});var Ln=s(ht);gi=a(Ln,`When this option is enabled, you should observe lower GPU memory usage and a potential speed up at inference
time. Speed up at training time is not guaranteed.`),Ln.forEach(o),_i=d(W),gt=n(W,"P",{});var Tn=s(gt);vi=a(Tn,`Warning: When Memory Efficient Attention and Sliced attention are both enabled, the Memory Efficient Attention
is used.`),Tn.forEach(o),bi=d(W),w(re.$$.fragment,W),W.forEach(o),yi=d(_),A=n(_,"DIV",{class:!0});var j=s(A);w(ke.$$.fragment,j),$i=d(j),_t=n(j,"P",{});var Cn=s(_t);wi=a(Cn,"Instantiate a PyTorch diffusion pipeline from pre-trained pipeline weights."),Cn.forEach(o),Pi=d(j),Ae=n(j,"P",{});var Kt=s(Ae);Ei=a(Kt,"The pipeline is set in evaluation mode by default using "),vt=n(Kt,"CODE",{});var qn=s(vt);Di=a(qn,"model.eval()"),qn.forEach(o),xi=a(Kt," (Dropout modules are deactivated)."),Kt.forEach(o),ki=d(j),Ie=n(j,"P",{});var Qt=s(Ie);Ai=a(Qt,"The warning "),bt=n(Qt,"EM",{});var Sn=s(bt);Ii=a(Sn,"Weights from XXX not initialized from pretrained model"),Sn.forEach(o),ji=a(Qt,` means that the weights of XXX do not come
pretrained with the rest of the model. It is up to you to train those weights with a downstream fine-tuning
task.`),Qt.forEach(o),Oi=d(j),je=n(j,"P",{});var Zt=s(je);Li=a(Zt,"The warning "),yt=n(Zt,"EM",{});var Mn=s(yt);Ti=a(Mn,"Weights from XXX not used in YYY"),Mn.forEach(o),Ci=a(Zt,` means that the layer XXX is not used by YYY, therefore those
weights are discarded.`),Zt.forEach(o),qi=d(j),w(ae.$$.fragment,j),Si=d(j),w(le.$$.fragment,j),Mi=d(j),w(de.$$.fragment,j),j.forEach(o),Ni=d(_),pe=n(_,"DIV",{class:!0});var eo=s(pe);w(Oe.$$.fragment,eo),Xi=d(eo),$t=n(eo,"P",{});var Nn=s($t);zi=a(Nn,"Convert a numpy image or a batch of images to a PIL image."),Nn.forEach(o),eo.forEach(o),Wi=d(_),fe=n(_,"DIV",{class:!0});var to=s(fe);w(Le.$$.fragment,to),Vi=d(to),Te=n(to,"P",{});var oo=s(Te);Fi=a(oo,`Save all variables of the pipeline that can be saved and loaded as well as the pipelines configuration file to
a directory. A pipeline variable can be saved and loaded if its class implements both a save and loading
method. The pipeline can easily be re-loaded using the `),wt=n(oo,"CODE",{});var Xn=s(wt);Ui=a(Xn,"[from_pretrained()](/docs/diffusers/v0.12.0/en/api/diffusion_pipeline#diffusers.DiffusionPipeline.from_pretrained)"),Xn.forEach(o),Hi=a(oo," class method."),oo.forEach(o),to.forEach(o),_.forEach(o),Nt=d(t),Y=n(t,"H2",{class:!0});var io=s(Y);ce=n(io,"A",{id:!0,class:!0,href:!0});var zn=s(ce);Pt=n(zn,"SPAN",{});var Wn=s(Pt);w(Ce.$$.fragment,Wn),Wn.forEach(o),zn.forEach(o),Yi=d(io),Et=n(io,"SPAN",{});var Vn=s(Et);Bi=a(Vn,"ImagePipelineOutput"),Vn.forEach(o),io.forEach(o),Xt=a(t,`

By default diffusion pipelines return an object of class
`),B=n(t,"DIV",{class:!0});var no=s(B);w(qe.$$.fragment,no),Gi=d(no),Dt=n(no,"P",{});var Fn=s(Dt);Ri=a(Fn,"Output class for image pipelines."),Fn.forEach(o),no.forEach(o),zt=d(t),G=n(t,"H2",{class:!0});var so=s(G);me=n(so,"A",{id:!0,class:!0,href:!0});var Un=s(me);xt=n(Un,"SPAN",{});var Hn=s(xt);w(Se.$$.fragment,Hn),Hn.forEach(o),Un.forEach(o),Ji=d(so),kt=n(so,"SPAN",{});var Yn=s(kt);Ki=a(Yn,"AudioPipelineOutput"),Yn.forEach(o),so.forEach(o),Wt=a(t,`

By default diffusion pipelines return an object of class
`),R=n(t,"DIV",{class:!0});var ro=s(R);w(Me.$$.fragment,ro),Qi=d(ro),At=n(ro,"P",{});var Bn=s(At);Zi=a(Bn,"Output class for audio pipelines."),Bn.forEach(o),ro.forEach(o),this.h()},h(){c(f,"name","hf:doc:metadata"),c(f,"content",JSON.stringify(ls)),c(g,"id","pipelines"),c(g,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(g,"href","#pipelines"),c(h,"class","relative group"),c(N,"href","/docs/diffusers/v0.12.0/en/api/diffusion_pipeline#diffusers.DiffusionPipeline"),c(X,"href","https://huggingface.co/models?library=diffusers"),c(X,"rel","nofollow"),c(We,"href","/docs/diffusers/v0.12.0/en/api/diffusion_pipeline#diffusers.DiffusionPipeline.from_pretrained"),c(Ve,"href","/docs/diffusers/v0.12.0/en/api/pipelines/stable_diffusion/text2img#diffusers.StableDiffusionPipeline"),c(Fe,"href","/docs/diffusers/v0.12.0/en/api/diffusion_pipeline#diffusers.DiffusionPipeline.save_pretrained"),c(ee,"id","diffusers.DiffusionPipeline"),c(ee,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(ee,"href","#diffusers.DiffusionPipeline"),c(H,"class","relative group"),c(He,"href","/docs/diffusers/v0.12.0/en/api/diffusion_pipeline#diffusers.DiffusionPipeline"),c(ie,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(Ye,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(Be,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(ne,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(se,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(z,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(T,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(A,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(pe,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(fe,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(m,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(ce,"id","diffusers.ImagePipelineOutput"),c(ce,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(ce,"href","#diffusers.ImagePipelineOutput"),c(Y,"class","relative group"),c(B,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),c(me,"id","diffusers.AudioPipelineOutput"),c(me,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),c(me,"href","#diffusers.AudioPipelineOutput"),c(G,"class","relative group"),c(R,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8")},m(t,u){e(document.head,f),b(t,y,u),b(t,h,u),e(h,g),e(g,k),P(p,k,null),e(h,v),e(h,M),e(M,V),b(t,K,u),b(t,L,u),e(L,F),e(L,N),e(N,U),e(L,O),e(L,X),e(X,Xe),e(L,ze),b(t,ue,u),P(Q,t,u),b(t,Ct,u),b(t,I,u),e(I,lo),e(I,We),e(We,po),e(I,fo),e(I,Re),e(Re,co),e(I,mo),e(I,Ve),e(Ve,uo),e(I,ho),e(I,Je),e(Je,go),e(I,_o),e(I,Ke),e(Ke,vo),e(I,bo),e(I,Qe),e(Qe,yo),e(I,$o),b(t,qt,u),b(t,Z,u),e(Z,wo),e(Z,Fe),e(Fe,Po),e(Z,Eo),b(t,St,u),b(t,H,u),e(H,ee),e(ee,Ze),P(he,Ze,null),e(H,Do),e(H,et),e(et,xo),b(t,Mt,u),b(t,m,u),P(ge,m,null),e(m,ko),e(m,tt),e(tt,Ao),e(m,Io),e(m,Ue),e(Ue,He),e(He,jo),e(Ue,Oo),e(m,Lo),e(m,_e),e(_e,ot),e(ot,To),e(_e,Co),e(_e,it),e(it,qo),e(m,So),e(m,nt),e(nt,Mo),e(m,No),e(m,ve),e(ve,te),e(te,st),e(st,Xo),e(te,zo),e(te,rt),e(rt,Wo),e(te,Vo),e(ve,Fo),e(ve,oe),e(oe,at),e(at,Uo),e(oe,Ho),e(oe,lt),e(lt,Yo),e(oe,Bo),e(m,Go),e(m,ie),P(be,ie,null),e(ie,Ro),e(ie,dt),e(dt,Jo),e(m,Ko),e(m,Ye),P(ye,Ye,null),e(m,Qo),e(m,Be),P($e,Be,null),e(m,Zo),e(m,ne),P(we,ne,null),e(ne,ei),e(ne,Pe),e(Pe,ti),e(Pe,pt),e(pt,oi),e(Pe,ii),e(m,ni),e(m,se),P(Ee,se,null),e(se,si),e(se,ft),e(ft,ri),e(m,ai),e(m,z),P(De,z,null),e(z,li),e(z,ct),e(ct,di),e(z,pi),e(z,mt),e(mt,fi),e(m,ci),e(m,T),P(xe,T,null),e(T,mi),e(T,ut),e(ut,ui),e(T,hi),e(T,ht),e(ht,gi),e(T,_i),e(T,gt),e(gt,vi),e(T,bi),P(re,T,null),e(m,yi),e(m,A),P(ke,A,null),e(A,$i),e(A,_t),e(_t,wi),e(A,Pi),e(A,Ae),e(Ae,Ei),e(Ae,vt),e(vt,Di),e(Ae,xi),e(A,ki),e(A,Ie),e(Ie,Ai),e(Ie,bt),e(bt,Ii),e(Ie,ji),e(A,Oi),e(A,je),e(je,Li),e(je,yt),e(yt,Ti),e(je,Ci),e(A,qi),P(ae,A,null),e(A,Si),P(le,A,null),e(A,Mi),P(de,A,null),e(m,Ni),e(m,pe),P(Oe,pe,null),e(pe,Xi),e(pe,$t),e($t,zi),e(m,Wi),e(m,fe),P(Le,fe,null),e(fe,Vi),e(fe,Te),e(Te,Fi),e(Te,wt),e(wt,Ui),e(Te,Hi),b(t,Nt,u),b(t,Y,u),e(Y,ce),e(ce,Pt),P(Ce,Pt,null),e(Y,Yi),e(Y,Et),e(Et,Bi),b(t,Xt,u),b(t,B,u),P(qe,B,null),e(B,Gi),e(B,Dt),e(Dt,Ri),b(t,zt,u),b(t,G,u),e(G,me),e(me,xt),P(Se,xt,null),e(G,Ji),e(G,kt),e(kt,Ki),b(t,Wt,u),b(t,R,u),P(Me,R,null),e(R,Qi),e(R,At),e(At,Zi),Vt=!0},p(t,[u]){const Ne={};u&2&&(Ne.$$scope={dirty:u,ctx:t}),Q.$set(Ne);const It={};u&2&&(It.$$scope={dirty:u,ctx:t}),re.$set(It);const jt={};u&2&&(jt.$$scope={dirty:u,ctx:t}),ae.$set(jt);const Ot={};u&2&&(Ot.$$scope={dirty:u,ctx:t}),le.$set(Ot);const J={};u&2&&(J.$$scope={dirty:u,ctx:t}),de.$set(J)},i(t){Vt||(E(p.$$.fragment,t),E(Q.$$.fragment,t),E(he.$$.fragment,t),E(ge.$$.fragment,t),E(be.$$.fragment,t),E(ye.$$.fragment,t),E($e.$$.fragment,t),E(we.$$.fragment,t),E(Ee.$$.fragment,t),E(De.$$.fragment,t),E(xe.$$.fragment,t),E(re.$$.fragment,t),E(ke.$$.fragment,t),E(ae.$$.fragment,t),E(le.$$.fragment,t),E(de.$$.fragment,t),E(Oe.$$.fragment,t),E(Le.$$.fragment,t),E(Ce.$$.fragment,t),E(qe.$$.fragment,t),E(Se.$$.fragment,t),E(Me.$$.fragment,t),Vt=!0)},o(t){D(p.$$.fragment,t),D(Q.$$.fragment,t),D(he.$$.fragment,t),D(ge.$$.fragment,t),D(be.$$.fragment,t),D(ye.$$.fragment,t),D($e.$$.fragment,t),D(we.$$.fragment,t),D(Ee.$$.fragment,t),D(De.$$.fragment,t),D(xe.$$.fragment,t),D(re.$$.fragment,t),D(ke.$$.fragment,t),D(ae.$$.fragment,t),D(le.$$.fragment,t),D(de.$$.fragment,t),D(Oe.$$.fragment,t),D(Le.$$.fragment,t),D(Ce.$$.fragment,t),D(qe.$$.fragment,t),D(Se.$$.fragment,t),D(Me.$$.fragment,t),Vt=!1},d(t){o(f),t&&o(y),t&&o(h),x(p),t&&o(K),t&&o(L),t&&o(ue),x(Q,t),t&&o(Ct),t&&o(I),t&&o(qt),t&&o(Z),t&&o(St),t&&o(H),x(he),t&&o(Mt),t&&o(m),x(ge),x(be),x(ye),x($e),x(we),x(Ee),x(De),x(xe),x(re),x(ke),x(ae),x(le),x(de),x(Oe),x(Le),t&&o(Nt),t&&o(Y),x(Ce),t&&o(Xt),t&&o(B),x(qe),t&&o(zt),t&&o(G),x(Se),t&&o(Wt),t&&o(R),x(Me)}}}const ls={local:"pipelines",sections:[{local:"diffusers.DiffusionPipeline",title:"DiffusionPipeline"},{local:"diffusers.ImagePipelineOutput",title:"ImagePipelineOutput"},{local:"diffusers.AudioPipelineOutput",title:"AudioPipelineOutput"}],title:"Pipelines"};function ds(S){return ts(()=>{new URLSearchParams(window.location.search).get("fw")}),[]}class gs extends Kn{constructor(f){super();Qn(this,f,ds,as,Zn,{})}}export{gs as default,ls as metadata};
