+
    œ°³jk'  ã                   ó  € R t ^ RIHt ^ RIHt ^RIHt ^RIHtH	t	 ^RI
HtHt ]	P                  ! ]4      t] ! R R]4      4       t] ! R R	]4      4       t] ! R
 R]4      4       t]! RR7      ] ! R R]4      4       4       tR tR.tR# )zESM model configuration)ÚUnion)Ústrict)ÚPreTrainedConfig)Úauto_docstringÚlogging)ÚintervalÚis_divisible_byc                   ól   a € ] tR t^t o RtRt^€t^t^€t^t	^t
^tRt^t^t^t^t^
tRtRtV 3R ltRtV tR# )	ÚStructureModuleConfiga$  
Args:
    sequence_dim:
        Single representation channel dimension
    pairwise_dim:
        Pair representation channel dimension
    ipa_dim:
        IPA hidden channel dimension
    resnet_dim:
        Angle resnet (Alg. 23 lines 11-14) hidden channel dimension
    num_heads_ipa:
        Number of IPA heads
    num_qk_points:
        Number of query/key points to generate during IPA
    num_v_points:
        Number of value points to generate during IPA
    dropout_rate:
        Dropout rate used throughout the layer
    num_blocks:
        Number of structure module blocks
    num_transition_layers:
        Number of layers in the single representation transition (Alg. 23 lines 8-9)
    num_resnet_blocks:
        Number of blocks in the angle resnet
    num_angles:
        Number of angles to generate in the angle resnet
    trans_scale_factor:
        Scale of single representation transition hidden dimension
    epsilon:
        Small number used in angle resnet normalization
    inf:
        Large number used for attention masking
i€  çš™™™™™¹?g:Œ0âŽyE>g     jø@c                ó   <€ V ^8„  d   Qh/ S[ R,          ;R&   S[ R,          ;R&   S[ R,          ;R&   S[ R,          ;R&   S[ R,          ;R&   S[ R,          ;R&   S[ R,          ;R&   S[R,          ;R	&   S[ R,          ;R
&   S[ R,          ;R&   S[ R,          ;R&   S[ R,          ;R&   S[ R,          ;R&   S[R,          ;R&   S[R,          ;R&   # )é   NÚsequence_dimÚpairwise_dimÚipa_dimÚ
resnet_dimÚnum_heads_ipaÚnum_qk_pointsÚnum_v_pointsÚdropout_rateÚ
num_blocksÚnum_transition_layersÚnum_resnet_blocksÚ
num_anglesÚtrans_scale_factorÚepsilonÚinf)ÚintÚfloat)ÚformatÚ__classdict__s   "€Új/home/luca/screen-checking/.venv/lib/python3.14/site-packages/transformers/models/esm/configuration_esm.pyÚ__annotate__Ú"StructureModuleConfig.__annotate__   s"  ø‡ ‚ ñH ˜•*Ñ"ñI ñJ ˜•*Ñ"ñK ñL �4�ZÑñM ñN �d•
Ñ ñO ñP ˜•:Ñ"ñQ ñR ˜•:Ñ!ñS ñT ˜•*Ñ ñU ñV ˜$•,Ñ$ñW ñX �d•
ÑñY ñZ  �:Ñ)ñ[ ñ\ ˜T•zÑ%ñ] ñ^ �d•
Ññ_ ñ` ˜d�
Ñ'ña ñb �T�\Ñ ñc ñd 
��Ñòe ó    © N)Ú__name__Ú
__module__Ú__qualname__Ú__firstlineno__Ú__doc__r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   Ú__annotate_func__Ú__static_attributes__Ú__classdictcell__)r    s   @r!   r
   r
      sc   ø‡ € ñ ðD  #€LØ"€LØ€GØ €JØ "€MØ !€MØ €LØ!$€LØ€JØ()ÐØ$%ÐØ€JØ%'ÐØ €GØ€C÷e ƒ r$   r
   c                   óÐ   a a€ ] tR t^Qt oR]/t^0tRt]! ^R7      ! ^€R7      t	^ t
^ t^ t]! RR7      ! RR7      tRtRt]! ^ R	7      ! ^R7      t^€tR
tV 3R ltR tV3R ltRtVtV ;t# )ÚTrunkConfigÚstructure_modulei   )Údivisor)Údefaultgš™™™™™Ù?)Úmaxç        F)ÚminNc                óØ   <€ V P                   f   \        4       V n         M:\        V P                   \        4      '       d   \        R/ V P                   B V n         \        SV `  ! R/ VB  R # ©Nr%   )r0   r
   Ú
isinstanceÚdictÚsuperÚ__post_init__©ÚselfÚkwargsÚ	__class__s   &,€r!   r;   ÚTrunkConfig.__post_init__b   sS   ø€ Ø× Ñ Ò(Ü$9Ó$;ˆDÕ!Ü˜×-Ñ-¬t×4Ò4Ü$9Ñ$R¸D×<QÑ<QÑ$RˆDÔ!Ü‰ÒÑ' Ô'r$   c           	     óÂ  € V P                   V P                   ,          ^ 8w  d'   \        RV P                    RV P                    R24      hV P                  V P                  ,          ^ 8w  d'   \        RV P                   RV P                   R24      hV P                   V P                  ,          pV P                  V P                  ,          pV P                   WP                  ,          8w  d*   \        RV P                    RV RV P                   R24      hV P                  W P                  ,          8w  d*   \        RV P                   RV RV P                   R24      hR	# )
é    zM`sequence_state_dim` should be a round multiple of `sequence_state_dim`, got z and Ú.zM`pairwise_state_dim` should be a round multiple of `pairwise_state_dim`, got zW`sequence_state_dim` should be equal to `sequence_num_heads * sequence_head_width, got z != z * zW`pairwise_state_dim` should be equal to `pairwise_num_heads * pairwise_head_width, got N)Úsequence_state_dimÚ
ValueErrorÚpairwise_state_dimÚsequence_head_widthÚpairwise_head_width)r=   Úsequence_num_headsÚpairwise_num_headss   &  r!   Úvalidate_architectureÚ!TrunkConfig.validate_architecturei   s|  € Ø×"Ñ" T×%<Ñ%<Õ<ÀÔAÜðØ×+Ñ+Ð,¨E°$×2IÑ2IÐ1JÈ!ðMóð ð ×"Ñ" T×%<Ñ%<Õ<ÀÔAÜðØ×+Ñ+Ð,¨E°$×2IÑ2IÐ1JÈ!ðMóð ð
 "×4Ñ4¸×8PÑ8PÕPÐØ!×4Ñ4¸×8PÑ8PÕPÐà×"Ñ"Ð&8×;SÑ;SÕ&SÔSÜðØ×+Ñ+Ð,¨DÐ1CÐ0DÀCÈ×H`ÑH`ÐGaÐabðdóð ð ×"Ñ"Ð&8×;SÑ;SÕ&SÔSÜðØ×+Ñ+Ð,¨DÐ1CÐ0DÀCÈ×H`ÑH`ÐGaÐabðdóð ñ Tr$   c                ó†  <€ V ^8„  d   Qh/ S[ R,          ;R&   S[ R,          ;R&   S[ R,          ;R&   S[ R,          ;R&   S[ R,          ;R&   S[ R,          ;R&   S[S[ ,          R,          ;R&   S[S[ ,          R,          ;R	&   S[R,          ;R
&   S[ R,          ;R&   S[ R,          ;R&   S[S[R3,          R,          ;R&   # )r   Nr   rD   rF   rG   rH   Úposition_binsÚdropoutÚ
layer_dropÚcpu_grad_checkpointÚmax_recyclesÚ
chunk_sizer
   r0   )r   r   Úboolr   r9   )r   r    s   "€r!   r"   ÚTrunkConfig.__annotate__Q   sç   ø‡ ‚ ñ �d•
Ññ	 ñ
 ˜d�
Ñ)ñ ñ ˜d�
ÑLñ ñ ˜t�Ñ(ñ ñ ˜t�Ñ(ñ ñ ˜•:Ñ"ñ ñ ‘S�[˜4ÕÑ@ñ ñ ™•˜dÕ"Ñ(ñ ñ  �Ñ,ñ ñ ˜•*Ñ9ñ ñ �d•
Ñ ñ ñ ™DÐ"9Ð9Õ:¸TÕAÑHò r$   )r0   )r&   r'   r(   r)   r
   Úsub_configsr   rD   r   rF   rG   rH   rN   r   rO   rP   rQ   rR   rS   r0   r;   rK   r+   r,   r-   Ú__classcell__©r?   r    s   @@r!   r/   r/   Q   s€   ù‡ € à%Ð'<Ð=€Kà€JØ%)ÐÙ%4¸QÕ%?ÈÔ%LÐØ&(ÐØ&(ÐØ "€MÙ"*¨sÕ"3¸CÔ"@€GØ%(€JØ',ÐÙ'¨A�°qÔ9€LØ €JØDHÐõ(ò÷1 … r$   r/   c                   ón   a a€ ] tR t^„t oR]/tRtRtRtRt	Rt
RtRtRt^€tRtV 3R ltV3R ltRtVtV ;t# )	ÚEsmFoldConfigÚtrunkNTFr4   c                óØ   <€ V P                   f   \        4       V n         M:\        V P                   \        4      '       d   \        R/ V P                   B V n         \        SV `  ! R/ VB  R # r7   )r[   r/   r8   r9   r:   r;   r<   s   &,€r!   r;   ÚEsmFoldConfig.__post_init__“   sJ   ø€ Ø�:‰:ÒÜ$›ˆD�JÜ˜Ÿ
™
¤D×)Ò)Ü$Ñ2 t§z¡zÑ2ˆDŒJÜ‰ÒÑ' Ô'r$   c                óB  <€ V ^8„  d   Qh/ S[ R,          ;R&   S[R,          ;R&   S[R,          ;R&   S[R,          ;R&   S[R,          ;R&   S[S[,          R,          ;R&   S[R,          ;R&   S[R,          ;R	&   S[R,          ;R
&   S[S[R3,          R,          ;R&   # )r   NÚesm_typeÚfp16_esmÚuse_esm_attn_mapÚesm_ablate_pairwiseÚesm_ablate_sequenceÚesm_input_dropoutÚembed_aaÚ	bypass_lmÚlddt_head_hid_dimr/   r[   )ÚstrrT   r   r   r   r9   )r   r    s   "€r!   r"   ÚEsmFoldConfig.__annotate__„   s¿   ø‡ ‚ ñ �D�jÑñ	 ñ
 �T�kÑ ñ ñ ˜T•kÑ)ñ ñ  �Ñ,ñ ñ  �Ñ,ñ ñ ™s•{ TÕ)Ñ/ñ ñ �T�kÑ ñ ñ �d�{Ñ"ñ ñ ˜T•zÑ'ñ ñ ‘�}Ð$Õ%¨Õ,Ñ3ò r$   )r[   )r&   r'   r(   r)   r/   rV   r_   r`   ra   rb   rc   rd   re   rf   rg   r[   r;   r+   r,   r-   rW   rX   s   @@r!   rZ   rZ   „   sR   ù‡ € à˜KÐ(€Kà€HØ €HØ$)ÐØ',ÐØ',ÐØ,/ÐØ €HØ"€IØ$'ÐØ/3€Eõ(÷ … r$   rZ   zfacebook/esm-1b)Ú
checkpointc                   ó²   a a€ ] tR t^›t oRtRtR]/tRtRt	Rt
Rt^t^tRtRtRtRtR	tR
tRtRtRtRtRtRtRtRtRtRtRtRt^t V 3R lt!V3R lt"Rt#Vt$V ;t%# )Ú	EsmConfiga—  
mask_token_id (`int`, *optional*):
    The index of the mask token in the vocabulary. This must be included in the config because of the
    "mask-dropout" scaling trick, which will scale the inputs depending on the number of masked tokens.
rope_theta (`float`, defaults to 10000.0):
    The base period of the RoPE embeddings. Only used when `position_embedding_type` is set to `"rotary"`.
position_embedding_type (`str`, *optional*, defaults to `"absolute"`):
    Type of position embedding. Choose either `"absolute"` or "rotary"`.
emb_layer_norm_before (`bool`, *optional*):
    Whether to apply layer normalization after embeddings but before the main stem of the network.
token_dropout (`bool`, defaults to `False`):
    When this is enabled, masked tokens are treated as if they had been dropped out by input dropout.
is_folding_model (`bool`, defaults to `False`):
    When this is enabled, ESMFold model will be initialized.
esmfold_config (`dict`, *optional*):
    Configuration to initiate the ESMFold module.
vocab_list (`list`, *optional*):
    List of the vocabulary items.

Examples:

```python
>>> from transformers import EsmModel, EsmConfig

>>> # Initializing a ESM facebook/esm-1b style configuration
>>> configuration = EsmConfig(vocab_size=33)

>>> # Initializing a model from the configuration
>>> model = EsmModel(configuration)

>>> # Accessing the model configuration
>>> configuration = model.config
```ÚesmÚesmfold_configNi   i   r   i  g     ˆÃ@g{®Gáz”?gê-�™—q=ÚabsoluteTFc                ó  <€ V P                   '       d¡   V P                  f&   \        P                  R4       \	        4       V n        M:\        V P                  \        4      '       d   \	        R/ V P                  B V n        V P                  f%   \        P                  R4       \        4       V n        MR V n        R V n        V P                  e)   \        V P                  RR4      '       d   \        R4      h\        SV `4  ! R/ VB  R # )NzCNo esmfold_config supplied for folding model, using default values.zHNo vocab_list supplied for folding model, assuming the ESM-2 vocabulary!ra   FzOThe HuggingFace port of ESMFold does not support use_esm_attn_map at this time!r%   )Úis_folding_modelrn   ÚloggerÚinforZ   r8   r9   Ú
vocab_listÚwarningÚget_default_vocab_listÚgetattrrE   r:   r;   r<   s   &,€r!   r;   ÚEsmConfig.__post_init__Ý   sÊ   ø€ Ø× × Ð Ø×"Ñ"Ò*Ü—‘ÐaÔbÜ&3£o�Õ#Ü˜D×/Ñ/´×6Ò6Ü&3Ñ&J°d×6IÑ6IÑ&J�Ô#à�‰Ò&Ü—‘ÐiÔjÜ"8Ó":�”øà"&ˆDÔØ"ˆDŒOà×ÑÒ*¬w°t×7JÑ7JÐL^Ð`e×/fÒ/fÜÐnÓoÐoä‰ÒÑ' Ô'r$   c                óŠ  <€ V ^8„  d   Qh/ S[ R,          ;R&   S[ R,          ;R&   S[ R,          ;R&   S[ ;R&   S[ ;R&   S[ ;R&   S[ ;R&   S[R,          ;R	&   S[R,          ;R
&   S[ ;R&   S[;R&   S[;R&   S[R,          ;R&   S[R,          ;R&   S[;R&   S[R,          ;R&   S[R,          ;R&   S[R,          ;R&   S[S[,          R,          ;R&   S[S[,          S[S[R3,          ,          R,          ;R&   S[R,          ;R&   S[R,          ;R&   S[;R&   S[ R,          ;R&   S[ S[S[ ,          ,          R,          ;R&   # )r   NÚ
vocab_sizeÚmask_token_idÚpad_token_idÚhidden_sizeÚnum_hidden_layersÚnum_attention_headsÚintermediate_sizeÚhidden_dropout_probÚattention_probs_dropout_probÚmax_position_embeddingsÚ
rope_thetaÚinitializer_rangeÚlayer_norm_epsÚposition_embedding_typeÚ	use_cacheÚemb_layer_norm_beforeÚtoken_dropoutrq   rn   .rt   Ú
is_decoderÚadd_cross_attentionÚtie_word_embeddingsÚbos_token_idÚeos_token_id)r   r   rh   rT   r9   rZ   ÚlistÚtuple)r   r    s   "€r!   r"   ÚEsmConfig.__annotate__›   sÝ  ø‡ ‚ ñP �d•
Ñ!ñQ ñR ˜•:Ñ$ñS ñT ˜•*Ñ#ñU ñV ÑñW ñX ÑñY ñZ Ñ!ñ[ ñ\ Ñ!ñ] ñ^  �Ñ+ñ_ ñ` #(¨$¥,Ñ4ña ñb !Ñ'ñc ñd Ññe ñf Ñ#ñg ñh ˜D•LÑ(ñi ñj ! 4�ZÑ4ñk ñl Ññm ñn   $�;Ñ-ño ñp ˜$•;Ñ&ñq ñr ˜T•kÑ)ñs ñt ™=Õ(¨4Õ/Ñ6ñu ñv ‘S•	™E¡# s (�OÕ+¨dÕ2Ñ9ñw ñx �t•Ñ#ñy ñz  �Ñ,ñ{ ñ| Ñ$ñ} ñ~ ˜•*Ñ#ñ ñ@ ™™S�	•/ DÕ(Ñ,òA r$   )rn   rt   )&r&   r'   r(   r)   r*   Ú
model_typerZ   rV   rz   r{   r|   r}   r~   r   r€   r�   r‚   rƒ   r„   r…   r†   r‡   rˆ   r‰   rŠ   rq   rn   rt   r‹   rŒ   r�   rŽ   r�   r;   r+   r,   r-   rW   rX   s   @@r!   rl   rl   ›   s²   ù‡ € ñ ðD €JØ# ]Ð3€Kà!€JØ $€MØ#€LØ€KØÐØ!ÐØ!ÐØ(+ÐØ14Ð Ø#'ÐØ€JØ#ÐØ#(€NØ*4ÐØ€IØ)-ÐØ!&€MØ$)ÐØ26€NØ59€JØ#€JØ',ÐØ $ÐØ#€LØ+,€Lõ(÷E … r$   rl   c                  ó   € R# )ú<cls>)!r•   z<pad>z<eos>z<unk>ÚLÚAÚGÚVÚSÚEÚRÚTÚIÚDÚPÚKÚQÚNÚFÚYÚMÚHÚWÚCÚXÚBÚUÚZÚOrC   Ú-z<null_1>z<mask>r%   r%   r$   r!   rv   rv   ò   s   € ð"ð "r$   N)r*   Útypingr   Úhuggingface_hub.dataclassesr   Úconfiguration_utilsr   Úutilsr   r   Úutils.type_validatorsr   r   Ú
get_loggerr&   rr   r
   r/   rZ   rl   rv   Ú__all__r%   r$   r!   Ú<module>r·      s¾   ðñ å å .å 3ß ,ß >ð 
×	Ò	˜HÓ	%€ð ô1Ð,ó 1ó ð1ðh ô/Ð"ó /ó ð/ðd ô(Ð$ó (ó ð(ñ, Ð,Ô-ØôR(Ð ó R(ó ó .ðR(òj#ðL ˆ-‚r$   