import{s as pt,o as ut,n as lt}from"../chunks/scheduler.182ea377.js";import{S as ot,i as dt,g as l,s as n,r as o,A as ft,h as p,f as s,c as a,j as w,u as d,x as h,k as L,y as u,a as i,v as f,d as m,t as g,w as c}from"../chunks/index.abf12888.js";import{T as rt}from"../chunks/Tip.230e2334.js";import{D as ee}from"../chunks/Docstring.93f6f462.js";import{C as Ge}from"../chunks/CodeBlock.57fe6e13.js";import{H as oe}from"../chunks/Heading.16916d63.js";function mt(te){let r,v="To check a specific pipeline or model output, refer to its corresponding API documentation.";return{c(){r=l("p"),r.textContent=v},l($){r=p($,"P",{"data-svelte-h":!0}),h(r)!=="svelte-60gd7d"&&(r.textContent=v)},m($,O){i($,r,O)},p:lt,d($){$&&s(r)}}}function gt(te){let r,v=`You can’t unpack a <code>BaseOutput</code> directly. Use the <a href="/docs/diffusers/main/en/api/outputs#diffusers.utils.BaseOutput.to_tuple">to_tuple()</a> method to convert it to a tuple
first.`;return{c(){r=l("p"),r.innerHTML=v},l($){r=p($,"P",{"data-svelte-h":!0}),h(r)!=="svelte-140uywr"&&(r.innerHTML=v)},m($,O){i($,r,O)},p:lt,d($){$&&s(r)}}}function ct(te){let r,v,$,O,V,fe,B,We='All model outputs are subclasses of <a href="/docs/diffusers/main/en/api/outputs#diffusers.utils.BaseOutput">BaseOutput</a>, data structures containing all the information returned by the model. The outputs can also be used as tuples or dictionaries.',me,k,Se="For example:",ge,U,ce,E,Qe='The <code>outputs</code> object is a <a href="/docs/diffusers/main/en/api/pipelines/dit#diffusers.ImagePipelineOutput">ImagePipelineOutput</a> which means it has an image attribute.',$e,z,Xe="You can access each attribute as you normally would or with a keyword lookup, and if that attribute is not returned by the model, you will get <code>None</code>:",he,D,be,j,Ye=`When considering the <code>outputs</code> object as a tuple, it only considers the attributes that don’t have <code>None</code> values.
For instance, retrieving an image by indexing into it returns the tuple <code>(outputs.images)</code>:`,_e,F,ye,T,ve,J,xe,b,N,ze,se,Ke=`Base class for all model outputs as dataclass. Has a <code>__getitem__</code> that allows indexing by integer or slice (like a
tuple) or strings (like a dictionary) that will ignore the <code>None</code> attributes. Otherwise behaves like a regular
Python dictionary.`,De,C,je,M,A,Fe,ie,et="Convert self to a tuple containing all the attributes/keys that are not <code>None</code>.",Pe,Z,Ie,x,q,Je,ne,tt="Output class for image pipelines.",we,R,Le,_,G,Ne,ae,st="Output class for image pipelines.",Ae,H,W,Ze,re,it="“Returns a new object replacing the specified fields with new values.",Oe,S,Te,P,Q,qe,le,nt="Output class for audio pipelines.",Ce,X,Me,I,Y,Re,pe,at="Output class for joint image-text pipelines.",He,de,Ve;return V=new oe({props:{title:"Outputs",local:"outputs",headingTag:"h1"}}),U=new Ge({props:{code:"ZnJvbSUyMGRpZmZ1c2VycyUyMGltcG9ydCUyMERESU1QaXBlbGluZSUwQSUwQXBpcGVsaW5lJTIwJTNEJTIwRERJTVBpcGVsaW5lLmZyb21fcHJldHJhaW5lZCglMjJnb29nbGUlMkZkZHBtLWNpZmFyMTAtMzIlMjIpJTBBb3V0cHV0cyUyMCUzRCUyMHBpcGVsaW5lKCk=",highlighted:`<span class="hljs-keyword">from</span> diffusers <span class="hljs-keyword">import</span> DDIMPipeline

pipeline = DDIMPipeline.from_pretrained(<span class="hljs-string">&quot;google/ddpm-cifar10-32&quot;</span>)
outputs = pipeline()`,wrap:!1}}),D=new Ge({props:{code:"b3V0cHV0cy5pbWFnZXMlMEFvdXRwdXRzJTVCJTIyaW1hZ2VzJTIyJTVE",highlighted:`outputs.images
outputs[<span class="hljs-string">&quot;images&quot;</span>]`,wrap:!1}}),F=new Ge({props:{code:"b3V0cHV0cyU1QiUzQTElNUQ=",highlighted:'outputs[:<span class="hljs-number">1</span>]',wrap:!1}}),T=new rt({props:{$$slots:{default:[mt]},$$scope:{ctx:te}}}),J=new oe({props:{title:"BaseOutput",local:"diffusers.utils.BaseOutput",headingTag:"h2"}}),N=new ee({props:{name:"class diffusers.utils.BaseOutput",anchor:"diffusers.utils.BaseOutput",parameters:"",source:"https://github.com/huggingface/diffusers/blob/main/src/diffusers/utils/outputs.py#L40"}}),C=new rt({props:{warning:!0,$$slots:{default:[gt]},$$scope:{ctx:te}}}),A=new ee({props:{name:"to_tuple",anchor:"diffusers.utils.BaseOutput.to_tuple",parameters:[],source:"https://github.com/huggingface/diffusers/blob/main/src/diffusers/utils/outputs.py#L126"}}),Z=new oe({props:{title:"ImagePipelineOutput",local:"diffusers.ImagePipelineOutput",headingTag:"h2"}}),q=new ee({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>.`,name:"images"}],source:"https://github.com/huggingface/diffusers/blob/main/src/diffusers/pipelines/pipeline_utils.py#L116"}}),R=new oe({props:{title:"FlaxImagePipelineOutput",local:"diffusers.pipelines.pipeline_flax_utils.FlaxImagePipelineOutput",headingTag:"h2"}}),G=new ee({props:{name:"class diffusers.pipelines.pipeline_flax_utils.FlaxImagePipelineOutput",anchor:"diffusers.pipelines.pipeline_flax_utils.FlaxImagePipelineOutput",parameters:[{name:"images",val:": typing.Union[typing.List[PIL.Image.Image], numpy.ndarray]"}],parametersDescription:[{anchor:"diffusers.pipelines.pipeline_flax_utils.FlaxImagePipelineOutput.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>.`,name:"images"}],source:"https://github.com/huggingface/diffusers/blob/main/src/diffusers/pipelines/pipeline_flax_utils.py#L88"}}),W=new ee({props:{name:"replace",anchor:"diffusers.pipelines.pipeline_flax_utils.FlaxImagePipelineOutput.replace",parameters:[{name:"**updates",val:""}],source:"https://github.com/huggingface/diffusers/blob/main/src/flax/struct.py#L111"}}),S=new oe({props:{title:"AudioPipelineOutput",local:"diffusers.AudioPipelineOutput",headingTag:"h2"}}),Q=new ee({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 audio samples of a NumPy array of shape <code>(batch_size, num_channels, sample_rate)</code>.`,name:"audios"}],source:"https://github.com/huggingface/diffusers/blob/main/src/diffusers/pipelines/pipeline_utils.py#L130"}}),X=new oe({props:{title:"ImageTextPipelineOutput",local:"diffusers.ImageTextPipelineOutput",headingTag:"h2"}}),Y=new ee({props:{name:"class diffusers.ImageTextPipelineOutput",anchor:"diffusers.ImageTextPipelineOutput",parameters:[{name:"images",val:": typing.Union[typing.List[PIL.Image.Image], numpy.ndarray, NoneType]"},{name:"text",val:": typing.Union[typing.List[str], typing.List[typing.List[str]], NoneType]"}],parametersDescription:[{anchor:"diffusers.ImageTextPipelineOutput.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>.`,name:"images"},{anchor:"diffusers.ImageTextPipelineOutput.text",description:`<strong>text</strong> (<code>List[str]</code> or <code>List[List[str]]</code>) &#x2014;
List of generated text strings of length <code>batch_size</code> or a list of list of strings whose outer list has
length <code>batch_size</code>.`,name:"text"}],source:"https://github.com/huggingface/diffusers/blob/main/src/diffusers/pipelines/unidiffuser/pipeline_unidiffuser.py#L34"}}),{c(){r=l("meta"),v=n(),$=l("p"),O=n(),o(V.$$.fragment),fe=n(),B=l("p"),B.innerHTML=We,me=n(),k=l("p"),k.textContent=Se,ge=n(),o(U.$$.fragment),ce=n(),E=l("p"),E.innerHTML=Qe,$e=n(),z=l("p"),z.innerHTML=Xe,he=n(),o(D.$$.fragment),be=n(),j=l("p"),j.innerHTML=Ye,_e=n(),o(F.$$.fragment),ye=n(),o(T.$$.fragment),ve=n(),o(J.$$.fragment),xe=n(),b=l("div"),o(N.$$.fragment),ze=n(),se=l("p"),se.innerHTML=Ke,De=n(),o(C.$$.fragment),je=n(),M=l("div"),o(A.$$.fragment),Fe=n(),ie=l("p"),ie.innerHTML=et,Pe=n(),o(Z.$$.fragment),Ie=n(),x=l("div"),o(q.$$.fragment),Je=n(),ne=l("p"),ne.textContent=tt,we=n(),o(R.$$.fragment),Le=n(),_=l("div"),o(G.$$.fragment),Ne=n(),ae=l("p"),ae.textContent=st,Ae=n(),H=l("div"),o(W.$$.fragment),Ze=n(),re=l("p"),re.textContent=it,Oe=n(),o(S.$$.fragment),Te=n(),P=l("div"),o(Q.$$.fragment),qe=n(),le=l("p"),le.textContent=nt,Ce=n(),o(X.$$.fragment),Me=n(),I=l("div"),o(Y.$$.fragment),Re=n(),pe=l("p"),pe.textContent=at,He=n(),de=l("p"),this.h()},l(e){const t=ft("svelte-u9bgzb",document.head);r=p(t,"META",{name:!0,content:!0}),t.forEach(s),v=a(e),$=p(e,"P",{}),w($).forEach(s),O=a(e),d(V.$$.fragment,e),fe=a(e),B=p(e,"P",{"data-svelte-h":!0}),h(B)!=="svelte-4sj20v"&&(B.innerHTML=We),me=a(e),k=p(e,"P",{"data-svelte-h":!0}),h(k)!=="svelte-1gkqha7"&&(k.textContent=Se),ge=a(e),d(U.$$.fragment,e),ce=a(e),E=p(e,"P",{"data-svelte-h":!0}),h(E)!=="svelte-1t37jem"&&(E.innerHTML=Qe),$e=a(e),z=p(e,"P",{"data-svelte-h":!0}),h(z)!=="svelte-1ntwqaz"&&(z.innerHTML=Xe),he=a(e),d(D.$$.fragment,e),be=a(e),j=p(e,"P",{"data-svelte-h":!0}),h(j)!=="svelte-qzd8sf"&&(j.innerHTML=Ye),_e=a(e),d(F.$$.fragment,e),ye=a(e),d(T.$$.fragment,e),ve=a(e),d(J.$$.fragment,e),xe=a(e),b=p(e,"DIV",{class:!0});var y=w(b);d(N.$$.fragment,y),ze=a(y),se=p(y,"P",{"data-svelte-h":!0}),h(se)!=="svelte-1qra1r9"&&(se.innerHTML=Ke),De=a(y),d(C.$$.fragment,y),je=a(y),M=p(y,"DIV",{class:!0});var K=w(M);d(A.$$.fragment,K),Fe=a(K),ie=p(K,"P",{"data-svelte-h":!0}),h(ie)!=="svelte-1gdpts"&&(ie.innerHTML=et),K.forEach(s),y.forEach(s),Pe=a(e),d(Z.$$.fragment,e),Ie=a(e),x=p(e,"DIV",{class:!0});var Be=w(x);d(q.$$.fragment,Be),Je=a(Be),ne=p(Be,"P",{"data-svelte-h":!0}),h(ne)!=="svelte-19wetgi"&&(ne.textContent=tt),Be.forEach(s),we=a(e),d(R.$$.fragment,e),Le=a(e),_=p(e,"DIV",{class:!0});var ue=w(_);d(G.$$.fragment,ue),Ne=a(ue),ae=p(ue,"P",{"data-svelte-h":!0}),h(ae)!=="svelte-19wetgi"&&(ae.textContent=st),Ae=a(ue),H=p(ue,"DIV",{class:!0});var ke=w(H);d(W.$$.fragment,ke),Ze=a(ke),re=p(ke,"P",{"data-svelte-h":!0}),h(re)!=="svelte-5ihtpa"&&(re.textContent=it),ke.forEach(s),ue.forEach(s),Oe=a(e),d(S.$$.fragment,e),Te=a(e),P=p(e,"DIV",{class:!0});var Ue=w(P);d(Q.$$.fragment,Ue),qe=a(Ue),le=p(Ue,"P",{"data-svelte-h":!0}),h(le)!=="svelte-19ryw33"&&(le.textContent=nt),Ue.forEach(s),Ce=a(e),d(X.$$.fragment,e),Me=a(e),I=p(e,"DIV",{class:!0});var Ee=w(I);d(Y.$$.fragment,Ee),Re=a(Ee),pe=p(Ee,"P",{"data-svelte-h":!0}),h(pe)!=="svelte-1i2ycus"&&(pe.textContent=at),Ee.forEach(s),He=a(e),de=p(e,"P",{}),w(de).forEach(s),this.h()},h(){L(r,"name","hf:doc:metadata"),L(r,"content",$t),L(M,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),L(b,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),L(x,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),L(H,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),L(_,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),L(P,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),L(I,"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,t){u(document.head,r),i(e,v,t),i(e,$,t),i(e,O,t),f(V,e,t),i(e,fe,t),i(e,B,t),i(e,me,t),i(e,k,t),i(e,ge,t),f(U,e,t),i(e,ce,t),i(e,E,t),i(e,$e,t),i(e,z,t),i(e,he,t),f(D,e,t),i(e,be,t),i(e,j,t),i(e,_e,t),f(F,e,t),i(e,ye,t),f(T,e,t),i(e,ve,t),f(J,e,t),i(e,xe,t),i(e,b,t),f(N,b,null),u(b,ze),u(b,se),u(b,De),f(C,b,null),u(b,je),u(b,M),f(A,M,null),u(M,Fe),u(M,ie),i(e,Pe,t),f(Z,e,t),i(e,Ie,t),i(e,x,t),f(q,x,null),u(x,Je),u(x,ne),i(e,we,t),f(R,e,t),i(e,Le,t),i(e,_,t),f(G,_,null),u(_,Ne),u(_,ae),u(_,Ae),u(_,H),f(W,H,null),u(H,Ze),u(H,re),i(e,Oe,t),f(S,e,t),i(e,Te,t),i(e,P,t),f(Q,P,null),u(P,qe),u(P,le),i(e,Ce,t),f(X,e,t),i(e,Me,t),i(e,I,t),f(Y,I,null),u(I,Re),u(I,pe),i(e,He,t),i(e,de,t),Ve=!0},p(e,[t]){const y={};t&2&&(y.$$scope={dirty:t,ctx:e}),T.$set(y);const K={};t&2&&(K.$$scope={dirty:t,ctx:e}),C.$set(K)},i(e){Ve||(m(V.$$.fragment,e),m(U.$$.fragment,e),m(D.$$.fragment,e),m(F.$$.fragment,e),m(T.$$.fragment,e),m(J.$$.fragment,e),m(N.$$.fragment,e),m(C.$$.fragment,e),m(A.$$.fragment,e),m(Z.$$.fragment,e),m(q.$$.fragment,e),m(R.$$.fragment,e),m(G.$$.fragment,e),m(W.$$.fragment,e),m(S.$$.fragment,e),m(Q.$$.fragment,e),m(X.$$.fragment,e),m(Y.$$.fragment,e),Ve=!0)},o(e){g(V.$$.fragment,e),g(U.$$.fragment,e),g(D.$$.fragment,e),g(F.$$.fragment,e),g(T.$$.fragment,e),g(J.$$.fragment,e),g(N.$$.fragment,e),g(C.$$.fragment,e),g(A.$$.fragment,e),g(Z.$$.fragment,e),g(q.$$.fragment,e),g(R.$$.fragment,e),g(G.$$.fragment,e),g(W.$$.fragment,e),g(S.$$.fragment,e),g(Q.$$.fragment,e),g(X.$$.fragment,e),g(Y.$$.fragment,e),Ve=!1},d(e){e&&(s(v),s($),s(O),s(fe),s(B),s(me),s(k),s(ge),s(ce),s(E),s($e),s(z),s(he),s(be),s(j),s(_e),s(ye),s(ve),s(xe),s(b),s(Pe),s(Ie),s(x),s(we),s(Le),s(_),s(Oe),s(Te),s(P),s(Ce),s(Me),s(I),s(He),s(de)),s(r),c(V,e),c(U,e),c(D,e),c(F,e),c(T,e),c(J,e),c(N),c(C),c(A),c(Z,e),c(q),c(R,e),c(G),c(W),c(S,e),c(Q),c(X,e),c(Y)}}}const $t='{"title":"Outputs","local":"outputs","sections":[{"title":"BaseOutput","local":"diffusers.utils.BaseOutput","sections":[],"depth":2},{"title":"ImagePipelineOutput","local":"diffusers.ImagePipelineOutput","sections":[],"depth":2},{"title":"FlaxImagePipelineOutput","local":"diffusers.pipelines.pipeline_flax_utils.FlaxImagePipelineOutput","sections":[],"depth":2},{"title":"AudioPipelineOutput","local":"diffusers.AudioPipelineOutput","sections":[],"depth":2},{"title":"ImageTextPipelineOutput","local":"diffusers.ImageTextPipelineOutput","sections":[],"depth":2}],"depth":1}';function ht(te){return ut(()=>{new URLSearchParams(window.location.search).get("fw")}),[]}class It extends ot{constructor(r){super(),dt(this,r,ht,ct,pt,{})}}export{It as component};
