§
    ‚Štjä  ã                   ó�   — d dl mZ ddlmZ ddlmZ ddlmZmZ  ed¬¦  «        e G d	„ d
e¦  «        ¦   «         ¦   «         Z	d
gZ
dS )é    )Ústricté   )ÚPreTrainedConfig)Úauto_docstringé   )ÚCONFIG_MAPPINGÚ
AutoConfigz%magic-leap-community/superglue_indoor)Ú
checkpointc                   óø   ‡ — e Zd ZU dZdZdeiZdZee	z  dz  e
d<   dZee
d<   dZee         dz  e
d<   dZee         dz  e
d<   d	Zee
d
<   dZee
d<   dZee
d<   dZee
d<   dZee
d<   dZeez  e
d<   ˆ fd„Zd„ Zˆ xZS )ÚSuperGlueConfigaÝ  
    keypoint_detector_config (`Union[AutoConfig, dict]`,  *optional*, defaults to `SuperPointConfig`):
        The config object or dictionary of the keypoint detector.
    keypoint_encoder_sizes (`list[int]`, *optional*, defaults to `[32, 64, 128, 256]`):
        The sizes of the keypoint encoder layers.
    gnn_layers_types (`list[str]`, *optional*, defaults to `['self', 'cross', 'self', 'cross', 'self', 'cross', 'self', 'cross', 'self', 'cross', 'self', 'cross', 'self', 'cross', 'self', 'cross', 'self', 'cross']`):
        The types of the GNN layers. Must be either 'self' or 'cross'.
    sinkhorn_iterations (`int`, *optional*, defaults to 100):
        The number of Sinkhorn iterations.
    matching_threshold (`float`, *optional*, defaults to 0.0):
        The matching threshold.

    Examples:
        ```python
        >>> from transformers import SuperGlueConfig, SuperGlueModel

        >>> # Initializing a SuperGlue superglue style configuration
        >>> configuration = SuperGlueConfig()

        >>> # Initializing a model from the superglue style configuration
        >>> model = SuperGlueModel(configuration)

        >>> # Accessing the model configuration
        >>> configuration = model.config
        ```
    Ú	superglueÚkeypoint_detector_configNé   Úhidden_sizeÚkeypoint_encoder_sizesÚgnn_layers_typesé   Únum_attention_headséd   Úsinkhorn_iterationsg        Úmatching_thresholdg{®Gáz”?Úinitializer_rangeFÚ
is_decoderÚattention_probs_dropout_probc                 ó¦  •— | j         �| j         nddgdz  | _         | j        �| j        ng d¢| _        t          | j        t          ¦  «        rK| j                             dd¦  «        | j        d<   t          | j        d                  di | j        ¤Ž| _        n | j        €t          d         ¦   «         | _         t          ¦   «         j        di |¤Ž d S )NÚselfÚcrossé	   )é    é@   é€   r   Ú
model_typeÚ
superpoint© )	r   r   Ú
isinstancer   ÚdictÚgetr   ÚsuperÚ__post_init__)r   ÚkwargsÚ	__class__s     €ús/var/www/html/CA-Chatbot/venv/lib/python3.11/site-packages/transformers/models/superglue/configuration_superglue.pyr)   zSuperGlueConfig.__post_init__B   sø   ø€ Ø9=Ô9NÐ9Z Ô 5Ð 5ÐagÐipÐ`qÐtuÑ`uˆÔà+/Ô+FÐ+RˆDÔ'Ð'ÐXjÐXjÐXjð 	Ô#õ �dÔ3µTÑ:Ô:ð 	KØ:>Ô:W×:[Ò:[Ð\hÐjvÑ:wÔ:wˆDÔ)¨,Ñ7Ý,:¸4Ô;XÐYeÔ;fÔ,gð -ð -ØÔ/ð-ð -ˆDÔ)Ð)ð Ô*Ð2Ý,:¸<Ô,HÑ,JÔ,JˆDÔ)à�‰ŒÔÐ'Ð' Ð'Ð'Ð'Ð'Ð'ó    c                 ó¤   — t          d„ | j        D ¦   «         ¦  «        st          d¦  «        ‚| j        | j        z  dk    rt          d¦  «        ‚dS )zOPart of `@strict`-powered validation. Validates the architecture of the config.c              3   ó   K  — | ]}|d v V — Œ	dS ))r   r   Nr$   )Ú.0Ú
layer_types     r,   ú	<genexpr>z8SuperGlueConfig.validate_architecture.<locals>.<genexpr>U   s(   è è € Ð[Ð[°z�:Ð!2Ð2Ð[Ð[Ð[Ð[Ð[Ð[r-   z5All gnn_layers_types must be either 'self' or 'cross'r   z8hidden_size % num_attention_heads is different from zeroN)Úallr   Ú
ValueErrorr   r   )r   s    r,   Úvalidate_architecturez%SuperGlueConfig.validate_architectureR   sc   € õ Ð[Ð[ÀTÔEZÐ[Ñ[Ô[Ñ[Ô[ð 	VÝÐTÑUÔUÐUàÔ˜dÔ6Ñ6¸!Ò;Ð;ÝÐWÑXÔXÐXð <Ð;r-   )Ú__name__Ú
__module__Ú__qualname__Ú__doc__r"   r	   Úsub_configsr   r&   r   Ú__annotations__r   Úintr   Úlistr   Ústrr   r   r   Úfloatr   r   Úboolr   r)   r5   Ú__classcell__)r+   s   @r,   r   r      s4  ø€ € € € € € ðð ð6 €JØ-¨zÐ:€Kà?CÐ˜dÐ%5Ñ5¸Ñ<ÐCÐCÑCØ€K�ÐÐÑØ/3Ð˜D œI¨Ñ,Ð3Ð3Ñ3Ø)-Ð�d˜3”i $Ñ&Ð-Ð-Ñ-Ø Ð˜Ð Ð Ñ Ø"Ð˜Ð"Ð"Ñ"Ø #Ð˜Ð#Ð#Ñ#Ø#Ð�uÐ#Ð#Ñ#Ø€J�ÐÐÑØ03Ð  #¨¡+Ð3Ð3Ñ3ð(ð (ð (ð (ð (ð Yð Yð Yð Yð Yð Yð Yr-   r   N)Úhuggingface_hub.dataclassesr   Úconfiguration_utilsr   Úutilsr   Úautor   r	   r   Ú__all__r$   r-   r,   ú<module>rG      sÅ   ðð /Ð .Ð .Ð .Ð .Ð .à 3Ð 3Ð 3Ð 3Ð 3Ð 3Ø #Ð #Ð #Ð #Ð #Ð #Ø -Ð -Ð -Ð -Ð -Ð -Ð -Ð -ð €ÐBÐCÑCÔCØðAYð AYð AYð AYð AYÐ&ñ AYô AYñ „ñ DÔCðAYðH Ð
€€€r-   