import{s as Ie,o as Je,n as we}from"../chunks/scheduler.8c3d61f6.js";import{S as je,i as Ce,g as d,s as l,r as u,A as We,h as f,f as o,c as a,j as z,u as g,x as T,k as Q,y as c,a as t,v as h,d as _,t as b,w as M}from"../chunks/index.da70eac4.js";import{T as Ge}from"../chunks/Tip.1d9b8c37.js";import{D as ue}from"../chunks/Docstring.ee4b6913.js";import{C as Ue}from"../chunks/CodeBlock.00a903b3.js";import{E as Le}from"../chunks/ExampleCodeBlock.f7bd2c1f.js";import{H as ee,E as Ne}from"../chunks/EditOnGithub.1e64e623.js";function He(Z){let n,m='Read the <a href="../../using-diffusers/other-formats">Model files and layouts</a> guide to learn more about the Diffusers-multifolder layout versus the single-file layout, and how to load models stored in these different layouts.';return{c(){n=d("p"),n.innerHTML=m},l(s){n=f(s,"P",{"data-svelte-h":!0}),T(n)!=="svelte-7ol9a4"&&(n.innerHTML=m)},m(s,p){t(s,n,p)},p:we,d(s){s&&o(n)}}}function Ve(Z){let n,m="Examples:",s,p,x;return p=new Ue({props:{code:"ZnJvbSUyMGRpZmZ1c2VycyUyMGltcG9ydCUyMFN0YWJsZURpZmZ1c2lvblBpcGVsaW5lJTBBJTBBJTIzJTIwRG93bmxvYWQlMjBwaXBlbGluZSUyMGZyb20lMjBodWdnaW5nZmFjZS5jbyUyMGFuZCUyMGNhY2hlLiUwQXBpcGVsaW5lJTIwJTNEJTIwU3RhYmxlRGlmZnVzaW9uUGlwZWxpbmUuZnJvbV9zaW5nbGVfZmlsZSglMEElMjAlMjAlMjAlMjAlMjJodHRwcyUzQSUyRiUyRmh1Z2dpbmdmYWNlLmNvJTJGV2Fycmlvck1hbWE3NzclMkZPcmFuZ2VNaXhzJTJGYmxvYiUyRm1haW4lMkZNb2RlbHMlMkZBYnlzc09yYW5nZU1peCUyRkFieXNzT3JhbmdlTWl4LnNhZmV0ZW5zb3JzJTIyJTBBKSUwQSUwQSUyMyUyMERvd25sb2FkJTIwcGlwZWxpbmUlMjBmcm9tJTIwbG9jYWwlMjBmaWxlJTBBJTIzJTIwZmlsZSUyMGlzJTIwZG93bmxvYWRlZCUyMHVuZGVyJTIwLiUyRnYxLTUtcHJ1bmVkLWVtYW9ubHkuY2twdCUwQXBpcGVsaW5lJTIwJTNEJTIwU3RhYmxlRGlmZnVzaW9uUGlwZWxpbmUuZnJvbV9zaW5nbGVfZmlsZSglMjIuJTJGdjEtNS1wcnVuZWQtZW1hb25seS5ja3B0JTIyKSUwQSUwQSUyMyUyMEVuYWJsZSUyMGZsb2F0MTYlMjBhbmQlMjBtb3ZlJTIwdG8lMjBHUFUlMEFwaXBlbGluZSUyMCUzRCUyMFN0YWJsZURpZmZ1c2lvblBpcGVsaW5lLmZyb21fc2luZ2xlX2ZpbGUoJTBBJTIwJTIwJTIwJTIwJTIyaHR0cHMlM0ElMkYlMkZodWdnaW5nZmFjZS5jbyUyRnJ1bndheW1sJTJGc3RhYmxlLWRpZmZ1c2lvbi12MS01JTJGYmxvYiUyRm1haW4lMkZ2MS01LXBydW5lZC1lbWFvbmx5LmNrcHQlMjIlMkMlMEElMjAlMjAlMjAlMjB0b3JjaF9kdHlwZSUzRHRvcmNoLmZsb2F0MTYlMkMlMEEpJTBBcGlwZWxpbmUudG8oJTIyY3VkYSUyMik=",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> diffusers <span class="hljs-keyword">import</span> StableDiffusionPipeline

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Download pipeline from huggingface.co and cache.</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>pipeline = StableDiffusionPipeline.from_single_file(
<span class="hljs-meta">... </span>    <span class="hljs-string">&quot;https://huggingface.co/WarriorMama777/OrangeMixs/blob/main/Models/AbyssOrangeMix/AbyssOrangeMix.safetensors&quot;</span>
<span class="hljs-meta">... </span>)

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Download pipeline from local file</span>
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># file is downloaded under ./v1-5-pruned-emaonly.ckpt</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>pipeline = StableDiffusionPipeline.from_single_file(<span class="hljs-string">&quot;./v1-5-pruned-emaonly.ckpt&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Enable float16 and move to GPU</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>pipeline = StableDiffusionPipeline.from_single_file(
<span class="hljs-meta">... </span>    <span class="hljs-string">&quot;https://huggingface.co/runwayml/stable-diffusion-v1-5/blob/main/v1-5-pruned-emaonly.ckpt&quot;</span>,
<span class="hljs-meta">... </span>    torch_dtype=torch.float16,
<span class="hljs-meta">... </span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>pipeline.to(<span class="hljs-string">&quot;cuda&quot;</span>)`,wrap:!1}}),{c(){n=d("p"),n.textContent=m,s=l(),u(p.$$.fragment)},l(r){n=f(r,"P",{"data-svelte-h":!0}),T(n)!=="svelte-kvfsh7"&&(n.textContent=m),s=a(r),g(p.$$.fragment,r)},m(r,y){t(r,n,y),t(r,s,y),h(p,r,y),x=!0},p:we,i(r){x||(_(p.$$.fragment,r),x=!0)},o(r){b(p.$$.fragment,r),x=!1},d(r){r&&(o(n),o(s)),M(p,r)}}}function Be(Z){let n,m;return n=new Ue({props:{code:"ZnJvbSUyMGRpZmZ1c2VycyUyMGltcG9ydCUyMFN0YWJsZUNhc2NhZGVVTmV0JTBBJTBBY2twdF9wYXRoJTIwJTNEJTIwJTIyaHR0cHMlM0ElMkYlMkZodWdnaW5nZmFjZS5jbyUyRnN0YWJpbGl0eWFpJTJGc3RhYmxlLWNhc2NhZGUlMkZibG9iJTJGbWFpbiUyRnN0YWdlX2JfbGl0ZS5zYWZldGVuc29ycyUyMiUwQW1vZGVsJTIwJTNEJTIwU3RhYmxlQ2FzY2FkZVVOZXQuZnJvbV9zaW5nbGVfZmlsZShja3B0X3BhdGgp",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> diffusers <span class="hljs-keyword">import</span> StableCascadeUNet

<span class="hljs-meta">&gt;&gt;&gt; </span>ckpt_path = <span class="hljs-string">&quot;https://huggingface.co/stabilityai/stable-cascade/blob/main/stage_b_lite.safetensors&quot;</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>model = StableCascadeUNet.from_single_file(ckpt_path)`,wrap:!1}}),{c(){u(n.$$.fragment)},l(s){g(n.$$.fragment,s)},m(s,p){h(n,s,p),m=!0},p:we,i(s){m||(_(n.$$.fragment,s),m=!0)},o(s){b(n.$$.fragment,s),m=!1},d(s){M(n,s)}}}function Xe(Z){let n,m,s,p,x,r,y,ve='The <a href="/docs/diffusers/main/en/api/loaders/single_file#diffusers.loaders.FromSingleFileMixin.from_single_file">from_single_file()</a> method allows you to load:',ie,I,Se="<li>a model stored in a single file, which is useful if you’re working with models from the diffusion ecosystem, like Automatic1111, and commonly rely on a single-file layout to store and share models</li> <li>a model stored in their originally distributed layout, which is useful if you’re working with models finetuned with other services, and want to load it directly into Diffusers model objects and pipelines</li>",oe,D,ne,J,se,j,Te='<li><a href="/docs/diffusers/main/en/api/pipelines/cogvideox#diffusers.CogVideoXPipeline">CogVideoXPipeline</a></li> <li><a href="/docs/diffusers/main/en/api/pipelines/stable_diffusion/text2img#diffusers.StableDiffusionPipeline">StableDiffusionPipeline</a></li> <li><a href="/docs/diffusers/main/en/api/pipelines/stable_diffusion/img2img#diffusers.StableDiffusionImg2ImgPipeline">StableDiffusionImg2ImgPipeline</a></li> <li><a href="/docs/diffusers/main/en/api/pipelines/stable_diffusion/inpaint#diffusers.StableDiffusionInpaintPipeline">StableDiffusionInpaintPipeline</a></li> <li><a href="/docs/diffusers/main/en/api/pipelines/controlnet#diffusers.StableDiffusionControlNetPipeline">StableDiffusionControlNetPipeline</a></li> <li><a href="/docs/diffusers/main/en/api/pipelines/controlnet#diffusers.StableDiffusionControlNetImg2ImgPipeline">StableDiffusionControlNetImg2ImgPipeline</a></li> <li><a href="/docs/diffusers/main/en/api/pipelines/controlnet#diffusers.StableDiffusionControlNetInpaintPipeline">StableDiffusionControlNetInpaintPipeline</a></li> <li><a href="/docs/diffusers/main/en/api/pipelines/stable_diffusion/upscale#diffusers.StableDiffusionUpscalePipeline">StableDiffusionUpscalePipeline</a></li> <li><a href="/docs/diffusers/main/en/api/pipelines/stable_diffusion/stable_diffusion_xl#diffusers.StableDiffusionXLPipeline">StableDiffusionXLPipeline</a></li> <li><a href="/docs/diffusers/main/en/api/pipelines/stable_diffusion/stable_diffusion_xl#diffusers.StableDiffusionXLImg2ImgPipeline">StableDiffusionXLImg2ImgPipeline</a></li> <li><a href="/docs/diffusers/main/en/api/pipelines/stable_diffusion/stable_diffusion_xl#diffusers.StableDiffusionXLInpaintPipeline">StableDiffusionXLInpaintPipeline</a></li> <li><a href="/docs/diffusers/main/en/api/pipelines/pix2pix#diffusers.StableDiffusionXLInstructPix2PixPipeline">StableDiffusionXLInstructPix2PixPipeline</a></li> <li><a href="/docs/diffusers/main/en/api/pipelines/controlnet_sdxl#diffusers.StableDiffusionXLControlNetPipeline">StableDiffusionXLControlNetPipeline</a></li> <li><a href="/docs/diffusers/main/en/api/pipelines/stable_diffusion/k_diffusion#diffusers.StableDiffusionXLKDiffusionPipeline">StableDiffusionXLKDiffusionPipeline</a></li> <li><a href="/docs/diffusers/main/en/api/pipelines/stable_diffusion/stable_diffusion_3#diffusers.StableDiffusion3Pipeline">StableDiffusion3Pipeline</a></li> <li><a href="/docs/diffusers/main/en/api/pipelines/latent_consistency_models#diffusers.LatentConsistencyModelPipeline">LatentConsistencyModelPipeline</a></li> <li><a href="/docs/diffusers/main/en/api/pipelines/latent_consistency_models#diffusers.LatentConsistencyModelImg2ImgPipeline">LatentConsistencyModelImg2ImgPipeline</a></li> <li><a href="/docs/diffusers/main/en/api/pipelines/controlnetxs#diffusers.StableDiffusionControlNetXSPipeline">StableDiffusionControlNetXSPipeline</a></li> <li><a href="/docs/diffusers/main/en/api/pipelines/controlnetxs_sdxl#diffusers.StableDiffusionXLControlNetXSPipeline">StableDiffusionXLControlNetXSPipeline</a></li> <li><a href="/docs/diffusers/main/en/api/pipelines/ledits_pp#diffusers.LEditsPPPipelineStableDiffusion">LEditsPPPipelineStableDiffusion</a></li> <li><a href="/docs/diffusers/main/en/api/pipelines/ledits_pp#diffusers.LEditsPPPipelineStableDiffusionXL">LEditsPPPipelineStableDiffusionXL</a></li> <li><a href="/docs/diffusers/main/en/api/pipelines/pia#diffusers.PIAPipeline">PIAPipeline</a></li>',te,C,le,W,Fe='<li><a href="/docs/diffusers/main/en/api/models/unet2d-cond#diffusers.UNet2DConditionModel">UNet2DConditionModel</a></li> <li><code>StableCascadeUNet</code></li> <li><a href="/docs/diffusers/main/en/api/models/autoencoderkl#diffusers.AutoencoderKL">AutoencoderKL</a></li> <li><a href="/docs/diffusers/main/en/api/models/autoencoderkl_cogvideox#diffusers.AutoencoderKLCogVideoX">AutoencoderKLCogVideoX</a></li> <li><a href="/docs/diffusers/main/en/api/models/controlnet#diffusers.ControlNetModel">ControlNetModel</a></li> <li><a href="/docs/diffusers/main/en/api/models/sd3_transformer2d#diffusers.SD3Transformer2DModel">SD3Transformer2DModel</a></li> <li><a href="/docs/diffusers/main/en/api/models/flux_transformer#diffusers.FluxTransformer2DModel">FluxTransformer2DModel</a></li>',ae,G,re,$,N,ge,Y,Pe='Load model weights saved in the <code>.ckpt</code> format into a <a href="/docs/diffusers/main/en/api/pipelines/overview#diffusers.DiffusionPipeline">DiffusionPipeline</a>.',he,v,H,_e,R,ke=`Instantiate a <a href="/docs/diffusers/main/en/api/pipelines/overview#diffusers.DiffusionPipeline">DiffusionPipeline</a> from pretrained pipeline weights saved in the <code>.ckpt</code> or <code>.safetensors</code>
format. The pipeline is set in evaluation mode (<code>model.eval()</code>) by default.`,be,L,de,V,fe,w,B,Me,q,Ze="Load pretrained weights saved in the <code>.ckpt</code> or <code>.safetensors</code> format into a model.",xe,S,X,ye,A,De=`Instantiate a model from pretrained weights saved in the original <code>.ckpt</code> or <code>.safetensors</code> format. The model
is set in evaluation mode (<code>model.eval()</code>) by default.`,$e,U,pe,E,me,K,ce;return x=new ee({props:{title:"Single files",local:"single-files",headingTag:"h1"}}),D=new Ge({props:{warning:!1,$$slots:{default:[He]},$$scope:{ctx:Z}}}),J=new ee({props:{title:"Supported pipelines",local:"supported-pipelines",headingTag:"h2"}}),C=new ee({props:{title:"Supported models",local:"supported-models",headingTag:"h2"}}),G=new ee({props:{title:"FromSingleFileMixin",local:"diffusers.loaders.FromSingleFileMixin",headingTag:"h2"}}),N=new ue({props:{name:"class diffusers.loaders.FromSingleFileMixin",anchor:"diffusers.loaders.FromSingleFileMixin",parameters:[],source:"https://github.com/huggingface/diffusers/blob/main/src/diffusers/loaders/single_file.py#L263"}}),H=new ue({props:{name:"from_single_file",anchor:"diffusers.loaders.FromSingleFileMixin.from_single_file",parameters:[{name:"pretrained_model_link_or_path",val:""},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"diffusers.loaders.FromSingleFileMixin.from_single_file.pretrained_model_link_or_path",description:`<strong>pretrained_model_link_or_path</strong> (<code>str</code> or <code>os.PathLike</code>, <em>optional</em>) &#x2014;
Can be either:</p>
<ul>
<li>A link to the <code>.ckpt</code> file (for example
<code>&quot;https://huggingface.co/&lt;repo_id&gt;/blob/main/&lt;path_to_file&gt;.ckpt&quot;</code>) on the Hub.</li>
<li>A path to a <em>file</em> containing all pipeline weights.</li>
</ul>`,name:"pretrained_model_link_or_path"},{anchor:"diffusers.loaders.FromSingleFileMixin.from_single_file.torch_dtype",description:`<strong>torch_dtype</strong> (<code>str</code> or <code>torch.dtype</code>, <em>optional</em>) &#x2014;
Override the default <code>torch.dtype</code> and load the model with another dtype.`,name:"torch_dtype"},{anchor:"diffusers.loaders.FromSingleFileMixin.from_single_file.force_download",description:`<strong>force_download</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether or not to force the (re-)download of the model weights and configuration files, overriding the
cached versions if they exist.`,name:"force_download"},{anchor:"diffusers.loaders.FromSingleFileMixin.from_single_file.cache_dir",description:`<strong>cache_dir</strong> (<code>Union[str, os.PathLike]</code>, <em>optional</em>) &#x2014;
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.FromSingleFileMixin.from_single_file.proxies",description:`<strong>proxies</strong> (<code>Dict[str, str]</code>, <em>optional</em>) &#x2014;
A dictionary of proxy servers to use by protocol or endpoint, for example, <code>{&apos;http&apos;: &apos;foo.bar:3128&apos;, &apos;http://hostname&apos;: &apos;foo.bar:4012&apos;}</code>. The proxies are used on each request.`,name:"proxies"},{anchor:"diffusers.loaders.FromSingleFileMixin.from_single_file.local_files_only",description:`<strong>local_files_only</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether to only load local model weights and configuration files or not. If set to <code>True</code>, the model
won&#x2019;t be downloaded from the Hub.`,name:"local_files_only"},{anchor:"diffusers.loaders.FromSingleFileMixin.from_single_file.token",description:`<strong>token</strong> (<code>str</code> or <em>bool</em>, <em>optional</em>) &#x2014;
The token to use as HTTP bearer authorization for remote files. If <code>True</code>, the token generated from
<code>diffusers-cli login</code> (stored in <code>~/.huggingface</code>) is used.`,name:"token"},{anchor:"diffusers.loaders.FromSingleFileMixin.from_single_file.revision",description:`<strong>revision</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;main&quot;</code>) &#x2014;
The specific model version to use. It can be a branch name, a tag name, a commit id, or any identifier
allowed by Git.`,name:"revision"},{anchor:"diffusers.loaders.FromSingleFileMixin.from_single_file.original_config_file",description:`<strong>original_config_file</strong> (<code>str</code>, <em>optional</em>) &#x2014;
The path to the original config file that was used to train the model. If not provided, the config file
will be inferred from the checkpoint file.`,name:"original_config_file"},{anchor:"diffusers.loaders.FromSingleFileMixin.from_single_file.config",description:`<strong>config</strong> (<code>str</code>, <em>optional</em>) &#x2014;
Can be either:</p>
<ul>
<li>A string, the <em>repo id</em> (for example <code>CompVis/ldm-text2im-large-256</code>) of a pretrained pipeline
hosted on the Hub.</li>
<li>A path to a <em>directory</em> (for example <code>./my_pipeline_directory/</code>) containing the pipeline
component configs in Diffusers format.</li>
</ul>`,name:"config"},{anchor:"diffusers.loaders.FromSingleFileMixin.from_single_file.kwargs",description:`<strong>kwargs</strong> (remaining dictionary of keyword arguments, <em>optional</em>) &#x2014;
Can be used to overwrite load and saveable variables (the pipeline components of the specific pipeline
class). The overwritten components are passed directly to the pipelines <code>__init__</code> method. See example
below for more information.`,name:"kwargs"}],source:"https://github.com/huggingface/diffusers/blob/main/src/diffusers/loaders/single_file.py#L268"}}),L=new Le({props:{anchor:"diffusers.loaders.FromSingleFileMixin.from_single_file.example",$$slots:{default:[Ve]},$$scope:{ctx:Z}}}),V=new ee({props:{title:"FromOriginalModelMixin",local:"diffusers.loaders.FromOriginalModelMixin",headingTag:"h2"}}),B=new ue({props:{name:"class diffusers.loaders.FromOriginalModelMixin",anchor:"diffusers.loaders.FromOriginalModelMixin",parameters:[],source:"https://github.com/huggingface/diffusers/blob/main/src/diffusers/loaders/single_file_model.py#L110"}}),X=new ue({props:{name:"from_single_file",anchor:"diffusers.loaders.FromOriginalModelMixin.from_single_file",parameters:[{name:"pretrained_model_link_or_path_or_dict",val:": Optional = None"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"diffusers.loaders.FromOriginalModelMixin.from_single_file.pretrained_model_link_or_path_or_dict",description:`<strong>pretrained_model_link_or_path_or_dict</strong> (<code>str</code>, <em>optional</em>) &#x2014;
Can be either:</p>
<ul>
<li>A link to the <code>.safetensors</code> or <code>.ckpt</code> file (for example
<code>&quot;https://huggingface.co/&lt;repo_id&gt;/blob/main/&lt;path_to_file&gt;.safetensors&quot;</code>) on the Hub.</li>
<li>A path to a local <em>file</em> containing the weights of the component model.</li>
<li>A state dict containing the component model weights.</li>
</ul>`,name:"pretrained_model_link_or_path_or_dict"},{anchor:"diffusers.loaders.FromOriginalModelMixin.from_single_file.config",description:`<strong>config</strong> (<code>str</code>, <em>optional</em>) &#x2014;</p>
<ul>
<li>A string, the <em>repo id</em> (for example <code>CompVis/ldm-text2im-large-256</code>) of a pretrained pipeline hosted
on the Hub.</li>
<li>A path to a <em>directory</em> (for example <code>./my_pipeline_directory/</code>) containing the pipeline component
configs in Diffusers format.</li>
</ul>`,name:"config"},{anchor:"diffusers.loaders.FromOriginalModelMixin.from_single_file.subfolder",description:`<strong>subfolder</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;&quot;</code>) &#x2014;
The subfolder location of a model file within a larger model repository on the Hub or locally.`,name:"subfolder"},{anchor:"diffusers.loaders.FromOriginalModelMixin.from_single_file.original_config",description:`<strong>original_config</strong> (<code>str</code>, <em>optional</em>) &#x2014;
Dict or path to a yaml file containing the configuration for the model in its original format.
If a dict is provided, it will be used to initialize the model configuration.`,name:"original_config"},{anchor:"diffusers.loaders.FromOriginalModelMixin.from_single_file.torch_dtype",description:`<strong>torch_dtype</strong> (<code>str</code> or <code>torch.dtype</code>, <em>optional</em>) &#x2014;
Override the default <code>torch.dtype</code> and load the model with another dtype. If <code>&quot;auto&quot;</code> is passed, the
dtype is automatically derived from the model&#x2019;s weights.`,name:"torch_dtype"},{anchor:"diffusers.loaders.FromOriginalModelMixin.from_single_file.force_download",description:`<strong>force_download</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether or not to force the (re-)download of the model weights and configuration files, overriding the
cached versions if they exist.`,name:"force_download"},{anchor:"diffusers.loaders.FromOriginalModelMixin.from_single_file.cache_dir",description:`<strong>cache_dir</strong> (<code>Union[str, os.PathLike]</code>, <em>optional</em>) &#x2014;
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.FromOriginalModelMixin.from_single_file.proxies",description:`<strong>proxies</strong> (<code>Dict[str, str]</code>, <em>optional</em>) &#x2014;
A dictionary of proxy servers to use by protocol or endpoint, for example, <code>{&apos;http&apos;: &apos;foo.bar:3128&apos;, &apos;http://hostname&apos;: &apos;foo.bar:4012&apos;}</code>. The proxies are used on each request.`,name:"proxies"},{anchor:"diffusers.loaders.FromOriginalModelMixin.from_single_file.local_files_only",description:`<strong>local_files_only</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether to only load local model weights and configuration files or not. If set to True, the model
won&#x2019;t be downloaded from the Hub.`,name:"local_files_only"},{anchor:"diffusers.loaders.FromOriginalModelMixin.from_single_file.token",description:`<strong>token</strong> (<code>str</code> or <em>bool</em>, <em>optional</em>) &#x2014;
The token to use as HTTP bearer authorization for remote files. If <code>True</code>, the token generated from
<code>diffusers-cli login</code> (stored in <code>~/.huggingface</code>) is used.`,name:"token"},{anchor:"diffusers.loaders.FromOriginalModelMixin.from_single_file.revision",description:`<strong>revision</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;main&quot;</code>) &#x2014;
The specific model version to use. It can be a branch name, a tag name, a commit id, or any identifier
allowed by Git.`,name:"revision"},{anchor:"diffusers.loaders.FromOriginalModelMixin.from_single_file.kwargs",description:`<strong>kwargs</strong> (remaining dictionary of keyword arguments, <em>optional</em>) &#x2014;
Can be used to overwrite load and saveable variables (for example the pipeline components of the
specific pipeline class). The overwritten components are directly passed to the pipelines <code>__init__</code>
method. See example below for more information.`,name:"kwargs"}],source:"https://github.com/huggingface/diffusers/blob/main/src/diffusers/loaders/single_file_model.py#L115"}}),U=new Le({props:{anchor:"diffusers.loaders.FromOriginalModelMixin.from_single_file.example",$$slots:{default:[Be]},$$scope:{ctx:Z}}}),E=new Ne({props:{source:"https://github.com/huggingface/diffusers/blob/main/docs/source/en/api/loaders/single_file.md"}}),{c(){n=d("meta"),m=l(),s=d("p"),p=l(),u(x.$$.fragment),r=l(),y=d("p"),y.innerHTML=ve,ie=l(),I=d("ul"),I.innerHTML=Se,oe=l(),u(D.$$.fragment),ne=l(),u(J.$$.fragment),se=l(),j=d("ul"),j.innerHTML=Te,te=l(),u(C.$$.fragment),le=l(),W=d("ul"),W.innerHTML=Fe,ae=l(),u(G.$$.fragment),re=l(),$=d("div"),u(N.$$.fragment),ge=l(),Y=d("p"),Y.innerHTML=Pe,he=l(),v=d("div"),u(H.$$.fragment),_e=l(),R=d("p"),R.innerHTML=ke,be=l(),u(L.$$.fragment),de=l(),u(V.$$.fragment),fe=l(),w=d("div"),u(B.$$.fragment),Me=l(),q=d("p"),q.innerHTML=Ze,xe=l(),S=d("div"),u(X.$$.fragment),ye=l(),A=d("p"),A.innerHTML=De,$e=l(),u(U.$$.fragment),pe=l(),u(E.$$.fragment),me=l(),K=d("p"),this.h()},l(e){const i=We("svelte-u9bgzb",document.head);n=f(i,"META",{name:!0,content:!0}),i.forEach(o),m=a(e),s=f(e,"P",{}),z(s).forEach(o),p=a(e),g(x.$$.fragment,e),r=a(e),y=f(e,"P",{"data-svelte-h":!0}),T(y)!=="svelte-qpwkxd"&&(y.innerHTML=ve),ie=a(e),I=f(e,"UL",{"data-svelte-h":!0}),T(I)!=="svelte-4h4p7d"&&(I.innerHTML=Se),oe=a(e),g(D.$$.fragment,e),ne=a(e),g(J.$$.fragment,e),se=a(e),j=f(e,"UL",{"data-svelte-h":!0}),T(j)!=="svelte-e6x6iq"&&(j.innerHTML=Te),te=a(e),g(C.$$.fragment,e),le=a(e),W=f(e,"UL",{"data-svelte-h":!0}),T(W)!=="svelte-1wn8pag"&&(W.innerHTML=Fe),ae=a(e),g(G.$$.fragment,e),re=a(e),$=f(e,"DIV",{class:!0});var F=z($);g(N.$$.fragment,F),ge=a(F),Y=f(F,"P",{"data-svelte-h":!0}),T(Y)!=="svelte-11v9qjy"&&(Y.innerHTML=Pe),he=a(F),v=f(F,"DIV",{class:!0});var P=z(v);g(H.$$.fragment,P),_e=a(P),R=f(P,"P",{"data-svelte-h":!0}),T(R)!=="svelte-pmqrln"&&(R.innerHTML=ke),be=a(P),g(L.$$.fragment,P),P.forEach(o),F.forEach(o),de=a(e),g(V.$$.fragment,e),fe=a(e),w=f(e,"DIV",{class:!0});var k=z(w);g(B.$$.fragment,k),Me=a(k),q=f(k,"P",{"data-svelte-h":!0}),T(q)!=="svelte-1angwv3"&&(q.innerHTML=Ze),xe=a(k),S=f(k,"DIV",{class:!0});var O=z(S);g(X.$$.fragment,O),ye=a(O),A=f(O,"P",{"data-svelte-h":!0}),T(A)!=="svelte-vw4n4o"&&(A.innerHTML=De),$e=a(O),g(U.$$.fragment,O),O.forEach(o),k.forEach(o),pe=a(e),g(E.$$.fragment,e),me=a(e),K=f(e,"P",{}),z(K).forEach(o),this.h()},h(){Q(n,"name","hf:doc:metadata"),Q(n,"content",Ee),Q(v,"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"),Q(S,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),Q(w,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8")},m(e,i){c(document.head,n),t(e,m,i),t(e,s,i),t(e,p,i),h(x,e,i),t(e,r,i),t(e,y,i),t(e,ie,i),t(e,I,i),t(e,oe,i),h(D,e,i),t(e,ne,i),h(J,e,i),t(e,se,i),t(e,j,i),t(e,te,i),h(C,e,i),t(e,le,i),t(e,W,i),t(e,ae,i),h(G,e,i),t(e,re,i),t(e,$,i),h(N,$,null),c($,ge),c($,Y),c($,he),c($,v),h(H,v,null),c(v,_e),c(v,R),c(v,be),h(L,v,null),t(e,de,i),h(V,e,i),t(e,fe,i),t(e,w,i),h(B,w,null),c(w,Me),c(w,q),c(w,xe),c(w,S),h(X,S,null),c(S,ye),c(S,A),c(S,$e),h(U,S,null),t(e,pe,i),h(E,e,i),t(e,me,i),t(e,K,i),ce=!0},p(e,[i]){const F={};i&2&&(F.$$scope={dirty:i,ctx:e}),D.$set(F);const P={};i&2&&(P.$$scope={dirty:i,ctx:e}),L.$set(P);const k={};i&2&&(k.$$scope={dirty:i,ctx:e}),U.$set(k)},i(e){ce||(_(x.$$.fragment,e),_(D.$$.fragment,e),_(J.$$.fragment,e),_(C.$$.fragment,e),_(G.$$.fragment,e),_(N.$$.fragment,e),_(H.$$.fragment,e),_(L.$$.fragment,e),_(V.$$.fragment,e),_(B.$$.fragment,e),_(X.$$.fragment,e),_(U.$$.fragment,e),_(E.$$.fragment,e),ce=!0)},o(e){b(x.$$.fragment,e),b(D.$$.fragment,e),b(J.$$.fragment,e),b(C.$$.fragment,e),b(G.$$.fragment,e),b(N.$$.fragment,e),b(H.$$.fragment,e),b(L.$$.fragment,e),b(V.$$.fragment,e),b(B.$$.fragment,e),b(X.$$.fragment,e),b(U.$$.fragment,e),b(E.$$.fragment,e),ce=!1},d(e){e&&(o(m),o(s),o(p),o(r),o(y),o(ie),o(I),o(oe),o(ne),o(se),o(j),o(te),o(le),o(W),o(ae),o(re),o($),o(de),o(fe),o(w),o(pe),o(me),o(K)),o(n),M(x,e),M(D,e),M(J,e),M(C,e),M(G,e),M(N),M(H),M(L),M(V,e),M(B),M(X),M(U),M(E,e)}}}const Ee='{"title":"Single files","local":"single-files","sections":[{"title":"Supported pipelines","local":"supported-pipelines","sections":[],"depth":2},{"title":"Supported models","local":"supported-models","sections":[],"depth":2},{"title":"FromSingleFileMixin","local":"diffusers.loaders.FromSingleFileMixin","sections":[],"depth":2},{"title":"FromOriginalModelMixin","local":"diffusers.loaders.FromOriginalModelMixin","sections":[],"depth":2}],"depth":1}';function Ye(Z){return Je(()=>{new URLSearchParams(window.location.search).get("fw")}),[]}class ei extends je{constructor(n){super(),Ce(this,n,Ye,Xe,Ie,{})}}export{ei as component};
