Ë
    ÜÓ^j{  ã                   óv   — d dl mZ ddlmZ ddlmZ ddlmZmZ  ed¬«      e G d	„ d
e«      «       «       Z	d
gZ
y)é    )Ústricté   )ÚPreTrainedConfig)Úauto_docstringé   )ÚCONFIG_MAPPINGÚ
AutoConfigzgoogle/shieldgemma-2-4b-it)Ú
checkpointc                   ó¸   ‡ — e Zd ZU dZdZddddœZeedœZdZe	e
z  dz  ed	<   dZe	e
z  d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<   ˆ fd„Zˆ xZS )ÚShieldGemma2ConfigaÖ  
    tie_word_embeddings (`bool`, *optional*):
        Whether to tie the word embeddings. Defaults to the value of `text_config.tie_word_embeddings` if not set.
    mm_tokens_per_image (`int`, *optional*, defaults to 256):
        The number of tokens per image embedding.
    boi_token_index (`int`, *optional*, defaults to 255999):
        The begin-of-image token index to wrap the image prompt.
    eoi_token_index (`int`, *optional*, defaults to 256000):
        The end-of-image token index to wrap the image prompt.

    Example:

    ```python
    >>> from transformers import ShieldGemma2ForConditionalGeneration, ShieldGemma2Config, SiglipVisionConfig, ShieldGemma2TextConfig

    >>> # Initializing a Siglip-like vision config
    >>> vision_config = SiglipVisionConfig()

    >>> # Initializing a ShieldGemma2 Text config
    >>> text_config = ShieldGemma2TextConfig()

    >>> # Initializing a ShieldGemma2 gemma-3-4b style configuration
    >>> configuration = ShieldGemma2Config(vision_config, text_config)

    >>> # Initializing a model from the gemma-3-4b style configuration
    >>> model = ShieldGemma2TextConfig(configuration)

    >>> # Accessing the model configuration
    >>> configuration = model.config
    ```Úshieldgemma2Úimage_token_indexÚboi_token_indexÚeoi_token_index)Úimage_token_idÚboi_token_idÚeoi_token_id)Útext_configÚvision_configNr   r   é   Úmm_tokens_per_imageiÿç i è i   g{®Gáz”?Úinitializer_rangec                 ó®  •— t        | j                  t        «      rT| j                  j                  dd«      | j                  d<   t	        | j                  d      di | j                  ¤Ž| _        n| j                  €t	        d   «       | _        t        | j
                  t        «      rT| j
                  j                  dd«      | j
                  d<   t	        | j
                  d      di | j
                  ¤Ž| _        n| j
                  €t	        d   «       | _        |j                  d«      €t        | j
                  dd«      | _        t        ‰| �$  di |¤Ž y )NÚ
model_typeÚsiglip_vision_modelÚgemma3_textÚtie_word_embeddingsT© )
Ú
isinstancer   ÚdictÚgetr   r   Úgetattrr   ÚsuperÚ__post_init__)ÚselfÚkwargsÚ	__class__s     €ú†/var/www/ramen.bs-engineer-server.com/venv/lib/python3.12/site-packages/transformers/models/shieldgemma2/configuration_shieldgemma2.pyr$   z ShieldGemma2Config.__post_init__J   s+  ø€ Ü�d×(Ñ(¬$Ô/Ø/3×/AÑ/A×/EÑ/EÀlÐTiÓ/jˆD×Ñ˜|Ñ,Ü!/°×0BÑ0BÀ<Ñ0PÑ!QÑ!gÐTX×TfÑTfÑ!gˆDÕØ×ÑÐ'Ü!/Ð0EÑ!FÓ!HˆDÔä�d×&Ñ&¬Ô-Ø-1×-=Ñ-=×-AÑ-AÀ,ÐP]Ó-^ˆD×Ñ˜\Ñ*Ü-¨d×.>Ñ.>¸|Ñ.LÑMÑaÐPT×P`ÑP`ÑaˆDÕØ×ÑÐ%Ü-¨mÑ<Ó>ˆDÔØ�:‰:Ð+Ó,Ð4Ü'.¨t×/?Ñ/?ÐAVÐX\Ó']ˆDÔ$ä‰ÑÑ' Ó'ó    )Ú__name__Ú
__module__Ú__qualname__Ú__doc__r   Úattribute_mapr	   Úsub_configsr   r    r   Ú__annotations__r   r   Úintr   r   r   r   Úfloatr$   Ú__classcell__)r'   s   @r(   r   r      s”   ø… ñð>  €Jà-Ø)Ø)ñ€Mð
 #-¸zÑJ€Kà26€K�Ð(Ñ(¨4Ñ/Ó6Ø48€M�4Ð*Ñ*¨TÑ1Ó8Ø"Ð˜Ó"Ø"€O�SÓ"Ø"€O�SÓ"Ø$Ð�sÓ$Ø#Ð�uÓ#÷(ð (r)   r   N)Úhuggingface_hub.dataclassesr   Úconfiguration_utilsr   Úutilsr   Úautor   r	   r   Ú__all__r   r)   r(   ú<module>r9      sH   ðõ" /å 3Ý #ß -ñ Ð7Ô8Øô?(Ð)ó ?(ó ó 9ð?(ðD  Ð
 �r)   