Ë
    ÄÓ^j7U  ã                  óÚ   — d dl mZ d dlmZ d dlmZ d dlmZ d dlm	Z	 d dl
mZmZmZ g d¢ZdZd	Zd
ZdZdZdZdZdZdZe G d„ d«      «       Z G d„ d«      Z G d„ d«      Z G d„ d«      Zy)é    )Úannotations)Ú	dataclass)ÚAny)ÚQConfigMapping)ÚBackendConfig)Ú_get_quant_type_to_strÚ_quant_type_from_strÚ	QuantType)ÚConvertCustomConfigÚFuseCustomConfigÚPrepareCustomConfigÚStandaloneModuleConfigEntryÚstandalone_module_nameÚstandalone_module_classÚ%float_to_observed_custom_module_classÚ)observed_to_quantized_custom_module_classÚnon_traceable_module_nameÚnon_traceable_module_classÚinput_quantized_idxsÚoutput_quantized_idxsÚpreserved_attributesc                  ó6   — e Zd ZU ded<   ded<   ded<   ded<   y	)
r   úQConfigMapping | NoneÚqconfig_mappingútuple[Any, ...]Úexample_inputsúPrepareCustomConfig | NoneÚprepare_custom_configúBackendConfig | NoneÚbackend_configN)Ú__name__Ú
__module__Ú__qualname__Ú__annotations__© ó    úq/var/www/ramen.bs-engineer-server.com/venv/lib/python3.12/site-packages/torch/ao/quantization/fx/custom_config.pyr   r   $   s   … ð +Ó*Ø#Ó#Ø5Ó5Ø(Ô(r&   r   c                  óæ   — e Zd ZdZdd„Zd„ Z	 	 	 	 	 	 	 	 	 	 	 	 dd„Z	 	 	 	 	 	 	 	 	 	 	 	 dd„Zej                  f	 	 	 	 	 	 	 dd„Z
	 	 	 	 dd„Z	 	 	 	 dd„Zdd	„Zdd
„Zdd„Ze	 	 	 	 dd„«       Zdd„Zy)r   aœ  
    Custom configuration for :func:`~torch.ao.quantization.quantize_fx.prepare_fx` and
    :func:`~torch.ao.quantization.quantize_fx.prepare_qat_fx`.

    Example usage::

        prepare_custom_config = PrepareCustomConfig()             .set_standalone_module_name("module1", qconfig_mapping, example_inputs,                 child_prepare_custom_config, backend_config)             .set_standalone_module_class(MyStandaloneModule, qconfig_mapping, example_inputs,                 child_prepare_custom_config, backend_config)             .set_float_to_observed_mapping(FloatCustomModule, ObservedCustomModule)             .set_non_traceable_module_names(["module2", "module3"])             .set_non_traceable_module_classes([NonTraceableModule1, NonTraceableModule2])             .set_input_quantized_indexes([0])             .set_output_quantized_indexes([0])             .set_preserved_attributes(["attr1", "attr2"])
    c                ót   — i | _         i | _        i | _        g | _        g | _        g | _        g | _        g | _        y ©N)Ústandalone_module_namesÚstandalone_module_classesÚfloat_to_observed_mappingÚnon_traceable_module_namesÚnon_traceable_module_classesÚinput_quantized_indexesÚoutput_quantized_indexesr   ©Úselfs    r'   Ú__init__zPrepareCustomConfig.__init__B   sB   € ØOQˆÔ$ØRTˆÔ&ØLNˆÔ&Ø57ˆÔ'Ø8:ˆÔ)Ø24ˆÔ$Ø35ˆÔ%Ø/1ˆÕ!r&   c                ó’   — | j                   j                  «       D ��ci c]  \  }}t        |«      dkD  sŒ||“Œ }}}d|› d�S c c}}w )Nr   zPrepareCustomConfig(ú)©Ú__dict__ÚitemsÚlen©r3   ÚkÚvÚdict_nonemptys       r'   Ú__repr__zPrepareCustomConfig.__repr__L   óI   € Ø*.¯-©-×*=Ñ*=Ó*?×N¡$ ! QÄ3ÀqÃ6ÈAÃ:˜˜A™ÐNˆÑNØ% m _°AÐ6Ð6ùó Oó
   žAµAc                ó<   — t        ||||«      | j                  |<   | S )a|  
        Set the configuration for running a standalone module identified by ``module_name``.

        If ``qconfig_mapping`` is None, the parent ``qconfig_mapping`` will be used instead.
        If ``prepare_custom_config`` is None, an empty ``PrepareCustomConfig`` will be used.
        If ``backend_config`` is None, the parent ``backend_config`` will be used instead.
        )r   r+   )r3   Úmodule_namer   r   r   r    s         r'   Úset_standalone_module_namez.PrepareCustomConfig.set_standalone_module_nameP   s+   € ô 5PØ˜^Ð-BÀNó5
ˆ×$Ñ$ [Ñ1ð ˆr&   c                ó<   — t        ||||«      | j                  |<   | S )a}  
        Set the configuration for running a standalone module identified by ``module_class``.

        If ``qconfig_mapping`` is None, the parent ``qconfig_mapping`` will be used instead.
        If ``prepare_custom_config`` is None, an empty ``PrepareCustomConfig`` will be used.
        If ``backend_config`` is None, the parent ``backend_config`` will be used instead.
        )r   r,   )r3   Úmodule_classr   r   r   r    s         r'   Úset_standalone_module_classz/PrepareCustomConfig.set_standalone_module_classd   s+   € ô 8SØ˜^Ð-BÀNó8
ˆ×&Ñ& |Ñ4ð ˆr&   c                ó    — |t         j                  k7  rt        d«      ‚|| j                  vri | j                  |<   || j                  |   |<   | S )a5  
        Set the mapping from a custom float module class to a custom observed module class.

        The observed module class must have a ``from_float`` class method that converts the float module class
        to the observed module class. This is currently only supported for static quantization.
        zQset_float_to_observed_mapping is currently only supported for static quantization)r
   ÚSTATICÚ
ValueErrorr-   )r3   Úfloat_classÚobserved_classÚ
quant_types       r'   Úset_float_to_observed_mappingz1PrepareCustomConfig.set_float_to_observed_mappingx   s\   € ð œ×)Ñ)Ò)ÜØcóð ð ˜T×;Ñ;Ñ;Ø9;ˆD×*Ñ*¨:Ñ6ØBPˆ×&Ñ& zÑ2°;Ñ?Øˆr&   c                ó   — || _         | S )zZ
        Set the modules that are not symbolically traceable, identified by name.
        )r.   )r3   Úmodule_namess     r'   Úset_non_traceable_module_namesz2PrepareCustomConfig.set_non_traceable_module_names�   s   € ð +7ˆÔ'Øˆr&   c                ó   — || _         | S )z[
        Set the modules that are not symbolically traceable, identified by class.
        )r/   )r3   Úmodule_classess     r'   Ú set_non_traceable_module_classesz4PrepareCustomConfig.set_non_traceable_module_classes–   s   € ð -;ˆÔ)Øˆr&   c                ó   — || _         | S )z�
        Set the indexes of the inputs of the graph that should be quantized.
        Inputs are otherwise assumed to be in fp32 by default instead.
        )r0   ©r3   Úindexess     r'   Úset_input_quantized_indexesz/PrepareCustomConfig.set_input_quantized_indexesŸ   s   € ð
 (/ˆÔ$Øˆr&   c                ó   — || _         | S )zŸ
        Set the indexes of the outputs of the graph that should be quantized.
        Outputs are otherwise assumed to be in fp32 by default instead.
        )r1   rV   s     r'   Úset_output_quantized_indexesz0PrepareCustomConfig.set_output_quantized_indexes§   s   € ð
 )0ˆÔ%Øˆr&   c                ó   — || _         | S ©zœ
        Set the names of the attributes that will persist in the graph module even if they are not used in
        the model's ``forward`` method.
        ©r   ©r3   Ú
attributess     r'   Úset_preserved_attributesz,PrepareCustomConfig.set_preserved_attributes¯   ó   € ð
 %/ˆÔ!Øˆr&   c                óâ  — dd„}	 	 	 	 	 	 dd„}dd„} | «       }|j                  t        g «      D ]D  \  }}}}	}
 ||t        «      } ||	t        «      } ||
t        «      }|j                  |||||«       ŒF |j                  t        g «      D ]D  \  }}}}	}
 ||t        «      } ||	t        «      } ||
t        «      }|j	                  |||||«       ŒF |j                  t
        i «      j                  «       D ];  \  }}t        |«      }|j                  «       D ]  \  }}|j                  |||«       Œ Œ= |j                  |j                  t        g «      «       |j                  |j                  t        g «      «       |j                  |j                  t        g «      «       |j                  |j                  t         g «      «       |j#                  |j                  t$        g «      «       |S )a  
        Create a ``PrepareCustomConfig`` from a dictionary with the following items:

            "standalone_module_name": a list of (module_name, qconfig_mapping, example_inputs,
            child_prepare_custom_config, backend_config) tuples

            "standalone_module_class" a list of (module_class, qconfig_mapping, example_inputs,
            child_prepare_custom_config, backend_config) tuples

            "float_to_observed_custom_module_class": a nested dictionary mapping from quantization
            mode to an inner mapping from float module classes to observed module classes, e.g.
            {"static": {FloatCustomModule: ObservedCustomModule}}

            "non_traceable_module_name": a list of modules names that are not symbolically traceable
            "non_traceable_module_class": a list of module classes that are not symbolically traceable
            "input_quantized_idxs": a list of indexes of graph inputs that should be quantized
            "output_quantized_idxs": a list of indexes of graph outputs that should be quantized
            "preserved_attributes": a list of attributes that persist even if they are not used in ``forward``

        This function is primarily for backward compatibility and may be removed in the future.
        c                óª   — t        | t        «      s| €| S t        | t        «      rt        j                  | «      S t	        d|› dt        | «      › d�«      ‚)zn
            Convert the given object into a QConfigMapping if possible, else throw an exception.
            z7Expected QConfigMapping in prepare_custom_config_dict["ú	"], got 'ú')Ú
isinstancer   ÚdictÚ	from_dictrJ   Útype©ÚobjÚdict_keys     r'   Ú_get_qconfig_mappingz;PrepareCustomConfig.from_dict.<locals>._get_qconfig_mappingÒ   s[   € ô ˜#œ~Ô.°#°+Ø�
Ü˜#œtÔ$Ü%×/Ñ/°Ó4Ð4ÜØJÈ8È*ÐT^Ô_cÐdgÓ_hÐ^iÐijÐkóð r&   c                óª   — t        | t        «      s| €| S t        | t        «      rt        j                  | «      S t	        d|› dt        | «      › d�«      ‚)zs
            Convert the given object into a PrepareCustomConfig if possible, else throw an exception.
            z<Expected PrepareCustomConfig in prepare_custom_config_dict["rd   re   )rf   r   rg   rh   rJ   ri   rj   s     r'   Ú_get_prepare_custom_configzAPrepareCustomConfig.from_dict.<locals>._get_prepare_custom_configÞ   s]   € ô ˜#Ô2Ô3°s°{Ø�
Ü˜#œtÔ$Ü*×4Ñ4°SÓ9Ð9ÜØOÐPXÈzÐYcÔdhÐilÓdmÐcnÐnoÐpóð r&   c                óª   — t        | t        «      s| €| S t        | t        «      rt        j                  | «      S t	        d|› dt        | «      › d�«      ‚)zm
            Convert the given object into a BackendConfig if possible, else throw an exception.
            z6Expected BackendConfig in prepare_custom_config_dict["rd   re   )rf   r   rg   rh   rJ   ri   rj   s     r'   Ú_get_backend_configz:PrepareCustomConfig.from_dict.<locals>._get_backend_configì   s[   € ô ˜#œ}Ô-°°Ø�
Ü˜#œtÔ$Ü$×.Ñ.¨sÓ3Ð3ÜØIÈ(ÈÐS]Ô^bÐcfÓ^gÐ]hÐhiÐjóð r&   )rk   r   rl   ÚstrÚreturnr   )rk   r   rl   rr   rs   r   )rk   r   rl   rr   rs   r   )ÚgetÚSTANDALONE_MODULE_NAME_DICT_KEYrD   Ú STANDALONE_MODULE_CLASS_DICT_KEYrG   ÚFLOAT_TO_OBSERVED_DICT_KEYr9   r	   rN   rQ   Ú"NON_TRACEABLE_MODULE_NAME_DICT_KEYrT   Ú#NON_TRACEABLE_MODULE_CLASS_DICT_KEYrX   Ú INPUT_QUANTIZED_INDEXES_DICT_KEYrZ   Ú!OUTPUT_QUANTIZED_INDEXES_DICT_KEYr`   ÚPRESERVED_ATTRIBUTES_DICT_KEY)ÚclsÚprepare_custom_config_dictrm   ro   rq   ÚconfrC   Úqconfig_dictr   Ú_prepare_custom_config_dictÚbackend_config_dictr   r   r    rF   Úquant_type_nameÚcustom_module_mappingrM   rK   rL   s                       r'   rh   zPrepareCustomConfig.from_dict¸   sV  € ó4
	ð	Øð	Ø #ð	à'ó	ó
	ñ ‹uˆð (×+Ñ+Ô,KÈRÓPò	ñ 
ØØØØ'Øá2ØÔ=óˆOñ %?Ø+Ô-Ló%Ð!ñ 1Ø#Ô%DóˆNð ×+Ñ+ØØØØ%Øõð!	ð: (×+Ñ+Ô,LÈbÓQò	ñ 
ØØØØ'Øá2ØÔ>óˆOñ %?Ø+Ô-Mó%Ð!ñ 1Ø#Ô%EóˆNð ×,Ñ,ØØØØ%Øõð!	ð. 7Q×6TÑ6TÜ&¨ó7
ç
‰%‹'ò	Ñ2ˆOÐ2ô .¨oÓ>ˆJØ/D×/JÑ/JÓ/Lò Ñ+�˜^Ø×2Ñ2Ø °õñð		ð 	×+Ñ+Ø&×*Ñ*Ô+MÈrÓRô	
ð 	×-Ñ-Ø&×*Ñ*Ô+NÐPRÓSô	
ð 	×(Ñ(Ø&×*Ñ*Ô+KÈRÓPô	
ð 	×)Ñ)Ø&×*Ñ*Ô+LÈbÓQô	
ð 	×%Ñ%Ø&×*Ñ*Ô+HÈ"ÓMô	
ð ˆr&   c                ó˜  — dd„}i }| j                   j                  «       D ]5  \  }}t        |vr	g |t        <   |t           j                   |||«      «       Œ7 | j                  j                  «       D ]5  \  }}t
        |vr	g |t
        <   |t
           j                   |||«      «       Œ7 | j                  j                  «       D ]+  \  }}t        |vr	i |t        <   ||t           t        |«      <   Œ- t        | j                  «      dkD  r| j                  |t        <   t        | j                  «      dkD  r| j                  |t        <   t        | j                  «      dkD  r| j                  |t        <   t        | j                   «      dkD  r| j                   |t"        <   t        | j$                  «      dkD  r| j$                  |t&        <   |S )z¹
        Convert this ``PrepareCustomConfig`` to a dictionary with the items described in
        :func:`~torch.ao.quantization.fx.custom_config.PrepareCustomConfig.from_dict`.
        c                óØ   — |j                   r|j                   j                  «       nd }|j                  r|j                  j                  «       nd }| ||j                  ||j                  fS r*   )r   Úto_dictr   r   r    )ÚkeyÚer€   r~   s       r'   Ú_make_tuplez0PrepareCustomConfig.to_dict.<locals>._make_tupleF  sj   € Ø:;×:KÒ:K˜1×,Ñ,×4Ñ4Ô6ÐQUˆLà56×5LÒ5L�×'Ñ'×/Ñ/Ô1ÐRVð 'ð ØØ× Ñ Ø*Ø× Ñ ðð r&   r   )rˆ   r   r‰   r   )r+   r9   ru   Úappendr,   rv   r-   rw   r   r:   r.   rx   r/   ry   r0   rz   r1   r{   r   r|   )r3   rŠ   ÚdrC   Úsm_config_entryrF   rM   r-   s           r'   r‡   zPrepareCustomConfig.to_dict@  sÈ  € ó	ð ˆØ,0×,HÑ,H×,NÑ,NÓ,Pò 	Ñ(ˆK˜Ü.°aÑ7Ø57�Ô1Ñ2ØÔ-Ñ.×5Ñ5Ù˜K¨Ó9õð	ð .2×-KÑ-K×-QÑ-QÓ-Sò 	Ñ)ˆL˜/Ü/°qÑ8Ø68�Ô2Ñ3ØÔ.Ñ/×6Ñ6Ù˜L¨/Ó:õð	ð ×+Ñ+×1Ñ1Ó3ò	ñ 
ØØ%ä)°Ñ2Ø02�Ô,Ñ-à)ð Ô(Ñ)Ô*@ÀÓ*LÒMð	ô ˆt×.Ñ.Ó/°!Ò3Ø48×4SÑ4SˆAÔ0Ñ1Üˆt×0Ñ0Ó1°AÒ5Ø59×5VÑ5VˆAÔ1Ñ2Üˆt×+Ñ+Ó,¨qÒ0Ø26×2NÑ2NˆAÔ.Ñ/Üˆt×,Ñ,Ó-°Ò1Ø37×3PÑ3PˆAÔ/Ñ0Üˆt×(Ñ(Ó)¨AÒ-Ø/3×/HÑ/HˆAÔ+Ñ,Øˆr&   N©rs   ÚNone)rC   rr   r   r   r   r   r   r   r    r   rs   r   )rF   ri   r   r   r   r   r   r   r    r   rs   r   )rK   ri   rL   ri   rM   r
   rs   r   )rP   ú	list[str]rs   r   )rS   z
list[type]rs   r   )rW   z	list[int]rs   r   )r_   r�   rs   r   )r~   údict[str, Any]rs   r   ©rs   r‘   )r!   r"   r#   Ú__doc__r4   r?   rD   rG   r
   rI   rN   rQ   rT   rX   rZ   r`   Úclassmethodrh   r‡   r%   r&   r'   r   r   .   s,  „ ñó&2ò7ðàðð /ðð (ð	ð
  :ðð -ðð 
óð(àðð /ðð (ð	ð
  :ðð -ðð 
óð0 !*× 0Ñ 0ð	àðð ðð ð	ð
 
óð*Ø%ðà	óðØ(ðà	óóóóð ðEØ)7ðEà	òEó ðEôN3r&   r   c                  óv   — e Zd ZdZd	d„Zd„ Zej                  f	 	 	 	 	 	 	 d
d„Zdd„Z	e
	 	 	 	 dd„«       Zdd„Zy)r   a;  
    Custom configuration for :func:`~torch.ao.quantization.quantize_fx.convert_fx`.

    Example usage::

        convert_custom_config = ConvertCustomConfig()             .set_observed_to_quantized_mapping(ObservedCustomModule, QuantizedCustomModule)             .set_preserved_attributes(["attr1", "attr2"])
    c                ó    — i | _         g | _        y r*   )Úobserved_to_quantized_mappingr   r2   s    r'   r4   zConvertCustomConfig.__init__�  s   € ØPRˆÔ*Ø/1ˆÕ!r&   c                ó’   — | j                   j                  «       D ��ci c]  \  }}t        |«      dkD  sŒ||“Œ }}}d|› d�S c c}}w )Nr   zConvertCustomConfig(r6   r7   r;   s       r'   r?   zConvertCustomConfig.__repr__…  r@   rA   c                ód   — || j                   vri | j                   |<   || j                   |   |<   | S )a  
        Set the mapping from a custom observed module class to a custom quantized module class.

        The quantized module class must have a ``from_observed`` class method that converts the observed module class
        to the quantized module class.
        )r—   )r3   rL   Úquantized_classrM   s       r'   Ú!set_observed_to_quantized_mappingz5ConvertCustomConfig.set_observed_to_quantized_mapping‰  s<   € ð ˜T×?Ñ?Ñ?Ø=?ˆD×.Ñ.¨zÑ:ØIXˆ×*Ñ*¨:Ñ6°~ÑFØˆr&   c                ó   — || _         | S r\   r]   r^   s     r'   r`   z,ConvertCustomConfig.set_preserved_attributesš  ra   r&   c                ó"  —  | «       }|j                  t        i «      j                  «       D ];  \  }}t        |«      }|j                  «       D ]  \  }}|j	                  |||«       Œ Œ= |j                  |j                  t        g «      «       |S )aà  
        Create a ``ConvertCustomConfig`` from a dictionary with the following items:

            "observed_to_quantized_custom_module_class": a nested dictionary mapping from quantization
            mode to an inner mapping from observed module classes to quantized module classes, e.g.::
            {
            "static": {FloatCustomModule: ObservedCustomModule},
            "dynamic": {FloatCustomModule: ObservedCustomModule},
            "weight_only": {FloatCustomModule: ObservedCustomModule}
            }
            "preserved_attributes": a list of attributes that persist even if they are not used in ``forward``

        This function is primarily for backward compatibility and may be removed in the future.
        )rt   ÚOBSERVED_TO_QUANTIZED_DICT_KEYr9   r	   r›   r`   r|   )r}   Úconvert_custom_config_dictr   rƒ   r„   rM   rL   rš   s           r'   rh   zConvertCustomConfig.from_dict£  s�   € ñ$ ‹uˆØ6P×6TÑ6TÜ*¨Bó7
ç
‰%‹'ò	Ñ2ˆOÐ2ô .¨oÓ>ˆJØ3H×3NÑ3NÓ3Pò Ñ/� Ø×6Ñ6Ø" O°Zõñð		ð 	×%Ñ%Ø&×*Ñ*Ô+HÈ"ÓMô	
ð ˆr&   c                óð   — i }| j                   j                  «       D ]+  \  }}t        |vr	i |t        <   ||t           t        |«      <   Œ- t	        | j
                  «      dkD  r| j
                  |t        <   |S )z¹
        Convert this ``ConvertCustomConfig`` to a dictionary with the items described in
        :func:`~torch.ao.quantization.fx.custom_config.ConvertCustomConfig.from_dict`.
        r   )r—   r9   rž   r   r:   r   r|   )r3   rŒ   rM   r—   s       r'   r‡   zConvertCustomConfig.to_dictÃ  s‰   € ð
 ˆð ×/Ñ/×5Ñ5Ó7ò	ñ 
ØØ)ä-°QÑ6Ø46�Ô0Ñ1à-ð Ô,Ñ-Ô.DÀZÓ.PÒQð	ô ˆt×(Ñ(Ó)¨AÒ-Ø/3×/HÑ/HˆAÔ+Ñ,Øˆr&   NrŽ   )rL   ri   rš   ri   rM   r
   rs   r   )r_   r�   rs   r   )rŸ   r‘   rs   r   r’   )r!   r"   r#   r“   r4   r?   r
   rI   r›   r`   r”   rh   r‡   r%   r&   r'   r   r   v  su   „ ñó2ò7ð !*× 0Ñ 0ð	àðð ðð ð	ð
 
óó"ð ðØ)7ðà	òó ðô>r&   r   c                  ó@   — e Zd ZdZdd„Zd„ Zd	d„Zed
d„«       Zdd„Z	y)r   zß
    Custom configuration for :func:`~torch.ao.quantization.quantize_fx.fuse_fx`.

    Example usage::

        fuse_custom_config = FuseCustomConfig().set_preserved_attributes(
            ["attr1", "attr2"]
        )
    c                ó   — g | _         y r*   r]   r2   s    r'   r4   zFuseCustomConfig.__init__â  s
   € Ø/1ˆÕ!r&   c                ó’   — | j                   j                  «       D ��ci c]  \  }}t        |«      dkD  sŒ||“Œ }}}d|› d�S c c}}w )Nr   zFuseCustomConfig(r6   r7   r;   s       r'   r?   zFuseCustomConfig.__repr__å  sI   € Ø*.¯-©-×*=Ñ*=Ó*?×N¡$ ! QÄ3ÀqÃ6ÈAÃ:˜˜A™ÐNˆÑNØ" = /°Ð3Ð3ùó OrA   c                ó   — || _         | S r\   r]   r^   s     r'   r`   z)FuseCustomConfig.set_preserved_attributesé  ra   r&   c                ó^   —  | «       }|j                  |j                  t        g «      «       |S )a/  
        Create a ``ConvertCustomConfig`` from a dictionary with the following items:

            "preserved_attributes": a list of attributes that persist even if they are not used in ``forward``

        This function is primarily for backward compatibility and may be removed in the future.
        )r`   rt   r|   )r}   Úfuse_custom_config_dictr   s      r'   rh   zFuseCustomConfig.from_dictò  s1   € ñ ‹uˆØ×%Ñ%Ø#×'Ñ'Ô(EÀrÓJô	
ð ˆr&   c                ó`   — i }t        | j                  «      dkD  r| j                  |t        <   |S )z¶
        Convert this ``FuseCustomConfig`` to a dictionary with the items described in
        :func:`~torch.ao.quantization.fx.custom_config.ConvertCustomConfig.from_dict`.
        r   )r:   r   r|   )r3   rŒ   s     r'   r‡   zFuseCustomConfig.to_dict  s2   € ð
 ˆÜˆt×(Ñ(Ó)¨AÒ-Ø/3×/HÑ/HˆAÔ+Ñ,Øˆr&   NrŽ   )r_   r�   rs   r   )r¦   r‘   rs   r   r’   )
r!   r"   r#   r“   r4   r?   r`   r”   rh   r‡   r%   r&   r'   r   r   ×  s/   „ ñó2ò4óð òó ðôr&   r   N)Ú
__future__r   Údataclassesr   Útypingr   Útorch.ao.quantizationr   Ú$torch.ao.quantization.backend_configr   Ú torch.ao.quantization.quant_typer   r	   r
   Ú__all__ru   rv   rw   rž   rx   ry   rz   r{   r|   r   r   r   r   r%   r&   r'   ú<module>r¯      sš   ðå "å !Ý å 0Ý >÷ñ ò€ð #;Ð Ø#<Ð  ØDÐ Ø!LÐ Ø%@Ð "Ø&BÐ #Ø#9Ð  Ø$;Ð !Ø 6Ð ð ÷)ð )ó ð)÷Eñ E÷P
^ñ ^÷B2ò 2r&   