+
    œ°³j–B  ã                   óæ   € ^ RI Ht ^RIHt ^RIHt ^RIHt ]! RR7      ] ! R R]4      4       4       t]! RR7      ] ! R	 R
]4      4       4       t	]! RR7      ] ! R R]4      4       4       t
. ROtR# )é    )Ústrict)ÚPreTrainedConfig)ÚRopeParameters)Úauto_docstringzstepfun-ai/Step-3.7-Flash)Ú
checkpointc                   ó†   a a€ ] tR t^t oRtRtRtRtRt^/t	^t
^tRt^tRtRtR	tR
tRtRtRtRtV 3R ltV3R ltRtVtV ;t# )ÚStep3p7VisionConfigaÞ  
Example:

```python
>>> from transformers import Step3p7VisionConfig, Step3p7VisionModel

>>> # Initializing a Step3p7VisionConfig with google/step3p7-base-patch16-224 style configuration
>>> configuration = Step3p7VisionConfig()

>>> # Initializing a Step3p7VisionModel (with random weights) from the google/step3p7-base-patch16-224 style configuration
>>> model = Step3p7VisionModel(configuration)

>>> # Accessing the model configuration
>>> configuration = model.config
```Ústep3p5_visionÚvision_configi   i   iØ  Ú
quick_geluçñhãˆµøä>ç        Úaxialgš™™™™™¹?Ni�
  c                ó†  <€ VP                  R V P                  4      V n        VP                  RV P                  4      V n        VP                  RV P                  4      V n        VP                  RV P                  4      V n        \
        SV `  ! R/ VB  \        V P                  V P                  ,          4      V n	        R# )ÚwidthÚlayersÚheadsÚls_init_valueN© )
ÚpopÚhidden_sizeÚnum_hidden_layersÚnum_attention_headsÚlayer_scale_init_valueÚsuperÚ__post_init__ÚintÚ	mlp_ratioÚintermediate_size)ÚselfÚkwargsÚ	__class__s   &,€Úr/home/luca/screen-checking/.venv/lib/python3.14/site-packages/transformers/models/step3p7/configuration_step3p7.pyr   Ú!Step3p7VisionConfig.__post_init__D   s“   ø€ Ø!Ÿ:™: g¨t×/?Ñ/?Ó@ˆÔØ!'§¡¨H°d×6LÑ6LÓ!MˆÔØ#)§:¡:¨g°t×7OÑ7OÓ#PˆÔ Ø&,§j¡j°À$×B]ÑB]Ó&^ˆÔ#Ü‰ÒÑ' Ò'Ü!$ T×%5Ñ%5¸¿¹Õ%FÓ!GˆÖó    c                óà   <€ V ^8„  d   Qh/ S[ ;R&   S[ ;R&   S[ ;R&   S[ ;R&   S[ ;R&   S[ ;R&   S[ ;R&   S[;R&   S[;R	&   S[S[ ,          ;R
&   S[;R&   S[;R&   S[R,          ;R&   S[ ;R&   # )é   r   r   r   r   Únum_channelsÚ
image_sizeÚ
patch_sizeÚ
hidden_actÚlayer_norm_epsÚattention_dropoutr   r   NÚrope_parametersÚmax_position_embeddings)r   ÚstrÚfloatÚdict)ÚformatÚ__classdict__s   "€r#   Ú__annotate__Ú Step3p7VisionConfig.__annotate__   sÍ   ø‡ ‚ ñ. Ññ/ ñ0 Ñ!ñ1 ñ2 Ññ3 ñ4 Ñ!ñ5 ñ6 Ññ7 ñ8 Ññ9 ñ: Ññ; ñ< Ñ"ñ= ñ> Ñ ñ? ñ@ ™s•{Ñ(ñA ñF Ñ"ñG ñH "Ñ'ñI ñJ ˜D•[Ñ'ñK ñL !Ñ'òM r%   )r   r   r   r   r   gUUUUUU@)Ú__name__Ú
__module__Ú__qualname__Ú__firstlineno__Ú__doc__Ú
model_typeÚbase_config_keyr   r   r   r   r(   r)   r*   r+   r,   r-   Údefault_rope_typer   r   r.   r/   r   Ú__annotate_func__Ú__static_attributes__Ú__classdictcell__Ú__classcell__©r"   r4   s   @@r#   r	   r	      sx   ù‡ € ñð  "€JØ%€Oð €KØ!ÐØÐØ!ÐØ€LØ€JØ€JØ"€JØ €NØ%(ÐØÐà"€IØ$'ÐØ#'€OØ#'ÐõH÷Q … r%   r	   c                   óf  a a€ ] tR t^Mt oRtRtR.tRRRRRRRRR	R
RRRRRR/tRR.R.3RRR.R.3RR.R.3/tRRRRRRRR/t	RRRRRRR R!R"R#R$R%/t
R&tR'tR(tR)t^-t^@t^t^€tR*tR+tR,tR-tR.t^tR/tR/tR0tR1t^t^€tR/tR2t R/t!R/t"R.t#R0t$R3t%R4t&R3t'R/t(R/t)R0t*R/t+R5t,R0t-R/t.R/t/R/t0R/t1V 3R6 lt2V3R7 lt3R8t4Vt5V ;t6# )9ÚStep3p7TextConfigaª  
mlp_layer_types (`list[str]`, *optional*):
    Per-layer MLP type: `"sparse"` (MoE) or `"dense"`. If not provided, derived from the legacy
    `moe_layers_enum` hub-config kwarg (comma-separated string or list of MoE layer indices),
    defaulting to all layers from index 3 onward being MoE.
n_routed_experts (`int`, *optional*, defaults to 288):
    Total number of routed experts. Accessible as `num_local_experts` via `attribute_map`.
share_expert_dim (`int`, *optional*, defaults to 1280):
    Intermediate size of the always-active shared expert.
num_sliding_attention_heads (`int`, *optional*):
    Attention head count for `"sliding_attention"` layers, if different from `num_attention_heads`.
    Defaults to the legacy `attention_other_setting` hub-config kwarg's `num_attention_heads` entry.
    Applied via a `per_layer_config` override (see `PreTrainedConfig`), not a per-layer list field.
query_pre_attn_scalar (`int` or `float`, *optional*):
    `Step3p7Attention.__init__` hook point: defaults to `head_dim`, giving standard
    `head_dim ** -0.5` scaling; overridable per released checkpoint variant.
moe_router_scaling_factor (`float`, *optional*, defaults to 1.0):
    Scaling factor applied to the MoE block's routed-expert output (`routed_scaling_factor` in
    `Step3p7SparseMoeBlock`).
swiglu_limits (`list[float | None]`, *optional*):
    Per-layer gate/up clamping bound; `None` means no clamping.
swiglu_limits_shared (`list[float | int | None]`, *optional*):
    Per-layer gate/up clamping bound for the always-active shared expert; `None` means no clamping.
mtp_layer_types (`list[str]`, *optional*):
    Per-MTP-layer attention type; split off `layer_types`'s legacy trailing pad instead of being
    discarded, so `Step3p7Config.get_mtp_config()` can build the MTP layers for `generate(use_mtp=True)`.
mtp_mlp_layer_types (`list[str]`, *optional*):
    Per-MTP-layer MLP type, analogous to `mtp_layer_types` for `mlp_layer_types`.
Ústep3p5Úpast_key_valueszlayers.*.self_attn.q_projÚcolwise_gather_outputzlayers.*.self_attn.k_projzlayers.*.self_attn.v_projzlayers.*.self_attn.g_projzlayers.*.self_attn.o_projÚrowwise_split_inputz!layers.*.mlp.experts.gate_up_projÚpacked_colwisezlayers.*.mlp.experts.down_projÚrowwisezlayers.*.mlp.expertsÚmoe_tp_expertsÚembed_tokensÚ	input_idsÚinputs_embedsr   Úhidden_statesÚattention_maskÚnormzlayers.*.mlp.gateÚ	ep_routerÚgrouped_gemmÚnum_local_expertsÚn_routed_expertsÚnum_attention_groupsÚnum_key_value_headsÚmoe_num_expertsÚ	moe_top_kÚnum_experts_per_tokÚshare_expert_dimsÚshare_expert_dimÚnum_mtp_layersÚnum_nextn_predict_layersg     ˆÃ@i/÷ i   i ,  Úsilui ô g{®Gáz”?r   TNFr   Útext_configi   i   g      ð?c           
     ó  <a€ VP                  R ^ 4      pW n        V P                  V P                  V,           rCV'       dö   R# FW  w  rV\        W4      p\	        V\
        4      '       g   K(  \        V4      V8X  g   K:  \        WVRV 4       \        WWsV 4       KY  	  R$ FG  p\        W4      p\	        V\
        4      '       g   K&  \        V4      V8X  g   K8  \        WVRV 4       KI  	  R% FE  pVP                  V4      p\	        V\
        4      '       g   K,  \        V4      V8X  g   K>  VRV W&   KG  	  V P                  f'   R.V,          V n	        V'       d   R.V,          V n
        V P                  fÎ   VP                  RR4      p	V	ef   \	        V	\        4      '       d   V	P                  R4      MT	p
V
 Uu0 uF/  p\        V4      P                  4       '       g   K$  \        V4      kK1  	  ppM\!        \#        ^V4      4      p\#        V4       Uu. uF  q»V9   d   RMRNK  	  ppVRV V n        V'       d
   WÓV V n        V P&                  fN   VP                  R	R4      pV'       d#   VP                  R
V P(                  4      V n        MV P(                  V n        TP+                  R\-        V P                  4       UUu/ uF  w  ppVR8X  g   K  VR
V P&                  /bK   	  upp4       V P.                  f   V P0                  V n        VP                  RV P2                  4      pVP                  RR4      pVP                  RR4      pVP                  RR4      ;'       g    / pVP                  RR4      p\4        SV `l  ! R&/ VB  RV n        RRRRRRRRRR/P;                  4        F#  w  ppVV9   g   K  \        V VVV,          4       K%  	  V P                  f0   RV9   d)   VR,           Uu. uF  pV'       d   RMRNK  	  upV n	        V P                  f   R.V P                  ,          V n	        V P                  f&   Ve"   V Uu. uF  pV'       d   RMRNK  	  upV n        V P                  f   R.V P                  ,          V n        \!        V P                  4      pV P<                  ;'       g    / o\>        ;QJ d    V3R lV 4       F  '       d   K   RM	  RM! V3R lV 4       4      '       d"   V Uu/ uF  pVSV,          bK  	  upV n        R# \	        V\
        4      '       g   V.\        V P                  4      ,          p/ V n        V FN  pV P                  PA                  V4      pR R!RVV,          /pV'       d   VV,          VR"&   VV P<                  V&   KP  	  V'       d8   RV P<                  9   d%   V P<                  R,          PC                  V4       R# R# R# u upi u upi u uppi u upi u upi u upi )'r_   NÚ
rope_thetaÚpartial_rotary_factorsÚfull_attentionÚmoe_layers_enumÚ,ÚsparseÚdenseÚattention_other_settingr   Úper_layer_configÚsliding_attentionÚrope_scalingÚsparse_attention_configÚmoe_layer_freqr`   Úindex_n_headsÚsparse_num_index_headsÚindex_head_dimÚsparse_index_dimÚindex_block_sizeÚsparse_block_sizeÚindex_topk_blocksÚsparse_topk_blocksÚindex_local_blocksÚsparse_local_blockÚsparse_attention_freqÚminimax_m3_sparsec              3   ób   <"  € T F$  p\        SP                  V4      \        4      x € K&  	  R # 5i)N)Ú
isinstanceÚgetr2   )Ú.0Ú
layer_typeÚrps   & €r#   Ú	<genexpr>Ú2Step3p7TextConfig.__post_init__.<locals>.<genexpr>)  s$   øé € ÐUÁn¸
Œz˜"Ÿ&™& Ó,¬d×3Ð3Ãnùs   ƒ,/FTÚ	rope_typeÚdefaultÚpartial_rotary_factor))Úlayer_typesÚmtp_layer_types)Úmlp_layer_typesÚmtp_mlp_layer_types)Úswiglu_limitsÚswiglu_limits_shared)rc   rd   r   )"r   r_   r   Úgetattrr}   ÚlistÚlenÚsetattrr~   r‡   rˆ   r‰   r0   ÚsplitÚstripr   ÚsetÚrangerŠ   Únum_sliding_attention_headsr   Ú
setdefaultÚ	enumerateÚquery_pre_attn_scalarÚhead_dimÚdefault_thetar   r   r+   Úitemsr.   ÚallÚindexÚupdate)r    r!   r_   ÚnÚpaddedÚfieldÚ	mtp_fieldÚvalueÚkeyrf   r›   ÚiÚmoe_setr‰   rj   Ú	layer_idxr€   rc   rd   rm   Ú
sparse_cfgro   ÚflatÚlegacyÚfÚlayer_type_setÚparamsr�   r"   s   &,                         @€r#   r   ÚStep3p7TextConfig.__post_init__¹   s’  ù€ ð
 $*§:¡:Ð.HÈ!Ó#LÐ Ø(@Ô%Ø×*Ñ*¨D×,BÑ,BÐE]Õ,]ˆ6ß#ó%Ñ �ô   Ó,�Ü˜e¤T×*Ô*¬s°5«z¸VÖ/CÜ˜D¨¨r°¨Ô3Ü˜D¨U°V¨_Ö=ñ%ó C�Ü Ó,�Ü˜e¤T×*Ô*¬s°5«z¸VÖ/CÜ˜D¨¨r°¨Ö3ñ Có @�ØŸ
™
 3›�Ü˜e¤T×*Ô*¬s°5«z¸VÖ/CØ"'¨¨ )�F“Kñ @ð
 ×ÑÒ#Ø 0Ð1°AÕ5ˆDÔß'Ø(8Ð'9Ð<TÕ'T�Ô$à×ÑÒ'ð %Ÿj™jÐ):¸DÓAˆOØÒ*Ü6@ÀÔRU×6VÒ6V˜×-Ñ-¨cÔ2Ð\k�Ù+0ÓC©5 a´C¸³F·L±L·Nœ6œ3˜qž6©5�ÐC�äœe A q›kÓ*�ÜNSÐTZÌmÓ\ÉmÈ°¬<™x¸WÒDÉmˆOÐ\Ø#2°2°AÐ#6ˆDÔ ß'Ø+:¸VÐ+D�Ô(à×+Ñ+Ò3ð '-§j¡jÐ1JÈDÓ&QÐ#ß&Ø3J×3NÑ3NØ)¨4×+CÑ+Có4�Õ0ð 48×3KÑ3K�Ô0ð 	×ÑØô .7°t×7GÑ7GÔ-Hôá-HÑ)�I˜zØÐ!4Ñ4ô U�	Ð1°4×3SÑ3SÐTÒTÙ-Hòô	
ð ×%Ñ%Ò-Ø)-¯©ˆDÔ&ð
 —Z‘Z ¨d×.@Ñ.@ÓAˆ
Ø!'§¡Ð,DÀdÓ!KÐØ—z‘z .°$Ó7ˆØ—Z‘ZÐ 9¸4Ó@×FÐFÀBˆ
ØŸ™Ð$4°dÓ;ˆÜ‰ÒÑ' Ò'ð !ˆŒð Ð5ØÐ0ØÐ 3ØÐ!5Ø Ð"6ð
÷ ‰%‹'ò‰LˆD�&ð ˜Ö#Ü˜˜d J¨vÕ$6Ö7ñð ×ÑÒ#Ð(?À:Ô(MàHRÐSjÖHkó ÙHkÀ1§qÑ#Ð.>Ò>ÑHkñ ˆDÔð ×ÑÒ#Ø 0Ð1°D×4JÑ4JÕJˆDÔð ×ÑÒ'¨NÒ,FÙHVÓ#WÉÀ1·¡H°wÒ$>ÉÑ#WˆDÔ Ø×ÑÒ'Ø$, :°×0FÑ0FÕ#FˆDÔ ô ˜T×-Ñ-Ó.ˆØ×!Ñ!×'Ð' Rˆß‹3ÔUÁnÓU�3�3Š3ÔUÁnÓU×UÒUÙQ_Ó#`ÑQ_À: J°°:µÒ$>ÑQ_Ñ#`ˆDÖ ä˜j¬$×/Ò/Ø(˜\¬C°×0@Ñ0@Ó,AÕA�
Ø#%ˆDÔ Û,�
Ø×$Ñ$×*Ñ*¨:Ó6�Ø% y°,À
È1ÅÐN�ß)Ø6LÈQÕ6O�FÐ2Ñ3Ø39�×$Ñ$ ZÓ0ñ -÷ Ð 0°D×4HÑ4HÔ HØ×$Ñ$Ð%5Õ6×=Ñ=¸lÖKñ !I‰|ùòo Dùò ]ùó&ùòJ ùò $Xùò $as<   Æ;!W.Ç!W.ÈW3ËW8ËW8Ï5W>ÐW>ÑXÑXÔXc                óR  <€ V ^8„  d   Qh/ S[ ;R&   S[ ;R&   S[ ;R&   S[ ;R&   S[ ;R&   S[ ;R&   S[ ;R&   S[;R&   S[ ;R	&   S[;R
&   S[;R&   S[;R&   S[ ;R&   S[ R,          ;R&   S[ S[S[ ,          ,          R,          ;R&   S[;R&   S[S[ ,          ;R&   S[ ;R&   S[ ;R&   S[S[,          R,          ;R&   S[S[,          R,          ;R&   S[S[,          R,          ;R&   S[ ;R&   S[ ;R&   S[ ;R&   S[ R,          ;R&   S[ R,          ;R&   S[;R&   S[ S[,          R,          ;R&   S[;R&   S[;R &   S[S[S[ ,          R,          ,          R,          ;R!&   S[S[S[ ,          R,          ,          R,          ;R"&   S[S[,          R,          ;R#&   S[S[,          R,          ;R$&   # )%r'   Ú
vocab_sizer   r   r   r   rX   r™   r+   r/   Úinitializer_rangeÚrms_norm_epsÚ	use_cacheÚpad_token_idNÚbos_token_idÚeos_token_idÚtie_word_embeddingsr-   r[   rU   r.   r‰   r‡   Úmoe_intermediate_sizerV   r]   Úsliding_windowr•   Úattention_biasr˜   Úmoe_router_scaling_factorÚmlp_biasr‹   rŒ   rˆ   rŠ   )r   r0   r1   ÚboolrŽ   r   r2   )r3   r4   s   "€r#   r5   ÚStep3p7TextConfig.__annotate__M   sŒ  ø‡ ‚ ñH ÑñI ñL ÑñM ñN Ñ"ñO ñP ÑñQ ñR Ñ!ñS ñT Ñ ñU ñV ÑñW ñX ÑñY ñZ !Ñ)ñ[ ñ\ Ñ#ñ] ñ^ Ññ_ ñ` Ñña ñb Ññc ñd ˜•*Ñ#ñe ñf ™™S�	•/ DÕ(Ñ/ñg ñh Ñ%ñi ñj ™s•{Ñ(ñk ñl Ñ ñm ñn Ñ ño ñp $¡dÕ*¨TÕ1Ñ8ñq ñt ™#•Y Õ%Ñ,ñu ñv ‘c•˜TÕ!Ñ(ñw ñ| Ñ%ñ} ñ~ Ññ ñ@ Ñ ñA ñB ˜$•JÑ%ñC ñD "% t¥Ñ2ñE ñF Ñ ñG ñH ¡�;¨Õ-Ñ4ñI ñJ  %Ñ*ñK ñL ÑñM ñN ™¡� dÕ*Õ+¨dÕ2Ñ9ñO ñP ™u¡s�{¨TÕ1Õ2°TÕ9Ñ@ñQ ñR ™#•Y Õ%Ñ,ñS ñT ™c� TÕ)Ñ0òU r%   )	r+   r‡   r‰   rˆ   rŠ   r_   r•   r˜   r.   )7r7   r8   r9   r:   r;   r<   Úkeys_to_ignore_at_inferenceÚbase_model_tp_planÚbase_model_pp_planÚbase_model_ep_planÚattribute_maprš   r°   r   r   r   r   rX   r™   r+   r/   r±   r²   r³   r´   rµ   r¶   r·   r-   r[   rU   r.   r=   r‰   r‡   ÚgatingÚuse_bidirectional_attentionr¸   rV   r]   r¹   r•   rº   r˜   r»   r¼   r‹   rŒ   rˆ   rŠ   r   r?   r@   rA   rB   rC   s   @@r#   rE   rE   M   sÂ  ù‡ € ñð< €JØ#4Ð"5Ðð
 	$Ð%<Ø#Ð%<Ø#Ð%<Ø#Ð%<Ø#Ð%:Ø+Ð-=Ø(¨)ØÐ 0ð	Ðð 	˜+˜¨Ð(9Ð:Ø�OÐ%5Ð6¸Ð8IÐJØ�/Ð" _Ð$5Ð6ðÐð 	˜[Ø+¨^Ø(¨.ØÐ 0ð	Ðð 	Ð/ØÐ 5ØÐ-ØÐ*ØÐ/ØÐ4ð€Mð €MØ€Jà€KØ"ÐØÐØ!ÐØ ÐØ€HØ€JØ#)ÐØ#ÐØ€LØ€IØ€LØ#€LØ+/€LØ %ÐØ%(ÐØ ÐØ ÐØ48€OØ#€OØ(,€OØ$(€KØ€FØ"'ÐØ!%ÐØÐØ ÐØ!%€NØ.2ÐØ €NØ04ÐØ'*ÐØ€HØ59€MØ<@ÐØ(,€OØ,0Ðõ}L÷Y … r%   rE   c                   ó^   a a€ ] tR tRt oRtR]R]/tRtRt	Rt
RtV 3R ltV3R	 ltR
tVtV ;t# )ÚStep3p7Configi9  Ústep3p7r   ra   NFiP c           
     óL  <€ V P                   f   \        4       V n         Me\        V P                   \        4      '       dF   \        R/ V P                   P	                  4        UUu/ uF  w  r#VR8w  g   K  W#bK  	  uppB V n         V P
                  f   \        4       V n        Me\        V P
                  \        4      '       dF   \        R/ V P
                  P	                  4        UUu/ uF  w  r#VR8w  g   K  W#bK  	  uppB V n        \        SV `   ! R/ VB  R # u uppi u uppi )Nr<   r   )	r   r	   r}   r2   r›   ra   rE   r   r   )r    r!   ÚkÚvr"   s   &,  €r#   r   ÚStep3p7Config.__post_init__D  sö   ø€ Ø×ÑÒ%Ü!4Ó!6ˆDÕÜ˜×*Ñ*¬D×1Ò1Ü!4ñ "Ø$(×$6Ñ$6×$<Ñ$<Ô$>ÔTÑ$>™D˜AÀ!À|ÑBS”4�1’4Ñ$>ÒTñ"ˆDÔð ×ÑÒ#Ü0Ó2ˆDÕÜ˜×(Ñ(¬$×/Ò/Ü0ÑtÀT×EUÑEU×E[ÑE[ÔE]Ô3sÑE]¹T¸QÐabÐfrÑar´D°A²DÑE]Ò3sÑtˆDÔä‰ÒÑ' Ô'ùó Uùó 4ts   Á$DÁ4DÃ'D Ã7D c                ó†   <€ V ^8„  d   Qh/ S[ S[,          R,          ;R&   S[ S[,          R,          ;R&   S[;R&   S[;R&   # )r'   Nr   ra   Úprojector_biasÚimage_token_id)r2   r   r½   r   )r3   r4   s   "€r#   r5   ÚStep3p7Config.__annotate__9  sO   ø‡ ‚ ñ Ñ*Õ*¨TÕ1Ñ8ñ ñ Ñ(Õ(¨4Õ/Ñ6ñ ñ Ñ ñ ñ Ñ ò r%   )ra   r   )r7   r8   r9   r:   r<   r	   rE   Úsub_configsr   ra   rÎ   rÏ   r   r?   r@   rA   rB   rC   s   @@r#   rÇ   rÇ   9  s<   ù‡ € ð €JØ"Ð$7¸ÐHYÐZ€Kà48€MØ26€KØ €NØ €Nõ(÷ … r%   rÇ   N)r	   rE   rÇ   )Úhuggingface_hub.dataclassesr   Úconfiguration_utilsr   Úmodeling_rope_utilsr   Úutilsr   r	   rE   rÇ   Ú__all__r   r%   r#   Ú<module>r×      s¤   ðõ* /å 3Ý 1Ý #ñ Ð6Ô7Øô,HÐ*ó ,Hó ó 8ð,Hñ^ Ð6Ô7ØôgLÐ(ó gLó ó 8ðgLñT Ð6Ô7Øô(Ð$ó (ó ó 8ð(ò2 H‚r%   