+
    œ°³j²  ã                   ó”   € ^RI HtHtHtHt ^RIHtHt ^RIH	t	  ! R R]RR7      t
 ! R R	]RR7      t] ! R
 R]4      4       tR.tR# )é   )ÚImagesKwargsÚMultiModalDataÚProcessingKwargsÚProcessorMixin)Ú
TensorTypeÚauto_docstring)ÚAutoTokenizerc                   ó0   a € ] tR t^t o RtV 3R ltRtV tR# )ÚAriaImagesKwargsaÍ  
split_image (`bool`, *optional*, defaults to `False`):
    Whether to split large images into multiple crops. When enabled, images exceeding the maximum size are
    divided into overlapping crops that are processed separately and then combined. This allows processing
    of very high-resolution images that exceed the model's input size limits.
max_image_size (`int`, *optional*, defaults to `980`):
    Maximum image size (in pixels) for a single image crop. Images larger than this will be split into
    multiple crops when `split_image=True`, or resized if splitting is disabled. This parameter controls
    the maximum resolution of individual image patches processed by the model.
min_image_size (`int`, *optional*):
    Minimum image size (in pixels) for a single image crop. Images smaller than this will be upscaled to
    meet the minimum requirement. If not specified, images are processed at their original size (subject
    to the maximum size constraint).
c                ó>   <€ V ^8„  d   Qh/ S[ ;R&   S[;R&   S[;R&   # )é   Úsplit_imageÚmax_image_sizeÚmin_image_size)ÚboolÚint)ÚformatÚ__classdict__s   "€Úi/home/luca/screen-checking/.venv/lib/python3.14/site-packages/transformers/models/aria/processing_aria.pyÚ__annotate__ÚAriaImagesKwargs.__annotate__   s,   ø‡ ‚ ñ  Ññ! ñ" Ññ# ñ$ Ñò% ó    © N)Ú__name__Ú
__module__Ú__qualname__Ú__firstlineno__Ú__doc__Ú__annotate_func__Ú__static_attributes__Ú__classdictcell__©r   s   @r   r   r      s   ø‡ € ñ÷ ƒ r   r   F)Útotalc                   ó`   a € ] tR t^.t o RRRRR/RRRRR/R	]P
                  /tV 3R
 ltRtV t	R# )ÚAriaProcessorKwargsÚtext_kwargsÚpaddingFÚreturn_mm_token_type_idsÚimages_kwargsr   éÔ  r   Úreturn_tensorsc                ó&   <€ V ^8„  d   Qh/ S[ ;R&   # )r   r)   )r   )r   r   s   "€r   r   Ú AriaProcessorKwargs.__annotate__.   s   ø‡ ‚ Ù#Ñ#ò r   r   N)
r   r   r   r   r   ÚPYTORCHÚ	_defaultsr   r    r!   r"   s   @r   r%   r%   .   sH   ø‡ € ð 	Ø�uØ&¨ð
ð 	Ø˜cØ˜5ð
ð 	˜*×,Ñ,ð
€I÷ ƒ r   r%   c                   ó~   a a€ ] tR t^>t o]tR	V3R lV 3R llltV3R lR ltR
R lt]	V3R lR l4       t
RtVtV ;t# )ÚAriaProcessorc                ó~   <€ V ^8„  d   QhRS[ S[,          RS[R,          RS[S[S[,          S[3,          R,          /# )r   Ú	tokenizerÚchat_templateNÚsize_conversion)r	   ÚstrÚdictÚfloatr   )r   r   s   "€r   r   ÚAriaProcessor.__annotate__B   sL   ø€ ÷ Rñ Rñ !¡3Õ&ðRñ ˜T•zð	Rñ
 ™e¡c�k©3Ð.Õ/°$Õ6ñRr   c                ó:  <€ Vf   R^€RR/pVP                  4        UUu/ uF  w  rV\        V4      VbK  	  uppV n        VP                  V n        VP                  V n        Ve    VP
                  f   VP                  Vn        \        SV `!  WVR7       R# u uppi )z`
size_conversion (`Dict`, *optional*):
    A dictionary indicating size conversions for images.
Niê  r*   é   )r4   )	Úitemsr   r5   Úimage_tokenÚimage_token_idÚ	pad_tokenÚ	unk_tokenÚsuperÚ__init__)ÚselfÚimage_processorr3   r4   r5   ÚkÚvÚ	__class__s   &&&&&  €r   rB   ÚAriaProcessor.__init__B   s˜   ø€ ð Ò"Ø" C¨¨cÐ2ˆOØ6E×6KÑ6KÔ6MÔNÑ6M©d¨a¤ A£¨¢	Ñ6MÒNˆÔà$×0Ñ0ˆÔØ'×6Ñ6ˆÔØÒ  Y×%8Ñ%8Ò%@Ø"+×"5Ñ"5ˆIÔä‰Ñ˜À=ÐÖQùó  Os   ŸBc                ó,   <€ V ^8„  d   QhRS[ RS[RS[/# )r   Úimage_inputsÚ	image_idxÚreturn)r7   r   r6   )r   r   s   "€r   r   r9   X   s#   ø€ ÷ 3ñ 3±ð 3Áð 3ÑSVñ 3r   c                óž   € V P                   VR ,          P                  ^,          ,          pVR,          V,          pV P                  V,          # )Úpixel_valuesÚ	num_crops)r5   Úshaper=   )rC   rJ   rK   ÚkwargsÚtokens_per_imageÚnum_image_tokenss   &&&,  r   Úreplace_image_tokenÚ!AriaProcessor.replace_image_tokenX   sG   € Ø×/Ñ/°¸^Õ0L×0RÑ0RÐSTÕ0UÕVÐØ'¨Õ4Ð7GÕGÐØ×ÑÐ"2Õ2Ð2r   c                óÐ  € / pVeÍ   \         P                  P                  R/ 4      pVP                  V4       VP                  RR4      ;'       g    V P                  P
                  pV Uu. uF"  pV P                  P                  ! . VOVN5!  NK$  	  ppV Uu. uF  q€P                  V,          V,          NK  	  p	pVP                  RV	RV/4       \        R/ VB # u upi u upi )ay  
Computes the number of placeholder tokens needed for multimodal inputs with the given sizes.
Args:
    image_sizes (`list[list[int]]`, *optional*):
        The input sizes formatted as (height, width) per each image.
Returns:
    `MultiModalData`: A `MultiModalData` object holding number of tokens per each of the provided
    input modalities, along with other useful data.
Nr)   r   rS   Únum_image_patchesr   )	r%   r/   ÚgetÚupdaterD   r   Úget_number_of_image_patchesr5   r   )
rC   Úimage_sizesrQ   Úvision_datar)   Úmax_sizeÚ
image_sizerW   Únum_patchesrS   s
   &&,       r   Ú_get_num_multimodal_tokensÚ(AriaProcessor._get_num_multimodal_tokens]   sø   € ð ˆØÒ"Ü/×9Ñ9×=Ñ=¸oÈrÓRˆMØ× Ñ  Ô(à$×(Ñ(Ð)9¸4Ó@×gÐgÀD×DXÑDX×DgÑDgˆHñ #.ó!á"-�Jð ×$Ñ$×@Ò@Ð\À*Ð\ÈmÖ\Ù"-ð ð !ñ arÓrÑ`qÐQ\× 4Ñ 4°XÕ >À× LÐ LÑ`qÐÐrØ×ÑÐ 2Ð4DÐFYÐ[lÐmÔnäÑ, Ñ,Ð,ùò!ùò  ss   Á,(CÂ"C#c                ó0   <€ V ^8„  d   QhRS[ S[,          /# )r   rL   )Úlistr6   )r   r   s   "€r   r   r9   x   s   ø€ ÷ ñ ¡D©¥Iñ r   c                ó   € R .# )rO   r   )rC   s   &r   Úunused_input_namesÚ AriaProcessor.unused_input_namesw   s
   € àˆ}Ðr   )r=   r>   r5   )NNNN)N)r   r   r   r   r%   Úvalid_processor_kwargsrB   rT   r`   Úpropertyre   r    r!   Ú__classcell__)rG   r   s   @@r   r1   r1   >   s?   ù‡ € à0Ð÷Rõ R÷,3ð 3ô
-ð4 ÷ó ÷ð r   r1   N)Úprocessing_utilsr   r   r   r   Úutilsr   r   Úautor	   r   r%   r1   Ú__all__r   r   r   Ú<module>rn      sW   ð÷( _Ó ^ß /Ý  ô�|¨5õ ô*Ð*°%õ ð  ô:�Nó :ó ð:ðz Ð
‚r   