import{S as wi,i as gi,s as Ei,e as l,k as h,w as Ae,t as o,M as Ti,c as i,d as a,m as f,a as r,x as Ce,h as n,b as s,G as e,g as c,y as ke,L as Mi,q as Ze,o as We,B as Be,v as Ui}from"../../chunks/vendor-hf-doc-builder.js";import{I as Nt}from"../../chunks/IconCopyLink-hf-doc-builder.js";import{C as _i}from"../../chunks/CodeBlock-hf-doc-builder.js";function Gi(_l){let v,ot,y,I,je,B,Rt,Ne,xt,nt,D,Pt,j,Ft,Qt,st,_,S,Re,N,zt,xe,Vt,ht,$,R,Yt,x,Lt,qt,Xt,Pe,Ot,ft,w,A,Fe,P,Kt,Qe,ea,ut,oe,ta,ct,C,g,aa,F,ze,la,ia,Ve,ra,oa,na,Q,sa,z,Ye,ha,fa,dt,d,ua,Le,ca,da,qe,pa,ma,Xe,ba,va,V,ya,_a,Y,wa,ga,pt,L,mt,ne,Ea,bt,q,vt,m,Ta,X,Ma,Ua,O,Ga,Ja,yt,E,k,Oe,K,Ha,Ke,Ia,_t,b,Da,ee,Sa,$a,te,Aa,Ca,wt,se,he,ae,ka,Za,gt,Z,et,T,Et,Wa,fe,Ba,ja,ue,Na,Ra,le,M,tt,xa,Pa,ce,Fa,Qa,de,za,Va,U,at,Ya,La,pe,qa,Xa,me,Oa,Tt,be,ve,ie,Ka,el,Mt,W,lt,G,Ut,tl,ye,al,ll,_e,il,rl,re,J,it,ol,nl,we,sl,hl,ge,fl,ul,H,rt,cl,dl,Ee,pl,ml,Te,bl,Gt;return B=new Nt({}),N=new Nt({}),P=new Nt({}),L=new _i({props:{code:"ZnJvbSUyMG9wdGltdW0uaGFiYW5hJTIwaW1wb3J0JTIwR2F1ZGlDb25maWclMEFmcm9tJTIwb3B0aW11bS5oYWJhbmEuZGlmZnVzZXJzJTIwaW1wb3J0JTIwR2F1ZGlERElNU2NoZWR1bGVyJTJDJTIwR2F1ZGlTdGFibGVEaWZmdXNpb25QaXBlbGluZSUwQSUwQW1vZGVsX25hbWUlMjAlM0QlMjAlMjJzdGFiaWxpdHlhaSUyRnN0YWJsZS1kaWZmdXNpb24tMi1iYXNlJTIyJTBBc2NoZWR1bGVyJTIwJTNEJTIwR2F1ZGlERElNU2NoZWR1bGVyLmZyb21fcHJldHJhaW5lZChtb2RlbF9uYW1lJTJDJTIwc3ViZm9sZGVyJTNEJTIyc2NoZWR1bGVyJTIyKSUwQXBpcGVsaW5lJTIwJTNEJTIwR2F1ZGlTdGFibGVEaWZmdXNpb25QaXBlbGluZS5mcm9tX3ByZXRyYWluZWQoJTBBJTIwJTIwJTIwJTIwbW9kZWxfbmFtZSUyQyUwQSUyMCUyMCUyMCUyMHNjaGVkdWxlciUzRHNjaGVkdWxlciUyQyUwQSUyMCUyMCUyMCUyMHVzZV9oYWJhbmElM0RUcnVlJTJDJTBBJTIwJTIwJTIwJTIwdXNlX2hwdV9ncmFwaHMlM0RUcnVlJTJDJTBBJTIwJTIwJTIwJTIwZ2F1ZGlfY29uZmlnJTNEJTIySGFiYW5hJTJGc3RhYmxlLWRpZmZ1c2lvbi0yJTIyJTJDJTBBKQ==",highlighted:`<span class="hljs-keyword">from</span> optimum.habana <span class="hljs-keyword">import</span> GaudiConfig
<span class="hljs-keyword">from</span> optimum.habana.diffusers <span class="hljs-keyword">import</span> GaudiDDIMScheduler, GaudiStableDiffusionPipeline

model_name = <span class="hljs-string">&quot;stabilityai/stable-diffusion-2-base&quot;</span>
scheduler = GaudiDDIMScheduler.from_pretrained(model_name, subfolder=<span class="hljs-string">&quot;scheduler&quot;</span>)
pipeline = GaudiStableDiffusionPipeline.from_pretrained(
    model_name,
    scheduler=scheduler,
    use_habana=<span class="hljs-literal">True</span>,
    use_hpu_graphs=<span class="hljs-literal">True</span>,
    gaudi_config=<span class="hljs-string">&quot;Habana/stable-diffusion-2&quot;</span>,
)`}}),q=new _i({props:{code:"b3V0cHV0cyUyMCUzRCUyMHBpcGVsaW5lKCUwQSUyMCUyMCUyMCUyMHByb21wdCUzRCU1QiUwQSUyMCUyMCUyMCUyMCUyMCUyMCUyMCUyMCUyMkhpZ2glMjBxdWFsaXR5JTIwcGhvdG8lMjBvZiUyMGFuJTIwYXN0cm9uYXV0JTIwcmlkaW5nJTIwYSUyMGhvcnNlJTIwaW4lMjBzcGFjZSUyMiUyQyUwQSUyMCUyMCUyMCUyMCUyMCUyMCUyMCUyMCUyMkZhY2UlMjBvZiUyMGElMjB5ZWxsb3clMjBjYXQlMkMlMjBoaWdoJTIwcmVzb2x1dGlvbiUyQyUyMHNpdHRpbmclMjBvbiUyMGElMjBwYXJrJTIwYmVuY2glMjIlMkMlMEElMjAlMjAlMjAlMjAlNUQlMkMlMEElMjAlMjAlMjAlMjBudW1faW1hZ2VzX3Blcl9wcm9tcHQlM0QxMCUyQyUwQSUyMCUyMCUyMCUyMGJhdGNoX3NpemUlM0Q0JTJDJTBBKQ==",highlighted:`outputs = pipeline(
    prompt=[
        <span class="hljs-string">&quot;High quality photo of an astronaut riding a horse in space&quot;</span>,
        <span class="hljs-string">&quot;Face of a yellow cat, high resolution, sitting on a park bench&quot;</span>,
    ],
    num_images_per_prompt=<span class="hljs-number">10</span>,
    batch_size=<span class="hljs-number">4</span>,
)`}}),K=new Nt({}),{c(){v=l("meta"),ot=h(),y=l("h1"),I=l("a"),je=l("span"),Ae(B.$$.fragment),Rt=h(),Ne=l("span"),xt=o("How to use Stable Diffusion on Habana Gaudi"),nt=h(),D=l("p"),Pt=o("\u{1F917} Diffusers is compatible with Habana Gaudi through \u{1F917} "),j=l("a"),Ft=o("Optimum Habana"),Qt=o("."),st=h(),_=l("h2"),S=l("a"),Re=l("span"),Ae(N.$$.fragment),zt=h(),xe=l("span"),Vt=o("Requirements"),ht=h(),$=l("ul"),R=l("li"),Yt=o("Optimum Habana 1.6 or later, "),x=l("a"),Lt=o("here"),qt=o(" is how to install it."),Xt=h(),Pe=l("li"),Ot=o("SynapseAI 1.10."),ft=h(),w=l("h2"),A=l("a"),Fe=l("span"),Ae(P.$$.fragment),Kt=h(),Qe=l("span"),ea=o("Inference Pipeline"),ut=h(),oe=l("p"),ta=o("To generate images with Stable Diffusion 1 and 2 on Gaudi, you need to instantiate two instances:"),ct=h(),C=l("ul"),g=l("li"),aa=o("A pipeline with "),F=l("a"),ze=l("code"),la=o("GaudiStableDiffusionPipeline"),ia=o(". This pipeline supports "),Ve=l("em"),ra=o("text-to-image generation"),oa=o("."),na=h(),Q=l("li"),sa=o("A scheduler with "),z=l("a"),Ye=l("code"),ha=o("GaudiDDIMScheduler"),fa=o(". This scheduler has been optimized for Habana Gaudi."),dt=h(),d=l("p"),ua=o("When initializing the pipeline, you have to specify "),Le=l("code"),ca=o("use_habana=True"),da=o(` to deploy it on HPUs.
Furthermore, in order to get the fastest possible generations you should enable `),qe=l("strong"),pa=o("HPU graphs"),ma=o(" with "),Xe=l("code"),ba=o("use_hpu_graphs=True"),va=o(`.
Finally, you will need to specify a `),V=l("a"),ya=o("Gaudi configuration"),_a=o(" which can be downloaded from the "),Y=l("a"),wa=o("Hugging Face Hub"),ga=o("."),pt=h(),Ae(L.$$.fragment),mt=h(),ne=l("p"),Ea=o("You can then call the pipeline to generate images by batches from one or several prompts:"),bt=h(),Ae(q.$$.fragment),vt=h(),m=l("p"),Ta=o("For more information, check out Optimum Habana\u2019s "),X=l("a"),Ma=o("documentation"),Ua=o(" and the "),O=l("a"),Ga=o("example"),Ja=o(" provided in the official Github repository."),yt=h(),E=l("h2"),k=l("a"),Oe=l("span"),Ae(K.$$.fragment),Ha=h(),Ke=l("span"),Ia=o("Benchmark"),_t=h(),b=l("p"),Da=o("Here are the latencies for Habana first-generation Gaudi and Gaudi2 with the "),ee=l("a"),Sa=o("Habana/stable-diffusion"),$a=o(" and "),te=l("a"),Aa=o("Habana/stable-diffusion-2"),Ca=o(" Gaudi configurations (mixed precision bf16/fp32):"),wt=h(),se=l("ul"),he=l("li"),ae=l("a"),ka=o("Stable Diffusion v1.5"),Za=o(" (512x512 resolution):"),gt=h(),Z=l("table"),et=l("thead"),T=l("tr"),Et=l("th"),Wa=h(),fe=l("th"),Ba=o("Latency (batch size = 1)"),ja=h(),ue=l("th"),Na=o("Throughput (batch size = 8)"),Ra=h(),le=l("tbody"),M=l("tr"),tt=l("td"),xa=o("first-generation Gaudi"),Pa=h(),ce=l("td"),Fa=o("3.80s"),Qa=h(),de=l("td"),za=o("0.308 images/s"),Va=h(),U=l("tr"),at=l("td"),Ya=o("Gaudi2"),La=h(),pe=l("td"),qa=o("1.33s"),Xa=h(),me=l("td"),Oa=o("1.081 images/s"),Tt=h(),be=l("ul"),ve=l("li"),ie=l("a"),Ka=o("Stable Diffusion v2.1"),el=o(" (768x768 resolution):"),Mt=h(),W=l("table"),lt=l("thead"),G=l("tr"),Ut=l("th"),tl=h(),ye=l("th"),al=o("Latency (batch size = 1)"),ll=h(),_e=l("th"),il=o("Throughput"),rl=h(),re=l("tbody"),J=l("tr"),it=l("td"),ol=o("first-generation Gaudi"),nl=h(),we=l("td"),sl=o("10.2s"),hl=h(),ge=l("td"),fl=o("0.108 images/s (batch size = 4)"),ul=h(),H=l("tr"),rt=l("td"),cl=o("Gaudi2"),dl=h(),Ee=l("td"),pl=o("3.17s"),ml=h(),Te=l("td"),bl=o("0.379 images/s (batch size = 8)"),this.h()},l(t){const u=Ti('[data-svelte="svelte-1phssyn"]',document.head);v=i(u,"META",{name:!0,content:!0}),u.forEach(a),ot=f(t),y=i(t,"H1",{class:!0});var Jt=r(y);I=i(Jt,"A",{id:!0,class:!0,href:!0});var wl=r(I);je=i(wl,"SPAN",{});var gl=r(je);Ce(B.$$.fragment,gl),gl.forEach(a),wl.forEach(a),Rt=f(Jt),Ne=i(Jt,"SPAN",{});var El=r(Ne);xt=n(El,"How to use Stable Diffusion on Habana Gaudi"),El.forEach(a),Jt.forEach(a),nt=f(t),D=i(t,"P",{});var Ht=r(D);Pt=n(Ht,"\u{1F917} Diffusers is compatible with Habana Gaudi through \u{1F917} "),j=i(Ht,"A",{href:!0,rel:!0});var Tl=r(j);Ft=n(Tl,"Optimum Habana"),Tl.forEach(a),Qt=n(Ht,"."),Ht.forEach(a),st=f(t),_=i(t,"H2",{class:!0});var It=r(_);S=i(It,"A",{id:!0,class:!0,href:!0});var Ml=r(S);Re=i(Ml,"SPAN",{});var Ul=r(Re);Ce(N.$$.fragment,Ul),Ul.forEach(a),Ml.forEach(a),zt=f(It),xe=i(It,"SPAN",{});var Gl=r(xe);Vt=n(Gl,"Requirements"),Gl.forEach(a),It.forEach(a),ht=f(t),$=i(t,"UL",{});var Dt=r($);R=i(Dt,"LI",{});var St=r(R);Yt=n(St,"Optimum Habana 1.6 or later, "),x=i(St,"A",{href:!0,rel:!0});var Jl=r(x);Lt=n(Jl,"here"),Jl.forEach(a),qt=n(St," is how to install it."),St.forEach(a),Xt=f(Dt),Pe=i(Dt,"LI",{});var Hl=r(Pe);Ot=n(Hl,"SynapseAI 1.10."),Hl.forEach(a),Dt.forEach(a),ft=f(t),w=i(t,"H2",{class:!0});var $t=r(w);A=i($t,"A",{id:!0,class:!0,href:!0});var Il=r(A);Fe=i(Il,"SPAN",{});var Dl=r(Fe);Ce(P.$$.fragment,Dl),Dl.forEach(a),Il.forEach(a),Kt=f($t),Qe=i($t,"SPAN",{});var Sl=r(Qe);ea=n(Sl,"Inference Pipeline"),Sl.forEach(a),$t.forEach(a),ut=f(t),oe=i(t,"P",{});var $l=r(oe);ta=n($l,"To generate images with Stable Diffusion 1 and 2 on Gaudi, you need to instantiate two instances:"),$l.forEach(a),ct=f(t),C=i(t,"UL",{});var At=r(C);g=i(At,"LI",{});var Me=r(g);aa=n(Me,"A pipeline with "),F=i(Me,"A",{href:!0,rel:!0});var Al=r(F);ze=i(Al,"CODE",{});var Cl=r(ze);la=n(Cl,"GaudiStableDiffusionPipeline"),Cl.forEach(a),Al.forEach(a),ia=n(Me,". This pipeline supports "),Ve=i(Me,"EM",{});var kl=r(Ve);ra=n(kl,"text-to-image generation"),kl.forEach(a),oa=n(Me,"."),Me.forEach(a),na=f(At),Q=i(At,"LI",{});var Ct=r(Q);sa=n(Ct,"A scheduler with "),z=i(Ct,"A",{href:!0,rel:!0});var Zl=r(z);Ye=i(Zl,"CODE",{});var Wl=r(Ye);ha=n(Wl,"GaudiDDIMScheduler"),Wl.forEach(a),Zl.forEach(a),fa=n(Ct,". This scheduler has been optimized for Habana Gaudi."),Ct.forEach(a),At.forEach(a),dt=f(t),d=i(t,"P",{});var p=r(d);ua=n(p,"When initializing the pipeline, you have to specify "),Le=i(p,"CODE",{});var Bl=r(Le);ca=n(Bl,"use_habana=True"),Bl.forEach(a),da=n(p,` to deploy it on HPUs.
Furthermore, in order to get the fastest possible generations you should enable `),qe=i(p,"STRONG",{});var jl=r(qe);pa=n(jl,"HPU graphs"),jl.forEach(a),ma=n(p," with "),Xe=i(p,"CODE",{});var Nl=r(Xe);ba=n(Nl,"use_hpu_graphs=True"),Nl.forEach(a),va=n(p,`.
Finally, you will need to specify a `),V=i(p,"A",{href:!0,rel:!0});var Rl=r(V);ya=n(Rl,"Gaudi configuration"),Rl.forEach(a),_a=n(p," which can be downloaded from the "),Y=i(p,"A",{href:!0,rel:!0});var xl=r(Y);wa=n(xl,"Hugging Face Hub"),xl.forEach(a),ga=n(p,"."),p.forEach(a),pt=f(t),Ce(L.$$.fragment,t),mt=f(t),ne=i(t,"P",{});var Pl=r(ne);Ea=n(Pl,"You can then call the pipeline to generate images by batches from one or several prompts:"),Pl.forEach(a),bt=f(t),Ce(q.$$.fragment,t),vt=f(t),m=i(t,"P",{});var Ue=r(m);Ta=n(Ue,"For more information, check out Optimum Habana\u2019s "),X=i(Ue,"A",{href:!0,rel:!0});var Fl=r(X);Ma=n(Fl,"documentation"),Fl.forEach(a),Ua=n(Ue," and the "),O=i(Ue,"A",{href:!0,rel:!0});var Ql=r(O);Ga=n(Ql,"example"),Ql.forEach(a),Ja=n(Ue," provided in the official Github repository."),Ue.forEach(a),yt=f(t),E=i(t,"H2",{class:!0});var kt=r(E);k=i(kt,"A",{id:!0,class:!0,href:!0});var zl=r(k);Oe=i(zl,"SPAN",{});var Vl=r(Oe);Ce(K.$$.fragment,Vl),Vl.forEach(a),zl.forEach(a),Ha=f(kt),Ke=i(kt,"SPAN",{});var Yl=r(Ke);Ia=n(Yl,"Benchmark"),Yl.forEach(a),kt.forEach(a),_t=f(t),b=i(t,"P",{});var Ge=r(b);Da=n(Ge,"Here are the latencies for Habana first-generation Gaudi and Gaudi2 with the "),ee=i(Ge,"A",{href:!0,rel:!0});var Ll=r(ee);Sa=n(Ll,"Habana/stable-diffusion"),Ll.forEach(a),$a=n(Ge," and "),te=i(Ge,"A",{href:!0,rel:!0});var ql=r(te);Aa=n(ql,"Habana/stable-diffusion-2"),ql.forEach(a),Ca=n(Ge," Gaudi configurations (mixed precision bf16/fp32):"),Ge.forEach(a),wt=f(t),se=i(t,"UL",{});var Xl=r(se);he=i(Xl,"LI",{});var vl=r(he);ae=i(vl,"A",{href:!0,rel:!0});var Ol=r(ae);ka=n(Ol,"Stable Diffusion v1.5"),Ol.forEach(a),Za=n(vl," (512x512 resolution):"),vl.forEach(a),Xl.forEach(a),gt=f(t),Z=i(t,"TABLE",{});var Zt=r(Z);et=i(Zt,"THEAD",{});var Kl=r(et);T=i(Kl,"TR",{});var Je=r(T);Et=i(Je,"TH",{}),r(Et).forEach(a),Wa=f(Je),fe=i(Je,"TH",{align:!0});var ei=r(fe);Ba=n(ei,"Latency (batch size = 1)"),ei.forEach(a),ja=f(Je),ue=i(Je,"TH",{align:!0});var ti=r(ue);Na=n(ti,"Throughput (batch size = 8)"),ti.forEach(a),Je.forEach(a),Kl.forEach(a),Ra=f(Zt),le=i(Zt,"TBODY",{});var Wt=r(le);M=i(Wt,"TR",{});var He=r(M);tt=i(He,"TD",{});var ai=r(tt);xa=n(ai,"first-generation Gaudi"),ai.forEach(a),Pa=f(He),ce=i(He,"TD",{align:!0});var li=r(ce);Fa=n(li,"3.80s"),li.forEach(a),Qa=f(He),de=i(He,"TD",{align:!0});var ii=r(de);za=n(ii,"0.308 images/s"),ii.forEach(a),He.forEach(a),Va=f(Wt),U=i(Wt,"TR",{});var Ie=r(U);at=i(Ie,"TD",{});var ri=r(at);Ya=n(ri,"Gaudi2"),ri.forEach(a),La=f(Ie),pe=i(Ie,"TD",{align:!0});var oi=r(pe);qa=n(oi,"1.33s"),oi.forEach(a),Xa=f(Ie),me=i(Ie,"TD",{align:!0});var ni=r(me);Oa=n(ni,"1.081 images/s"),ni.forEach(a),Ie.forEach(a),Wt.forEach(a),Zt.forEach(a),Tt=f(t),be=i(t,"UL",{});var si=r(be);ve=i(si,"LI",{});var yl=r(ve);ie=i(yl,"A",{href:!0,rel:!0});var hi=r(ie);Ka=n(hi,"Stable Diffusion v2.1"),hi.forEach(a),el=n(yl," (768x768 resolution):"),yl.forEach(a),si.forEach(a),Mt=f(t),W=i(t,"TABLE",{});var Bt=r(W);lt=i(Bt,"THEAD",{});var fi=r(lt);G=i(fi,"TR",{});var De=r(G);Ut=i(De,"TH",{}),r(Ut).forEach(a),tl=f(De),ye=i(De,"TH",{align:!0});var ui=r(ye);al=n(ui,"Latency (batch size = 1)"),ui.forEach(a),ll=f(De),_e=i(De,"TH",{align:!0});var ci=r(_e);il=n(ci,"Throughput"),ci.forEach(a),De.forEach(a),fi.forEach(a),rl=f(Bt),re=i(Bt,"TBODY",{});var jt=r(re);J=i(jt,"TR",{});var Se=r(J);it=i(Se,"TD",{});var di=r(it);ol=n(di,"first-generation Gaudi"),di.forEach(a),nl=f(Se),we=i(Se,"TD",{align:!0});var pi=r(we);sl=n(pi,"10.2s"),pi.forEach(a),hl=f(Se),ge=i(Se,"TD",{align:!0});var mi=r(ge);fl=n(mi,"0.108 images/s (batch size = 4)"),mi.forEach(a),Se.forEach(a),ul=f(jt),H=i(jt,"TR",{});var $e=r(H);rt=i($e,"TD",{});var bi=r(rt);cl=n(bi,"Gaudi2"),bi.forEach(a),dl=f($e),Ee=i($e,"TD",{align:!0});var vi=r(Ee);pl=n(vi,"3.17s"),vi.forEach(a),ml=f($e),Te=i($e,"TD",{align:!0});var yi=r(Te);bl=n(yi,"0.379 images/s (batch size = 8)"),yi.forEach(a),$e.forEach(a),jt.forEach(a),Bt.forEach(a),this.h()},h(){s(v,"name","hf:doc:metadata"),s(v,"content",JSON.stringify(Ji)),s(I,"id","how-to-use-stable-diffusion-on-habana-gaudi"),s(I,"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"),s(I,"href","#how-to-use-stable-diffusion-on-habana-gaudi"),s(y,"class","relative group"),s(j,"href","https://huggingface.co/docs/optimum/habana/usage_guides/stable_diffusion"),s(j,"rel","nofollow"),s(S,"id","requirements"),s(S,"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"),s(S,"href","#requirements"),s(_,"class","relative group"),s(x,"href","https://huggingface.co/docs/optimum/habana/installation"),s(x,"rel","nofollow"),s(A,"id","inference-pipeline"),s(A,"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"),s(A,"href","#inference-pipeline"),s(w,"class","relative group"),s(F,"href","https://huggingface.co/docs/optimum/habana/package_reference/stable_diffusion_pipeline"),s(F,"rel","nofollow"),s(z,"href","https://huggingface.co/docs/optimum/habana/package_reference/stable_diffusion_pipeline#optimum.habana.diffusers.GaudiDDIMScheduler"),s(z,"rel","nofollow"),s(V,"href","https://huggingface.co/docs/optimum/habana/package_reference/gaudi_config"),s(V,"rel","nofollow"),s(Y,"href","https://huggingface.co/Habana"),s(Y,"rel","nofollow"),s(X,"href","https://huggingface.co/docs/optimum/habana/usage_guides/stable_diffusion"),s(X,"rel","nofollow"),s(O,"href","https://github.com/huggingface/optimum-habana/tree/main/examples/stable-diffusion"),s(O,"rel","nofollow"),s(k,"id","benchmark"),s(k,"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"),s(k,"href","#benchmark"),s(E,"class","relative group"),s(ee,"href","https://huggingface.co/Habana/stable-diffusion"),s(ee,"rel","nofollow"),s(te,"href","https://huggingface.co/Habana/stable-diffusion-2"),s(te,"rel","nofollow"),s(ae,"href","https://huggingface.co/runwayml/stable-diffusion-v1-5"),s(ae,"rel","nofollow"),s(fe,"align","center"),s(ue,"align","center"),s(ce,"align","center"),s(de,"align","center"),s(pe,"align","center"),s(me,"align","center"),s(ie,"href","https://huggingface.co/stabilityai/stable-diffusion-2-1"),s(ie,"rel","nofollow"),s(ye,"align","center"),s(_e,"align","center"),s(we,"align","center"),s(ge,"align","center"),s(Ee,"align","center"),s(Te,"align","center")},m(t,u){e(document.head,v),c(t,ot,u),c(t,y,u),e(y,I),e(I,je),ke(B,je,null),e(y,Rt),e(y,Ne),e(Ne,xt),c(t,nt,u),c(t,D,u),e(D,Pt),e(D,j),e(j,Ft),e(D,Qt),c(t,st,u),c(t,_,u),e(_,S),e(S,Re),ke(N,Re,null),e(_,zt),e(_,xe),e(xe,Vt),c(t,ht,u),c(t,$,u),e($,R),e(R,Yt),e(R,x),e(x,Lt),e(R,qt),e($,Xt),e($,Pe),e(Pe,Ot),c(t,ft,u),c(t,w,u),e(w,A),e(A,Fe),ke(P,Fe,null),e(w,Kt),e(w,Qe),e(Qe,ea),c(t,ut,u),c(t,oe,u),e(oe,ta),c(t,ct,u),c(t,C,u),e(C,g),e(g,aa),e(g,F),e(F,ze),e(ze,la),e(g,ia),e(g,Ve),e(Ve,ra),e(g,oa),e(C,na),e(C,Q),e(Q,sa),e(Q,z),e(z,Ye),e(Ye,ha),e(Q,fa),c(t,dt,u),c(t,d,u),e(d,ua),e(d,Le),e(Le,ca),e(d,da),e(d,qe),e(qe,pa),e(d,ma),e(d,Xe),e(Xe,ba),e(d,va),e(d,V),e(V,ya),e(d,_a),e(d,Y),e(Y,wa),e(d,ga),c(t,pt,u),ke(L,t,u),c(t,mt,u),c(t,ne,u),e(ne,Ea),c(t,bt,u),ke(q,t,u),c(t,vt,u),c(t,m,u),e(m,Ta),e(m,X),e(X,Ma),e(m,Ua),e(m,O),e(O,Ga),e(m,Ja),c(t,yt,u),c(t,E,u),e(E,k),e(k,Oe),ke(K,Oe,null),e(E,Ha),e(E,Ke),e(Ke,Ia),c(t,_t,u),c(t,b,u),e(b,Da),e(b,ee),e(ee,Sa),e(b,$a),e(b,te),e(te,Aa),e(b,Ca),c(t,wt,u),c(t,se,u),e(se,he),e(he,ae),e(ae,ka),e(he,Za),c(t,gt,u),c(t,Z,u),e(Z,et),e(et,T),e(T,Et),e(T,Wa),e(T,fe),e(fe,Ba),e(T,ja),e(T,ue),e(ue,Na),e(Z,Ra),e(Z,le),e(le,M),e(M,tt),e(tt,xa),e(M,Pa),e(M,ce),e(ce,Fa),e(M,Qa),e(M,de),e(de,za),e(le,Va),e(le,U),e(U,at),e(at,Ya),e(U,La),e(U,pe),e(pe,qa),e(U,Xa),e(U,me),e(me,Oa),c(t,Tt,u),c(t,be,u),e(be,ve),e(ve,ie),e(ie,Ka),e(ve,el),c(t,Mt,u),c(t,W,u),e(W,lt),e(lt,G),e(G,Ut),e(G,tl),e(G,ye),e(ye,al),e(G,ll),e(G,_e),e(_e,il),e(W,rl),e(W,re),e(re,J),e(J,it),e(it,ol),e(J,nl),e(J,we),e(we,sl),e(J,hl),e(J,ge),e(ge,fl),e(re,ul),e(re,H),e(H,rt),e(rt,cl),e(H,dl),e(H,Ee),e(Ee,pl),e(H,ml),e(H,Te),e(Te,bl),Gt=!0},p:Mi,i(t){Gt||(Ze(B.$$.fragment,t),Ze(N.$$.fragment,t),Ze(P.$$.fragment,t),Ze(L.$$.fragment,t),Ze(q.$$.fragment,t),Ze(K.$$.fragment,t),Gt=!0)},o(t){We(B.$$.fragment,t),We(N.$$.fragment,t),We(P.$$.fragment,t),We(L.$$.fragment,t),We(q.$$.fragment,t),We(K.$$.fragment,t),Gt=!1},d(t){a(v),t&&a(ot),t&&a(y),Be(B),t&&a(nt),t&&a(D),t&&a(st),t&&a(_),Be(N),t&&a(ht),t&&a($),t&&a(ft),t&&a(w),Be(P),t&&a(ut),t&&a(oe),t&&a(ct),t&&a(C),t&&a(dt),t&&a(d),t&&a(pt),Be(L,t),t&&a(mt),t&&a(ne),t&&a(bt),Be(q,t),t&&a(vt),t&&a(m),t&&a(yt),t&&a(E),Be(K),t&&a(_t),t&&a(b),t&&a(wt),t&&a(se),t&&a(gt),t&&a(Z),t&&a(Tt),t&&a(be),t&&a(Mt),t&&a(W)}}}const Ji={local:"how-to-use-stable-diffusion-on-habana-gaudi",sections:[{local:"requirements",title:"Requirements"},{local:"inference-pipeline",title:"Inference Pipeline"},{local:"benchmark",title:"Benchmark"}],title:"How to use Stable Diffusion on Habana Gaudi"};function Hi(_l){return Ui(()=>{new URLSearchParams(window.location.search).get("fw")}),[]}class $i extends wi{constructor(v){super();gi(this,v,Hi,Gi,Ei,{})}}export{$i as default,Ji as metadata};
