§
    ‚ŠtjV  ã                   ó’   — d Z ddlmZ ddlmZ ddlmZ ddlmZ  ed¬¦  «        e G d	„ d
ee¦  «        ¦   «         ¦   «         Z	d
gZ
dS )zBiT model configurationé    )Ústricté   )ÚBackboneConfigMixin)ÚPreTrainedConfig)Úauto_docstringzgoogle/bit-50)Ú
checkpointc                   óv  ‡ — e Zd ZU dZdZddgZg d¢ZdZee	d<   dZ
ee	d	<   d
Zee         eedf         z  e	d<   dZee         eedf         z  e	d<   dZee	d<   dZee	d<   dZedz  e	d<   dZee	d<   dZeez  e	d<   dZee	d<   dZee	d<   dZee	d<   dZee         dz  e	d<   dZee         dz  e	d<   ˆ fd„Zd „ Zˆ xZS )!Ú	BitConfiga&  
    layer_type (`str`, *optional*, defaults to `"preactivation"`):
        The layer to use, it can be either `"preactivation"` or `"bottleneck"`.
    global_padding (`str`, *optional*):
        Padding strategy to use for the convolutional layers. Can be either `"valid"`, `"same"`, or `None`.
    num_groups (`int`, *optional*, defaults to 32):
        Number of groups used for the `BitGroupNormActivation` layers.
    embedding_dynamic_padding (`bool`, *optional*, defaults to `False`):
        Whether or not to make use of dynamic padding for the embedding layer.
    width_factor (`int`, *optional*, defaults to 1):
        The width factor for the model.

    Example:
    ```python
    >>> from transformers import BitConfig, BitModel

    >>> # Initializing a BiT bit-50 style configuration
    >>> configuration = BitConfig()

    >>> # Initializing a model (with random weights) from the bit-50 style configuration
    >>> model = BitModel(configuration)

    >>> # Accessing the model configuration
    >>> configuration = model.config
    ```
    ÚbitÚpreactivationÚ
bottleneck)NÚSAMEÚVALIDr   Únum_channelsé@   Úembedding_size)é   i   i   i   .Úhidden_sizes)r   é   é   r   ÚdepthsÚ
layer_typeÚreluÚ
hidden_actNÚglobal_paddingé    Ú
num_groupsg        Údrop_path_rateFÚembedding_dynamic_paddingÚoutput_strideé   Úwidth_factorÚ_out_featuresÚ_out_indicesc                 óÖ  •— t          | j        ¦  «        | _        t          | j        ¦  «        | _        | j        �| j                             ¦   «         | _        dgd„ t          dt          | j        ¦  «        dz   ¦  «        D ¦   «         z   | _        |                      | 	                    dd ¦  «        | 	                    dd ¦  «        ¬¦  «          t          ¦   «         j        di |¤Ž d S )NÚstemc                 ó   — g | ]}d |› �‘ŒS )Ústage© )Ú.0Úidxs     úg/var/www/html/CA-Chatbot/venv/lib/python3.11/site-packages/transformers/models/bit/configuration_bit.pyú
<listcomp>z+BitConfig.__post_init__.<locals>.<listcomp>O   s   € Ð&_Ð&_Ð&_¸ }¨s } }Ð&_Ð&_Ð&_ó    r!   Úout_indicesÚout_features)r/   r0   r)   )Úlistr   r   r   ÚupperÚrangeÚlenÚstage_namesÚ"set_output_features_output_indicesÚpopÚsuperÚ__post_init__)ÚselfÚkwargsÚ	__class__s     €r,   r9   zBitConfig.__post_init__H   sä   ø€ Ý  Ô!2Ñ3Ô3ˆÔÝ˜4œ;Ñ'Ô'ˆŒàÔÐ*Ø"&Ô"5×";Ò";Ñ"=Ô"=ˆDÔà"˜8Ð&_Ð&_ÅÀaÍÈTÌ[ÑIYÔIYÐ\]ÑI]Ñ@^Ô@^Ð&_Ñ&_Ô&_Ñ_ˆÔØ×/Ò/ØŸ
š
 =°$Ñ7Ô7ÀfÇjÂjÐQ_ÐaeÑFfÔFfð 	0ñ 	
ô 	
ð 	
ð 	�‰ŒÔÐ'Ð' Ð'Ð'Ð'Ð'Ð'r.   c                 óÒ   — | j         | j        vr2t          d| j         › dd                     | j        ¦  «        › �¦  «        ‚| j        | j        vrt          d| j        › d�¦  «        ‚dS )zOPart of `@strict`-powered validation. Validates the architecture of the config.zlayer_type=z is not one of ú,zPadding strategy z not supportedN)r   Úlayer_typesÚ
ValueErrorÚjoinr   Úsupported_padding)r:   s    r,   Úvalidate_architecturezBitConfig.validate_architectureV   sy   € àŒ? $Ô"2Ð2Ð2ÝÐg¨4¬?ÐgÐgÈ3Ï8Ê8ÐTXÔTdÑKeÔKeÐgÐgÑhÔhÐhàÔ dÔ&<Ð<Ð<ÝÐT°Ô1DÐTÐTÐTÑUÔUÐUð =Ð<r.   )Ú__name__Ú
__module__Ú__qualname__Ú__doc__Ú
model_typer?   rB   r   ÚintÚ__annotations__r   r   r1   Útupler   r   Ústrr   r   r   r   Úfloatr   Úboolr    r"   r#   r$   r9   rC   Ú__classcell__)r<   s   @r,   r
   r
      s”  ø€ € € € € € ðð ð6 €JØ" LÐ1€KØ/Ð/Ð/Ðà€L�#ÐÐÑØ€N�CÐÐÑØ0F€L�$�s”)˜e C¨ HœoÑ-ÐFÐFÑFØ*6€FˆD�ŒI˜˜c 3˜hœÑ'Ð6Ð6Ñ6Ø%€J�Ð%Ð%Ñ%Ø€J�ÐÐÑØ!%€N�C˜$‘JÐ%Ð%Ñ%Ø€J�ÐÐÑØ"%€N�E˜C‘KÐ%Ð%Ñ%Ø&+Ð˜tÐ+Ð+Ñ+Ø€M�3ÐÐÑØ€L�#ÐÐÑØ&*€M�4˜”9˜tÑ#Ð*Ð*Ñ*Ø%)€L�$�s”)˜dÑ"Ð)Ð)Ñ)ð(ð (ð (ð (ð (ðVð Vð Vð Vð Vð Vð Vr.   r
   N)rG   Úhuggingface_hub.dataclassesr   Úbackbone_utilsr   Úconfiguration_utilsr   Úutilsr   r
   Ú__all__r)   r.   r,   ú<module>rU      sÅ   ðð Ð à .Ð .Ð .Ð .Ð .Ð .à 1Ð 1Ð 1Ð 1Ð 1Ð 1Ø 3Ð 3Ð 3Ð 3Ð 3Ð 3Ø #Ð #Ð #Ð #Ð #Ð #ð €˜?Ð+Ñ+Ô+ØðCVð CVð CVð CVð CVÐ#Ð%5ñ CVô CVñ „ñ ,Ô+ðCVðL ˆ-€€€r.   