ó
    qyüiþ  ã                   ód   • S r SSKJr  SSKJr  SSKJr  \" SS9\ " S S	\5      5       5       rS	/rg
)zUDOP model configurationé    )Ústricté   )ÚPreTrainedConfig)Úauto_docstringzmicrosoft/udop-large)Ú
checkpointc                   ó  ^ • \ rS rSr% SrSrS/rSSSS.rS	r\	\
S
'   Sr\	\
S'   Sr\	\
S'   Sr\	\
S'   Sr\	\
S'   Sr\	S-  \
S'   Sr\	\
S'   Sr\	\
S'   Sr\	\
S'   Sr\\   S-  \
S'   Sr\\	-  \
S'   Sr\\
S'   Sr\\
S'   Sr\\
S '   S!r\\
S"'   S!r\\
S#'   S$r\	S-  \
S%'   S&r \	\\	   -  S-  \
S''   Sr!\	\
S('   S)r"\	\\	   -  \#\	\	4   -  \
S*'   Sr$\	\\	   -  \#\	\	4   -  \
S+'   S,r%\	\
S-'   S.r&\\
S/'   S.r'\\
S0'   S!r(\\
S1'   U 4S2 jr)S3 r*S4r+U =r,$ )5Ú
UdopConfigé   ac  
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                 óJ  >• U R                   c  SS0SS0SS0/U l         U R                  b  U R                  OU R                  U l        U R                  R	                  S5      nUS   U l        US   S:H  U l        UR                  S	S 5        S
U l        [        TU ](  " S0 UD6  g )NÚtypeÚ1dÚ
horizontalÚverticalÚ-éÿÿÿÿr   Úgatedr0   T© )r   r   r   r#   ÚsplitÚdense_act_fnÚis_gated_actÚpopr0   ÚsuperÚ__post_init__)ÚselfÚkwargsÚact_infoÚ	__class__s      €Úh/home/mande/repo/quber/.venv/lib/python3.13/site-packages/transformers/models/udop/configuration_udop.pyr?   ÚUdopConfig.__post_init__E   s±   ø€ Ø×"Ñ"Ñ*Ø(.° ~¸ÀÐ7MÐPVÐXbÐOcÐ&dˆDÔ#ð (,×'>Ñ'>Ñ'JˆD×#Ò#ÐPT×P_ÑP_ð 	Ôð ×)Ñ)×/Ñ/°Ó4ˆØ$ R™LˆÔØ$ Q™K¨7Ñ2ˆÔà�
‰
Ð(¨$Ô/Ø#'ˆÔ Ü‰ÒÑ' Ó'ó    c                 óº   • U R                   R                  S5      n[        U5      S:”  a	  US   S:w  d  [        U5      S:”  a  [        SU R                    S35      eg)	zOPart of `@strict`-powered validation. Validates the architecture of the config.r6   r'   r   r8   é   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#   r:   ÚlenÚ
ValueError)r@   rB   s     rD   Úvalidate_architectureÚ UdopConfig.validate_architectureU   sf   € à×)Ñ)×/Ñ/°Ó4ˆÜˆx‹=˜1Ó ¨!¡°Ó!7¼3¸x»=È1Ó;LÜØ'¨×(>Ñ(>Ð'?ð @)ð )óð ð <MrF   )r;   r<   r   r   r0   )-Ú__name__Ú
__module__Ú__qualname__Ú__firstlineno__Ú__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/   r0   r?   rK   Ú__static_attributes__Ú__classcell__)rC   s   @rD   r	   r	      s„  ø‡ ñð €JØ#4Ð"5ÐØ$-ÀkÐhtÑu€Mà€J�ÓØ€GˆSÓØ€Dˆ#ƒNØ€Dˆ#ÓØ€J�ÓØ%)Ð˜˜d™
Ó)Ø€IˆsÓØ*,Ð" CÓ,Ø+.Ð# SÓ.Ø,0Ð˜˜T™
 TÑ)Ó0Ø #€L�%˜#‘+Ó#Ø $Ð˜Ó$Ø #Ð˜Ó#Ø#Ð�sÓ#Ø#Ð˜Ó#Ø€IˆtÓØ €L�#˜‘*Ó Ø+,€L�#˜˜S™	‘/ DÑ(Ó,Ø&*Ð Ó*Ø47€J��d˜3‘i‘ %¨¨S¨¡/Ñ1Ó7Ø46€J��d˜3‘i‘ %¨¨S¨¡/Ñ1Ó6Ø€L�#ÓØ€J�ÓØ %Ð˜Ó%Ø $Ð˜Ó$õ(÷ ð rF   r	   N)	rQ   Úhuggingface_hub.dataclassesr   Úconfiguration_utilsr   Úutilsr   r	   Ú__all__r9   rF   rD   Ú<module>rc      sJ   ðñ å .å 3Ý #ñ Ð1Ñ2ØôEÐ!ó Eó ó 3ðEðP ˆ.�rF   