import{s as ot,o as ft,n as ut}from"../chunks/scheduler.8c3d61f6.js";import{S as dt,i as mt,g as l,s as n,r as o,A as ct,h as p,f as s,c as a,j as I,u as f,x as h,k as O,y as u,a as i,v as d,d as m,t as c,w as g}from"../chunks/index.da70eac4.js";import{T as pt}from"../chunks/Tip.1d9b8c37.js";import{D as te}from"../chunks/Docstring.ee4b6913.js";import{C as Se}from"../chunks/CodeBlock.00a903b3.js";import{H as fe,E as gt}from"../chunks/EditOnGithub.1e64e623.js";function $t(se){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($,T){i($,r,T)},p:ut,d($){$&&s(r)}}}function ht(se){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($,T){i($,r,T)},p:ut,d($){$&&s(r)}}}function bt(se){let r,v,$,T,V,me,B,Qe='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.',ce,E,Xe="For example:",ge,k,$e,U,Ye='The <code>outputs</code> object is a <a href="/docs/diffusers/main/en/api/pipelines/unclip#diffusers.ImagePipelineOutput">ImagePipelineOutput</a> which means it has an image attribute.',he,z,Ke="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>:",be,D,_e,j,et=`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>:`,xe,F,ve,L,Pe,J,ye,b,A,je,ie,tt=`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.`,Fe,C,Je,M,N,Ae,ne,st="Convert self to a tuple containing all the attributes/keys that are not <code>None</code>.",we,Z,Ie,P,q,Ne,ae,it="Output class for image pipelines.",Oe,G,Te,_,R,Ze,re,nt="Output class for image pipelines.",qe,H,W,Ge,le,at="“Returns a new object replacing the specified fields with new values.",Le,S,Ce,y,Q,Re,pe,rt="Output class for audio pipelines.",Me,X,He,w,Y,We,ue,lt="Output class for joint image-text pipelines.",Ve,K,Be,de,Ee;return V=new fe({props:{title:"Outputs",local:"outputs",headingTag:"h1"}}),k=new Se({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 Se({props:{code:"b3V0cHV0cy5pbWFnZXMlMEFvdXRwdXRzJTVCJTIyaW1hZ2VzJTIyJTVE",highlighted:`outputs.images
outputs[<span class="hljs-string">&quot;images&quot;</span>]`,wrap:!1}}),F=new Se({props:{code:"b3V0cHV0cyU1QiUzQTElNUQ=",highlighted:'outputs[:<span class="hljs-number">1</span>]',wrap:!1}}),L=new pt({props:{$$slots:{default:[$t]},$$scope:{ctx:se}}}),J=new fe({props:{title:"BaseOutput",local:"diffusers.utils.BaseOutput",headingTag:"h2"}}),A=new te({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 pt({props:{warning:!0,$$slots:{default:[ht]},$$scope:{ctx:se}}}),N=new te({props:{name:"to_tuple",anchor:"diffusers.utils.BaseOutput.to_tuple",parameters:[],source:"https://github.com/huggingface/diffusers/blob/main/src/diffusers/utils/outputs.py#L133"}}),Z=new fe({props:{title:"ImagePipelineOutput",local:"diffusers.ImagePipelineOutput",headingTag:"h2"}}),q=new te({props:{name:"class diffusers.ImagePipelineOutput",anchor:"diffusers.ImagePipelineOutput",parameters:[{name:"images",val:": Union"}],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#L100"}}),G=new fe({props:{title:"FlaxImagePipelineOutput",local:"diffusers.pipelines.pipeline_flax_utils.FlaxImagePipelineOutput",headingTag:"h2"}}),R=new te({props:{name:"class diffusers.pipelines.pipeline_flax_utils.FlaxImagePipelineOutput",anchor:"diffusers.pipelines.pipeline_flax_utils.FlaxImagePipelineOutput",parameters:[{name:"images",val:": Union"}],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#L87"}}),W=new te({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#L120"}}),S=new fe({props:{title:"AudioPipelineOutput",local:"diffusers.AudioPipelineOutput",headingTag:"h2"}}),Q=new te({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#L114"}}),X=new fe({props:{title:"ImageTextPipelineOutput",local:"diffusers.ImageTextPipelineOutput",headingTag:"h2"}}),Y=new te({props:{name:"class diffusers.ImageTextPipelineOutput",anchor:"diffusers.ImageTextPipelineOutput",parameters:[{name:"images",val:": Union"},{name:"text",val:": Union"}],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#L33"}}),K=new gt({props:{source:"https://github.com/huggingface/diffusers/blob/main/docs/source/en/api/outputs.md"}}),{c(){r=l("meta"),v=n(),$=l("p"),T=n(),o(V.$$.fragment),me=n(),B=l("p"),B.innerHTML=Qe,ce=n(),E=l("p"),E.textContent=Xe,ge=n(),o(k.$$.fragment),$e=n(),U=l("p"),U.innerHTML=Ye,he=n(),z=l("p"),z.innerHTML=Ke,be=n(),o(D.$$.fragment),_e=n(),j=l("p"),j.innerHTML=et,xe=n(),o(F.$$.fragment),ve=n(),o(L.$$.fragment),Pe=n(),o(J.$$.fragment),ye=n(),b=l("div"),o(A.$$.fragment),je=n(),ie=l("p"),ie.innerHTML=tt,Fe=n(),o(C.$$.fragment),Je=n(),M=l("div"),o(N.$$.fragment),Ae=n(),ne=l("p"),ne.innerHTML=st,we=n(),o(Z.$$.fragment),Ie=n(),P=l("div"),o(q.$$.fragment),Ne=n(),ae=l("p"),ae.textContent=it,Oe=n(),o(G.$$.fragment),Te=n(),_=l("div"),o(R.$$.fragment),Ze=n(),re=l("p"),re.textContent=nt,qe=n(),H=l("div"),o(W.$$.fragment),Ge=n(),le=l("p"),le.textContent=at,Le=n(),o(S.$$.fragment),Ce=n(),y=l("div"),o(Q.$$.fragment),Re=n(),pe=l("p"),pe.textContent=rt,Me=n(),o(X.$$.fragment),He=n(),w=l("div"),o(Y.$$.fragment),We=n(),ue=l("p"),ue.textContent=lt,Ve=n(),o(K.$$.fragment),Be=n(),de=l("p"),this.h()},l(e){const t=ct("svelte-u9bgzb",document.head);r=p(t,"META",{name:!0,content:!0}),t.forEach(s),v=a(e),$=p(e,"P",{}),I($).forEach(s),T=a(e),f(V.$$.fragment,e),me=a(e),B=p(e,"P",{"data-svelte-h":!0}),h(B)!=="svelte-4sj20v"&&(B.innerHTML=Qe),ce=a(e),E=p(e,"P",{"data-svelte-h":!0}),h(E)!=="svelte-1gkqha7"&&(E.textContent=Xe),ge=a(e),f(k.$$.fragment,e),$e=a(e),U=p(e,"P",{"data-svelte-h":!0}),h(U)!=="svelte-8x6xs0"&&(U.innerHTML=Ye),he=a(e),z=p(e,"P",{"data-svelte-h":!0}),h(z)!=="svelte-1ntwqaz"&&(z.innerHTML=Ke),be=a(e),f(D.$$.fragment,e),_e=a(e),j=p(e,"P",{"data-svelte-h":!0}),h(j)!=="svelte-qzd8sf"&&(j.innerHTML=et),xe=a(e),f(F.$$.fragment,e),ve=a(e),f(L.$$.fragment,e),Pe=a(e),f(J.$$.fragment,e),ye=a(e),b=p(e,"DIV",{class:!0});var x=I(b);f(A.$$.fragment,x),je=a(x),ie=p(x,"P",{"data-svelte-h":!0}),h(ie)!=="svelte-1qra1r9"&&(ie.innerHTML=tt),Fe=a(x),f(C.$$.fragment,x),Je=a(x),M=p(x,"DIV",{class:!0});var ee=I(M);f(N.$$.fragment,ee),Ae=a(ee),ne=p(ee,"P",{"data-svelte-h":!0}),h(ne)!=="svelte-1gdpts"&&(ne.innerHTML=st),ee.forEach(s),x.forEach(s),we=a(e),f(Z.$$.fragment,e),Ie=a(e),P=p(e,"DIV",{class:!0});var ke=I(P);f(q.$$.fragment,ke),Ne=a(ke),ae=p(ke,"P",{"data-svelte-h":!0}),h(ae)!=="svelte-19wetgi"&&(ae.textContent=it),ke.forEach(s),Oe=a(e),f(G.$$.fragment,e),Te=a(e),_=p(e,"DIV",{class:!0});var oe=I(_);f(R.$$.fragment,oe),Ze=a(oe),re=p(oe,"P",{"data-svelte-h":!0}),h(re)!=="svelte-19wetgi"&&(re.textContent=nt),qe=a(oe),H=p(oe,"DIV",{class:!0});var Ue=I(H);f(W.$$.fragment,Ue),Ge=a(Ue),le=p(Ue,"P",{"data-svelte-h":!0}),h(le)!=="svelte-5ihtpa"&&(le.textContent=at),Ue.forEach(s),oe.forEach(s),Le=a(e),f(S.$$.fragment,e),Ce=a(e),y=p(e,"DIV",{class:!0});var ze=I(y);f(Q.$$.fragment,ze),Re=a(ze),pe=p(ze,"P",{"data-svelte-h":!0}),h(pe)!=="svelte-19ryw33"&&(pe.textContent=rt),ze.forEach(s),Me=a(e),f(X.$$.fragment,e),He=a(e),w=p(e,"DIV",{class:!0});var De=I(w);f(Y.$$.fragment,De),We=a(De),ue=p(De,"P",{"data-svelte-h":!0}),h(ue)!=="svelte-1i2ycus"&&(ue.textContent=lt),De.forEach(s),Ve=a(e),f(K.$$.fragment,e),Be=a(e),de=p(e,"P",{}),I(de).forEach(s),this.h()},h(){O(r,"name","hf:doc:metadata"),O(r,"content",_t),O(M,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),O(b,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),O(P,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),O(H,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),O(_,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),O(y,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),O(w,"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,T,t),d(V,e,t),i(e,me,t),i(e,B,t),i(e,ce,t),i(e,E,t),i(e,ge,t),d(k,e,t),i(e,$e,t),i(e,U,t),i(e,he,t),i(e,z,t),i(e,be,t),d(D,e,t),i(e,_e,t),i(e,j,t),i(e,xe,t),d(F,e,t),i(e,ve,t),d(L,e,t),i(e,Pe,t),d(J,e,t),i(e,ye,t),i(e,b,t),d(A,b,null),u(b,je),u(b,ie),u(b,Fe),d(C,b,null),u(b,Je),u(b,M),d(N,M,null),u(M,Ae),u(M,ne),i(e,we,t),d(Z,e,t),i(e,Ie,t),i(e,P,t),d(q,P,null),u(P,Ne),u(P,ae),i(e,Oe,t),d(G,e,t),i(e,Te,t),i(e,_,t),d(R,_,null),u(_,Ze),u(_,re),u(_,qe),u(_,H),d(W,H,null),u(H,Ge),u(H,le),i(e,Le,t),d(S,e,t),i(e,Ce,t),i(e,y,t),d(Q,y,null),u(y,Re),u(y,pe),i(e,Me,t),d(X,e,t),i(e,He,t),i(e,w,t),d(Y,w,null),u(w,We),u(w,ue),i(e,Ve,t),d(K,e,t),i(e,Be,t),i(e,de,t),Ee=!0},p(e,[t]){const x={};t&2&&(x.$$scope={dirty:t,ctx:e}),L.$set(x);const ee={};t&2&&(ee.$$scope={dirty:t,ctx:e}),C.$set(ee)},i(e){Ee||(m(V.$$.fragment,e),m(k.$$.fragment,e),m(D.$$.fragment,e),m(F.$$.fragment,e),m(L.$$.fragment,e),m(J.$$.fragment,e),m(A.$$.fragment,e),m(C.$$.fragment,e),m(N.$$.fragment,e),m(Z.$$.fragment,e),m(q.$$.fragment,e),m(G.$$.fragment,e),m(R.$$.fragment,e),m(W.$$.fragment,e),m(S.$$.fragment,e),m(Q.$$.fragment,e),m(X.$$.fragment,e),m(Y.$$.fragment,e),m(K.$$.fragment,e),Ee=!0)},o(e){c(V.$$.fragment,e),c(k.$$.fragment,e),c(D.$$.fragment,e),c(F.$$.fragment,e),c(L.$$.fragment,e),c(J.$$.fragment,e),c(A.$$.fragment,e),c(C.$$.fragment,e),c(N.$$.fragment,e),c(Z.$$.fragment,e),c(q.$$.fragment,e),c(G.$$.fragment,e),c(R.$$.fragment,e),c(W.$$.fragment,e),c(S.$$.fragment,e),c(Q.$$.fragment,e),c(X.$$.fragment,e),c(Y.$$.fragment,e),c(K.$$.fragment,e),Ee=!1},d(e){e&&(s(v),s($),s(T),s(me),s(B),s(ce),s(E),s(ge),s($e),s(U),s(he),s(z),s(be),s(_e),s(j),s(xe),s(ve),s(Pe),s(ye),s(b),s(we),s(Ie),s(P),s(Oe),s(Te),s(_),s(Le),s(Ce),s(y),s(Me),s(He),s(w),s(Ve),s(Be),s(de)),s(r),g(V,e),g(k,e),g(D,e),g(F,e),g(L,e),g(J,e),g(A),g(C),g(N),g(Z,e),g(q),g(G,e),g(R),g(W),g(S,e),g(Q),g(X,e),g(Y),g(K,e)}}}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 xt(se){return ft(()=>{new URLSearchParams(window.location.search).get("fw")}),[]}class Tt extends dt{constructor(r){super(),mt(this,r,xt,bt,ot,{})}}export{Tt as component};
