Buckets:
| import{s as qo,o as xo,n as zo}from"../chunks/scheduler.8c3d61f6.js";import{S as Co,i as To,g as i,s as n,r as l,A as ko,h as r,f as s,c as o,j as b,u,x as h,k as v,y as t,a as _,v as f,d as c,t as p,w as m}from"../chunks/index.da70eac4.js";import{T as Mo}from"../chunks/Tip.6f698f24.js";import{D as $}from"../chunks/Docstring.634d8861.js";import{C as Do}from"../chunks/CodeBlock.a9c4becf.js";import{E as Lo}from"../chunks/ExampleCodeBlock.f879b663.js";import{H as Ae,E as Qo}from"../chunks/getInferenceSnippets.ea1775db.js";function Bo(Ie){let y,L='Learn how to quantize models in the <a href="../quantization/overview">Quantization</a> guide.';return{c(){y=i("p"),y.innerHTML=L},l(x){y=r(x,"P",{"data-svelte-h":!0}),h(y)!=="svelte-1dd515k"&&(y.innerHTML=L)},m(x,C){_(x,y,C)},p:zo,d(x){x&&s(y)}}}function Po(Ie){let y,L="Example:",x,C,k;return C=new Do({props:{code:"ZnJvbSUyMGRpZmZ1c2VycyUyMGltcG9ydCUyMEZsdXhUcmFuc2Zvcm1lcjJETW9kZWwlMkMlMjBUb3JjaEFvQ29uZmlnJTBBJTBBcXVhbnRpemF0aW9uX2NvbmZpZyUyMCUzRCUyMFRvcmNoQW9Db25maWcoJTIyaW50OHdvJTIyKSUwQXRyYW5zZm9ybWVyJTIwJTNEJTIwRmx1eFRyYW5zZm9ybWVyMkRNb2RlbC5mcm9tX3ByZXRyYWluZWQoJTBBJTIwJTIwJTIwJTIwJTIyYmxhY2stZm9yZXN0LWxhYnMlMkZGbHV4LjEtRGV2JTIyJTJDJTBBJTIwJTIwJTIwJTIwc3ViZm9sZGVyJTNEJTIydHJhbnNmb3JtZXIlMjIlMkMlMEElMjAlMjAlMjAlMjBxdWFudGl6YXRpb25fY29uZmlnJTNEcXVhbnRpemF0aW9uX2NvbmZpZyUyQyUwQSUyMCUyMCUyMCUyMHRvcmNoX2R0eXBlJTNEdG9yY2guYmZsb2F0MTYlMkMlMEEp",highlighted:`<span class="hljs-keyword">from</span> diffusers <span class="hljs-keyword">import</span> FluxTransformer2DModel, TorchAoConfig | |
| quantization_config = TorchAoConfig(<span class="hljs-string">"int8wo"</span>) | |
| transformer = FluxTransformer2DModel.from_pretrained( | |
| <span class="hljs-string">"black-forest-labs/Flux.1-Dev"</span>, | |
| subfolder=<span class="hljs-string">"transformer"</span>, | |
| quantization_config=quantization_config, | |
| torch_dtype=torch.bfloat16, | |
| )`,wrap:!1}}),{c(){y=i("p"),y.textContent=L,x=n(),l(C.$$.fragment)},l(z){y=r(z,"P",{"data-svelte-h":!0}),h(y)!=="svelte-11lpom8"&&(y.textContent=L),x=o(z),u(C.$$.fragment,z)},m(z,M){_(z,y,M),_(z,x,M),f(C,z,M),k=!0},p:zo,i(z){k||(c(C.$$.fragment,z),k=!0)},o(z){p(C.$$.fragment,z),k=!1},d(z){z&&(s(y),s(x)),m(C,z)}}}function Ao(Ie){let y,L,x,C,k,z,M,Zn="Quantization techniques reduce memory and computational costs by representing weights and activations with lower-precision data types like 8-bit integers (int8). This enables loading larger models you normally wouldn’t be able to fit into memory, and speeding up inference.",mt,P,gt,ne,ht,Q,oe,Xt,Fe,Rn='Configuration class to be used when applying quantization on-the-fly to <a href="/docs/diffusers/pr_12403/en/api/pipelines/overview#diffusers.DiffusionPipeline.from_pretrained">from_pretrained()</a>.',_t,ie,bt,w,re,Yt,Ee,Wn=`This is a wrapper class about all possible attributes and features that you can play with a model that has been | |
| loaded using <code>bitsandbytes</code>.`,Ot,He,Sn="This replaces <code>load_in_8bit</code> or <code>load_in_4bit</code> therefore both options are mutually exclusive.",Kt,Ve,Xn=`Currently only supports <code>LLM.int8()</code>, <code>FP4</code>, and <code>NF4</code> quantization. If more methods are added to <code>bitsandbytes</code>, | |
| then more arguments will be added to this class.`,en,A,se,tn,Ue,Yn="Returns <code>True</code> if the model is quantizable, <code>False</code> otherwise.",nn,I,ae,on,Je,On="Safety checker that arguments are correct - also replaces some NoneType arguments with their default values.",rn,F,de,sn,Ne,Kn=`This method returns the quantization method used for the model. If the model is not quantizable, it returns | |
| <code>None</code>.`,an,E,le,dn,je,eo=`Removes all attributes from config which correspond to the default config attributes for better readability and | |
| serializes to a Python dictionary.`,vt,ue,yt,B,fe,ln,Ge,to="This is a config class for GGUF Quantization techniques.",$t,ce,wt,T,pe,un,Ze,no=`This is a wrapper class about all possible attributes and features that you can play with a model that has been | |
| loaded using <code>quanto</code>.`,fn,Re,oo=`modules_to_not_convert (<code>list</code>, <em>optional</em>, default to <code>None</code>): | |
| The list of modules to not quantize, useful for quantizing models that explicitly require to have some | |
| modules left in their original precision (e.g. Whisper encoder, Llava encoder, Mixtral gate layers).`,cn,H,me,pn,We,io="Safety checker that arguments are correct",zt,ge,qt,D,he,mn,Se,ro="This is a config class for torchao quantization/sparsity techniques.",gn,V,xt,_e,Ct,d,be,hn,Xe,so=`Abstract class of the HuggingFace quantizer. Supports for now quantizing HF diffusers models for inference and/or | |
| quantization. This class is used only for diffusers.models.modeling_utils.ModelMixin.from_pretrained and cannot be | |
| easily used outside the scope of that method yet.`,_n,Ye,ao=`Attributes | |
| quantization_config (<code>diffusers.quantizers.quantization_config.QuantizationConfigMixin</code>): | |
| The quantization config that defines the quantization parameters of your model that you want to quantize. | |
| modules_to_not_convert (<code>List[str]</code>, <em>optional</em>): | |
| The list of module names to not convert when quantizing the model. | |
| required_packages (<code>List[str]</code>, <em>optional</em>): | |
| The list of required pip packages to install prior to using the quantizer | |
| requires_calibration (<code>bool</code>): | |
| Whether the quantization method requires to calibrate the model before using it.`,bn,U,ve,vn,Oe,lo="adjust max_memory argument for infer_auto_device_map() if extra memory is needed for quantization",yn,J,ye,$n,Ke,uo=`Override this method if you want to adjust the <code>target_dtype</code> variable used in <code>from_pretrained</code> to compute the | |
| device_map in case the device_map is a <code>str</code>. E.g. for bitsandbytes we force-set <code>target_dtype</code> to <code>torch.int8</code> | |
| and for 4-bit we pass a custom enum <code>accelerate.CustomDtype.int4</code>.`,wn,N,$e,zn,et,fo=`checks if a loaded state_dict component is part of quantized param + some validation; only defined for | |
| quantization methods that require to create a new parameters for quantization.`,qn,j,we,xn,tt,co="checks if the quantized param has expected shape.",Cn,G,ze,Tn,nt,po="takes needed components from state_dict and creates quantized param.",kn,Z,qe,Mn,ot,mo=`Potentially dequantize the model to retrieve the original model, with some loss in accuracy / performance. Note | |
| not all quantization schemes support this.`,Dn,R,xe,Ln,it,go=`The factor to be used in <code>caching_allocator_warmup</code> to get the number of bytes to pre-allocate to warm up cuda. | |
| A factor of 2 means we allocate all bytes in the empty model (since we allocate in fp16), a factor of 4 means | |
| we allocate half the memory of the weights residing in the empty model, etc…`,Qn,W,Ce,Bn,rt,ho=`returns dtypes for modules that are not quantized - used for the computation of the device_map in case one | |
| passes a str as a device_map. The method will use the <code>modules_to_not_convert</code> that is modified in | |
| <code>_process_model_before_weight_loading</code>. <code>diffusers</code> models don’t have any <code>modules_to_not_convert</code> attributes | |
| yet but this can change soon in the future.`,Pn,S,Te,An,st,_o=`Post-process the model post weights loading. Make sure to override the abstract method | |
| <code>_process_model_after_weight_loading</code>.`,In,X,ke,Fn,at,bo=`Setting model attributes and/or converting model before weights loading. At this point the model should be | |
| initialized on the meta device so you can freely manipulate the skeleton of the model in order to replace | |
| modules in-place. Make sure to override the abstract method <code>_process_model_before_weight_loading</code>.`,En,Y,Me,Hn,dt,vo=`Override this method if you want to pass a override the existing device map with a new one. E.g. for | |
| bitsandbytes, since <code>accelerate</code> is a hard requirement, if no device_map is passed, the device_map is set to | |
| \`“auto”“`,Vn,O,De,Un,lt,yo="Override this method if you want to adjust the <code>missing_keys</code>.",Jn,K,Le,Nn,ut,$o=`Some quantization methods require to explicitly set the dtype of the model to a target dtype. You need to | |
| override this method in case you want to make sure that behavior is preserved`,jn,ee,Qe,Gn,ft,wo=`This method is used to potentially check for potential conflicts with arguments that are passed in | |
| <code>from_pretrained</code>. You need to define it for all future quantizers that are integrated with diffusers. If no | |
| explicit check are needed, simply return nothing.`,Tt,Be,kt,pt,Mt;return k=new Ae({props:{title:"Quantization",local:"quantization",headingTag:"h1"}}),P=new Mo({props:{$$slots:{default:[Bo]},$$scope:{ctx:Ie}}}),ne=new Ae({props:{title:"PipelineQuantizationConfig",local:"diffusers.PipelineQuantizationConfig",headingTag:"h2"}}),oe=new $({props:{name:"class diffusers.PipelineQuantizationConfig",anchor:"diffusers.PipelineQuantizationConfig",parameters:[{name:"quant_backend",val:": str = None"},{name:"quant_kwargs",val:": typing.Dict[str, typing.Union[str, float, int, dict]] = None"},{name:"components_to_quantize",val:": typing.Union[typing.List[str], str, NoneType] = None"},{name:"quant_mapping",val:": typing.Dict[str, typing.Union[diffusers.quantizers.quantization_config.QuantizationConfigMixin, ForwardRef('TransformersQuantConfigMixin')]] = None"}],parametersDescription:[{anchor:"diffusers.PipelineQuantizationConfig.quant_backend",description:`<strong>quant_backend</strong> (<code>str</code>) — Quantization backend to be used. When using this option, we assume that the backend | |
| is available to both <code>diffusers</code> and <code>transformers</code>.`,name:"quant_backend"},{anchor:"diffusers.PipelineQuantizationConfig.quant_kwargs",description:"<strong>quant_kwargs</strong> (<code>dict</code>) — Params to initialize the quantization backend class.",name:"quant_kwargs"},{anchor:"diffusers.PipelineQuantizationConfig.components_to_quantize",description:"<strong>components_to_quantize</strong> (<code>list</code>) — Components of a pipeline to be quantized.",name:"components_to_quantize"},{anchor:"diffusers.PipelineQuantizationConfig.quant_mapping",description:`<strong>quant_mapping</strong> (<code>dict</code>) — Mapping defining the quantization specs to be used for the pipeline | |
| components. When using this argument, users are not expected to provide <code>quant_backend</code>, <code>quant_kawargs</code>, | |
| and <code>components_to_quantize</code>.`,name:"quant_mapping"}],source:"https://github.com/huggingface/diffusers/blob/vr_12403/src/diffusers/quantizers/pipe_quant_config.py#L33"}}),ie=new Ae({props:{title:"BitsAndBytesConfig",local:"diffusers.BitsAndBytesConfig",headingTag:"h2"}}),re=new $({props:{name:"class diffusers.BitsAndBytesConfig",anchor:"diffusers.BitsAndBytesConfig",parameters:[{name:"load_in_8bit",val:" = False"},{name:"load_in_4bit",val:" = False"},{name:"llm_int8_threshold",val:" = 6.0"},{name:"llm_int8_skip_modules",val:" = None"},{name:"llm_int8_enable_fp32_cpu_offload",val:" = False"},{name:"llm_int8_has_fp16_weight",val:" = False"},{name:"bnb_4bit_compute_dtype",val:" = None"},{name:"bnb_4bit_quant_type",val:" = 'fp4'"},{name:"bnb_4bit_use_double_quant",val:" = False"},{name:"bnb_4bit_quant_storage",val:" = None"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"diffusers.BitsAndBytesConfig.load_in_8bit",description:`<strong>load_in_8bit</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) — | |
| This flag is used to enable 8-bit quantization with LLM.int8().`,name:"load_in_8bit"},{anchor:"diffusers.BitsAndBytesConfig.load_in_4bit",description:`<strong>load_in_4bit</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) — | |
| This flag is used to enable 4-bit quantization by replacing the Linear layers with FP4/NF4 layers from | |
| <code>bitsandbytes</code>.`,name:"load_in_4bit"},{anchor:"diffusers.BitsAndBytesConfig.llm_int8_threshold",description:`<strong>llm_int8_threshold</strong> (<code>float</code>, <em>optional</em>, defaults to 6.0) — | |
| This corresponds to the outlier threshold for outlier detection as described in <code>LLM.int8() : 8-bit Matrix Multiplication for Transformers at Scale</code> paper: <a href="https://huggingface.co/papers/2208.07339" rel="nofollow">https://huggingface.co/papers/2208.07339</a> Any hidden states | |
| value that is above this threshold will be considered an outlier and the operation on those values will be | |
| done in fp16. Values are usually normally distributed, that is, most values are in the range [-3.5, 3.5], | |
| but there are some exceptional systematic outliers that are very differently distributed for large models. | |
| These outliers are often in the interval [-60, -6] or [6, 60]. Int8 quantization works well for values of | |
| magnitude ~5, but beyond that, there is a significant performance penalty. A good default threshold is 6, | |
| but a lower threshold might be needed for more unstable models (small models, fine-tuning).`,name:"llm_int8_threshold"},{anchor:"diffusers.BitsAndBytesConfig.llm_int8_skip_modules",description:`<strong>llm_int8_skip_modules</strong> (<code>List[str]</code>, <em>optional</em>) — | |
| An explicit list of the modules that we do not want to convert in 8-bit. This is useful for models such as | |
| Jukebox that has several heads in different places and not necessarily at the last position. For example | |
| for <code>CausalLM</code> models, the last <code>lm_head</code> is typically kept in its original <code>dtype</code>.`,name:"llm_int8_skip_modules"},{anchor:"diffusers.BitsAndBytesConfig.llm_int8_enable_fp32_cpu_offload",description:`<strong>llm_int8_enable_fp32_cpu_offload</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) — | |
| This flag is used for advanced use cases and users that are aware of this feature. If you want to split | |
| your model in different parts and run some parts in int8 on GPU and some parts in fp32 on CPU, you can use | |
| this flag. This is useful for offloading large models such as <code>google/flan-t5-xxl</code>. Note that the int8 | |
| operations will not be run on CPU.`,name:"llm_int8_enable_fp32_cpu_offload"},{anchor:"diffusers.BitsAndBytesConfig.llm_int8_has_fp16_weight",description:`<strong>llm_int8_has_fp16_weight</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) — | |
| This flag runs LLM.int8() with 16-bit main weights. This is useful for fine-tuning as the weights do not | |
| have to be converted back and forth for the backward pass.`,name:"llm_int8_has_fp16_weight"},{anchor:"diffusers.BitsAndBytesConfig.bnb_4bit_compute_dtype",description:`<strong>bnb_4bit_compute_dtype</strong> (<code>torch.dtype</code> or str, <em>optional</em>, defaults to <code>torch.float32</code>) — | |
| This sets the computational type which might be different than the input type. For example, inputs might be | |
| fp32, but computation can be set to bf16 for speedups.`,name:"bnb_4bit_compute_dtype"},{anchor:"diffusers.BitsAndBytesConfig.bnb_4bit_quant_type",description:`<strong>bnb_4bit_quant_type</strong> (<code>str</code>, <em>optional</em>, defaults to <code>"fp4"</code>) — | |
| This sets the quantization data type in the bnb.nn.Linear4Bit layers. Options are FP4 and NF4 data types | |
| which are specified by <code>fp4</code> or <code>nf4</code>.`,name:"bnb_4bit_quant_type"},{anchor:"diffusers.BitsAndBytesConfig.bnb_4bit_use_double_quant",description:`<strong>bnb_4bit_use_double_quant</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) — | |
| This flag is used for nested quantization where the quantization constants from the first quantization are | |
| quantized again.`,name:"bnb_4bit_use_double_quant"},{anchor:"diffusers.BitsAndBytesConfig.bnb_4bit_quant_storage",description:`<strong>bnb_4bit_quant_storage</strong> (<code>torch.dtype</code> or str, <em>optional</em>, defaults to <code>torch.uint8</code>) — | |
| This sets the storage type to pack the quanitzed 4-bit prarams.`,name:"bnb_4bit_quant_storage"},{anchor:"diffusers.BitsAndBytesConfig.kwargs",description:`<strong>kwargs</strong> (<code>Dict[str, Any]</code>, <em>optional</em>) — | |
| Additional parameters from which to initialize the configuration object.`,name:"kwargs"}],source:"https://github.com/huggingface/diffusers/blob/vr_12403/src/diffusers/quantizers/quantization_config.py#L179"}}),se=new $({props:{name:"is_quantizable",anchor:"diffusers.BitsAndBytesConfig.is_quantizable",parameters:[],source:"https://github.com/huggingface/diffusers/blob/vr_12403/src/diffusers/quantizers/quantization_config.py#L358"}}),ae=new $({props:{name:"post_init",anchor:"diffusers.BitsAndBytesConfig.post_init",parameters:[],source:"https://github.com/huggingface/diffusers/blob/vr_12403/src/diffusers/quantizers/quantization_config.py#L321"}}),de=new $({props:{name:"quantization_method",anchor:"diffusers.BitsAndBytesConfig.quantization_method",parameters:[],source:"https://github.com/huggingface/diffusers/blob/vr_12403/src/diffusers/quantizers/quantization_config.py#L364"}}),le=new $({props:{name:"to_diff_dict",anchor:"diffusers.BitsAndBytesConfig.to_diff_dict",parameters:[],source:"https://github.com/huggingface/diffusers/blob/vr_12403/src/diffusers/quantizers/quantization_config.py#L395",returnDescription:`<script context="module">export const metadata = 'undefined';<\/script> | |
| <p>Dictionary of all the attributes that make up this configuration instance,</p> | |
| `,returnType:`<script context="module">export const metadata = 'undefined';<\/script> | |
| <p><code>Dict[str, Any]</code></p> | |
| `}}),ue=new Ae({props:{title:"GGUFQuantizationConfig",local:"diffusers.GGUFQuantizationConfig",headingTag:"h2"}}),fe=new $({props:{name:"class diffusers.GGUFQuantizationConfig",anchor:"diffusers.GGUFQuantizationConfig",parameters:[{name:"compute_dtype",val:": typing.Optional[ForwardRef('torch.dtype')] = None"}],parametersDescription:[{anchor:"diffusers.GGUFQuantizationConfig.compute_dtype",description:`<strong>compute_dtype</strong> — (<code>torch.dtype</code>, defaults to <code>torch.float32</code>): | |
| This sets the computational type which might be different than the input type. For example, inputs might be | |
| fp32, but computation can be set to bf16 for speedups.`,name:"compute_dtype"}],source:"https://github.com/huggingface/diffusers/blob/vr_12403/src/diffusers/quantizers/quantization_config.py#L419"}}),ce=new Ae({props:{title:"QuantoConfig",local:"diffusers.QuantoConfig",headingTag:"h2"}}),pe=new $({props:{name:"class diffusers.QuantoConfig",anchor:"diffusers.QuantoConfig",parameters:[{name:"weights_dtype",val:": str = 'int8'"},{name:"modules_to_not_convert",val:": typing.Optional[typing.List[str]] = None"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"diffusers.QuantoConfig.weights_dtype",description:`<strong>weights_dtype</strong> (<code>str</code>, <em>optional</em>, defaults to <code>"int8"</code>) — | |
| The target dtype for the weights after quantization. Supported values are (“float8”,“int8”,“int4”,“int2”)`,name:"weights_dtype"}],source:"https://github.com/huggingface/diffusers/blob/vr_12403/src/diffusers/quantizers/quantization_config.py#L709"}}),me=new $({props:{name:"post_init",anchor:"diffusers.QuantoConfig.post_init",parameters:[],source:"https://github.com/huggingface/diffusers/blob/vr_12403/src/diffusers/quantizers/quantization_config.py#L734"}}),ge=new Ae({props:{title:"TorchAoConfig",local:"diffusers.TorchAoConfig",headingTag:"h2"}}),he=new $({props:{name:"class diffusers.TorchAoConfig",anchor:"diffusers.TorchAoConfig",parameters:[{name:"quant_type",val:": str"},{name:"modules_to_not_convert",val:": typing.Optional[typing.List[str]] = None"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"diffusers.TorchAoConfig.quant_type",description:`<strong>quant_type</strong> (<code>str</code>) — | |
| The type of quantization we want to use, currently supporting:</p> | |
| <ul> | |
| <li> | |
| <p><strong>Integer quantization:</strong></p> | |
| <ul> | |
| <li>Full function names: <code>int4_weight_only</code>, <code>int8_dynamic_activation_int4_weight</code>, | |
| <code>int8_weight_only</code>, <code>int8_dynamic_activation_int8_weight</code></li> | |
| <li>Shorthands: <code>int4wo</code>, <code>int4dq</code>, <code>int8wo</code>, <code>int8dq</code></li> | |
| </ul> | |
| </li> | |
| <li> | |
| <p><strong>Floating point 8-bit quantization:</strong></p> | |
| <ul> | |
| <li>Full function names: <code>float8_weight_only</code>, <code>float8_dynamic_activation_float8_weight</code>, | |
| <code>float8_static_activation_float8_weight</code></li> | |
| <li>Shorthands: <code>float8wo</code>, <code>float8wo_e5m2</code>, <code>float8wo_e4m3</code>, <code>float8dq</code>, <code>float8dq_e4m3</code>, | |
| <code>float8_e4m3_tensor</code>, <code>float8_e4m3_row</code>,</li> | |
| </ul> | |
| </li> | |
| <li> | |
| <p><strong>Floating point X-bit quantization:</strong></p> | |
| <ul> | |
| <li>Full function names: <code>fpx_weight_only</code></li> | |
| <li>Shorthands: <code>fpX_eAwB</code>, where <code>X</code> is the number of bits (between <code>1</code> to <code>7</code>), <code>A</code> is the number | |
| of exponent bits and <code>B</code> is the number of mantissa bits. The constraint of <code>X == A + B + 1</code> must | |
| be satisfied for a given shorthand notation.</li> | |
| </ul> | |
| </li> | |
| <li> | |
| <p><strong>Unsigned Integer quantization:</strong></p> | |
| <ul> | |
| <li>Full function names: <code>uintx_weight_only</code></li> | |
| <li>Shorthands: <code>uint1wo</code>, <code>uint2wo</code>, <code>uint3wo</code>, <code>uint4wo</code>, <code>uint5wo</code>, <code>uint6wo</code>, <code>uint7wo</code></li> | |
| </ul> | |
| </li> | |
| </ul>`,name:"quant_type"},{anchor:"diffusers.TorchAoConfig.modules_to_not_convert",description:`<strong>modules_to_not_convert</strong> (<code>List[str]</code>, <em>optional</em>, default to <code>None</code>) — | |
| The list of modules to not quantize, useful for quantizing models that explicitly require to have some | |
| modules left in their original precision.`,name:"modules_to_not_convert"},{anchor:"diffusers.TorchAoConfig.kwargs",description:`<strong>kwargs</strong> (<code>Dict[str, Any]</code>, <em>optional</em>) — | |
| The keyword arguments for the chosen type of quantization, for example, int4_weight_only quantization | |
| supports two keyword arguments <code>group_size</code> and <code>inner_k_tiles</code> currently. More API examples and | |
| documentation of arguments can be found in | |
| <a href="https://github.com/pytorch/ao/tree/main/torchao/quantization#other-available-quantization-techniques" rel="nofollow">https://github.com/pytorch/ao/tree/main/torchao/quantization#other-available-quantization-techniques</a>`,name:"kwargs"}],source:"https://github.com/huggingface/diffusers/blob/vr_12403/src/diffusers/quantizers/quantization_config.py#L442"}}),V=new Lo({props:{anchor:"diffusers.TorchAoConfig.example",$$slots:{default:[Po]},$$scope:{ctx:Ie}}}),_e=new Ae({props:{title:"DiffusersQuantizer",local:"diffusers.DiffusersQuantizer",headingTag:"h2"}}),be=new $({props:{name:"class diffusers.DiffusersQuantizer",anchor:"diffusers.DiffusersQuantizer",parameters:[{name:"quantization_config",val:": QuantizationConfigMixin"},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/diffusers/blob/vr_12403/src/diffusers/quantizers/base.py#L34"}}),ve=new $({props:{name:"adjust_max_memory",anchor:"diffusers.DiffusersQuantizer.adjust_max_memory",parameters:[{name:"max_memory",val:": typing.Dict[str, typing.Union[int, str]]"}],source:"https://github.com/huggingface/diffusers/blob/vr_12403/src/diffusers/quantizers/base.py#L133"}}),ye=new $({props:{name:"adjust_target_dtype",anchor:"diffusers.DiffusersQuantizer.adjust_target_dtype",parameters:[{name:"torch_dtype",val:": torch.dtype"}],parametersDescription:[{anchor:"diffusers.DiffusersQuantizer.adjust_target_dtype.torch_dtype",description:`<strong>torch_dtype</strong> (<code>torch.dtype</code>, <em>optional</em>) — | |
| The torch_dtype that is used to compute the device_map.`,name:"torch_dtype"}],source:"https://github.com/huggingface/diffusers/blob/vr_12403/src/diffusers/quantizers/base.py#L91"}}),$e=new $({props:{name:"check_if_quantized_param",anchor:"diffusers.DiffusersQuantizer.check_if_quantized_param",parameters:[{name:"model",val:": ModelMixin"},{name:"param_value",val:": torch.Tensor"},{name:"param_name",val:": str"},{name:"state_dict",val:": typing.Dict[str, typing.Any]"},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/diffusers/blob/vr_12403/src/diffusers/quantizers/base.py#L137"}}),we=new $({props:{name:"check_quantized_param_shape",anchor:"diffusers.DiffusersQuantizer.check_quantized_param_shape",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/diffusers/blob/vr_12403/src/diffusers/quantizers/base.py#L157"}}),ze=new $({props:{name:"create_quantized_param",anchor:"diffusers.DiffusersQuantizer.create_quantized_param",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/diffusers/blob/vr_12403/src/diffusers/quantizers/base.py#L151"}}),qe=new $({props:{name:"dequantize",anchor:"diffusers.DiffusersQuantizer.dequantize",parameters:[{name:"model",val:""}],source:"https://github.com/huggingface/diffusers/blob/vr_12403/src/diffusers/quantizers/base.py#L200"}}),xe=new $({props:{name:"get_cuda_warm_up_factor",anchor:"diffusers.DiffusersQuantizer.get_cuda_warm_up_factor",parameters:[],source:"https://github.com/huggingface/diffusers/blob/vr_12403/src/diffusers/quantizers/base.py#L212"}}),Ce=new $({props:{name:"get_special_dtypes_update",anchor:"diffusers.DiffusersQuantizer.get_special_dtypes_update",parameters:[{name:"model",val:""},{name:"torch_dtype",val:": torch.dtype"}],parametersDescription:[{anchor:"diffusers.DiffusersQuantizer.get_special_dtypes_update.model",description:`<strong>model</strong> (<code>~diffusers.models.modeling_utils.ModelMixin</code>) — | |
| The model to quantize`,name:"model"},{anchor:"diffusers.DiffusersQuantizer.get_special_dtypes_update.torch_dtype",description:`<strong>torch_dtype</strong> (<code>torch.dtype</code>) — | |
| The dtype passed in <code>from_pretrained</code> method.`,name:"torch_dtype"}],source:"https://github.com/huggingface/diffusers/blob/vr_12403/src/diffusers/quantizers/base.py#L113"}}),Te=new $({props:{name:"postprocess_model",anchor:"diffusers.DiffusersQuantizer.postprocess_model",parameters:[{name:"model",val:": ModelMixin"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"diffusers.DiffusersQuantizer.postprocess_model.model",description:`<strong>model</strong> (<code>~diffusers.models.modeling_utils.ModelMixin</code>) — | |
| The model to quantize`,name:"model"},{anchor:"diffusers.DiffusersQuantizer.postprocess_model.kwargs",description:`<strong>kwargs</strong> (<code>dict</code>, <em>optional</em>) — | |
| The keyword arguments that are passed along <code>_process_model_after_weight_loading</code>.`,name:"kwargs"}],source:"https://github.com/huggingface/diffusers/blob/vr_12403/src/diffusers/quantizers/base.py#L187"}}),ke=new $({props:{name:"preprocess_model",anchor:"diffusers.DiffusersQuantizer.preprocess_model",parameters:[{name:"model",val:": ModelMixin"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"diffusers.DiffusersQuantizer.preprocess_model.model",description:`<strong>model</strong> (<code>~diffusers.models.modeling_utils.ModelMixin</code>) — | |
| The model to quantize`,name:"model"},{anchor:"diffusers.DiffusersQuantizer.preprocess_model.kwargs",description:`<strong>kwargs</strong> (<code>dict</code>, <em>optional</em>) — | |
| The keyword arguments that are passed along <code>_process_model_before_weight_loading</code>.`,name:"kwargs"}],source:"https://github.com/huggingface/diffusers/blob/vr_12403/src/diffusers/quantizers/base.py#L171"}}),Me=new $({props:{name:"update_device_map",anchor:"diffusers.DiffusersQuantizer.update_device_map",parameters:[{name:"device_map",val:": typing.Optional[typing.Dict[str, typing.Any]]"}],parametersDescription:[{anchor:"diffusers.DiffusersQuantizer.update_device_map.device_map",description:`<strong>device_map</strong> (<code>Union[dict, str]</code>, <em>optional</em>) — | |
| The device_map that is passed through the <code>from_pretrained</code> method.`,name:"device_map"}],source:"https://github.com/huggingface/diffusers/blob/vr_12403/src/diffusers/quantizers/base.py#L79"}}),De=new $({props:{name:"update_missing_keys",anchor:"diffusers.DiffusersQuantizer.update_missing_keys",parameters:[{name:"model",val:""},{name:"missing_keys",val:": typing.List[str]"},{name:"prefix",val:": str"}],parametersDescription:[{anchor:"diffusers.DiffusersQuantizer.update_missing_keys.missing_keys",description:`<strong>missing_keys</strong> (<code>List[str]</code>, <em>optional</em>) — | |
| The list of missing keys in the checkpoint compared to the state dict of the model`,name:"missing_keys"}],source:"https://github.com/huggingface/diffusers/blob/vr_12403/src/diffusers/quantizers/base.py#L103"}}),Le=new $({props:{name:"update_torch_dtype",anchor:"diffusers.DiffusersQuantizer.update_torch_dtype",parameters:[{name:"torch_dtype",val:": torch.dtype"}],parametersDescription:[{anchor:"diffusers.DiffusersQuantizer.update_torch_dtype.torch_dtype",description:`<strong>torch_dtype</strong> (<code>torch.dtype</code>) — | |
| The input dtype that is passed in <code>from_pretrained</code>`,name:"torch_dtype"}],source:"https://github.com/huggingface/diffusers/blob/vr_12403/src/diffusers/quantizers/base.py#L68"}}),Qe=new $({props:{name:"validate_environment",anchor:"diffusers.DiffusersQuantizer.validate_environment",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/diffusers/blob/vr_12403/src/diffusers/quantizers/base.py#L163"}}),Be=new Qo({props:{source:"https://github.com/huggingface/diffusers/blob/main/docs/source/en/api/quantization.md"}}),{c(){y=i("meta"),L=n(),x=i("p"),C=n(),l(k.$$.fragment),z=n(),M=i("p"),M.textContent=Zn,mt=n(),l(P.$$.fragment),gt=n(),l(ne.$$.fragment),ht=n(),Q=i("div"),l(oe.$$.fragment),Xt=n(),Fe=i("p"),Fe.innerHTML=Rn,_t=n(),l(ie.$$.fragment),bt=n(),w=i("div"),l(re.$$.fragment),Yt=n(),Ee=i("p"),Ee.innerHTML=Wn,Ot=n(),He=i("p"),He.innerHTML=Sn,Kt=n(),Ve=i("p"),Ve.innerHTML=Xn,en=n(),A=i("div"),l(se.$$.fragment),tn=n(),Ue=i("p"),Ue.innerHTML=Yn,nn=n(),I=i("div"),l(ae.$$.fragment),on=n(),Je=i("p"),Je.textContent=On,rn=n(),F=i("div"),l(de.$$.fragment),sn=n(),Ne=i("p"),Ne.innerHTML=Kn,an=n(),E=i("div"),l(le.$$.fragment),dn=n(),je=i("p"),je.textContent=eo,vt=n(),l(ue.$$.fragment),yt=n(),B=i("div"),l(fe.$$.fragment),ln=n(),Ge=i("p"),Ge.textContent=to,$t=n(),l(ce.$$.fragment),wt=n(),T=i("div"),l(pe.$$.fragment),un=n(),Ze=i("p"),Ze.innerHTML=no,fn=n(),Re=i("p"),Re.innerHTML=oo,cn=n(),H=i("div"),l(me.$$.fragment),pn=n(),We=i("p"),We.textContent=io,zt=n(),l(ge.$$.fragment),qt=n(),D=i("div"),l(he.$$.fragment),mn=n(),Se=i("p"),Se.textContent=ro,gn=n(),l(V.$$.fragment),xt=n(),l(_e.$$.fragment),Ct=n(),d=i("div"),l(be.$$.fragment),hn=n(),Xe=i("p"),Xe.textContent=so,_n=n(),Ye=i("p"),Ye.innerHTML=ao,bn=n(),U=i("div"),l(ve.$$.fragment),vn=n(),Oe=i("p"),Oe.textContent=lo,yn=n(),J=i("div"),l(ye.$$.fragment),$n=n(),Ke=i("p"),Ke.innerHTML=uo,wn=n(),N=i("div"),l($e.$$.fragment),zn=n(),et=i("p"),et.textContent=fo,qn=n(),j=i("div"),l(we.$$.fragment),xn=n(),tt=i("p"),tt.textContent=co,Cn=n(),G=i("div"),l(ze.$$.fragment),Tn=n(),nt=i("p"),nt.textContent=po,kn=n(),Z=i("div"),l(qe.$$.fragment),Mn=n(),ot=i("p"),ot.textContent=mo,Dn=n(),R=i("div"),l(xe.$$.fragment),Ln=n(),it=i("p"),it.innerHTML=go,Qn=n(),W=i("div"),l(Ce.$$.fragment),Bn=n(),rt=i("p"),rt.innerHTML=ho,Pn=n(),S=i("div"),l(Te.$$.fragment),An=n(),st=i("p"),st.innerHTML=_o,In=n(),X=i("div"),l(ke.$$.fragment),Fn=n(),at=i("p"),at.innerHTML=bo,En=n(),Y=i("div"),l(Me.$$.fragment),Hn=n(),dt=i("p"),dt.innerHTML=vo,Vn=n(),O=i("div"),l(De.$$.fragment),Un=n(),lt=i("p"),lt.innerHTML=yo,Jn=n(),K=i("div"),l(Le.$$.fragment),Nn=n(),ut=i("p"),ut.textContent=$o,jn=n(),ee=i("div"),l(Qe.$$.fragment),Gn=n(),ft=i("p"),ft.innerHTML=wo,Tt=n(),l(Be.$$.fragment),kt=n(),pt=i("p"),this.h()},l(e){const a=ko("svelte-u9bgzb",document.head);y=r(a,"META",{name:!0,content:!0}),a.forEach(s),L=o(e),x=r(e,"P",{}),b(x).forEach(s),C=o(e),u(k.$$.fragment,e),z=o(e),M=r(e,"P",{"data-svelte-h":!0}),h(M)!=="svelte-1balldr"&&(M.textContent=Zn),mt=o(e),u(P.$$.fragment,e),gt=o(e),u(ne.$$.fragment,e),ht=o(e),Q=r(e,"DIV",{class:!0});var Pe=b(Q);u(oe.$$.fragment,Pe),Xt=o(Pe),Fe=r(Pe,"P",{"data-svelte-h":!0}),h(Fe)!=="svelte-1cnjutk"&&(Fe.innerHTML=Rn),Pe.forEach(s),_t=o(e),u(ie.$$.fragment,e),bt=o(e),w=r(e,"DIV",{class:!0});var q=b(w);u(re.$$.fragment,q),Yt=o(q),Ee=r(q,"P",{"data-svelte-h":!0}),h(Ee)!=="svelte-woamwr"&&(Ee.innerHTML=Wn),Ot=o(q),He=r(q,"P",{"data-svelte-h":!0}),h(He)!=="svelte-izpi0w"&&(He.innerHTML=Sn),Kt=o(q),Ve=r(q,"P",{"data-svelte-h":!0}),h(Ve)!=="svelte-8qsk2q"&&(Ve.innerHTML=Xn),en=o(q),A=r(q,"DIV",{class:!0});var Dt=b(A);u(se.$$.fragment,Dt),tn=o(Dt),Ue=r(Dt,"P",{"data-svelte-h":!0}),h(Ue)!=="svelte-10tvzyv"&&(Ue.innerHTML=Yn),Dt.forEach(s),nn=o(q),I=r(q,"DIV",{class:!0});var Lt=b(I);u(ae.$$.fragment,Lt),on=o(Lt),Je=r(Lt,"P",{"data-svelte-h":!0}),h(Je)!=="svelte-gy26u4"&&(Je.textContent=On),Lt.forEach(s),rn=o(q),F=r(q,"DIV",{class:!0});var Qt=b(F);u(de.$$.fragment,Qt),sn=o(Qt),Ne=r(Qt,"P",{"data-svelte-h":!0}),h(Ne)!=="svelte-19bn0da"&&(Ne.innerHTML=Kn),Qt.forEach(s),an=o(q),E=r(q,"DIV",{class:!0});var Bt=b(E);u(le.$$.fragment,Bt),dn=o(Bt),je=r(Bt,"P",{"data-svelte-h":!0}),h(je)!=="svelte-1p6bdas"&&(je.textContent=eo),Bt.forEach(s),q.forEach(s),vt=o(e),u(ue.$$.fragment,e),yt=o(e),B=r(e,"DIV",{class:!0});var Pt=b(B);u(fe.$$.fragment,Pt),ln=o(Pt),Ge=r(Pt,"P",{"data-svelte-h":!0}),h(Ge)!=="svelte-1r606z3"&&(Ge.textContent=to),Pt.forEach(s),$t=o(e),u(ce.$$.fragment,e),wt=o(e),T=r(e,"DIV",{class:!0});var te=b(T);u(pe.$$.fragment,te),un=o(te),Ze=r(te,"P",{"data-svelte-h":!0}),h(Ze)!=="svelte-b8v0f"&&(Ze.innerHTML=no),fn=o(te),Re=r(te,"P",{"data-svelte-h":!0}),h(Re)!=="svelte-7hlgr"&&(Re.innerHTML=oo),cn=o(te),H=r(te,"DIV",{class:!0});var At=b(H);u(me.$$.fragment,At),pn=o(At),We=r(At,"P",{"data-svelte-h":!0}),h(We)!=="svelte-1ozftb6"&&(We.textContent=io),At.forEach(s),te.forEach(s),zt=o(e),u(ge.$$.fragment,e),qt=o(e),D=r(e,"DIV",{class:!0});var ct=b(D);u(he.$$.fragment,ct),mn=o(ct),Se=r(ct,"P",{"data-svelte-h":!0}),h(Se)!=="svelte-1pwo8e0"&&(Se.textContent=ro),gn=o(ct),u(V.$$.fragment,ct),ct.forEach(s),xt=o(e),u(_e.$$.fragment,e),Ct=o(e),d=r(e,"DIV",{class:!0});var g=b(d);u(be.$$.fragment,g),hn=o(g),Xe=r(g,"P",{"data-svelte-h":!0}),h(Xe)!=="svelte-n1gm3c"&&(Xe.textContent=so),_n=o(g),Ye=r(g,"P",{"data-svelte-h":!0}),h(Ye)!=="svelte-1fnduym"&&(Ye.innerHTML=ao),bn=o(g),U=r(g,"DIV",{class:!0});var It=b(U);u(ve.$$.fragment,It),vn=o(It),Oe=r(It,"P",{"data-svelte-h":!0}),h(Oe)!=="svelte-1d4i4z7"&&(Oe.textContent=lo),It.forEach(s),yn=o(g),J=r(g,"DIV",{class:!0});var Ft=b(J);u(ye.$$.fragment,Ft),$n=o(Ft),Ke=r(Ft,"P",{"data-svelte-h":!0}),h(Ke)!=="svelte-eyxa3y"&&(Ke.innerHTML=uo),Ft.forEach(s),wn=o(g),N=r(g,"DIV",{class:!0});var Et=b(N);u($e.$$.fragment,Et),zn=o(Et),et=r(Et,"P",{"data-svelte-h":!0}),h(et)!=="svelte-y0lxmf"&&(et.textContent=fo),Et.forEach(s),qn=o(g),j=r(g,"DIV",{class:!0});var Ht=b(j);u(we.$$.fragment,Ht),xn=o(Ht),tt=r(Ht,"P",{"data-svelte-h":!0}),h(tt)!=="svelte-1170ss6"&&(tt.textContent=co),Ht.forEach(s),Cn=o(g),G=r(g,"DIV",{class:!0});var Vt=b(G);u(ze.$$.fragment,Vt),Tn=o(Vt),nt=r(Vt,"P",{"data-svelte-h":!0}),h(nt)!=="svelte-odkanz"&&(nt.textContent=po),Vt.forEach(s),kn=o(g),Z=r(g,"DIV",{class:!0});var Ut=b(Z);u(qe.$$.fragment,Ut),Mn=o(Ut),ot=r(Ut,"P",{"data-svelte-h":!0}),h(ot)!=="svelte-upajm7"&&(ot.textContent=mo),Ut.forEach(s),Dn=o(g),R=r(g,"DIV",{class:!0});var Jt=b(R);u(xe.$$.fragment,Jt),Ln=o(Jt),it=r(Jt,"P",{"data-svelte-h":!0}),h(it)!=="svelte-72nwdx"&&(it.innerHTML=go),Jt.forEach(s),Qn=o(g),W=r(g,"DIV",{class:!0});var Nt=b(W);u(Ce.$$.fragment,Nt),Bn=o(Nt),rt=r(Nt,"P",{"data-svelte-h":!0}),h(rt)!=="svelte-1cb2fzf"&&(rt.innerHTML=ho),Nt.forEach(s),Pn=o(g),S=r(g,"DIV",{class:!0});var jt=b(S);u(Te.$$.fragment,jt),An=o(jt),st=r(jt,"P",{"data-svelte-h":!0}),h(st)!=="svelte-6rgq61"&&(st.innerHTML=_o),jt.forEach(s),In=o(g),X=r(g,"DIV",{class:!0});var Gt=b(X);u(ke.$$.fragment,Gt),Fn=o(Gt),at=r(Gt,"P",{"data-svelte-h":!0}),h(at)!=="svelte-wiwxpv"&&(at.innerHTML=bo),Gt.forEach(s),En=o(g),Y=r(g,"DIV",{class:!0});var Zt=b(Y);u(Me.$$.fragment,Zt),Hn=o(Zt),dt=r(Zt,"P",{"data-svelte-h":!0}),h(dt)!=="svelte-5g503h"&&(dt.innerHTML=vo),Zt.forEach(s),Vn=o(g),O=r(g,"DIV",{class:!0});var Rt=b(O);u(De.$$.fragment,Rt),Un=o(Rt),lt=r(Rt,"P",{"data-svelte-h":!0}),h(lt)!=="svelte-13hqoy0"&&(lt.innerHTML=yo),Rt.forEach(s),Jn=o(g),K=r(g,"DIV",{class:!0});var Wt=b(K);u(Le.$$.fragment,Wt),Nn=o(Wt),ut=r(Wt,"P",{"data-svelte-h":!0}),h(ut)!=="svelte-udr2k7"&&(ut.textContent=$o),Wt.forEach(s),jn=o(g),ee=r(g,"DIV",{class:!0});var St=b(ee);u(Qe.$$.fragment,St),Gn=o(St),ft=r(St,"P",{"data-svelte-h":!0}),h(ft)!=="svelte-1ra2q1u"&&(ft.innerHTML=wo),St.forEach(s),g.forEach(s),Tt=o(e),u(Be.$$.fragment,e),kt=o(e),pt=r(e,"P",{}),b(pt).forEach(s),this.h()},h(){v(y,"name","hf:doc:metadata"),v(y,"content",Io),v(Q,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),v(A,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),v(I,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),v(F,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),v(E,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),v(w,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),v(B,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),v(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(T,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),v(D,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),v(U,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),v(J,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),v(N,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),v(j,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),v(G,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),v(Z,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),v(R,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),v(W,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),v(S,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),v(X,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),v(Y,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),v(O,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),v(K,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),v(ee,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),v(d,"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,a){t(document.head,y),_(e,L,a),_(e,x,a),_(e,C,a),f(k,e,a),_(e,z,a),_(e,M,a),_(e,mt,a),f(P,e,a),_(e,gt,a),f(ne,e,a),_(e,ht,a),_(e,Q,a),f(oe,Q,null),t(Q,Xt),t(Q,Fe),_(e,_t,a),f(ie,e,a),_(e,bt,a),_(e,w,a),f(re,w,null),t(w,Yt),t(w,Ee),t(w,Ot),t(w,He),t(w,Kt),t(w,Ve),t(w,en),t(w,A),f(se,A,null),t(A,tn),t(A,Ue),t(w,nn),t(w,I),f(ae,I,null),t(I,on),t(I,Je),t(w,rn),t(w,F),f(de,F,null),t(F,sn),t(F,Ne),t(w,an),t(w,E),f(le,E,null),t(E,dn),t(E,je),_(e,vt,a),f(ue,e,a),_(e,yt,a),_(e,B,a),f(fe,B,null),t(B,ln),t(B,Ge),_(e,$t,a),f(ce,e,a),_(e,wt,a),_(e,T,a),f(pe,T,null),t(T,un),t(T,Ze),t(T,fn),t(T,Re),t(T,cn),t(T,H),f(me,H,null),t(H,pn),t(H,We),_(e,zt,a),f(ge,e,a),_(e,qt,a),_(e,D,a),f(he,D,null),t(D,mn),t(D,Se),t(D,gn),f(V,D,null),_(e,xt,a),f(_e,e,a),_(e,Ct,a),_(e,d,a),f(be,d,null),t(d,hn),t(d,Xe),t(d,_n),t(d,Ye),t(d,bn),t(d,U),f(ve,U,null),t(U,vn),t(U,Oe),t(d,yn),t(d,J),f(ye,J,null),t(J,$n),t(J,Ke),t(d,wn),t(d,N),f($e,N,null),t(N,zn),t(N,et),t(d,qn),t(d,j),f(we,j,null),t(j,xn),t(j,tt),t(d,Cn),t(d,G),f(ze,G,null),t(G,Tn),t(G,nt),t(d,kn),t(d,Z),f(qe,Z,null),t(Z,Mn),t(Z,ot),t(d,Dn),t(d,R),f(xe,R,null),t(R,Ln),t(R,it),t(d,Qn),t(d,W),f(Ce,W,null),t(W,Bn),t(W,rt),t(d,Pn),t(d,S),f(Te,S,null),t(S,An),t(S,st),t(d,In),t(d,X),f(ke,X,null),t(X,Fn),t(X,at),t(d,En),t(d,Y),f(Me,Y,null),t(Y,Hn),t(Y,dt),t(d,Vn),t(d,O),f(De,O,null),t(O,Un),t(O,lt),t(d,Jn),t(d,K),f(Le,K,null),t(K,Nn),t(K,ut),t(d,jn),t(d,ee),f(Qe,ee,null),t(ee,Gn),t(ee,ft),_(e,Tt,a),f(Be,e,a),_(e,kt,a),_(e,pt,a),Mt=!0},p(e,[a]){const Pe={};a&2&&(Pe.$$scope={dirty:a,ctx:e}),P.$set(Pe);const q={};a&2&&(q.$$scope={dirty:a,ctx:e}),V.$set(q)},i(e){Mt||(c(k.$$.fragment,e),c(P.$$.fragment,e),c(ne.$$.fragment,e),c(oe.$$.fragment,e),c(ie.$$.fragment,e),c(re.$$.fragment,e),c(se.$$.fragment,e),c(ae.$$.fragment,e),c(de.$$.fragment,e),c(le.$$.fragment,e),c(ue.$$.fragment,e),c(fe.$$.fragment,e),c(ce.$$.fragment,e),c(pe.$$.fragment,e),c(me.$$.fragment,e),c(ge.$$.fragment,e),c(he.$$.fragment,e),c(V.$$.fragment,e),c(_e.$$.fragment,e),c(be.$$.fragment,e),c(ve.$$.fragment,e),c(ye.$$.fragment,e),c($e.$$.fragment,e),c(we.$$.fragment,e),c(ze.$$.fragment,e),c(qe.$$.fragment,e),c(xe.$$.fragment,e),c(Ce.$$.fragment,e),c(Te.$$.fragment,e),c(ke.$$.fragment,e),c(Me.$$.fragment,e),c(De.$$.fragment,e),c(Le.$$.fragment,e),c(Qe.$$.fragment,e),c(Be.$$.fragment,e),Mt=!0)},o(e){p(k.$$.fragment,e),p(P.$$.fragment,e),p(ne.$$.fragment,e),p(oe.$$.fragment,e),p(ie.$$.fragment,e),p(re.$$.fragment,e),p(se.$$.fragment,e),p(ae.$$.fragment,e),p(de.$$.fragment,e),p(le.$$.fragment,e),p(ue.$$.fragment,e),p(fe.$$.fragment,e),p(ce.$$.fragment,e),p(pe.$$.fragment,e),p(me.$$.fragment,e),p(ge.$$.fragment,e),p(he.$$.fragment,e),p(V.$$.fragment,e),p(_e.$$.fragment,e),p(be.$$.fragment,e),p(ve.$$.fragment,e),p(ye.$$.fragment,e),p($e.$$.fragment,e),p(we.$$.fragment,e),p(ze.$$.fragment,e),p(qe.$$.fragment,e),p(xe.$$.fragment,e),p(Ce.$$.fragment,e),p(Te.$$.fragment,e),p(ke.$$.fragment,e),p(Me.$$.fragment,e),p(De.$$.fragment,e),p(Le.$$.fragment,e),p(Qe.$$.fragment,e),p(Be.$$.fragment,e),Mt=!1},d(e){e&&(s(L),s(x),s(C),s(z),s(M),s(mt),s(gt),s(ht),s(Q),s(_t),s(bt),s(w),s(vt),s(yt),s(B),s($t),s(wt),s(T),s(zt),s(qt),s(D),s(xt),s(Ct),s(d),s(Tt),s(kt),s(pt)),s(y),m(k,e),m(P,e),m(ne,e),m(oe),m(ie,e),m(re),m(se),m(ae),m(de),m(le),m(ue,e),m(fe),m(ce,e),m(pe),m(me),m(ge,e),m(he),m(V),m(_e,e),m(be),m(ve),m(ye),m($e),m(we),m(ze),m(qe),m(xe),m(Ce),m(Te),m(ke),m(Me),m(De),m(Le),m(Qe),m(Be,e)}}}const Io='{"title":"Quantization","local":"quantization","sections":[{"title":"PipelineQuantizationConfig","local":"diffusers.PipelineQuantizationConfig","sections":[],"depth":2},{"title":"BitsAndBytesConfig","local":"diffusers.BitsAndBytesConfig","sections":[],"depth":2},{"title":"GGUFQuantizationConfig","local":"diffusers.GGUFQuantizationConfig","sections":[],"depth":2},{"title":"QuantoConfig","local":"diffusers.QuantoConfig","sections":[],"depth":2},{"title":"TorchAoConfig","local":"diffusers.TorchAoConfig","sections":[],"depth":2},{"title":"DiffusersQuantizer","local":"diffusers.DiffusersQuantizer","sections":[],"depth":2}],"depth":1}';function Fo(Ie){return xo(()=>{new URLSearchParams(window.location.search).get("fw")}),[]}class Go extends Co{constructor(y){super(),To(this,y,Fo,Ao,qo,{})}}export{Go as component}; | |
Xet Storage Details
- Size:
- 44 kB
- Xet hash:
- ed2aa75280d6e90811c6b6541822382d75fa14a58101174a5cf48a406a42e613
·
Xet efficiently stores files, intelligently splitting them into unique chunks and accelerating uploads and downloads. More info.