Buckets:
| import{s as Cn,o as kn,n as j}from"../chunks/scheduler.8c3d61f6.js";import{S as Pn,i as Rn,g as a,s as o,r as _,A as In,h as n,f as d,c as r,j as v,u as m,x as p,k as $,y as t,a as L,v as u,d as h,t as g,w as x}from"../chunks/index.da70eac4.js";import{T as Ce}from"../chunks/Tip.1d9b8c37.js";import{D as y}from"../chunks/Docstring.ee4b6913.js";import{C as Pa}from"../chunks/CodeBlock.00a903b3.js";import{E as ka}from"../chunks/ExampleCodeBlock.f7bd2c1f.js";import{H as Mt,E as Hn}from"../chunks/EditOnGithub.1e64e623.js";function Un(D){let s,b='To learn more about how to load LoRA weights, see the <a href="../../using-diffusers/loading_adapters#lora">LoRA</a> loading guide.';return{c(){s=a("p"),s.innerHTML=b},l(c){s=n(c,"P",{"data-svelte-h":!0}),p(s)!=="svelte-1fw6lx1"&&(s.innerHTML=b)},m(c,l){L(c,s,l)},p:j,d(c){c&&d(s)}}}function En(D){let s,b="We support loading A1111 formatted LoRA checkpoints in a limited capacity.",c,l,M="This function is experimental and might change in the future.";return{c(){s=a("p"),s.textContent=b,c=o(),l=a("p"),l.textContent=M},l(i){s=n(i,"P",{"data-svelte-h":!0}),p(s)!=="svelte-15l1sdn"&&(s.textContent=b),c=r(i),l=n(i,"P",{"data-svelte-h":!0}),p(l)!=="svelte-3fufvn"&&(l.textContent=M)},m(i,w){L(i,s,w),L(i,c,w),L(i,l,w)},p:j,d(i){i&&(d(s),d(c),d(l))}}}function Nn(D){let s,b="We support loading A1111 formatted LoRA checkpoints in a limited capacity.",c,l,M="This function is experimental and might change in the future.";return{c(){s=a("p"),s.textContent=b,c=o(),l=a("p"),l.textContent=M},l(i){s=n(i,"P",{"data-svelte-h":!0}),p(s)!=="svelte-15l1sdn"&&(s.textContent=b),c=r(i),l=n(i,"P",{"data-svelte-h":!0}),p(l)!=="svelte-3fufvn"&&(l.textContent=M)},m(i,w){L(i,s,w),L(i,c,w),L(i,l,w)},p:j,d(i){i&&(d(s),d(c),d(l))}}}function Fn(D){let s,b="We support loading A1111 formatted LoRA checkpoints in a limited capacity.",c,l,M="This function is experimental and might change in the future.";return{c(){s=a("p"),s.textContent=b,c=o(),l=a("p"),l.textContent=M},l(i){s=n(i,"P",{"data-svelte-h":!0}),p(s)!=="svelte-15l1sdn"&&(s.textContent=b),c=r(i),l=n(i,"P",{"data-svelte-h":!0}),p(l)!=="svelte-3fufvn"&&(l.textContent=M)},m(i,w){L(i,s,w),L(i,c,w),L(i,l,w)},p:j,d(i){i&&(d(s),d(c),d(l))}}}function Wn(D){let s,b="We support loading A1111 formatted LoRA checkpoints in a limited capacity.",c,l,M="This function is experimental and might change in the future.";return{c(){s=a("p"),s.textContent=b,c=o(),l=a("p"),l.textContent=M},l(i){s=n(i,"P",{"data-svelte-h":!0}),p(s)!=="svelte-15l1sdn"&&(s.textContent=b),c=r(i),l=n(i,"P",{"data-svelte-h":!0}),p(l)!=="svelte-3fufvn"&&(l.textContent=M)},m(i,w){L(i,s,w),L(i,c,w),L(i,l,w)},p:j,d(i){i&&(d(s),d(c),d(l))}}}function Xn(D){let s,b="This is an experimental API.";return{c(){s=a("p"),s.textContent=b},l(c){s=n(c,"P",{"data-svelte-h":!0}),p(s)!=="svelte-8w79b9"&&(s.textContent=b)},m(c,l){L(c,s,l)},p:j,d(c){c&&d(s)}}}function Bn(D){let s,b="This is an experimental API.";return{c(){s=a("p"),s.textContent=b},l(c){s=n(c,"P",{"data-svelte-h":!0}),p(s)!=="svelte-8w79b9"&&(s.textContent=b)},m(c,l){L(c,s,l)},p:j,d(c){c&&d(s)}}}function qn(D){let s,b="Example:",c,l,M;return l=new Pa({props:{code:"ZnJvbSUyMGRpZmZ1c2VycyUyMGltcG9ydCUyMERpZmZ1c2lvblBpcGVsaW5lJTBBaW1wb3J0JTIwdG9yY2glMEElMEFwaXBlbGluZSUyMCUzRCUyMERpZmZ1c2lvblBpcGVsaW5lLmZyb21fcHJldHJhaW5lZCglMEElMjAlMjAlMjAlMjAlMjJzdGFiaWxpdHlhaSUyRnN0YWJsZS1kaWZmdXNpb24teGwtYmFzZS0xLjAlMjIlMkMlMjB0b3JjaF9kdHlwZSUzRHRvcmNoLmZsb2F0MTYlMEEpLnRvKCUyMmN1ZGElMjIpJTBBcGlwZWxpbmUubG9hZF9sb3JhX3dlaWdodHMoJTIybmVyaWpzJTJGcGl4ZWwtYXJ0LXhsJTIyJTJDJTIwd2VpZ2h0X25hbWUlM0QlMjJwaXhlbC1hcnQteGwuc2FmZXRlbnNvcnMlMjIlMkMlMjBhZGFwdGVyX25hbWUlM0QlMjJwaXhlbCUyMiklMEFwaXBlbGluZS5mdXNlX2xvcmEobG9yYV9zY2FsZSUzRDAuNyk=",highlighted:`<span class="hljs-keyword">from</span> diffusers <span class="hljs-keyword">import</span> DiffusionPipeline | |
| <span class="hljs-keyword">import</span> torch | |
| pipeline = DiffusionPipeline.from_pretrained( | |
| <span class="hljs-string">"stabilityai/stable-diffusion-xl-base-1.0"</span>, torch_dtype=torch.float16 | |
| ).to(<span class="hljs-string">"cuda"</span>) | |
| pipeline.load_lora_weights(<span class="hljs-string">"nerijs/pixel-art-xl"</span>, weight_name=<span class="hljs-string">"pixel-art-xl.safetensors"</span>, adapter_name=<span class="hljs-string">"pixel"</span>) | |
| pipeline.fuse_lora(lora_scale=<span class="hljs-number">0.7</span>)`,wrap:!1}}),{c(){s=a("p"),s.textContent=b,c=o(),_(l.$$.fragment)},l(i){s=n(i,"P",{"data-svelte-h":!0}),p(s)!=="svelte-11lpom8"&&(s.textContent=b),c=r(i),m(l.$$.fragment,i)},m(i,w){L(i,s,w),L(i,c,w),u(l,i,w),M=!0},p:j,i(i){M||(h(l.$$.fragment,i),M=!0)},o(i){g(l.$$.fragment,i),M=!1},d(i){i&&(d(s),d(c)),x(l,i)}}}function jn(D){let s,b="Example:",c,l,M;return l=new Pa({props:{code:"ZnJvbSUyMGRpZmZ1c2VycyUyMGltcG9ydCUyMERpZmZ1c2lvblBpcGVsaW5lJTBBJTBBcGlwZWxpbmUlMjAlM0QlMjBEaWZmdXNpb25QaXBlbGluZS5mcm9tX3ByZXRyYWluZWQoJTBBJTIwJTIwJTIwJTIwJTIyc3RhYmlsaXR5YWklMkZzdGFibGUtZGlmZnVzaW9uLXhsLWJhc2UtMS4wJTIyJTJDJTBBKS50byglMjJjdWRhJTIyKSUwQXBpcGVsaW5lLmxvYWRfbG9yYV93ZWlnaHRzKCUyMkNpcm9OMjAyMiUyRnRveS1mYWNlJTIyJTJDJTIwd2VpZ2h0X25hbWUlM0QlMjJ0b3lfZmFjZV9zZHhsLnNhZmV0ZW5zb3JzJTIyJTJDJTIwYWRhcHRlcl9uYW1lJTNEJTIydG95JTIyKSUwQXBpcGVsaW5lLmdldF9hY3RpdmVfYWRhcHRlcnMoKQ==",highlighted:`<span class="hljs-keyword">from</span> diffusers <span class="hljs-keyword">import</span> DiffusionPipeline | |
| pipeline = DiffusionPipeline.from_pretrained( | |
| <span class="hljs-string">"stabilityai/stable-diffusion-xl-base-1.0"</span>, | |
| ).to(<span class="hljs-string">"cuda"</span>) | |
| pipeline.load_lora_weights(<span class="hljs-string">"CiroN2022/toy-face"</span>, weight_name=<span class="hljs-string">"toy_face_sdxl.safetensors"</span>, adapter_name=<span class="hljs-string">"toy"</span>) | |
| pipeline.get_active_adapters()`,wrap:!1}}),{c(){s=a("p"),s.textContent=b,c=o(),_(l.$$.fragment)},l(i){s=n(i,"P",{"data-svelte-h":!0}),p(s)!=="svelte-11lpom8"&&(s.textContent=b),c=r(i),m(l.$$.fragment,i)},m(i,w){L(i,s,w),L(i,c,w),u(l,i,w),M=!0},p:j,i(i){M||(h(l.$$.fragment,i),M=!0)},o(i){g(l.$$.fragment,i),M=!1},d(i){i&&(d(s),d(c)),x(l,i)}}}function Vn(D){let s,b="This is an experimental API.";return{c(){s=a("p"),s.textContent=b},l(c){s=n(c,"P",{"data-svelte-h":!0}),p(s)!=="svelte-8w79b9"&&(s.textContent=b)},m(c,l){L(c,s,l)},p:j,d(c){c&&d(s)}}}function Jn(D){let s,b="Examples:",c,l,M;return l=new Pa({props:{code:"JTIzJTIwQXNzdW1pbmclMjAlNjBwaXBlbGluZSU2MCUyMGlzJTIwYWxyZWFkeSUyMGxvYWRlZCUyMHdpdGglMjB0aGUlMjBMb1JBJTIwcGFyYW1ldGVycy4lMEFwaXBlbGluZS51bmxvYWRfbG9yYV93ZWlnaHRzKCklMEEuLi4=",highlighted:'<span class="hljs-meta">>>> </span><span class="hljs-comment"># Assuming `pipeline` is already loaded with the LoRA parameters.</span>\n<span class="hljs-meta">>>> </span>pipeline.unload_lora_weights()\n<span class="hljs-meta">>>> </span>...',wrap:!1}}),{c(){s=a("p"),s.textContent=b,c=o(),_(l.$$.fragment)},l(i){s=n(i,"P",{"data-svelte-h":!0}),p(s)!=="svelte-kvfsh7"&&(s.textContent=b),c=r(i),m(l.$$.fragment,i)},m(i,w){L(i,s,w),L(i,c,w),u(l,i,w),M=!0},p:j,i(i){M||(h(l.$$.fragment,i),M=!0)},o(i){g(l.$$.fragment,i),M=!1},d(i){i&&(d(s),d(c)),x(l,i)}}}function Gn(D){let s,b,c,l,M,i,w,Ra='LoRA is a fast and lightweight training method that inserts and trains a significantly smaller number of parameters instead of all the model parameters. This produces a smaller file (~100 MBs) and makes it easier to quickly train a model to learn a new concept. LoRA weights are typically loaded into the denoiser, text encoder or both. The denoiser usually corresponds to a UNet (<a href="/docs/diffusers/pr_9017/en/api/models/unet2d-cond#diffusers.UNet2DConditionModel">UNet2DConditionModel</a>, for example) or a Transformer (<a href="/docs/diffusers/pr_9017/en/api/models/sd3_transformer2d#diffusers.SD3Transformer2DModel">SD3Transformer2DModel</a>, for example). There are several classes for loading LoRA weights:',To,ke,Ia='<li><code>StableDiffusionLoraLoaderMixin</code> provides functions for loading and unloading, fusing and unfusing, enabling and disabling, and more functions for managing LoRA weights. This class can be used with any model.</li> <li><code>StableDiffusionXLLoraLoaderMixin</code> is a <a href="../../api/pipelines/stable_diffusion/stable_diffusion_xl">Stable Diffusion (SDXL)</a> version of the <code>StableDiffusionLoraLoaderMixin</code> class for loading and saving LoRA weights. It can only be used with the SDXL model.</li> <li><code>SD3LoraLoaderMixin</code> provides similar functions for <a href="https://huggingface.co/blog/sd3" rel="nofollow">Stable Diffusion 3</a>.</li> <li><code>AuraFlowLoraLoaderMixin</code> provides similar functions for <a href="https://huggingface.co/fal/AuraFlow" rel="nofollow">AuraFlow</a>.</li> <li><code>AmusedLoraLoaderMixin</code> is for the <a href="/docs/diffusers/pr_9017/en/api/pipelines/amused#diffusers.AmusedPipeline">AmusedPipeline</a>.</li> <li><code>LoraBaseMixin</code> provides a base class with several utility methods to fuse, unfuse, unload, LoRAs and more.</li>',So,ae,Ao,Pe,Co,A,Re,er,yt,Ha=`Load LoRA layers into Stable Diffusion <a href="/docs/diffusers/pr_9017/en/api/models/unet2d-cond#diffusers.UNet2DConditionModel">UNet2DConditionModel</a> and | |
| <a href="https://huggingface.co/docs/transformers/model_doc/clip#transformers.CLIPTextModel" rel="nofollow"><code>CLIPTextModel</code></a>.`,tr,ne,Ie,or,Dt,Ua="This will load the LoRA layers specified in <code>state_dict</code> into <code>text_encoder</code>",rr,se,He,ar,Tt,Ea="This will load the LoRA layers specified in <code>state_dict</code> into <code>unet</code>.",nr,H,Ue,sr,St,Na=`Load LoRA weights specified in <code>pretrained_model_name_or_path_or_dict</code> into <code>self.unet</code> and | |
| <code>self.text_encoder</code>.`,ir,At,Fa="All kwargs are forwarded to <code>self.lora_state_dict</code>.",dr,Ct,Wa=`See <a href="/docs/diffusers/pr_9017/en/api/loaders/lora#diffusers.loaders.StableDiffusionLoraLoaderMixin.lora_state_dict">lora_state_dict()</a> for more details on how the state dict is | |
| loaded.`,lr,kt,Xa=`See <a href="/docs/diffusers/pr_9017/en/api/loaders/lora#diffusers.loaders.StableDiffusionLoraLoaderMixin.load_lora_into_unet">load_lora_into_unet()</a> for more details on how the state dict is | |
| loaded into <code>self.unet</code>.`,cr,Pt,Ba=`See <a href="/docs/diffusers/pr_9017/en/api/loaders/lora#diffusers.loaders.StableDiffusionLoraLoaderMixin.load_lora_into_text_encoder">load_lora_into_text_encoder()</a> for more details on how the state | |
| dict is loaded into <code>self.text_encoder</code>.`,fr,V,Ee,pr,Rt,qa="Return state dict for lora weights and the network alphas.",_r,ie,mr,de,Ne,ur,It,ja="Save the LoRA parameters corresponding to the UNet and text encoder.",ko,Fe,Po,C,We,hr,Ht,Va=`Load LoRA layers into Stable Diffusion XL <a href="/docs/diffusers/pr_9017/en/api/models/unet2d-cond#diffusers.UNet2DConditionModel">UNet2DConditionModel</a>, | |
| <a href="https://huggingface.co/docs/transformers/model_doc/clip#transformers.CLIPTextModel" rel="nofollow"><code>CLIPTextModel</code></a>, and | |
| <a href="https://huggingface.co/docs/transformers/model_doc/clip#transformers.CLIPTextModelWithProjection" rel="nofollow"><code>CLIPTextModelWithProjection</code></a>.`,gr,le,Xe,xr,Ut,Ja="This will load the LoRA layers specified in <code>state_dict</code> into <code>text_encoder</code>",Lr,ce,Be,br,Et,Ga="This will load the LoRA layers specified in <code>state_dict</code> into <code>unet</code>.",vr,U,qe,$r,Nt,Za=`Load LoRA weights specified in <code>pretrained_model_name_or_path_or_dict</code> into <code>self.unet</code> and | |
| <code>self.text_encoder</code>.`,wr,Ft,za="All kwargs are forwarded to <code>self.lora_state_dict</code>.",Mr,Wt,Ya=`See <a href="/docs/diffusers/pr_9017/en/api/loaders/lora#diffusers.loaders.StableDiffusionLoraLoaderMixin.lora_state_dict">lora_state_dict()</a> for more details on how the state dict is | |
| loaded.`,yr,Xt,Qa=`See <a href="/docs/diffusers/pr_9017/en/api/loaders/lora#diffusers.loaders.StableDiffusionLoraLoaderMixin.load_lora_into_unet">load_lora_into_unet()</a> for more details on how the state dict is | |
| loaded into <code>self.unet</code>.`,Dr,Bt,Oa=`See <a href="/docs/diffusers/pr_9017/en/api/loaders/lora#diffusers.loaders.StableDiffusionLoraLoaderMixin.load_lora_into_text_encoder">load_lora_into_text_encoder()</a> for more details on how the state | |
| dict is loaded into <code>self.text_encoder</code>.`,Tr,J,je,Sr,qt,Ka="Return state dict for lora weights and the network alphas.",Ar,fe,Cr,pe,Ve,kr,jt,en="Save the LoRA parameters corresponding to the UNet and text encoder.",Ro,Je,Io,S,Ge,Pr,Vt,tn=`Load LoRA layers into <a href="/docs/diffusers/pr_9017/en/api/models/sd3_transformer2d#diffusers.SD3Transformer2DModel">SD3Transformer2DModel</a>, | |
| <a href="https://huggingface.co/docs/transformers/model_doc/clip#transformers.CLIPTextModel" rel="nofollow"><code>CLIPTextModel</code></a>, and | |
| <a href="https://huggingface.co/docs/transformers/model_doc/clip#transformers.CLIPTextModelWithProjection" rel="nofollow"><code>CLIPTextModelWithProjection</code></a>.`,Rr,Jt,on='Specific to <a href="/docs/diffusers/pr_9017/en/api/pipelines/stable_diffusion/stable_diffusion_3#diffusers.StableDiffusion3Pipeline">StableDiffusion3Pipeline</a>.',Ir,_e,Ze,Hr,Gt,rn="This will load the LoRA layers specified in <code>state_dict</code> into <code>text_encoder</code>",Ur,me,ze,Er,Zt,an="This will load the LoRA layers specified in <code>state_dict</code> into <code>transformer</code>.",Nr,W,Ye,Fr,zt,nn=`Load LoRA weights specified in <code>pretrained_model_name_or_path_or_dict</code> into <code>self.unet</code> and | |
| <code>self.text_encoder</code>.`,Wr,Yt,sn="All kwargs are forwarded to <code>self.lora_state_dict</code>.",Xr,Qt,dn=`See <a href="/docs/diffusers/pr_9017/en/api/loaders/lora#diffusers.loaders.StableDiffusionLoraLoaderMixin.lora_state_dict">lora_state_dict()</a> for more details on how the state dict is | |
| loaded.`,Br,Ot,ln=`See <code>~loaders.StableDiffusionLoraLoaderMixin.load_lora_into_transformer</code> for more details on how the state | |
| dict is loaded into <code>self.transformer</code>.`,qr,G,Qe,jr,Kt,cn="Return state dict for lora weights and the network alphas.",Vr,ue,Jr,he,Oe,Gr,eo,fn="Save the LoRA parameters corresponding to the UNet and text encoder.",Ho,Ke,Uo,k,et,Zr,to,pn=`Load LoRA layers into <a href="/docs/diffusers/pr_9017/en/api/models/aura_flow_transformer2d#diffusers.AuraFlowTransformer2DModel">AuraFlowTransformer2DModel</a> | |
| Specific to <a href="/docs/diffusers/pr_9017/en/api/pipelines/aura_flow#diffusers.AuraFlowPipeline">AuraFlowPipeline</a>.`,zr,ge,tt,Yr,oo,_n="This will load the LoRA layers specified in <code>state_dict</code> into <code>transformer</code>.",Qr,X,ot,Or,ro,mn="Load LoRA weights specified in <code>pretrained_model_name_or_path_or_dict</code> into <code>self.transformer</code>",Kr,ao,un="All kwargs are forwarded to <code>self.lora_state_dict</code>.",ea,no,hn=`See <a href="/docs/diffusers/pr_9017/en/api/loaders/lora#diffusers.loaders.StableDiffusionLoraLoaderMixin.lora_state_dict">lora_state_dict()</a> for more details on how the state dict is | |
| loaded.`,ta,so,gn=`See <code>~loaders.StableDiffusionLoraLoaderMixin.load_lora_into_transformer</code> for more details on how the state | |
| dict is loaded into <code>self.transformer</code>.`,oa,Z,rt,ra,io,xn="Return state dict for lora weights and the network alphas.",aa,xe,na,Le,at,sa,lo,Ln="Save the LoRA parameters corresponding to the UNet and text encoder.",ia,z,nt,da,co,bn=`Reverses the effect of | |
| <a href="https://huggingface.co/docs/diffusers/main/en/api/loaders#diffusers.loaders.LoraBaseMixin.fuse_lora" rel="nofollow"><code>pipe.fuse_lora()</code></a>.`,la,be,Eo,st,No,te,it,ca,ve,dt,fa,fo,vn="This will load the LoRA layers specified in <code>state_dict</code> into <code>transformer</code>.",Fo,lt,Wo,T,ct,pa,po,$n="Utility class for handling LoRAs.",_a,_o,ft,ma,q,pt,ua,mo,wn="Fuses the LoRA parameters into the original parameters of the corresponding blocks.",ha,$e,ga,we,xa,Y,_t,La,uo,Mn="Gets the list of the current active adapters.",ba,Me,va,ye,mt,$a,ho,yn="Gets the current list of all available adapters in the pipeline.",wa,De,ut,Ma,go,Dn=`Moves the LoRAs listed in <code>adapter_names</code> to a target device. Useful for offloading the LoRA to the CPU in case | |
| you want to load multiple adapters and free some GPU memory.`,ya,Q,ht,Da,xo,Tn=`Reverses the effect of | |
| <a href="https://huggingface.co/docs/diffusers/main/en/api/loaders#diffusers.loaders.LoraBaseMixin.fuse_lora" rel="nofollow"><code>pipe.fuse_lora()</code></a>.`,Ta,Te,Sa,O,gt,Aa,Lo,Sn="Unloads the LoRA parameters.",Ca,Se,Xo,xt,Bo,Do,qo;return M=new Mt({props:{title:"LoRA",local:"lora",headingTag:"h1"}}),ae=new Ce({props:{$$slots:{default:[Un]},$$scope:{ctx:D}}}),Pe=new Mt({props:{title:"StableDiffusionLoraLoaderMixin",local:"diffusers.loaders.StableDiffusionLoraLoaderMixin",headingTag:"h2"}}),Re=new y({props:{name:"class diffusers.loaders.StableDiffusionLoraLoaderMixin",anchor:"diffusers.loaders.StableDiffusionLoraLoaderMixin",parameters:[],source:"https://github.com/huggingface/diffusers/blob/vr_9017/src/diffusers/loaders/lora_pipeline.py#L50"}}),Ie=new y({props:{name:"load_lora_into_text_encoder",anchor:"diffusers.loaders.StableDiffusionLoraLoaderMixin.load_lora_into_text_encoder",parameters:[{name:"state_dict",val:""},{name:"network_alphas",val:""},{name:"text_encoder",val:""},{name:"prefix",val:" = None"},{name:"lora_scale",val:" = 1.0"},{name:"adapter_name",val:" = None"},{name:"_pipeline",val:" = None"}],parametersDescription:[{anchor:"diffusers.loaders.StableDiffusionLoraLoaderMixin.load_lora_into_text_encoder.state_dict",description:`<strong>state_dict</strong> (<code>dict</code>) — | |
| A standard state dict containing the lora layer parameters. The key should be prefixed with an | |
| additional <code>text_encoder</code> to distinguish between unet lora layers.`,name:"state_dict"},{anchor:"diffusers.loaders.StableDiffusionLoraLoaderMixin.load_lora_into_text_encoder.network_alphas",description:`<strong>network_alphas</strong> (<code>Dict[str, float]</code>) — | |
| See <code>LoRALinearLayer</code> for more details.`,name:"network_alphas"},{anchor:"diffusers.loaders.StableDiffusionLoraLoaderMixin.load_lora_into_text_encoder.text_encoder",description:`<strong>text_encoder</strong> (<code>CLIPTextModel</code>) — | |
| The text encoder model to load the LoRA layers into.`,name:"text_encoder"},{anchor:"diffusers.loaders.StableDiffusionLoraLoaderMixin.load_lora_into_text_encoder.prefix",description:`<strong>prefix</strong> (<code>str</code>) — | |
| Expected prefix of the <code>text_encoder</code> in the <code>state_dict</code>.`,name:"prefix"},{anchor:"diffusers.loaders.StableDiffusionLoraLoaderMixin.load_lora_into_text_encoder.lora_scale",description:`<strong>lora_scale</strong> (<code>float</code>) — | |
| How much to scale the output of the lora linear layer before it is added with the output of the regular | |
| lora layer.`,name:"lora_scale"},{anchor:"diffusers.loaders.StableDiffusionLoraLoaderMixin.load_lora_into_text_encoder.adapter_name",description:`<strong>adapter_name</strong> (<code>str</code>, <em>optional</em>) — | |
| Adapter name to be used for referencing the loaded adapter model. If not specified, it will use | |
| <code>default_{i}</code> where i is the total number of adapters being loaded.`,name:"adapter_name"}],source:"https://github.com/huggingface/diffusers/blob/vr_9017/src/diffusers/loaders/lora_pipeline.py#L264"}}),He=new y({props:{name:"load_lora_into_unet",anchor:"diffusers.loaders.StableDiffusionLoraLoaderMixin.load_lora_into_unet",parameters:[{name:"state_dict",val:""},{name:"network_alphas",val:""},{name:"unet",val:""},{name:"adapter_name",val:" = None"},{name:"_pipeline",val:" = None"}],parametersDescription:[{anchor:"diffusers.loaders.StableDiffusionLoraLoaderMixin.load_lora_into_unet.state_dict",description:`<strong>state_dict</strong> (<code>dict</code>) — | |
| A standard state dict containing the lora layer parameters. The keys can either be indexed directly | |
| into the unet or prefixed with an additional <code>unet</code> which can be used to distinguish between text | |
| encoder lora layers.`,name:"state_dict"},{anchor:"diffusers.loaders.StableDiffusionLoraLoaderMixin.load_lora_into_unet.network_alphas",description:`<strong>network_alphas</strong> (<code>Dict[str, float]</code>) — | |
| The value of the network alpha used for stable learning and preventing underflow. This value has the | |
| same meaning as the <code>--network_alpha</code> option in the kohya-ss trainer script. Refer to <a href="https://github.com/darkstorm2150/sd-scripts/blob/main/docs/train_network_README-en.md#execute-learning" rel="nofollow">this | |
| link</a>.`,name:"network_alphas"},{anchor:"diffusers.loaders.StableDiffusionLoraLoaderMixin.load_lora_into_unet.unet",description:`<strong>unet</strong> (<code>UNet2DConditionModel</code>) — | |
| The UNet model to load the LoRA layers into.`,name:"unet"},{anchor:"diffusers.loaders.StableDiffusionLoraLoaderMixin.load_lora_into_unet.adapter_name",description:`<strong>adapter_name</strong> (<code>str</code>, <em>optional</em>) — | |
| Adapter name to be used for referencing the loaded adapter model. If not specified, it will use | |
| <code>default_{i}</code> where i is the total number of adapters being loaded.`,name:"adapter_name"}],source:"https://github.com/huggingface/diffusers/blob/vr_9017/src/diffusers/loaders/lora_pipeline.py#L229"}}),Ue=new y({props:{name:"load_lora_weights",anchor:"diffusers.loaders.StableDiffusionLoraLoaderMixin.load_lora_weights",parameters:[{name:"pretrained_model_name_or_path_or_dict",val:": Union"},{name:"adapter_name",val:" = None"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"diffusers.loaders.StableDiffusionLoraLoaderMixin.load_lora_weights.pretrained_model_name_or_path_or_dict",description:`<strong>pretrained_model_name_or_path_or_dict</strong> (<code>str</code> or <code>os.PathLike</code> or <code>dict</code>) — | |
| See <a href="/docs/diffusers/pr_9017/en/api/loaders/lora#diffusers.loaders.StableDiffusionLoraLoaderMixin.lora_state_dict">lora_state_dict()</a>.`,name:"pretrained_model_name_or_path_or_dict"},{anchor:"diffusers.loaders.StableDiffusionLoraLoaderMixin.load_lora_weights.kwargs",description:`<strong>kwargs</strong> (<code>dict</code>, <em>optional</em>) — | |
| See <a href="/docs/diffusers/pr_9017/en/api/loaders/lora#diffusers.loaders.StableDiffusionLoraLoaderMixin.lora_state_dict">lora_state_dict()</a>.`,name:"kwargs"},{anchor:"diffusers.loaders.StableDiffusionLoraLoaderMixin.load_lora_weights.adapter_name",description:`<strong>adapter_name</strong> (<code>str</code>, <em>optional</em>) — | |
| Adapter name to be used for referencing the loaded adapter model. If not specified, it will use | |
| <code>default_{i}</code> where i is the total number of adapters being loaded.`,name:"adapter_name"}],source:"https://github.com/huggingface/diffusers/blob/vr_9017/src/diffusers/loaders/lora_pipeline.py#L60"}}),Ee=new y({props:{name:"lora_state_dict",anchor:"diffusers.loaders.StableDiffusionLoraLoaderMixin.lora_state_dict",parameters:[{name:"pretrained_model_name_or_path_or_dict",val:": Union"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"diffusers.loaders.StableDiffusionLoraLoaderMixin.lora_state_dict.pretrained_model_name_or_path_or_dict",description:`<strong>pretrained_model_name_or_path_or_dict</strong> (<code>str</code> or <code>os.PathLike</code> or <code>dict</code>) — | |
| Can be either:</p> | |
| <ul> | |
| <li>A string, the <em>model id</em> (for example <code>google/ddpm-celebahq-256</code>) of a pretrained model hosted on | |
| the Hub.</li> | |
| <li>A path to a <em>directory</em> (for example <code>./my_model_directory</code>) containing the model weights saved | |
| with <a href="/docs/diffusers/pr_9017/en/api/models/overview#diffusers.ModelMixin.save_pretrained">ModelMixin.save_pretrained()</a>.</li> | |
| <li>A <a href="https://pytorch.org/tutorials/beginner/saving_loading_models.html#what-is-a-state-dict" rel="nofollow">torch state | |
| dict</a>.</li> | |
| </ul>`,name:"pretrained_model_name_or_path_or_dict"},{anchor:"diffusers.loaders.StableDiffusionLoraLoaderMixin.lora_state_dict.cache_dir",description:`<strong>cache_dir</strong> (<code>Union[str, os.PathLike]</code>, <em>optional</em>) — | |
| Path to a directory where a downloaded pretrained model configuration is cached if the standard cache | |
| is not used.`,name:"cache_dir"},{anchor:"diffusers.loaders.StableDiffusionLoraLoaderMixin.lora_state_dict.force_download",description:`<strong>force_download</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) — | |
| 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.loaders.StableDiffusionLoraLoaderMixin.lora_state_dict.proxies",description:`<strong>proxies</strong> (<code>Dict[str, str]</code>, <em>optional</em>) — | |
| A dictionary of proxy servers to use by protocol or endpoint, for example, <code>{'http': 'foo.bar:3128', 'http://hostname': 'foo.bar:4012'}</code>. The proxies are used on each request.`,name:"proxies"},{anchor:"diffusers.loaders.StableDiffusionLoraLoaderMixin.lora_state_dict.local_files_only",description:`<strong>local_files_only</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) — | |
| Whether to only load local model weights and configuration files or not. If set to <code>True</code>, the model | |
| won’t be downloaded from the Hub.`,name:"local_files_only"},{anchor:"diffusers.loaders.StableDiffusionLoraLoaderMixin.lora_state_dict.token",description:`<strong>token</strong> (<code>str</code> or <em>bool</em>, <em>optional</em>) — | |
| The token to use as HTTP bearer authorization for remote files. If <code>True</code>, the token generated from | |
| <code>diffusers-cli login</code> (stored in <code>~/.huggingface</code>) is used.`,name:"token"},{anchor:"diffusers.loaders.StableDiffusionLoraLoaderMixin.lora_state_dict.revision",description:`<strong>revision</strong> (<code>str</code>, <em>optional</em>, defaults to <code>"main"</code>) — | |
| The specific model version to use. It can be a branch name, a tag name, a commit id, or any identifier | |
| allowed by Git.`,name:"revision"},{anchor:"diffusers.loaders.StableDiffusionLoraLoaderMixin.lora_state_dict.subfolder",description:`<strong>subfolder</strong> (<code>str</code>, <em>optional</em>, defaults to <code>""</code>) — | |
| The subfolder location of a model file within a larger model repository on the Hub or locally.`,name:"subfolder"},{anchor:"diffusers.loaders.StableDiffusionLoraLoaderMixin.lora_state_dict.weight_name",description:`<strong>weight_name</strong> (<code>str</code>, <em>optional</em>, defaults to None) — | |
| Name of the serialized state dict file.`,name:"weight_name"}],source:"https://github.com/huggingface/diffusers/blob/vr_9017/src/diffusers/loaders/lora_pipeline.py#L119"}}),ie=new Ce({props:{warning:!0,$$slots:{default:[En]},$$scope:{ctx:D}}}),Ne=new y({props:{name:"save_lora_weights",anchor:"diffusers.loaders.StableDiffusionLoraLoaderMixin.save_lora_weights",parameters:[{name:"save_directory",val:": Union"},{name:"unet_lora_layers",val:": Dict = None"},{name:"text_encoder_lora_layers",val:": Dict = None"},{name:"is_main_process",val:": bool = True"},{name:"weight_name",val:": str = None"},{name:"save_function",val:": Callable = None"},{name:"safe_serialization",val:": bool = True"}],parametersDescription:[{anchor:"diffusers.loaders.StableDiffusionLoraLoaderMixin.save_lora_weights.save_directory",description:`<strong>save_directory</strong> (<code>str</code> or <code>os.PathLike</code>) — | |
| Directory to save LoRA parameters to. Will be created if it doesn’t exist.`,name:"save_directory"},{anchor:"diffusers.loaders.StableDiffusionLoraLoaderMixin.save_lora_weights.unet_lora_layers",description:`<strong>unet_lora_layers</strong> (<code>Dict[str, torch.nn.Module]</code> or <code>Dict[str, torch.Tensor]</code>) — | |
| State dict of the LoRA layers corresponding to the <code>unet</code>.`,name:"unet_lora_layers"},{anchor:"diffusers.loaders.StableDiffusionLoraLoaderMixin.save_lora_weights.text_encoder_lora_layers",description:`<strong>text_encoder_lora_layers</strong> (<code>Dict[str, torch.nn.Module]</code> or <code>Dict[str, torch.Tensor]</code>) — | |
| State dict of the LoRA layers corresponding to the <code>text_encoder</code>. Must explicitly pass the text | |
| encoder LoRA state dict because it comes from 🤗 Transformers.`,name:"text_encoder_lora_layers"},{anchor:"diffusers.loaders.StableDiffusionLoraLoaderMixin.save_lora_weights.is_main_process",description:`<strong>is_main_process</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code>) — | |
| Whether the process calling this is the main process or not. Useful during distributed training and you | |
| need to call this function on all processes. In this case, set <code>is_main_process=True</code> only on the main | |
| process to avoid race conditions.`,name:"is_main_process"},{anchor:"diffusers.loaders.StableDiffusionLoraLoaderMixin.save_lora_weights.save_function",description:`<strong>save_function</strong> (<code>Callable</code>) — | |
| The function to use to save the state dictionary. Useful during distributed training when you need to | |
| replace <code>torch.save</code> with another method. Can be configured with the environment variable | |
| <code>DIFFUSERS_SAVE_MODE</code>.`,name:"save_function"},{anchor:"diffusers.loaders.StableDiffusionLoraLoaderMixin.save_lora_weights.safe_serialization",description:`<strong>safe_serialization</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code>) — | |
| Whether to save the model using <code>safetensors</code> or the traditional PyTorch way with <code>pickle</code>.`,name:"safe_serialization"}],source:"https://github.com/huggingface/diffusers/blob/vr_9017/src/diffusers/loaders/lora_pipeline.py#L382"}}),Fe=new Mt({props:{title:"StableDiffusionXLLoraLoaderMixin",local:"diffusers.loaders.StableDiffusionXLLoraLoaderMixin",headingTag:"h2"}}),We=new y({props:{name:"class diffusers.loaders.StableDiffusionXLLoraLoaderMixin",anchor:"diffusers.loaders.StableDiffusionXLLoraLoaderMixin",parameters:[],source:"https://github.com/huggingface/diffusers/blob/vr_9017/src/diffusers/loaders/lora_pipeline.py#L500"}}),Xe=new y({props:{name:"load_lora_into_text_encoder",anchor:"diffusers.loaders.StableDiffusionXLLoraLoaderMixin.load_lora_into_text_encoder",parameters:[{name:"state_dict",val:""},{name:"network_alphas",val:""},{name:"text_encoder",val:""},{name:"prefix",val:" = None"},{name:"lora_scale",val:" = 1.0"},{name:"adapter_name",val:" = None"},{name:"_pipeline",val:" = None"}],parametersDescription:[{anchor:"diffusers.loaders.StableDiffusionXLLoraLoaderMixin.load_lora_into_text_encoder.state_dict",description:`<strong>state_dict</strong> (<code>dict</code>) — | |
| A standard state dict containing the lora layer parameters. The key should be prefixed with an | |
| additional <code>text_encoder</code> to distinguish between unet lora layers.`,name:"state_dict"},{anchor:"diffusers.loaders.StableDiffusionXLLoraLoaderMixin.load_lora_into_text_encoder.network_alphas",description:`<strong>network_alphas</strong> (<code>Dict[str, float]</code>) — | |
| See <code>LoRALinearLayer</code> for more details.`,name:"network_alphas"},{anchor:"diffusers.loaders.StableDiffusionXLLoraLoaderMixin.load_lora_into_text_encoder.text_encoder",description:`<strong>text_encoder</strong> (<code>CLIPTextModel</code>) — | |
| The text encoder model to load the LoRA layers into.`,name:"text_encoder"},{anchor:"diffusers.loaders.StableDiffusionXLLoraLoaderMixin.load_lora_into_text_encoder.prefix",description:`<strong>prefix</strong> (<code>str</code>) — | |
| Expected prefix of the <code>text_encoder</code> in the <code>state_dict</code>.`,name:"prefix"},{anchor:"diffusers.loaders.StableDiffusionXLLoraLoaderMixin.load_lora_into_text_encoder.lora_scale",description:`<strong>lora_scale</strong> (<code>float</code>) — | |
| How much to scale the output of the lora linear layer before it is added with the output of the regular | |
| lora layer.`,name:"lora_scale"},{anchor:"diffusers.loaders.StableDiffusionXLLoraLoaderMixin.load_lora_into_text_encoder.adapter_name",description:`<strong>adapter_name</strong> (<code>str</code>, <em>optional</em>) — | |
| Adapter name to be used for referencing the loaded adapter model. If not specified, it will use | |
| <code>default_{i}</code> where i is the total number of adapters being loaded.`,name:"adapter_name"}],source:"https://github.com/huggingface/diffusers/blob/vr_9017/src/diffusers/loaders/lora_pipeline.py#L736"}}),Be=new y({props:{name:"load_lora_into_unet",anchor:"diffusers.loaders.StableDiffusionXLLoraLoaderMixin.load_lora_into_unet",parameters:[{name:"state_dict",val:""},{name:"network_alphas",val:""},{name:"unet",val:""},{name:"adapter_name",val:" = None"},{name:"_pipeline",val:" = None"}],parametersDescription:[{anchor:"diffusers.loaders.StableDiffusionXLLoraLoaderMixin.load_lora_into_unet.state_dict",description:`<strong>state_dict</strong> (<code>dict</code>) — | |
| A standard state dict containing the lora layer parameters. The keys can either be indexed directly | |
| into the unet or prefixed with an additional <code>unet</code> which can be used to distinguish between text | |
| encoder lora layers.`,name:"state_dict"},{anchor:"diffusers.loaders.StableDiffusionXLLoraLoaderMixin.load_lora_into_unet.network_alphas",description:`<strong>network_alphas</strong> (<code>Dict[str, float]</code>) — | |
| The value of the network alpha used for stable learning and preventing underflow. This value has the | |
| same meaning as the <code>--network_alpha</code> option in the kohya-ss trainer script. Refer to <a href="https://github.com/darkstorm2150/sd-scripts/blob/main/docs/train_network_README-en.md#execute-learning" rel="nofollow">this | |
| link</a>.`,name:"network_alphas"},{anchor:"diffusers.loaders.StableDiffusionXLLoraLoaderMixin.load_lora_into_unet.unet",description:`<strong>unet</strong> (<code>UNet2DConditionModel</code>) — | |
| The UNet model to load the LoRA layers into.`,name:"unet"},{anchor:"diffusers.loaders.StableDiffusionXLLoraLoaderMixin.load_lora_into_unet.adapter_name",description:`<strong>adapter_name</strong> (<code>str</code>, <em>optional</em>) — | |
| Adapter name to be used for referencing the loaded adapter model. If not specified, it will use | |
| <code>default_{i}</code> where i is the total number of adapters being loaded.`,name:"adapter_name"}],source:"https://github.com/huggingface/diffusers/blob/vr_9017/src/diffusers/loaders/lora_pipeline.py#L700"}}),qe=new y({props:{name:"load_lora_weights",anchor:"diffusers.loaders.StableDiffusionXLLoraLoaderMixin.load_lora_weights",parameters:[{name:"pretrained_model_name_or_path_or_dict",val:": Union"},{name:"adapter_name",val:": Optional = None"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"diffusers.loaders.StableDiffusionXLLoraLoaderMixin.load_lora_weights.pretrained_model_name_or_path_or_dict",description:`<strong>pretrained_model_name_or_path_or_dict</strong> (<code>str</code> or <code>os.PathLike</code> or <code>dict</code>) — | |
| See <a href="/docs/diffusers/pr_9017/en/api/loaders/lora#diffusers.loaders.StableDiffusionLoraLoaderMixin.lora_state_dict">lora_state_dict()</a>.`,name:"pretrained_model_name_or_path_or_dict"},{anchor:"diffusers.loaders.StableDiffusionXLLoraLoaderMixin.load_lora_weights.adapter_name",description:`<strong>adapter_name</strong> (<code>str</code>, <em>optional</em>) — | |
| Adapter name to be used for referencing the loaded adapter model. If not specified, it will use | |
| <code>default_{i}</code> where i is the total number of adapters being loaded.`,name:"adapter_name"},{anchor:"diffusers.loaders.StableDiffusionXLLoraLoaderMixin.load_lora_weights.kwargs",description:`<strong>kwargs</strong> (<code>dict</code>, <em>optional</em>) — | |
| See <a href="/docs/diffusers/pr_9017/en/api/loaders/lora#diffusers.loaders.StableDiffusionLoraLoaderMixin.lora_state_dict">lora_state_dict()</a>.`,name:"kwargs"}],source:"https://github.com/huggingface/diffusers/blob/vr_9017/src/diffusers/loaders/lora_pipeline.py#L511"}}),je=new y({props:{name:"lora_state_dict",anchor:"diffusers.loaders.StableDiffusionXLLoraLoaderMixin.lora_state_dict",parameters:[{name:"pretrained_model_name_or_path_or_dict",val:": Union"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"diffusers.loaders.StableDiffusionXLLoraLoaderMixin.lora_state_dict.pretrained_model_name_or_path_or_dict",description:`<strong>pretrained_model_name_or_path_or_dict</strong> (<code>str</code> or <code>os.PathLike</code> or <code>dict</code>) — | |
| Can be either:</p> | |
| <ul> | |
| <li>A string, the <em>model id</em> (for example <code>google/ddpm-celebahq-256</code>) of a pretrained model hosted on | |
| the Hub.</li> | |
| <li>A path to a <em>directory</em> (for example <code>./my_model_directory</code>) containing the model weights saved | |
| with <a href="/docs/diffusers/pr_9017/en/api/models/overview#diffusers.ModelMixin.save_pretrained">ModelMixin.save_pretrained()</a>.</li> | |
| <li>A <a href="https://pytorch.org/tutorials/beginner/saving_loading_models.html#what-is-a-state-dict" rel="nofollow">torch state | |
| dict</a>.</li> | |
| </ul>`,name:"pretrained_model_name_or_path_or_dict"},{anchor:"diffusers.loaders.StableDiffusionXLLoraLoaderMixin.lora_state_dict.cache_dir",description:`<strong>cache_dir</strong> (<code>Union[str, os.PathLike]</code>, <em>optional</em>) — | |
| Path to a directory where a downloaded pretrained model configuration is cached if the standard cache | |
| is not used.`,name:"cache_dir"},{anchor:"diffusers.loaders.StableDiffusionXLLoraLoaderMixin.lora_state_dict.force_download",description:`<strong>force_download</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) — | |
| 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.loaders.StableDiffusionXLLoraLoaderMixin.lora_state_dict.proxies",description:`<strong>proxies</strong> (<code>Dict[str, str]</code>, <em>optional</em>) — | |
| A dictionary of proxy servers to use by protocol or endpoint, for example, <code>{'http': 'foo.bar:3128', 'http://hostname': 'foo.bar:4012'}</code>. The proxies are used on each request.`,name:"proxies"},{anchor:"diffusers.loaders.StableDiffusionXLLoraLoaderMixin.lora_state_dict.local_files_only",description:`<strong>local_files_only</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) — | |
| Whether to only load local model weights and configuration files or not. If set to <code>True</code>, the model | |
| won’t be downloaded from the Hub.`,name:"local_files_only"},{anchor:"diffusers.loaders.StableDiffusionXLLoraLoaderMixin.lora_state_dict.token",description:`<strong>token</strong> (<code>str</code> or <em>bool</em>, <em>optional</em>) — | |
| The token to use as HTTP bearer authorization for remote files. If <code>True</code>, the token generated from | |
| <code>diffusers-cli login</code> (stored in <code>~/.huggingface</code>) is used.`,name:"token"},{anchor:"diffusers.loaders.StableDiffusionXLLoraLoaderMixin.lora_state_dict.revision",description:`<strong>revision</strong> (<code>str</code>, <em>optional</em>, defaults to <code>"main"</code>) — | |
| The specific model version to use. It can be a branch name, a tag name, a commit id, or any identifier | |
| allowed by Git.`,name:"revision"},{anchor:"diffusers.loaders.StableDiffusionXLLoraLoaderMixin.lora_state_dict.subfolder",description:`<strong>subfolder</strong> (<code>str</code>, <em>optional</em>, defaults to <code>""</code>) — | |
| The subfolder location of a model file within a larger model repository on the Hub or locally.`,name:"subfolder"},{anchor:"diffusers.loaders.StableDiffusionXLLoraLoaderMixin.lora_state_dict.weight_name",description:`<strong>weight_name</strong> (<code>str</code>, <em>optional</em>, defaults to None) — | |
| Name of the serialized state dict file.`,name:"weight_name"}],source:"https://github.com/huggingface/diffusers/blob/vr_9017/src/diffusers/loaders/lora_pipeline.py#L589"}}),fe=new Ce({props:{warning:!0,$$slots:{default:[Nn]},$$scope:{ctx:D}}}),Ve=new y({props:{name:"save_lora_weights",anchor:"diffusers.loaders.StableDiffusionXLLoraLoaderMixin.save_lora_weights",parameters:[{name:"save_directory",val:": Union"},{name:"unet_lora_layers",val:": Dict = None"},{name:"text_encoder_lora_layers",val:": Dict = None"},{name:"text_encoder_2_lora_layers",val:": Dict = None"},{name:"is_main_process",val:": bool = True"},{name:"weight_name",val:": str = None"},{name:"save_function",val:": Callable = None"},{name:"safe_serialization",val:": bool = True"}],parametersDescription:[{anchor:"diffusers.loaders.StableDiffusionXLLoraLoaderMixin.save_lora_weights.save_directory",description:`<strong>save_directory</strong> (<code>str</code> or <code>os.PathLike</code>) — | |
| Directory to save LoRA parameters to. Will be created if it doesn’t exist.`,name:"save_directory"},{anchor:"diffusers.loaders.StableDiffusionXLLoraLoaderMixin.save_lora_weights.unet_lora_layers",description:`<strong>unet_lora_layers</strong> (<code>Dict[str, torch.nn.Module]</code> or <code>Dict[str, torch.Tensor]</code>) — | |
| State dict of the LoRA layers corresponding to the <code>unet</code>.`,name:"unet_lora_layers"},{anchor:"diffusers.loaders.StableDiffusionXLLoraLoaderMixin.save_lora_weights.text_encoder_lora_layers",description:`<strong>text_encoder_lora_layers</strong> (<code>Dict[str, torch.nn.Module]</code> or <code>Dict[str, torch.Tensor]</code>) — | |
| State dict of the LoRA layers corresponding to the <code>text_encoder</code>. Must explicitly pass the text | |
| encoder LoRA state dict because it comes from 🤗 Transformers.`,name:"text_encoder_lora_layers"},{anchor:"diffusers.loaders.StableDiffusionXLLoraLoaderMixin.save_lora_weights.text_encoder_2_lora_layers",description:`<strong>text_encoder_2_lora_layers</strong> (<code>Dict[str, torch.nn.Module]</code> or <code>Dict[str, torch.Tensor]</code>) — | |
| State dict of the LoRA layers corresponding to the <code>text_encoder_2</code>. Must explicitly pass the text | |
| encoder LoRA state dict because it comes from 🤗 Transformers.`,name:"text_encoder_2_lora_layers"},{anchor:"diffusers.loaders.StableDiffusionXLLoraLoaderMixin.save_lora_weights.is_main_process",description:`<strong>is_main_process</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code>) — | |
| Whether the process calling this is the main process or not. Useful during distributed training and you | |
| need to call this function on all processes. In this case, set <code>is_main_process=True</code> only on the main | |
| process to avoid race conditions.`,name:"is_main_process"},{anchor:"diffusers.loaders.StableDiffusionXLLoraLoaderMixin.save_lora_weights.save_function",description:`<strong>save_function</strong> (<code>Callable</code>) — | |
| The function to use to save the state dictionary. Useful during distributed training when you need to | |
| replace <code>torch.save</code> with another method. Can be configured with the environment variable | |
| <code>DIFFUSERS_SAVE_MODE</code>.`,name:"save_function"},{anchor:"diffusers.loaders.StableDiffusionXLLoraLoaderMixin.save_lora_weights.safe_serialization",description:`<strong>safe_serialization</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code>) — | |
| Whether to save the model using <code>safetensors</code> or the traditional PyTorch way with <code>pickle</code>.`,name:"safe_serialization"}],source:"https://github.com/huggingface/diffusers/blob/vr_9017/src/diffusers/loaders/lora_pipeline.py#L855"}}),Je=new Mt({props:{title:"SD3LoraLoaderMixin",local:"diffusers.loaders.SD3LoraLoaderMixin",headingTag:"h2"}}),Ge=new y({props:{name:"class diffusers.loaders.SD3LoraLoaderMixin",anchor:"diffusers.loaders.SD3LoraLoaderMixin",parameters:[],source:"https://github.com/huggingface/diffusers/blob/vr_9017/src/diffusers/loaders/lora_pipeline.py#L981"}}),Ze=new y({props:{name:"load_lora_into_text_encoder",anchor:"diffusers.loaders.SD3LoraLoaderMixin.load_lora_into_text_encoder",parameters:[{name:"state_dict",val:""},{name:"network_alphas",val:""},{name:"text_encoder",val:""},{name:"prefix",val:" = None"},{name:"lora_scale",val:" = 1.0"},{name:"adapter_name",val:" = None"},{name:"_pipeline",val:" = None"}],parametersDescription:[{anchor:"diffusers.loaders.SD3LoraLoaderMixin.load_lora_into_text_encoder.state_dict",description:`<strong>state_dict</strong> (<code>dict</code>) — | |
| A standard state dict containing the lora layer parameters. The key should be prefixed with an | |
| additional <code>text_encoder</code> to distinguish between unet lora layers.`,name:"state_dict"},{anchor:"diffusers.loaders.SD3LoraLoaderMixin.load_lora_into_text_encoder.network_alphas",description:`<strong>network_alphas</strong> (<code>Dict[str, float]</code>) — | |
| See <code>LoRALinearLayer</code> for more details.`,name:"network_alphas"},{anchor:"diffusers.loaders.SD3LoraLoaderMixin.load_lora_into_text_encoder.text_encoder",description:`<strong>text_encoder</strong> (<code>CLIPTextModel</code>) — | |
| The text encoder model to load the LoRA layers into.`,name:"text_encoder"},{anchor:"diffusers.loaders.SD3LoraLoaderMixin.load_lora_into_text_encoder.prefix",description:`<strong>prefix</strong> (<code>str</code>) — | |
| Expected prefix of the <code>text_encoder</code> in the <code>state_dict</code>.`,name:"prefix"},{anchor:"diffusers.loaders.SD3LoraLoaderMixin.load_lora_into_text_encoder.lora_scale",description:`<strong>lora_scale</strong> (<code>float</code>) — | |
| How much to scale the output of the lora linear layer before it is added with the output of the regular | |
| lora layer.`,name:"lora_scale"},{anchor:"diffusers.loaders.SD3LoraLoaderMixin.load_lora_into_text_encoder.adapter_name",description:`<strong>adapter_name</strong> (<code>str</code>, <em>optional</em>) — | |
| Adapter name to be used for referencing the loaded adapter model. If not specified, it will use | |
| <code>default_{i}</code> where i is the total number of adapters being loaded.`,name:"adapter_name"}],source:"https://github.com/huggingface/diffusers/blob/vr_9017/src/diffusers/loaders/lora_pipeline.py#L1232"}}),ze=new y({props:{name:"load_lora_into_transformer",anchor:"diffusers.loaders.SD3LoraLoaderMixin.load_lora_into_transformer",parameters:[{name:"state_dict",val:""},{name:"transformer",val:""},{name:"adapter_name",val:" = None"},{name:"_pipeline",val:" = None"}],parametersDescription:[{anchor:"diffusers.loaders.SD3LoraLoaderMixin.load_lora_into_transformer.state_dict",description:`<strong>state_dict</strong> (<code>dict</code>) — | |
| A standard state dict containing the lora layer parameters. The keys can either be indexed directly | |
| into the unet or prefixed with an additional <code>unet</code> which can be used to distinguish between text | |
| encoder lora layers.`,name:"state_dict"},{anchor:"diffusers.loaders.SD3LoraLoaderMixin.load_lora_into_transformer.transformer",description:`<strong>transformer</strong> (<code>SD3Transformer2DModel</code>) — | |
| The Transformer model to load the LoRA layers into.`,name:"transformer"},{anchor:"diffusers.loaders.SD3LoraLoaderMixin.load_lora_into_transformer.adapter_name",description:`<strong>adapter_name</strong> (<code>str</code>, <em>optional</em>) — | |
| Adapter name to be used for referencing the loaded adapter model. If not specified, it will use | |
| <code>default_{i}</code> where i is the total number of adapters being loaded.`,name:"adapter_name"}],source:"https://github.com/huggingface/diffusers/blob/vr_9017/src/diffusers/loaders/lora_pipeline.py#L1154"}}),Ye=new y({props:{name:"load_lora_weights",anchor:"diffusers.loaders.SD3LoraLoaderMixin.load_lora_weights",parameters:[{name:"pretrained_model_name_or_path_or_dict",val:": Union"},{name:"adapter_name",val:" = None"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"diffusers.loaders.SD3LoraLoaderMixin.load_lora_weights.pretrained_model_name_or_path_or_dict",description:`<strong>pretrained_model_name_or_path_or_dict</strong> (<code>str</code> or <code>os.PathLike</code> or <code>dict</code>) — | |
| See <a href="/docs/diffusers/pr_9017/en/api/loaders/lora#diffusers.loaders.StableDiffusionLoraLoaderMixin.lora_state_dict">lora_state_dict()</a>.`,name:"pretrained_model_name_or_path_or_dict"},{anchor:"diffusers.loaders.SD3LoraLoaderMixin.load_lora_weights.kwargs",description:`<strong>kwargs</strong> (<code>dict</code>, <em>optional</em>) — | |
| See <a href="/docs/diffusers/pr_9017/en/api/loaders/lora#diffusers.loaders.StableDiffusionLoraLoaderMixin.lora_state_dict">lora_state_dict()</a>.`,name:"kwargs"},{anchor:"diffusers.loaders.SD3LoraLoaderMixin.load_lora_weights.adapter_name",description:`<strong>adapter_name</strong> (<code>str</code>, <em>optional</em>) — | |
| Adapter name to be used for referencing the loaded adapter model. If not specified, it will use | |
| <code>default_{i}</code> where i is the total number of adapters being loaded.`,name:"adapter_name"}],source:"https://github.com/huggingface/diffusers/blob/vr_9017/src/diffusers/loaders/lora_pipeline.py#L1085"}}),Qe=new y({props:{name:"lora_state_dict",anchor:"diffusers.loaders.SD3LoraLoaderMixin.lora_state_dict",parameters:[{name:"pretrained_model_name_or_path_or_dict",val:": Union"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"diffusers.loaders.SD3LoraLoaderMixin.lora_state_dict.pretrained_model_name_or_path_or_dict",description:`<strong>pretrained_model_name_or_path_or_dict</strong> (<code>str</code> or <code>os.PathLike</code> or <code>dict</code>) — | |
| Can be either:</p> | |
| <ul> | |
| <li>A string, the <em>model id</em> (for example <code>google/ddpm-celebahq-256</code>) of a pretrained model hosted on | |
| the Hub.</li> | |
| <li>A path to a <em>directory</em> (for example <code>./my_model_directory</code>) containing the model weights saved | |
| with <a href="/docs/diffusers/pr_9017/en/api/models/overview#diffusers.ModelMixin.save_pretrained">ModelMixin.save_pretrained()</a>.</li> | |
| <li>A <a href="https://pytorch.org/tutorials/beginner/saving_loading_models.html#what-is-a-state-dict" rel="nofollow">torch state | |
| dict</a>.</li> | |
| </ul>`,name:"pretrained_model_name_or_path_or_dict"},{anchor:"diffusers.loaders.SD3LoraLoaderMixin.lora_state_dict.cache_dir",description:`<strong>cache_dir</strong> (<code>Union[str, os.PathLike]</code>, <em>optional</em>) — | |
| Path to a directory where a downloaded pretrained model configuration is cached if the standard cache | |
| is not used.`,name:"cache_dir"},{anchor:"diffusers.loaders.SD3LoraLoaderMixin.lora_state_dict.force_download",description:`<strong>force_download</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) — | |
| 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.loaders.SD3LoraLoaderMixin.lora_state_dict.proxies",description:`<strong>proxies</strong> (<code>Dict[str, str]</code>, <em>optional</em>) — | |
| A dictionary of proxy servers to use by protocol or endpoint, for example, <code>{'http': 'foo.bar:3128', 'http://hostname': 'foo.bar:4012'}</code>. The proxies are used on each request.`,name:"proxies"},{anchor:"diffusers.loaders.SD3LoraLoaderMixin.lora_state_dict.local_files_only",description:`<strong>local_files_only</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) — | |
| Whether to only load local model weights and configuration files or not. If set to <code>True</code>, the model | |
| won’t be downloaded from the Hub.`,name:"local_files_only"},{anchor:"diffusers.loaders.SD3LoraLoaderMixin.lora_state_dict.token",description:`<strong>token</strong> (<code>str</code> or <em>bool</em>, <em>optional</em>) — | |
| The token to use as HTTP bearer authorization for remote files. If <code>True</code>, the token generated from | |
| <code>diffusers-cli login</code> (stored in <code>~/.huggingface</code>) is used.`,name:"token"},{anchor:"diffusers.loaders.SD3LoraLoaderMixin.lora_state_dict.revision",description:`<strong>revision</strong> (<code>str</code>, <em>optional</em>, defaults to <code>"main"</code>) — | |
| The specific model version to use. It can be a branch name, a tag name, a commit id, or any identifier | |
| allowed by Git.`,name:"revision"},{anchor:"diffusers.loaders.SD3LoraLoaderMixin.lora_state_dict.subfolder",description:`<strong>subfolder</strong> (<code>str</code>, <em>optional</em>, defaults to <code>""</code>) — | |
| The subfolder location of a model file within a larger model repository on the Hub or locally.`,name:"subfolder"}],source:"https://github.com/huggingface/diffusers/blob/vr_9017/src/diffusers/loaders/lora_pipeline.py#L994"}}),ue=new Ce({props:{warning:!0,$$slots:{default:[Fn]},$$scope:{ctx:D}}}),Oe=new y({props:{name:"save_lora_weights",anchor:"diffusers.loaders.SD3LoraLoaderMixin.save_lora_weights",parameters:[{name:"save_directory",val:": Union"},{name:"transformer_lora_layers",val:": Dict = None"},{name:"text_encoder_lora_layers",val:": Dict = None"},{name:"text_encoder_2_lora_layers",val:": Dict = None"},{name:"is_main_process",val:": bool = True"},{name:"weight_name",val:": str = None"},{name:"save_function",val:": Callable = None"},{name:"safe_serialization",val:": bool = True"}],parametersDescription:[{anchor:"diffusers.loaders.SD3LoraLoaderMixin.save_lora_weights.save_directory",description:`<strong>save_directory</strong> (<code>str</code> or <code>os.PathLike</code>) — | |
| Directory to save LoRA parameters to. Will be created if it doesn’t exist.`,name:"save_directory"},{anchor:"diffusers.loaders.SD3LoraLoaderMixin.save_lora_weights.transformer_lora_layers",description:`<strong>transformer_lora_layers</strong> (<code>Dict[str, torch.nn.Module]</code> or <code>Dict[str, torch.Tensor]</code>) — | |
| State dict of the LoRA layers corresponding to the <code>transformer</code>.`,name:"transformer_lora_layers"},{anchor:"diffusers.loaders.SD3LoraLoaderMixin.save_lora_weights.text_encoder_lora_layers",description:`<strong>text_encoder_lora_layers</strong> (<code>Dict[str, torch.nn.Module]</code> or <code>Dict[str, torch.Tensor]</code>) — | |
| State dict of the LoRA layers corresponding to the <code>text_encoder</code>. Must explicitly pass the text | |
| encoder LoRA state dict because it comes from 🤗 Transformers.`,name:"text_encoder_lora_layers"},{anchor:"diffusers.loaders.SD3LoraLoaderMixin.save_lora_weights.text_encoder_2_lora_layers",description:`<strong>text_encoder_2_lora_layers</strong> (<code>Dict[str, torch.nn.Module]</code> or <code>Dict[str, torch.Tensor]</code>) — | |
| State dict of the LoRA layers corresponding to the <code>text_encoder_2</code>. Must explicitly pass the text | |
| encoder LoRA state dict because it comes from 🤗 Transformers.`,name:"text_encoder_2_lora_layers"},{anchor:"diffusers.loaders.SD3LoraLoaderMixin.save_lora_weights.is_main_process",description:`<strong>is_main_process</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code>) — | |
| Whether the process calling this is the main process or not. Useful during distributed training and you | |
| need to call this function on all processes. In this case, set <code>is_main_process=True</code> only on the main | |
| process to avoid race conditions.`,name:"is_main_process"},{anchor:"diffusers.loaders.SD3LoraLoaderMixin.save_lora_weights.save_function",description:`<strong>save_function</strong> (<code>Callable</code>) — | |
| The function to use to save the state dictionary. Useful during distributed training when you need to | |
| replace <code>torch.save</code> with another method. Can be configured with the environment variable | |
| <code>DIFFUSERS_SAVE_MODE</code>.`,name:"save_function"},{anchor:"diffusers.loaders.SD3LoraLoaderMixin.save_lora_weights.safe_serialization",description:`<strong>safe_serialization</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code>) — | |
| Whether to save the model using <code>safetensors</code> or the traditional PyTorch way with <code>pickle</code>.`,name:"safe_serialization"}],source:"https://github.com/huggingface/diffusers/blob/vr_9017/src/diffusers/loaders/lora_pipeline.py#L1351"}}),Ke=new Mt({props:{title:"AuraFlowLoraLoaderMixin",local:"diffusers.loaders.AuraFlowLoraLoaderMixin",headingTag:"h2"}}),et=new y({props:{name:"class diffusers.loaders.AuraFlowLoraLoaderMixin",anchor:"diffusers.loaders.AuraFlowLoraLoaderMixin",parameters:[],source:"https://github.com/huggingface/diffusers/blob/vr_9017/src/diffusers/loaders/lora_pipeline.py#L1951"}}),tt=new y({props:{name:"load_lora_into_transformer",anchor:"diffusers.loaders.AuraFlowLoraLoaderMixin.load_lora_into_transformer",parameters:[{name:"state_dict",val:""},{name:"transformer",val:""},{name:"adapter_name",val:" = None"},{name:"_pipeline",val:" = None"}],parametersDescription:[{anchor:"diffusers.loaders.AuraFlowLoraLoaderMixin.load_lora_into_transformer.state_dict",description:`<strong>state_dict</strong> (<code>dict</code>) — | |
| A standard state dict containing the lora layer parameters. The keys can either be indexed directly | |
| into the unet or prefixed with an additional <code>unet</code> which can be used to distinguish between text | |
| encoder lora layers.`,name:"state_dict"},{anchor:"diffusers.loaders.AuraFlowLoraLoaderMixin.load_lora_into_transformer.transformer",description:`<strong>transformer</strong> (<code>SD3Transformer2DModel</code>) — | |
| The Transformer model to load the LoRA layers into.`,name:"transformer"},{anchor:"diffusers.loaders.AuraFlowLoraLoaderMixin.load_lora_into_transformer.adapter_name",description:`<strong>adapter_name</strong> (<code>str</code>, <em>optional</em>) — | |
| Adapter name to be used for referencing the loaded adapter model. If not specified, it will use | |
| <code>default_{i}</code> where i is the total number of adapters being loaded.`,name:"adapter_name"}],source:"https://github.com/huggingface/diffusers/blob/vr_9017/src/diffusers/loaders/lora_pipeline.py#L2094"}}),ot=new y({props:{name:"load_lora_weights",anchor:"diffusers.loaders.AuraFlowLoraLoaderMixin.load_lora_weights",parameters:[{name:"pretrained_model_name_or_path_or_dict",val:": Union"},{name:"adapter_name",val:" = None"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"diffusers.loaders.AuraFlowLoraLoaderMixin.load_lora_weights.pretrained_model_name_or_path_or_dict",description:`<strong>pretrained_model_name_or_path_or_dict</strong> (<code>str</code> or <code>os.PathLike</code> or <code>dict</code>) — | |
| See <a href="/docs/diffusers/pr_9017/en/api/loaders/lora#diffusers.loaders.StableDiffusionLoraLoaderMixin.lora_state_dict">lora_state_dict()</a>.`,name:"pretrained_model_name_or_path_or_dict"},{anchor:"diffusers.loaders.AuraFlowLoraLoaderMixin.load_lora_weights.kwargs",description:`<strong>kwargs</strong> (<code>dict</code>, <em>optional</em>) — | |
| See <a href="/docs/diffusers/pr_9017/en/api/loaders/lora#diffusers.loaders.StableDiffusionLoraLoaderMixin.lora_state_dict">lora_state_dict()</a>.`,name:"kwargs"},{anchor:"diffusers.loaders.AuraFlowLoraLoaderMixin.load_lora_weights.adapter_name",description:`<strong>adapter_name</strong> (<code>str</code>, <em>optional</em>) — | |
| Adapter name to be used for referencing the loaded adapter model. If not specified, it will use | |
| <code>default_{i}</code> where i is the total number of adapters being loaded.`,name:"adapter_name"}],source:"https://github.com/huggingface/diffusers/blob/vr_9017/src/diffusers/loaders/lora_pipeline.py#L2050"}}),rt=new y({props:{name:"lora_state_dict",anchor:"diffusers.loaders.AuraFlowLoraLoaderMixin.lora_state_dict",parameters:[{name:"pretrained_model_name_or_path_or_dict",val:": Union"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"diffusers.loaders.AuraFlowLoraLoaderMixin.lora_state_dict.pretrained_model_name_or_path_or_dict",description:`<strong>pretrained_model_name_or_path_or_dict</strong> (<code>str</code> or <code>os.PathLike</code> or <code>dict</code>) — | |
| Can be either:</p> | |
| <ul> | |
| <li>A string, the <em>model id</em> (for example <code>google/ddpm-celebahq-256</code>) of a pretrained model hosted on | |
| the Hub.</li> | |
| <li>A path to a <em>directory</em> (for example <code>./my_model_directory</code>) containing the model weights saved | |
| with <a href="/docs/diffusers/pr_9017/en/api/models/overview#diffusers.ModelMixin.save_pretrained">ModelMixin.save_pretrained()</a>.</li> | |
| <li>A <a href="https://pytorch.org/tutorials/beginner/saving_loading_models.html#what-is-a-state-dict" rel="nofollow">torch state | |
| dict</a>.</li> | |
| </ul>`,name:"pretrained_model_name_or_path_or_dict"},{anchor:"diffusers.loaders.AuraFlowLoraLoaderMixin.lora_state_dict.cache_dir",description:`<strong>cache_dir</strong> (<code>Union[str, os.PathLike]</code>, <em>optional</em>) — | |
| Path to a directory where a downloaded pretrained model configuration is cached if the standard cache | |
| is not used.`,name:"cache_dir"},{anchor:"diffusers.loaders.AuraFlowLoraLoaderMixin.lora_state_dict.force_download",description:`<strong>force_download</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) — | |
| 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.loaders.AuraFlowLoraLoaderMixin.lora_state_dict.proxies",description:`<strong>proxies</strong> (<code>Dict[str, str]</code>, <em>optional</em>) — | |
| A dictionary of proxy servers to use by protocol or endpoint, for example, <code>{'http': 'foo.bar:3128', 'http://hostname': 'foo.bar:4012'}</code>. The proxies are used on each request.`,name:"proxies"},{anchor:"diffusers.loaders.AuraFlowLoraLoaderMixin.lora_state_dict.local_files_only",description:`<strong>local_files_only</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) — | |
| Whether to only load local model weights and configuration files or not. If set to <code>True</code>, the model | |
| won’t be downloaded from the Hub.`,name:"local_files_only"},{anchor:"diffusers.loaders.AuraFlowLoraLoaderMixin.lora_state_dict.token",description:`<strong>token</strong> (<code>str</code> or <em>bool</em>, <em>optional</em>) — | |
| The token to use as HTTP bearer authorization for remote files. If <code>True</code>, the token generated from | |
| <code>diffusers-cli login</code> (stored in <code>~/.huggingface</code>) is used.`,name:"token"},{anchor:"diffusers.loaders.AuraFlowLoraLoaderMixin.lora_state_dict.revision",description:`<strong>revision</strong> (<code>str</code>, <em>optional</em>, defaults to <code>"main"</code>) — | |
| The specific model version to use. It can be a branch name, a tag name, a commit id, or any identifier | |
| allowed by Git.`,name:"revision"},{anchor:"diffusers.loaders.AuraFlowLoraLoaderMixin.lora_state_dict.subfolder",description:`<strong>subfolder</strong> (<code>str</code>, <em>optional</em>, defaults to <code>""</code>) — | |
| The subfolder location of a model file within a larger model repository on the Hub or locally.`,name:"subfolder"}],source:"https://github.com/huggingface/diffusers/blob/vr_9017/src/diffusers/loaders/lora_pipeline.py#L1960"}}),xe=new Ce({props:{warning:!0,$$slots:{default:[Wn]},$$scope:{ctx:D}}}),at=new y({props:{name:"save_lora_weights",anchor:"diffusers.loaders.AuraFlowLoraLoaderMixin.save_lora_weights",parameters:[{name:"save_directory",val:": Union"},{name:"transformer_lora_layers",val:": Dict = None"},{name:"is_main_process",val:": bool = True"},{name:"weight_name",val:": str = None"},{name:"save_function",val:": Callable = None"},{name:"safe_serialization",val:": bool = True"}],parametersDescription:[{anchor:"diffusers.loaders.AuraFlowLoraLoaderMixin.save_lora_weights.save_directory",description:`<strong>save_directory</strong> (<code>str</code> or <code>os.PathLike</code>) — | |
| Directory to save LoRA parameters to. Will be created if it doesn’t exist.`,name:"save_directory"},{anchor:"diffusers.loaders.AuraFlowLoraLoaderMixin.save_lora_weights.transformer_lora_layers",description:`<strong>transformer_lora_layers</strong> (<code>Dict[str, torch.nn.Module]</code> or <code>Dict[str, torch.Tensor]</code>) — | |
| State dict of the LoRA layers corresponding to the <code>transformer</code>.`,name:"transformer_lora_layers"},{anchor:"diffusers.loaders.AuraFlowLoraLoaderMixin.save_lora_weights.is_main_process",description:`<strong>is_main_process</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code>) — | |
| Whether the process calling this is the main process or not. Useful during distributed training and you | |
| need to call this function on all processes. In this case, set <code>is_main_process=True</code> only on the main | |
| process to avoid race conditions.`,name:"is_main_process"},{anchor:"diffusers.loaders.AuraFlowLoraLoaderMixin.save_lora_weights.save_function",description:`<strong>save_function</strong> (<code>Callable</code>) — | |
| The function to use to save the state dictionary. Useful during distributed training when you need to | |
| replace <code>torch.save</code> with another method. Can be configured with the environment variable | |
| <code>DIFFUSERS_SAVE_MODE</code>.`,name:"save_function"},{anchor:"diffusers.loaders.AuraFlowLoraLoaderMixin.save_lora_weights.safe_serialization",description:`<strong>safe_serialization</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code>) — | |
| Whether to save the model using <code>safetensors</code> or the traditional PyTorch way with <code>pickle</code>.`,name:"safe_serialization"}],source:"https://github.com/huggingface/diffusers/blob/vr_9017/src/diffusers/loaders/lora_pipeline.py#L2173"}}),nt=new y({props:{name:"unfuse_lora",anchor:"diffusers.loaders.AuraFlowLoraLoaderMixin.unfuse_lora",parameters:[{name:"components",val:": List = ['transformer']"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"diffusers.loaders.AuraFlowLoraLoaderMixin.unfuse_lora.components",description:"<strong>components</strong> (<code>List[str]</code>) — List of LoRA-injectable components to unfuse LoRA from.",name:"components"}],source:"https://github.com/huggingface/diffusers/blob/vr_9017/src/diffusers/loaders/lora_pipeline.py#L2265"}}),be=new Ce({props:{warning:!0,$$slots:{default:[Xn]},$$scope:{ctx:D}}}),st=new Mt({props:{title:"AmusedLoraLoaderMixin",local:"diffusers.loaders.AmusedLoraLoaderMixin",headingTag:"h2"}}),it=new y({props:{name:"class diffusers.loaders.AmusedLoraLoaderMixin",anchor:"diffusers.loaders.AmusedLoraLoaderMixin",parameters:[],source:"https://github.com/huggingface/diffusers/blob/vr_9017/src/diffusers/loaders/lora_pipeline.py#L2284"}}),dt=new y({props:{name:"load_lora_into_transformer",anchor:"diffusers.loaders.AmusedLoraLoaderMixin.load_lora_into_transformer",parameters:[{name:"state_dict",val:""},{name:"network_alphas",val:""},{name:"transformer",val:""},{name:"adapter_name",val:" = None"},{name:"_pipeline",val:" = None"}],parametersDescription:[{anchor:"diffusers.loaders.AmusedLoraLoaderMixin.load_lora_into_transformer.state_dict",description:`<strong>state_dict</strong> (<code>dict</code>) — | |
| A standard state dict containing the lora layer parameters. The keys can either be indexed directly | |
| into the unet or prefixed with an additional <code>unet</code> which can be used to distinguish between text | |
| encoder lora layers.`,name:"state_dict"},{anchor:"diffusers.loaders.AmusedLoraLoaderMixin.load_lora_into_transformer.network_alphas",description:`<strong>network_alphas</strong> (<code>Dict[str, float]</code>) — | |
| See <code>LoRALinearLayer</code> for more details.`,name:"network_alphas"},{anchor:"diffusers.loaders.AmusedLoraLoaderMixin.load_lora_into_transformer.unet",description:`<strong>unet</strong> (<code>UNet2DConditionModel</code>) — | |
| The UNet model to load the LoRA layers into.`,name:"unet"},{anchor:"diffusers.loaders.AmusedLoraLoaderMixin.load_lora_into_transformer.adapter_name",description:`<strong>adapter_name</strong> (<code>str</code>, <em>optional</em>) — | |
| Adapter name to be used for referencing the loaded adapter model. If not specified, it will use | |
| <code>default_{i}</code> where i is the total number of adapters being loaded.`,name:"adapter_name"}],source:"https://github.com/huggingface/diffusers/blob/vr_9017/src/diffusers/loaders/lora_pipeline.py#L2289"}}),lt=new Mt({props:{title:"LoraBaseMixin",local:"diffusers.loaders.lora_base.LoraBaseMixin",headingTag:"h2"}}),ct=new y({props:{name:"class diffusers.loaders.lora_base.LoraBaseMixin",anchor:"diffusers.loaders.lora_base.LoraBaseMixin",parameters:[],source:"https://github.com/huggingface/diffusers/blob/vr_9017/src/diffusers/loaders/lora_base.py#L184"}}),ft=new y({props:{name:"delete_adapters",anchor:"diffusers.loaders.lora_base.LoraBaseMixin.delete_adapters",parameters:[{name:"adapter_names",val:": Union"}],parametersDescription:[{anchor:"diffusers.loaders.lora_base.LoraBaseMixin.delete_adapters.Deletes",description:`<strong>Deletes</strong> the LoRA layers of <code>adapter_name</code> for the unet and text-encoder(s). — | |
| adapter_names (<code>Union[List[str], str]</code>): | |
| The names of the adapter to delete. Can be a single string or a list of strings`,name:"Deletes"}],source:"https://github.com/huggingface/diffusers/blob/vr_9017/src/diffusers/loaders/lora_base.py#L601"}}),pt=new y({props:{name:"fuse_lora",anchor:"diffusers.loaders.lora_base.LoraBaseMixin.fuse_lora",parameters:[{name:"components",val:": List = []"},{name:"lora_scale",val:": float = 1.0"},{name:"safe_fusing",val:": bool = False"},{name:"adapter_names",val:": Optional = None"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"diffusers.loaders.lora_base.LoraBaseMixin.fuse_lora.lora_scale",description:`<strong>lora_scale</strong> (<code>float</code>, defaults to 1.0) — | |
| Controls how much to influence the outputs with the LoRA parameters.`,name:"lora_scale"},{anchor:"diffusers.loaders.lora_base.LoraBaseMixin.fuse_lora.safe_fusing",description:`<strong>safe_fusing</strong> (<code>bool</code>, defaults to <code>False</code>) — | |
| Whether to check fused weights for NaN values before fusing and if values are NaN not fusing them.`,name:"safe_fusing"},{anchor:"diffusers.loaders.lora_base.LoraBaseMixin.fuse_lora.adapter_names",description:`<strong>adapter_names</strong> (<code>List[str]</code>, <em>optional</em>) — | |
| Adapter names to be used for fusing. If nothing is passed, all active adapters will be fused.`,name:"adapter_names"}],source:"https://github.com/huggingface/diffusers/blob/vr_9017/src/diffusers/loaders/lora_base.py#L379"}}),$e=new Ce({props:{warning:!0,$$slots:{default:[Bn]},$$scope:{ctx:D}}}),we=new ka({props:{anchor:"diffusers.loaders.lora_base.LoraBaseMixin.fuse_lora.example",$$slots:{default:[qn]},$$scope:{ctx:D}}}),_t=new y({props:{name:"get_active_adapters",anchor:"diffusers.loaders.lora_base.LoraBaseMixin.get_active_adapters",parameters:[],source:"https://github.com/huggingface/diffusers/blob/vr_9017/src/diffusers/loaders/lora_base.py#L623"}}),Me=new ka({props:{anchor:"diffusers.loaders.lora_base.LoraBaseMixin.get_active_adapters.example",$$slots:{default:[jn]},$$scope:{ctx:D}}}),mt=new y({props:{name:"get_list_adapters",anchor:"diffusers.loaders.lora_base.LoraBaseMixin.get_list_adapters",parameters:[],source:"https://github.com/huggingface/diffusers/blob/vr_9017/src/diffusers/loaders/lora_base.py#L656"}}),ut=new y({props:{name:"set_lora_device",anchor:"diffusers.loaders.lora_base.LoraBaseMixin.set_lora_device",parameters:[{name:"adapter_names",val:": List"},{name:"device",val:": Union"}],parametersDescription:[{anchor:"diffusers.loaders.lora_base.LoraBaseMixin.set_lora_device.adapter_names",description:`<strong>adapter_names</strong> (<code>List[str]</code>) — | |
| List of adapters to send device to.`,name:"adapter_names"},{anchor:"diffusers.loaders.lora_base.LoraBaseMixin.set_lora_device.device",description:`<strong>device</strong> (<code>Union[torch.device, str, int]</code>) — | |
| Device to send the adapters to. Can be either a torch device, a str or an integer.`,name:"device"}],source:"https://github.com/huggingface/diffusers/blob/vr_9017/src/diffusers/loaders/lora_base.py#L678"}}),ht=new y({props:{name:"unfuse_lora",anchor:"diffusers.loaders.lora_base.LoraBaseMixin.unfuse_lora",parameters:[{name:"components",val:": List = []"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"diffusers.loaders.lora_base.LoraBaseMixin.unfuse_lora.components",description:"<strong>components</strong> (<code>List[str]</code>) — List of LoRA-injectable components to unfuse LoRA from.",name:"components"},{anchor:"diffusers.loaders.lora_base.LoraBaseMixin.unfuse_lora.unfuse_unet",description:"<strong>unfuse_unet</strong> (<code>bool</code>, defaults to <code>True</code>) — Whether to unfuse the UNet LoRA parameters.",name:"unfuse_unet"},{anchor:"diffusers.loaders.lora_base.LoraBaseMixin.unfuse_lora.unfuse_text_encoder",description:`<strong>unfuse_text_encoder</strong> (<code>bool</code>, defaults to <code>True</code>) — | |
| Whether to unfuse the text encoder LoRA parameters. If the text encoder wasn’t monkey-patched with the | |
| LoRA parameters then it won’t have any effect.`,name:"unfuse_text_encoder"}],source:"https://github.com/huggingface/diffusers/blob/vr_9017/src/diffusers/loaders/lora_base.py#L460"}}),Te=new Ce({props:{warning:!0,$$slots:{default:[Vn]},$$scope:{ctx:D}}}),gt=new y({props:{name:"unload_lora_weights",anchor:"diffusers.loaders.lora_base.LoraBaseMixin.unload_lora_weights",parameters:[],source:"https://github.com/huggingface/diffusers/blob/vr_9017/src/diffusers/loaders/lora_base.py#L356"}}),Se=new ka({props:{anchor:"diffusers.loaders.lora_base.LoraBaseMixin.unload_lora_weights.example",$$slots:{default:[Jn]},$$scope:{ctx:D}}}),xt=new Hn({props:{source:"https://github.com/huggingface/diffusers/blob/main/docs/source/en/api/loaders/lora.md"}}),{c(){s=a("meta"),b=o(),c=a("p"),l=o(),_(M.$$.fragment),i=o(),w=a("p"),w.innerHTML=Ra,To=o(),ke=a("ul"),ke.innerHTML=Ia,So=o(),_(ae.$$.fragment),Ao=o(),_(Pe.$$.fragment),Co=o(),A=a("div"),_(Re.$$.fragment),er=o(),yt=a("p"),yt.innerHTML=Ha,tr=o(),ne=a("div"),_(Ie.$$.fragment),or=o(),Dt=a("p"),Dt.innerHTML=Ua,rr=o(),se=a("div"),_(He.$$.fragment),ar=o(),Tt=a("p"),Tt.innerHTML=Ea,nr=o(),H=a("div"),_(Ue.$$.fragment),sr=o(),St=a("p"),St.innerHTML=Na,ir=o(),At=a("p"),At.innerHTML=Fa,dr=o(),Ct=a("p"),Ct.innerHTML=Wa,lr=o(),kt=a("p"),kt.innerHTML=Xa,cr=o(),Pt=a("p"),Pt.innerHTML=Ba,fr=o(),V=a("div"),_(Ee.$$.fragment),pr=o(),Rt=a("p"),Rt.textContent=qa,_r=o(),_(ie.$$.fragment),mr=o(),de=a("div"),_(Ne.$$.fragment),ur=o(),It=a("p"),It.textContent=ja,ko=o(),_(Fe.$$.fragment),Po=o(),C=a("div"),_(We.$$.fragment),hr=o(),Ht=a("p"),Ht.innerHTML=Va,gr=o(),le=a("div"),_(Xe.$$.fragment),xr=o(),Ut=a("p"),Ut.innerHTML=Ja,Lr=o(),ce=a("div"),_(Be.$$.fragment),br=o(),Et=a("p"),Et.innerHTML=Ga,vr=o(),U=a("div"),_(qe.$$.fragment),$r=o(),Nt=a("p"),Nt.innerHTML=Za,wr=o(),Ft=a("p"),Ft.innerHTML=za,Mr=o(),Wt=a("p"),Wt.innerHTML=Ya,yr=o(),Xt=a("p"),Xt.innerHTML=Qa,Dr=o(),Bt=a("p"),Bt.innerHTML=Oa,Tr=o(),J=a("div"),_(je.$$.fragment),Sr=o(),qt=a("p"),qt.textContent=Ka,Ar=o(),_(fe.$$.fragment),Cr=o(),pe=a("div"),_(Ve.$$.fragment),kr=o(),jt=a("p"),jt.textContent=en,Ro=o(),_(Je.$$.fragment),Io=o(),S=a("div"),_(Ge.$$.fragment),Pr=o(),Vt=a("p"),Vt.innerHTML=tn,Rr=o(),Jt=a("p"),Jt.innerHTML=on,Ir=o(),_e=a("div"),_(Ze.$$.fragment),Hr=o(),Gt=a("p"),Gt.innerHTML=rn,Ur=o(),me=a("div"),_(ze.$$.fragment),Er=o(),Zt=a("p"),Zt.innerHTML=an,Nr=o(),W=a("div"),_(Ye.$$.fragment),Fr=o(),zt=a("p"),zt.innerHTML=nn,Wr=o(),Yt=a("p"),Yt.innerHTML=sn,Xr=o(),Qt=a("p"),Qt.innerHTML=dn,Br=o(),Ot=a("p"),Ot.innerHTML=ln,qr=o(),G=a("div"),_(Qe.$$.fragment),jr=o(),Kt=a("p"),Kt.textContent=cn,Vr=o(),_(ue.$$.fragment),Jr=o(),he=a("div"),_(Oe.$$.fragment),Gr=o(),eo=a("p"),eo.textContent=fn,Ho=o(),_(Ke.$$.fragment),Uo=o(),k=a("div"),_(et.$$.fragment),Zr=o(),to=a("p"),to.innerHTML=pn,zr=o(),ge=a("div"),_(tt.$$.fragment),Yr=o(),oo=a("p"),oo.innerHTML=_n,Qr=o(),X=a("div"),_(ot.$$.fragment),Or=o(),ro=a("p"),ro.innerHTML=mn,Kr=o(),ao=a("p"),ao.innerHTML=un,ea=o(),no=a("p"),no.innerHTML=hn,ta=o(),so=a("p"),so.innerHTML=gn,oa=o(),Z=a("div"),_(rt.$$.fragment),ra=o(),io=a("p"),io.textContent=xn,aa=o(),_(xe.$$.fragment),na=o(),Le=a("div"),_(at.$$.fragment),sa=o(),lo=a("p"),lo.textContent=Ln,ia=o(),z=a("div"),_(nt.$$.fragment),da=o(),co=a("p"),co.innerHTML=bn,la=o(),_(be.$$.fragment),Eo=o(),_(st.$$.fragment),No=o(),te=a("div"),_(it.$$.fragment),ca=o(),ve=a("div"),_(dt.$$.fragment),fa=o(),fo=a("p"),fo.innerHTML=vn,Fo=o(),_(lt.$$.fragment),Wo=o(),T=a("div"),_(ct.$$.fragment),pa=o(),po=a("p"),po.textContent=$n,_a=o(),_o=a("div"),_(ft.$$.fragment),ma=o(),q=a("div"),_(pt.$$.fragment),ua=o(),mo=a("p"),mo.textContent=wn,ha=o(),_($e.$$.fragment),ga=o(),_(we.$$.fragment),xa=o(),Y=a("div"),_(_t.$$.fragment),La=o(),uo=a("p"),uo.textContent=Mn,ba=o(),_(Me.$$.fragment),va=o(),ye=a("div"),_(mt.$$.fragment),$a=o(),ho=a("p"),ho.textContent=yn,wa=o(),De=a("div"),_(ut.$$.fragment),Ma=o(),go=a("p"),go.innerHTML=Dn,ya=o(),Q=a("div"),_(ht.$$.fragment),Da=o(),xo=a("p"),xo.innerHTML=Tn,Ta=o(),_(Te.$$.fragment),Sa=o(),O=a("div"),_(gt.$$.fragment),Aa=o(),Lo=a("p"),Lo.textContent=Sn,Ca=o(),_(Se.$$.fragment),Xo=o(),_(xt.$$.fragment),Bo=o(),Do=a("p"),this.h()},l(e){const f=In("svelte-u9bgzb",document.head);s=n(f,"META",{name:!0,content:!0}),f.forEach(d),b=r(e),c=n(e,"P",{}),v(c).forEach(d),l=r(e),m(M.$$.fragment,e),i=r(e),w=n(e,"P",{"data-svelte-h":!0}),p(w)!=="svelte-1x18tj"&&(w.innerHTML=Ra),To=r(e),ke=n(e,"UL",{"data-svelte-h":!0}),p(ke)!=="svelte-cs7i9a"&&(ke.innerHTML=Ia),So=r(e),m(ae.$$.fragment,e),Ao=r(e),m(Pe.$$.fragment,e),Co=r(e),A=n(e,"DIV",{class:!0});var R=v(A);m(Re.$$.fragment,R),er=r(R),yt=n(R,"P",{"data-svelte-h":!0}),p(yt)!=="svelte-1rbrgig"&&(yt.innerHTML=Ha),tr=r(R),ne=n(R,"DIV",{class:!0});var Lt=v(ne);m(Ie.$$.fragment,Lt),or=r(Lt),Dt=n(Lt,"P",{"data-svelte-h":!0}),p(Dt)!=="svelte-1062ci4"&&(Dt.innerHTML=Ua),Lt.forEach(d),rr=r(R),se=n(R,"DIV",{class:!0});var bt=v(se);m(He.$$.fragment,bt),ar=r(bt),Tt=n(bt,"P",{"data-svelte-h":!0}),p(Tt)!=="svelte-u3q4so"&&(Tt.innerHTML=Ea),bt.forEach(d),nr=r(R),H=n(R,"DIV",{class:!0});var N=v(H);m(Ue.$$.fragment,N),sr=r(N),St=n(N,"P",{"data-svelte-h":!0}),p(St)!=="svelte-vs7s0z"&&(St.innerHTML=Na),ir=r(N),At=n(N,"P",{"data-svelte-h":!0}),p(At)!=="svelte-15b960v"&&(At.innerHTML=Fa),dr=r(N),Ct=n(N,"P",{"data-svelte-h":!0}),p(Ct)!=="svelte-1h6d7r9"&&(Ct.innerHTML=Wa),lr=r(N),kt=n(N,"P",{"data-svelte-h":!0}),p(kt)!=="svelte-17zsu44"&&(kt.innerHTML=Xa),cr=r(N),Pt=n(N,"P",{"data-svelte-h":!0}),p(Pt)!=="svelte-1tt2ju2"&&(Pt.innerHTML=Ba),N.forEach(d),fr=r(R),V=n(R,"DIV",{class:!0});var oe=v(V);m(Ee.$$.fragment,oe),pr=r(oe),Rt=n(oe,"P",{"data-svelte-h":!0}),p(Rt)!=="svelte-flusvq"&&(Rt.textContent=qa),_r=r(oe),m(ie.$$.fragment,oe),oe.forEach(d),mr=r(R),de=n(R,"DIV",{class:!0});var vt=v(de);m(Ne.$$.fragment,vt),ur=r(vt),It=n(vt,"P",{"data-svelte-h":!0}),p(It)!=="svelte-1ufq5ot"&&(It.textContent=ja),vt.forEach(d),R.forEach(d),ko=r(e),m(Fe.$$.fragment,e),Po=r(e),C=n(e,"DIV",{class:!0});var I=v(C);m(We.$$.fragment,I),hr=r(I),Ht=n(I,"P",{"data-svelte-h":!0}),p(Ht)!=="svelte-1g8dlhj"&&(Ht.innerHTML=Va),gr=r(I),le=n(I,"DIV",{class:!0});var $t=v(le);m(Xe.$$.fragment,$t),xr=r($t),Ut=n($t,"P",{"data-svelte-h":!0}),p(Ut)!=="svelte-1062ci4"&&(Ut.innerHTML=Ja),$t.forEach(d),Lr=r(I),ce=n(I,"DIV",{class:!0});var wt=v(ce);m(Be.$$.fragment,wt),br=r(wt),Et=n(wt,"P",{"data-svelte-h":!0}),p(Et)!=="svelte-u3q4so"&&(Et.innerHTML=Ga),wt.forEach(d),vr=r(I),U=n(I,"DIV",{class:!0});var F=v(U);m(qe.$$.fragment,F),$r=r(F),Nt=n(F,"P",{"data-svelte-h":!0}),p(Nt)!=="svelte-vs7s0z"&&(Nt.innerHTML=Za),wr=r(F),Ft=n(F,"P",{"data-svelte-h":!0}),p(Ft)!=="svelte-15b960v"&&(Ft.innerHTML=za),Mr=r(F),Wt=n(F,"P",{"data-svelte-h":!0}),p(Wt)!=="svelte-1h6d7r9"&&(Wt.innerHTML=Ya),yr=r(F),Xt=n(F,"P",{"data-svelte-h":!0}),p(Xt)!=="svelte-17zsu44"&&(Xt.innerHTML=Qa),Dr=r(F),Bt=n(F,"P",{"data-svelte-h":!0}),p(Bt)!=="svelte-1tt2ju2"&&(Bt.innerHTML=Oa),F.forEach(d),Tr=r(I),J=n(I,"DIV",{class:!0});var re=v(J);m(je.$$.fragment,re),Sr=r(re),qt=n(re,"P",{"data-svelte-h":!0}),p(qt)!=="svelte-flusvq"&&(qt.textContent=Ka),Ar=r(re),m(fe.$$.fragment,re),re.forEach(d),Cr=r(I),pe=n(I,"DIV",{class:!0});var jo=v(pe);m(Ve.$$.fragment,jo),kr=r(jo),jt=n(jo,"P",{"data-svelte-h":!0}),p(jt)!=="svelte-1ufq5ot"&&(jt.textContent=en),jo.forEach(d),I.forEach(d),Ro=r(e),m(Je.$$.fragment,e),Io=r(e),S=n(e,"DIV",{class:!0});var E=v(S);m(Ge.$$.fragment,E),Pr=r(E),Vt=n(E,"P",{"data-svelte-h":!0}),p(Vt)!=="svelte-lrfrwk"&&(Vt.innerHTML=tn),Rr=r(E),Jt=n(E,"P",{"data-svelte-h":!0}),p(Jt)!=="svelte-mb8jw0"&&(Jt.innerHTML=on),Ir=r(E),_e=n(E,"DIV",{class:!0});var Vo=v(_e);m(Ze.$$.fragment,Vo),Hr=r(Vo),Gt=n(Vo,"P",{"data-svelte-h":!0}),p(Gt)!=="svelte-1062ci4"&&(Gt.innerHTML=rn),Vo.forEach(d),Ur=r(E),me=n(E,"DIV",{class:!0});var Jo=v(me);m(ze.$$.fragment,Jo),Er=r(Jo),Zt=n(Jo,"P",{"data-svelte-h":!0}),p(Zt)!=="svelte-1lgbsz7"&&(Zt.innerHTML=an),Jo.forEach(d),Nr=r(E),W=n(E,"DIV",{class:!0});var K=v(W);m(Ye.$$.fragment,K),Fr=r(K),zt=n(K,"P",{"data-svelte-h":!0}),p(zt)!=="svelte-vs7s0z"&&(zt.innerHTML=nn),Wr=r(K),Yt=n(K,"P",{"data-svelte-h":!0}),p(Yt)!=="svelte-15b960v"&&(Yt.innerHTML=sn),Xr=r(K),Qt=n(K,"P",{"data-svelte-h":!0}),p(Qt)!=="svelte-1h6d7r9"&&(Qt.innerHTML=dn),Br=r(K),Ot=n(K,"P",{"data-svelte-h":!0}),p(Ot)!=="svelte-1ukghd4"&&(Ot.innerHTML=ln),K.forEach(d),qr=r(E),G=n(E,"DIV",{class:!0});var bo=v(G);m(Qe.$$.fragment,bo),jr=r(bo),Kt=n(bo,"P",{"data-svelte-h":!0}),p(Kt)!=="svelte-flusvq"&&(Kt.textContent=cn),Vr=r(bo),m(ue.$$.fragment,bo),bo.forEach(d),Jr=r(E),he=n(E,"DIV",{class:!0});var Go=v(he);m(Oe.$$.fragment,Go),Gr=r(Go),eo=n(Go,"P",{"data-svelte-h":!0}),p(eo)!=="svelte-1ufq5ot"&&(eo.textContent=fn),Go.forEach(d),E.forEach(d),Ho=r(e),m(Ke.$$.fragment,e),Uo=r(e),k=n(e,"DIV",{class:!0});var B=v(k);m(et.$$.fragment,B),Zr=r(B),to=n(B,"P",{"data-svelte-h":!0}),p(to)!=="svelte-1dk9use"&&(to.innerHTML=pn),zr=r(B),ge=n(B,"DIV",{class:!0});var Zo=v(ge);m(tt.$$.fragment,Zo),Yr=r(Zo),oo=n(Zo,"P",{"data-svelte-h":!0}),p(oo)!=="svelte-1lgbsz7"&&(oo.innerHTML=_n),Zo.forEach(d),Qr=r(B),X=n(B,"DIV",{class:!0});var ee=v(X);m(ot.$$.fragment,ee),Or=r(ee),ro=n(ee,"P",{"data-svelte-h":!0}),p(ro)!=="svelte-10qctye"&&(ro.innerHTML=mn),Kr=r(ee),ao=n(ee,"P",{"data-svelte-h":!0}),p(ao)!=="svelte-15b960v"&&(ao.innerHTML=un),ea=r(ee),no=n(ee,"P",{"data-svelte-h":!0}),p(no)!=="svelte-1h6d7r9"&&(no.innerHTML=hn),ta=r(ee),so=n(ee,"P",{"data-svelte-h":!0}),p(so)!=="svelte-1ukghd4"&&(so.innerHTML=gn),ee.forEach(d),oa=r(B),Z=n(B,"DIV",{class:!0});var vo=v(Z);m(rt.$$.fragment,vo),ra=r(vo),io=n(vo,"P",{"data-svelte-h":!0}),p(io)!=="svelte-flusvq"&&(io.textContent=xn),aa=r(vo),m(xe.$$.fragment,vo),vo.forEach(d),na=r(B),Le=n(B,"DIV",{class:!0});var zo=v(Le);m(at.$$.fragment,zo),sa=r(zo),lo=n(zo,"P",{"data-svelte-h":!0}),p(lo)!=="svelte-1ufq5ot"&&(lo.textContent=Ln),zo.forEach(d),ia=r(B),z=n(B,"DIV",{class:!0});var $o=v(z);m(nt.$$.fragment,$o),da=r($o),co=n($o,"P",{"data-svelte-h":!0}),p(co)!=="svelte-ioswce"&&(co.innerHTML=bn),la=r($o),m(be.$$.fragment,$o),$o.forEach(d),B.forEach(d),Eo=r(e),m(st.$$.fragment,e),No=r(e),te=n(e,"DIV",{class:!0});var Yo=v(te);m(it.$$.fragment,Yo),ca=r(Yo),ve=n(Yo,"DIV",{class:!0});var Qo=v(ve);m(dt.$$.fragment,Qo),fa=r(Qo),fo=n(Qo,"P",{"data-svelte-h":!0}),p(fo)!=="svelte-1lgbsz7"&&(fo.innerHTML=vn),Qo.forEach(d),Yo.forEach(d),Fo=r(e),m(lt.$$.fragment,e),Wo=r(e),T=n(e,"DIV",{class:!0});var P=v(T);m(ct.$$.fragment,P),pa=r(P),po=n(P,"P",{"data-svelte-h":!0}),p(po)!=="svelte-1q4bbx"&&(po.textContent=$n),_a=r(P),_o=n(P,"DIV",{class:!0});var An=v(_o);m(ft.$$.fragment,An),An.forEach(d),ma=r(P),q=n(P,"DIV",{class:!0});var Ae=v(q);m(pt.$$.fragment,Ae),ua=r(Ae),mo=n(Ae,"P",{"data-svelte-h":!0}),p(mo)!=="svelte-1nr2dy0"&&(mo.textContent=wn),ha=r(Ae),m($e.$$.fragment,Ae),ga=r(Ae),m(we.$$.fragment,Ae),Ae.forEach(d),xa=r(P),Y=n(P,"DIV",{class:!0});var wo=v(Y);m(_t.$$.fragment,wo),La=r(wo),uo=n(wo,"P",{"data-svelte-h":!0}),p(uo)!=="svelte-h0os0v"&&(uo.textContent=Mn),ba=r(wo),m(Me.$$.fragment,wo),wo.forEach(d),va=r(P),ye=n(P,"DIV",{class:!0});var Oo=v(ye);m(mt.$$.fragment,Oo),$a=r(Oo),ho=n(Oo,"P",{"data-svelte-h":!0}),p(ho)!=="svelte-1825k9e"&&(ho.textContent=yn),Oo.forEach(d),wa=r(P),De=n(P,"DIV",{class:!0});var Ko=v(De);m(ut.$$.fragment,Ko),Ma=r(Ko),go=n(Ko,"P",{"data-svelte-h":!0}),p(go)!=="svelte-rvubqa"&&(go.innerHTML=Dn),Ko.forEach(d),ya=r(P),Q=n(P,"DIV",{class:!0});var Mo=v(Q);m(ht.$$.fragment,Mo),Da=r(Mo),xo=n(Mo,"P",{"data-svelte-h":!0}),p(xo)!=="svelte-ioswce"&&(xo.innerHTML=Tn),Ta=r(Mo),m(Te.$$.fragment,Mo),Mo.forEach(d),Sa=r(P),O=n(P,"DIV",{class:!0});var yo=v(O);m(gt.$$.fragment,yo),Aa=r(yo),Lo=n(yo,"P",{"data-svelte-h":!0}),p(Lo)!=="svelte-119cgd9"&&(Lo.textContent=Sn),Ca=r(yo),m(Se.$$.fragment,yo),yo.forEach(d),P.forEach(d),Xo=r(e),m(xt.$$.fragment,e),Bo=r(e),Do=n(e,"P",{}),v(Do).forEach(d),this.h()},h(){$(s,"name","hf:doc:metadata"),$(s,"content",Zn),$(ne,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(se,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(H,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(V,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(de,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(A,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(le,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(ce,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(U,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(J,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(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,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(_e,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(me,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(W,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(G,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(he,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(S,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(ge,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(X,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(Z,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(Le,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(z,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(k,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(ve,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(te,"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"),$(q,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(Y,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(ye,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(De,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),$(Q,"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"),$(T,"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,f){t(document.head,s),L(e,b,f),L(e,c,f),L(e,l,f),u(M,e,f),L(e,i,f),L(e,w,f),L(e,To,f),L(e,ke,f),L(e,So,f),u(ae,e,f),L(e,Ao,f),u(Pe,e,f),L(e,Co,f),L(e,A,f),u(Re,A,null),t(A,er),t(A,yt),t(A,tr),t(A,ne),u(Ie,ne,null),t(ne,or),t(ne,Dt),t(A,rr),t(A,se),u(He,se,null),t(se,ar),t(se,Tt),t(A,nr),t(A,H),u(Ue,H,null),t(H,sr),t(H,St),t(H,ir),t(H,At),t(H,dr),t(H,Ct),t(H,lr),t(H,kt),t(H,cr),t(H,Pt),t(A,fr),t(A,V),u(Ee,V,null),t(V,pr),t(V,Rt),t(V,_r),u(ie,V,null),t(A,mr),t(A,de),u(Ne,de,null),t(de,ur),t(de,It),L(e,ko,f),u(Fe,e,f),L(e,Po,f),L(e,C,f),u(We,C,null),t(C,hr),t(C,Ht),t(C,gr),t(C,le),u(Xe,le,null),t(le,xr),t(le,Ut),t(C,Lr),t(C,ce),u(Be,ce,null),t(ce,br),t(ce,Et),t(C,vr),t(C,U),u(qe,U,null),t(U,$r),t(U,Nt),t(U,wr),t(U,Ft),t(U,Mr),t(U,Wt),t(U,yr),t(U,Xt),t(U,Dr),t(U,Bt),t(C,Tr),t(C,J),u(je,J,null),t(J,Sr),t(J,qt),t(J,Ar),u(fe,J,null),t(C,Cr),t(C,pe),u(Ve,pe,null),t(pe,kr),t(pe,jt),L(e,Ro,f),u(Je,e,f),L(e,Io,f),L(e,S,f),u(Ge,S,null),t(S,Pr),t(S,Vt),t(S,Rr),t(S,Jt),t(S,Ir),t(S,_e),u(Ze,_e,null),t(_e,Hr),t(_e,Gt),t(S,Ur),t(S,me),u(ze,me,null),t(me,Er),t(me,Zt),t(S,Nr),t(S,W),u(Ye,W,null),t(W,Fr),t(W,zt),t(W,Wr),t(W,Yt),t(W,Xr),t(W,Qt),t(W,Br),t(W,Ot),t(S,qr),t(S,G),u(Qe,G,null),t(G,jr),t(G,Kt),t(G,Vr),u(ue,G,null),t(S,Jr),t(S,he),u(Oe,he,null),t(he,Gr),t(he,eo),L(e,Ho,f),u(Ke,e,f),L(e,Uo,f),L(e,k,f),u(et,k,null),t(k,Zr),t(k,to),t(k,zr),t(k,ge),u(tt,ge,null),t(ge,Yr),t(ge,oo),t(k,Qr),t(k,X),u(ot,X,null),t(X,Or),t(X,ro),t(X,Kr),t(X,ao),t(X,ea),t(X,no),t(X,ta),t(X,so),t(k,oa),t(k,Z),u(rt,Z,null),t(Z,ra),t(Z,io),t(Z,aa),u(xe,Z,null),t(k,na),t(k,Le),u(at,Le,null),t(Le,sa),t(Le,lo),t(k,ia),t(k,z),u(nt,z,null),t(z,da),t(z,co),t(z,la),u(be,z,null),L(e,Eo,f),u(st,e,f),L(e,No,f),L(e,te,f),u(it,te,null),t(te,ca),t(te,ve),u(dt,ve,null),t(ve,fa),t(ve,fo),L(e,Fo,f),u(lt,e,f),L(e,Wo,f),L(e,T,f),u(ct,T,null),t(T,pa),t(T,po),t(T,_a),t(T,_o),u(ft,_o,null),t(T,ma),t(T,q),u(pt,q,null),t(q,ua),t(q,mo),t(q,ha),u($e,q,null),t(q,ga),u(we,q,null),t(T,xa),t(T,Y),u(_t,Y,null),t(Y,La),t(Y,uo),t(Y,ba),u(Me,Y,null),t(T,va),t(T,ye),u(mt,ye,null),t(ye,$a),t(ye,ho),t(T,wa),t(T,De),u(ut,De,null),t(De,Ma),t(De,go),t(T,ya),t(T,Q),u(ht,Q,null),t(Q,Da),t(Q,xo),t(Q,Ta),u(Te,Q,null),t(T,Sa),t(T,O),u(gt,O,null),t(O,Aa),t(O,Lo),t(O,Ca),u(Se,O,null),L(e,Xo,f),u(xt,e,f),L(e,Bo,f),L(e,Do,f),qo=!0},p(e,[f]){const R={};f&2&&(R.$$scope={dirty:f,ctx:e}),ae.$set(R);const Lt={};f&2&&(Lt.$$scope={dirty:f,ctx:e}),ie.$set(Lt);const bt={};f&2&&(bt.$$scope={dirty:f,ctx:e}),fe.$set(bt);const N={};f&2&&(N.$$scope={dirty:f,ctx:e}),ue.$set(N);const oe={};f&2&&(oe.$$scope={dirty:f,ctx:e}),xe.$set(oe);const vt={};f&2&&(vt.$$scope={dirty:f,ctx:e}),be.$set(vt);const I={};f&2&&(I.$$scope={dirty:f,ctx:e}),$e.$set(I);const $t={};f&2&&($t.$$scope={dirty:f,ctx:e}),we.$set($t);const wt={};f&2&&(wt.$$scope={dirty:f,ctx:e}),Me.$set(wt);const F={};f&2&&(F.$$scope={dirty:f,ctx:e}),Te.$set(F);const re={};f&2&&(re.$$scope={dirty:f,ctx:e}),Se.$set(re)},i(e){qo||(h(M.$$.fragment,e),h(ae.$$.fragment,e),h(Pe.$$.fragment,e),h(Re.$$.fragment,e),h(Ie.$$.fragment,e),h(He.$$.fragment,e),h(Ue.$$.fragment,e),h(Ee.$$.fragment,e),h(ie.$$.fragment,e),h(Ne.$$.fragment,e),h(Fe.$$.fragment,e),h(We.$$.fragment,e),h(Xe.$$.fragment,e),h(Be.$$.fragment,e),h(qe.$$.fragment,e),h(je.$$.fragment,e),h(fe.$$.fragment,e),h(Ve.$$.fragment,e),h(Je.$$.fragment,e),h(Ge.$$.fragment,e),h(Ze.$$.fragment,e),h(ze.$$.fragment,e),h(Ye.$$.fragment,e),h(Qe.$$.fragment,e),h(ue.$$.fragment,e),h(Oe.$$.fragment,e),h(Ke.$$.fragment,e),h(et.$$.fragment,e),h(tt.$$.fragment,e),h(ot.$$.fragment,e),h(rt.$$.fragment,e),h(xe.$$.fragment,e),h(at.$$.fragment,e),h(nt.$$.fragment,e),h(be.$$.fragment,e),h(st.$$.fragment,e),h(it.$$.fragment,e),h(dt.$$.fragment,e),h(lt.$$.fragment,e),h(ct.$$.fragment,e),h(ft.$$.fragment,e),h(pt.$$.fragment,e),h($e.$$.fragment,e),h(we.$$.fragment,e),h(_t.$$.fragment,e),h(Me.$$.fragment,e),h(mt.$$.fragment,e),h(ut.$$.fragment,e),h(ht.$$.fragment,e),h(Te.$$.fragment,e),h(gt.$$.fragment,e),h(Se.$$.fragment,e),h(xt.$$.fragment,e),qo=!0)},o(e){g(M.$$.fragment,e),g(ae.$$.fragment,e),g(Pe.$$.fragment,e),g(Re.$$.fragment,e),g(Ie.$$.fragment,e),g(He.$$.fragment,e),g(Ue.$$.fragment,e),g(Ee.$$.fragment,e),g(ie.$$.fragment,e),g(Ne.$$.fragment,e),g(Fe.$$.fragment,e),g(We.$$.fragment,e),g(Xe.$$.fragment,e),g(Be.$$.fragment,e),g(qe.$$.fragment,e),g(je.$$.fragment,e),g(fe.$$.fragment,e),g(Ve.$$.fragment,e),g(Je.$$.fragment,e),g(Ge.$$.fragment,e),g(Ze.$$.fragment,e),g(ze.$$.fragment,e),g(Ye.$$.fragment,e),g(Qe.$$.fragment,e),g(ue.$$.fragment,e),g(Oe.$$.fragment,e),g(Ke.$$.fragment,e),g(et.$$.fragment,e),g(tt.$$.fragment,e),g(ot.$$.fragment,e),g(rt.$$.fragment,e),g(xe.$$.fragment,e),g(at.$$.fragment,e),g(nt.$$.fragment,e),g(be.$$.fragment,e),g(st.$$.fragment,e),g(it.$$.fragment,e),g(dt.$$.fragment,e),g(lt.$$.fragment,e),g(ct.$$.fragment,e),g(ft.$$.fragment,e),g(pt.$$.fragment,e),g($e.$$.fragment,e),g(we.$$.fragment,e),g(_t.$$.fragment,e),g(Me.$$.fragment,e),g(mt.$$.fragment,e),g(ut.$$.fragment,e),g(ht.$$.fragment,e),g(Te.$$.fragment,e),g(gt.$$.fragment,e),g(Se.$$.fragment,e),g(xt.$$.fragment,e),qo=!1},d(e){e&&(d(b),d(c),d(l),d(i),d(w),d(To),d(ke),d(So),d(Ao),d(Co),d(A),d(ko),d(Po),d(C),d(Ro),d(Io),d(S),d(Ho),d(Uo),d(k),d(Eo),d(No),d(te),d(Fo),d(Wo),d(T),d(Xo),d(Bo),d(Do)),d(s),x(M,e),x(ae,e),x(Pe,e),x(Re),x(Ie),x(He),x(Ue),x(Ee),x(ie),x(Ne),x(Fe,e),x(We),x(Xe),x(Be),x(qe),x(je),x(fe),x(Ve),x(Je,e),x(Ge),x(Ze),x(ze),x(Ye),x(Qe),x(ue),x(Oe),x(Ke,e),x(et),x(tt),x(ot),x(rt),x(xe),x(at),x(nt),x(be),x(st,e),x(it),x(dt),x(lt,e),x(ct),x(ft),x(pt),x($e),x(we),x(_t),x(Me),x(mt),x(ut),x(ht),x(Te),x(gt),x(Se),x(xt,e)}}}const Zn='{"title":"LoRA","local":"lora","sections":[{"title":"StableDiffusionLoraLoaderMixin","local":"diffusers.loaders.StableDiffusionLoraLoaderMixin","sections":[],"depth":2},{"title":"StableDiffusionXLLoraLoaderMixin","local":"diffusers.loaders.StableDiffusionXLLoraLoaderMixin","sections":[],"depth":2},{"title":"SD3LoraLoaderMixin","local":"diffusers.loaders.SD3LoraLoaderMixin","sections":[],"depth":2},{"title":"AuraFlowLoraLoaderMixin","local":"diffusers.loaders.AuraFlowLoraLoaderMixin","sections":[],"depth":2},{"title":"AmusedLoraLoaderMixin","local":"diffusers.loaders.AmusedLoraLoaderMixin","sections":[],"depth":2},{"title":"LoraBaseMixin","local":"diffusers.loaders.lora_base.LoraBaseMixin","sections":[],"depth":2}],"depth":1}';function zn(D){return kn(()=>{new URLSearchParams(window.location.search).get("fw")}),[]}class rs extends Pn{constructor(s){super(),Rn(this,s,zn,Gn,Cn,{})}}export{rs as component}; | |
Xet Storage Details
- Size:
- 95.7 kB
- Xet hash:
- 0135793a47226617f4f0c80e28af5c7fa528b3b1a61c0ef3f84314a3f140e42e
·
Xet efficiently stores files, intelligently splitting them into unique chunks and accelerating uploads and downloads. More info.