§
    ‚Štjþ  ã                   ó„   — d Z ddlmZ ddlmZ ddlmZ  ed¬¦  «        e G d„ d	e¦  «        ¦   «         ¦   «         Zd	gZd
S )zUDOP model configurationé    )Ústricté   )ÚPreTrainedConfig)Úauto_docstringzmicrosoft/udop-large)Ú
checkpointc                   ó*  ‡ — e Zd ZU dZdZdgZddddœZ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d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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dz  e	d$<   d%Zeee         z  dz  e	d&<   d
Z ee	d'<   d(Z!eee         z  e"eef         z  e	d)<   dZ#eee         z  e"eef         z  e	d*<   d+Z$ee	d,<   d-Z%ee	d.<   d-Z&ee	d/<   d Z'ee	d0<   ˆ fd1„Z(d2„ Z)ˆ xZ*S )3Ú
UdopConfiga“  
    relative_attention_num_buckets (`int`, *optional*, defaults to 32):
        The number of buckets to use for each attention layer.
    relative_attention_max_distance (`int`, *optional*, defaults to 128):
        The maximum distance of the longer sequences for the bucket separation.
    relative_bias_args (`list[dict]`, *optional*, defaults to `[{'type': '1d'}, {'type': 'horizontal'}, {'type': 'vertical'}]`):
        A list of dictionaries containing the arguments for the relative bias layers.
    feed_forward_proj (`string`, *optional*, defaults to `"relu"`):
        Type of feed forward layer to be used. Should be one of `"relu"` or `"gated-gelu"`. Udopv1.1 uses the
        `"gated-gelu"` feed forward projection. Original Udop uses `"relu"`.
    max_2d_position_embeddings (`int`, *optional*, defaults to 1024):
        The maximum absolute position embeddings for relative position encoding.
    ÚudopÚpast_key_valuesÚd_modelÚ	num_headsÚ
num_layers)Úhidden_sizeÚnum_attention_headsÚnum_hidden_layersi±�  Ú
vocab_sizei   é@   Úd_kvi   Úd_ffé   NÚnum_decoder_layersé   é    Úrelative_attention_num_bucketsé€   Úrelative_attention_max_distanceÚrelative_bias_argsgš™™™™™¹?Údropout_rateg�íµ ÷Æ°>Úlayer_norm_epsilong      ð?Úinitializer_factorÚreluÚfeed_forward_projTÚis_encoder_decoderÚ	use_cacher   Úpad_token_idé   Úeos_token_idÚmax_2d_position_embeddingséà   Ú
image_sizeÚ
patch_sizer   Únum_channelsFÚ
is_decoderÚadd_cross_attentionÚtie_word_embeddingsc                 óF  •— | j         €ddiddiddig| _         | j        �| j        n| j        | _        | j                             d¦  «        }|d         | _        |d         dk    | _        |                     d	d ¦  «         d
| _         t          ¦   «         j
        di |¤Ž d S )NÚtypeÚ1dÚ
horizontalÚverticalú-éÿÿÿÿr   Úgatedr/   T© )r   r   r   r"   ÚsplitÚdense_act_fnÚis_gated_actÚpopr/   ÚsuperÚ__post_init__)ÚselfÚkwargsÚact_infoÚ	__class__s      €úi/var/www/html/CA-Chatbot/venv/lib/python3.11/site-packages/transformers/models/udop/configuration_udop.pyr>   zUdopConfig.__post_init__E   sÁ   ø€ ØÔ"Ð*Ø(.° ~¸ÀÐ7MÐPVÐXbÐOcÐ&dˆDÔ#ð (,Ô'>Ð'JˆDÔ#Ð#ÐPTÔP_ð 	Ôð Ô)×/Ò/°Ñ4Ô4ˆØ$ RœLˆÔØ$ QœK¨7Ò2ˆÔà�
Š
Ð(¨$Ñ/Ô/Ð/Ø#'ˆÔ Ø�‰ŒÔÐ'Ð' Ð'Ð'Ð'Ð'Ð'ó    c                 óÎ   — | j                              d¦  «        }t          |¦  «        dk    r|d         dk    st          |¦  «        dk    rt          d| j         › d�¦  «        ‚dS )	zOPart of `@strict`-powered validation. Validates the architecture of the config.r5   r&   r   r7   é   z`feed_forward_proj`: z¨ is not a valid activation function of the dense layer.Please make sure `feed_forward_proj` is of the format `gated-{ACT_FN}` or `{ACT_FN}`, e.g. 'gated-gelu' or 'relu'N)r"   r9   ÚlenÚ
ValueError)r?   rA   s     rC   Úvalidate_architecturez UdopConfig.validate_architectureU   s{   € àÔ)×/Ò/°Ñ4Ô4ˆÝˆx‰=Œ=˜1ÒÐ ¨!¤°Ò!7Ð!7½3¸x¹=¼=È1Ò;LÐ;LÝð)¨Ô(>ð )ð )ð )ñô ð ð <MÐ;LrD   )+Ú__name__Ú
__module__Ú__qualname__Ú__doc__Ú
model_typeÚkeys_to_ignore_at_inferenceÚattribute_mapr   ÚintÚ__annotations__r   r   r   r   r   r   r   r   r   ÚlistÚdictr   Úfloatr   r    r"   Ústrr#   Úboolr$   r%   r'   r(   r*   Útupler+   r,   r-   r.   r/   r>   rI   Ú__classcell__)rB   s   @rC   r	   r	      sW  ø€ € € € € € ðð ð €JØ#4Ð"5ÐØ$-ÀkÐhtÐuÐu€Mà€J�ÐÐÑØ€GˆSÐÐÑØ€Dˆ#€N€N�NØ€Dˆ#ÐÐÑØ€J�ÐÐÑØ%)Ð˜˜d™
Ð)Ð)Ñ)Ø€IˆsÐÐÑØ*,Ð" CÐ,Ð,Ñ,Ø+.Ð# SÐ.Ð.Ñ.Ø,0Ð˜˜Tœ
 TÑ)Ð0Ð0Ñ0Ø #€L�%˜#‘+Ð#Ð#Ñ#Ø $Ð˜Ð$Ð$Ñ$Ø #Ð˜Ð#Ð#Ñ#Ø#Ð�sÐ#Ð#Ñ#Ø#Ð˜Ð#Ð#Ñ#Ø€IˆtÐÐÑØ €L�#˜‘*Ð Ð Ñ Ø+,€L�#˜˜Sœ	‘/ DÑ(Ð,Ð,Ñ,Ø&*Ð Ð*Ð*Ñ*Ø47€J��d˜3”i‘ %¨¨S¨¤/Ñ1Ð7Ð7Ñ7Ø46€J��d˜3”i‘ %¨¨S¨¤/Ñ1Ð6Ð6Ñ6Ø€L�#ÐÐÑØ€J�ÐÐÑØ %Ð˜Ð%Ð%Ñ%Ø $Ð˜Ð$Ð$Ñ$ð(ð (ð (ð (ð (ð ð ð ð ð ð ð rD   r	   N)	rM   Úhuggingface_hub.dataclassesr   Úconfiguration_utilsr   Úutilsr   r	   Ú__all__r8   rD   rC   ú<module>r^      s©   ðð Ð à .Ð .Ð .Ð .Ð .Ð .à 3Ð 3Ð 3Ð 3Ð 3Ð 3Ø #Ð #Ð #Ð #Ð #Ð #ð €Ð1Ð2Ñ2Ô2ØðEð Eð Eð Eð EÐ!ñ Eô Eñ „ñ 3Ô2ðEðP ˆ.€€€rD   